The Design and Implementation of the FreeBSD Operating System, Second Edition
Now available: The Design and Implementation of the FreeBSD Operating System (Second Edition)


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]

FreeBSD/Linux Kernel Cross Reference
sys/i386/include/_stdint.h

Version: -  FREEBSD  -  FREEBSD-12-STABLE  -  FREEBSD-12-0  -  FREEBSD-11-STABLE  -  FREEBSD-11-2  -  FREEBSD-11-1  -  FREEBSD-11-0  -  FREEBSD-10-STABLE  -  FREEBSD-10-4  -  FREEBSD-10-3  -  FREEBSD-10-2  -  FREEBSD-10-1  -  FREEBSD-10-0  -  FREEBSD-9-STABLE  -  FREEBSD-9-3  -  FREEBSD-9-2  -  FREEBSD-9-1  -  FREEBSD-9-0  -  FREEBSD-8-STABLE  -  FREEBSD-8-4  -  FREEBSD-8-3  -  FREEBSD-8-2  -  FREEBSD-8-1  -  FREEBSD-8-0  -  FREEBSD-7-STABLE  -  FREEBSD-7-4  -  FREEBSD-7-3  -  FREEBSD-7-2  -  FREEBSD-7-1  -  FREEBSD-7-0  -  FREEBSD-6-STABLE  -  FREEBSD-6-4  -  FREEBSD-6-3  -  FREEBSD-6-2  -  FREEBSD-6-1  -  FREEBSD-6-0  -  FREEBSD-5-STABLE  -  FREEBSD-5-5  -  FREEBSD-5-4  -  FREEBSD-5-3  -  FREEBSD-5-2  -  FREEBSD-5-1  -  FREEBSD-5-0  -  FREEBSD-4-STABLE  -  FREEBSD-3-STABLE  -  FREEBSD22  -  linux-2.6  -  linux-2.4.22  -  MK83  -  MK84  -  PLAN9  -  DFBSD  -  NETBSD  -  NETBSD5  -  NETBSD4  -  NETBSD3  -  NETBSD20  -  OPENBSD  -  xnu-517  -  xnu-792  -  xnu-792.6.70  -  xnu-1228  -  xnu-1456.1.26  -  xnu-1699.24.8  -  xnu-2050.18.24  -  OPENSOLARIS  -  minix-3-1-1 
SearchContext: -  none  -  3  -  10 

    1 /*-
    2  * Copyright (c) 2001, 2002 Mike Barcroft <mike@FreeBSD.org>
    3  * Copyright (c) 2001 The NetBSD Foundation, Inc.
    4  * All rights reserved.
    5  *
    6  * This code is derived from software contributed to The NetBSD Foundation
    7  * by Klaus Klein.
    8  *
    9  * Redistribution and use in source and binary forms, with or without
   10  * modification, are permitted provided that the following conditions
   11  * are met:
   12  * 1. Redistributions of source code must retain the above copyright
   13  *    notice, this list of conditions and the following disclaimer.
   14  * 2. Redistributions in binary form must reproduce the above copyright
   15  *    notice, this list of conditions and the following disclaimer in the
   16  *    documentation and/or other materials provided with the distribution.
   17  * 3. All advertising materials mentioning features or use of this software
   18  *    must display the following acknowledgement:
   19  *        This product includes software developed by the NetBSD
   20  *        Foundation, Inc. and its contributors.
   21  * 4. Neither the name of The NetBSD Foundation nor the names of its
   22  *    contributors may be used to endorse or promote products derived
   23  *    from this software without specific prior written permission.
   24  *
   25  * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
   26  * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
   27  * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
   28  * PURPOSE ARE DISCLAIMED.  IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
   29  * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
   30  * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
   31  * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
   32  * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
   33  * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
   34  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
   35  * POSSIBILITY OF SUCH DAMAGE.
   36  *
   37  * $FreeBSD: releng/9.1/sys/i386/include/_stdint.h 217147 2011-01-08 12:43:05Z tijl $
   38  */
   39 
   40 #ifndef _MACHINE__STDINT_H_
   41 #define _MACHINE__STDINT_H_
   42 
   43 #if !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS)
   44 
   45 #define INT8_C(c)               (c)
   46 #define INT16_C(c)              (c)
   47 #define INT32_C(c)              (c)
   48 #define INT64_C(c)              (c ## LL)
   49 
   50 #define UINT8_C(c)              (c)
   51 #define UINT16_C(c)             (c)
   52 #define UINT32_C(c)             (c ## U)
   53 #define UINT64_C(c)             (c ## ULL)
   54 
   55 #define INTMAX_C(c)             INT64_C(c)
   56 #define UINTMAX_C(c)            UINT64_C(c)
   57 
   58 #endif /* !defined(__cplusplus) || defined(__STDC_CONSTANT_MACROS) */
   59 
   60 #if !defined(__cplusplus) || defined(__STDC_LIMIT_MACROS)
   61 
   62 /*
   63  * ISO/IEC 9899:1999
   64  * 7.18.2.1 Limits of exact-width integer types
   65  */
   66 /* Minimum values of exact-width signed integer types. */
   67 #define INT8_MIN        (-0x7f-1)
   68 #define INT16_MIN       (-0x7fff-1)
   69 #define INT32_MIN       (-0x7fffffff-1)
   70 #define INT64_MIN       (-0x7fffffffffffffffLL-1)
   71 
   72 /* Maximum values of exact-width signed integer types. */
   73 #define INT8_MAX        0x7f
   74 #define INT16_MAX       0x7fff
   75 #define INT32_MAX       0x7fffffff
   76 #define INT64_MAX       0x7fffffffffffffffLL
   77 
   78 /* Maximum values of exact-width unsigned integer types. */
   79 #define UINT8_MAX       0xff
   80 #define UINT16_MAX      0xffff
   81 #define UINT32_MAX      0xffffffffU
   82 #define UINT64_MAX      0xffffffffffffffffULL
   83 
   84 /*
   85  * ISO/IEC 9899:1999
   86  * 7.18.2.2  Limits of minimum-width integer types
   87  */
   88 /* Minimum values of minimum-width signed integer types. */
   89 #define INT_LEAST8_MIN  INT8_MIN
   90 #define INT_LEAST16_MIN INT16_MIN
   91 #define INT_LEAST32_MIN INT32_MIN
   92 #define INT_LEAST64_MIN INT64_MIN
   93 
   94 /* Maximum values of minimum-width signed integer types. */
   95 #define INT_LEAST8_MAX  INT8_MAX
   96 #define INT_LEAST16_MAX INT16_MAX
   97 #define INT_LEAST32_MAX INT32_MAX
   98 #define INT_LEAST64_MAX INT64_MAX
   99 
  100 /* Maximum values of minimum-width unsigned integer types. */
  101 #define UINT_LEAST8_MAX  UINT8_MAX
  102 #define UINT_LEAST16_MAX UINT16_MAX
  103 #define UINT_LEAST32_MAX UINT32_MAX
  104 #define UINT_LEAST64_MAX UINT64_MAX
  105 
  106 /*
  107  * ISO/IEC 9899:1999
  108  * 7.18.2.3  Limits of fastest minimum-width integer types
  109  */
  110 /* Minimum values of fastest minimum-width signed integer types. */
  111 #define INT_FAST8_MIN   INT32_MIN
  112 #define INT_FAST16_MIN  INT32_MIN
  113 #define INT_FAST32_MIN  INT32_MIN
  114 #define INT_FAST64_MIN  INT64_MIN
  115 
  116 /* Maximum values of fastest minimum-width signed integer types. */
  117 #define INT_FAST8_MAX   INT32_MAX
  118 #define INT_FAST16_MAX  INT32_MAX
  119 #define INT_FAST32_MAX  INT32_MAX
  120 #define INT_FAST64_MAX  INT64_MAX
  121 
  122 /* Maximum values of fastest minimum-width unsigned integer types. */
  123 #define UINT_FAST8_MAX  UINT32_MAX
  124 #define UINT_FAST16_MAX UINT32_MAX
  125 #define UINT_FAST32_MAX UINT32_MAX
  126 #define UINT_FAST64_MAX UINT64_MAX
  127 
  128 /*
  129  * ISO/IEC 9899:1999
  130  * 7.18.2.4  Limits of integer types capable of holding object pointers
  131  */
  132 #define INTPTR_MIN      INT32_MIN
  133 #define INTPTR_MAX      INT32_MAX
  134 #define UINTPTR_MAX     UINT32_MAX
  135 
  136 /*
  137  * ISO/IEC 9899:1999
  138  * 7.18.2.5  Limits of greatest-width integer types
  139  */
  140 #define INTMAX_MIN      INT64_MIN
  141 #define INTMAX_MAX      INT64_MAX
  142 #define UINTMAX_MAX     UINT64_MAX
  143 
  144 /*
  145  * ISO/IEC 9899:1999
  146  * 7.18.3  Limits of other integer types
  147  */
  148 /* Limits of ptrdiff_t. */
  149 #define PTRDIFF_MIN     INT32_MIN       
  150 #define PTRDIFF_MAX     INT32_MAX
  151 
  152 /* Limits of sig_atomic_t. */
  153 #define SIG_ATOMIC_MIN  INT32_MIN
  154 #define SIG_ATOMIC_MAX  INT32_MAX
  155 
  156 /* Limit of size_t. */
  157 #define SIZE_MAX        UINT32_MAX
  158 
  159 #ifndef WCHAR_MIN /* Also possibly defined in <wchar.h> */
  160 /* Limits of wchar_t. */
  161 #define WCHAR_MIN       INT32_MIN
  162 #define WCHAR_MAX       INT32_MAX
  163 #endif
  164 
  165 /* Limits of wint_t. */
  166 #define WINT_MIN        INT32_MIN
  167 #define WINT_MAX        INT32_MAX
  168 
  169 #endif /* !defined(__cplusplus) || defined(__STDC_LIMIT_MACROS) */
  170 
  171 #endif /* !_MACHINE__STDINT_H_ */

Cache object: efcbe32c5eb99557e61ed5c7057c9ef2


[ source navigation ] [ diff markup ] [ identifier search ] [ freetext search ] [ file search ] [ list types ] [ track identifier ]


This page is part of the FreeBSD/Linux Linux Kernel Cross-Reference, and was automatically generated using a modified version of the LXR engine.