1178172Simp/*- 2178172Simp * Copyright (c) 2002 Mike Barcroft <mike@FreeBSD.org> 3178172Simp * Copyright (c) 1990, 1993 4178172Simp * The Regents of the University of California. All rights reserved. 5178172Simp * 6178172Simp * Redistribution and use in source and binary forms, with or without 7178172Simp * modification, are permitted provided that the following conditions 8178172Simp * are met: 9178172Simp * 1. Redistributions of source code must retain the above copyright 10178172Simp * notice, this list of conditions and the following disclaimer. 11178172Simp * 2. Redistributions in binary form must reproduce the above copyright 12178172Simp * notice, this list of conditions and the following disclaimer in the 13178172Simp * documentation and/or other materials provided with the distribution. 14178172Simp * 3. All advertising materials mentioning features or use of this software 15178172Simp * must display the following acknowledgement: 16178172Simp * This product includes software developed by the University of 17178172Simp * California, Berkeley and its contributors. 18178172Simp * 4. Neither the name of the University nor the names of its contributors 19178172Simp * may be used to endorse or promote products derived from this software 20178172Simp * without specific prior written permission. 21178172Simp * 22178172Simp * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND 23178172Simp * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 24178172Simp * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 25178172Simp * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE 26178172Simp * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 27178172Simp * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 28178172Simp * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 29178172Simp * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30178172Simp * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 31178172Simp * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 32178172Simp * SUCH DAMAGE. 33178172Simp * 34178172Simp * From: @(#)ansi.h 8.2 (Berkeley) 1/4/94 35178172Simp * From: @(#)types.h 8.3 (Berkeley) 1/5/94 36178172Simp * from: src/sys/i386/include/_types.h,v 1.12 2005/07/02 23:13:31 thompsa 37178172Simp * $FreeBSD: stable/11/sys/mips/include/_types.h 332135 2018-04-06 19:17:59Z kevans $ 38178172Simp */ 39178172Simp 40178172Simp#ifndef _MACHINE__TYPES_H_ 41178172Simp#define _MACHINE__TYPES_H_ 42178172Simp 43178172Simp#ifndef _SYS_CDEFS_H_ 44178172Simp#error this file needs sys/cdefs.h as a prerequisite 45178172Simp#endif 46178172Simp 47178172Simp/* 48178172Simp * Basic types upon which most other types are built. 49178172Simp */ 50228469Sedtypedef signed char __int8_t; 51178172Simptypedef unsigned char __uint8_t; 52178172Simptypedef short __int16_t; 53178172Simptypedef unsigned short __uint16_t; 54178172Simptypedef int __int32_t; 55178172Simptypedef unsigned int __uint32_t; 56218266Stijl#ifdef __mips_n64 57178172Simptypedef long __int64_t; 58178172Simptypedef unsigned long __uint64_t; 59178172Simp#else 60217146Stijl#ifndef lint 61217146Stijl__extension__ 62217146Stijl#endif 63178172Simp/* LONGLONG */ 64178172Simptypedef long long __int64_t; 65217146Stijl#ifndef lint 66217146Stijl__extension__ 67217146Stijl#endif 68178172Simp/* LONGLONG */ 69178172Simptypedef unsigned long long __uint64_t; 70178172Simp#endif 71178172Simp 72178172Simp/* 73178172Simp * Standard type definitions. 74178172Simp */ 75178172Simptypedef __int32_t __clock_t; /* clock()... */ 76332135Skevans#ifndef _STANDALONE 77178172Simptypedef double __double_t; 78230229Sdastypedef float __float_t; 79332135Skevans#endif 80218266Stijl#ifdef __mips_n64 81217147Stijltypedef __int64_t __critical_t; 82178172Simptypedef __int64_t __intfptr_t; 83178172Simptypedef __int64_t __intptr_t; 84178172Simp#else 85217147Stijltypedef __int32_t __critical_t; 86178172Simptypedef __int32_t __intfptr_t; 87178172Simptypedef __int32_t __intptr_t; 88178172Simp#endif 89178172Simptypedef __int64_t __intmax_t; 90178172Simptypedef __int32_t __int_fast8_t; 91178172Simptypedef __int32_t __int_fast16_t; 92178172Simptypedef __int32_t __int_fast32_t; 93178172Simptypedef __int64_t __int_fast64_t; 94178172Simptypedef __int8_t __int_least8_t; 95178172Simptypedef __int16_t __int_least16_t; 96178172Simptypedef __int32_t __int_least32_t; 97178172Simptypedef __int64_t __int_least64_t; 98218266Stijl#if defined(__mips_n64) || defined(__mips_n32) 99178172Simptypedef __int64_t __register_t; 100178172Simptypedef __int64_t f_register_t; 101178172Simp#else 102178172Simptypedef __int32_t __register_t; 103178172Simptypedef __int32_t f_register_t; 104178172Simp#endif 105218266Stijl#ifdef __mips_n64 106178172Simptypedef __int64_t __ptrdiff_t; 107178172Simptypedef __int64_t __segsz_t; 108178172Simptypedef __uint64_t __size_t; 109178172Simptypedef __int64_t __ssize_t; 110178172Simptypedef __uint64_t __uintfptr_t; 111178172Simptypedef __uint64_t __uintptr_t; 112178172Simp#else 113178172Simptypedef __int32_t __ptrdiff_t; /* ptr1 - ptr2 */ 114178172Simptypedef __int32_t __segsz_t; /* segment size (in pages) */ 115178172Simptypedef __uint32_t __size_t; /* sizeof() */ 116178172Simptypedef __int32_t __ssize_t; /* byte count or error */ 117178172Simptypedef __uint32_t __uintfptr_t; 118178172Simptypedef __uint32_t __uintptr_t; 119178172Simp#endif 120178172Simptypedef __int64_t __time_t; /* time()... */ 121178172Simptypedef __uint64_t __uintmax_t; 122178172Simptypedef __uint32_t __uint_fast8_t; 123178172Simptypedef __uint32_t __uint_fast16_t; 124178172Simptypedef __uint32_t __uint_fast32_t; 125178172Simptypedef __uint64_t __uint_fast64_t; 126178172Simptypedef __uint8_t __uint_least8_t; 127178172Simptypedef __uint16_t __uint_least16_t; 128178172Simptypedef __uint32_t __uint_least32_t; 129178172Simptypedef __uint64_t __uint_least64_t; 130218266Stijl#if defined(__mips_n64) || defined(__mips_n32) 131178172Simptypedef __uint64_t __u_register_t; 132202031Simp#else 133202031Simptypedef __uint32_t __u_register_t; 134202031Simp#endif 135218266Stijl#ifdef __mips_n64 136178172Simptypedef __uint64_t __vm_offset_t; 137178172Simptypedef __uint64_t __vm_size_t; 138178172Simp#else 139178172Simptypedef __uint32_t __vm_offset_t; 140178172Simptypedef __uint32_t __vm_size_t; 141178172Simp#endif 142218266Stijl#if defined(__mips_n64) || defined(__mips_n32) /* PHYSADDR_64_BIT */ 143217354Sjchandratypedef __uint64_t __vm_paddr_t; 144217354Sjchandra#else 145217354Sjchandratypedef __uint32_t __vm_paddr_t; 146217354Sjchandra#endif 147217354Sjchandra 148263998Stijltypedef int ___wchar_t; 149178172Simp 150237517Sandrew#define __WCHAR_MIN __INT_MIN /* min value for a wchar_t */ 151237517Sandrew#define __WCHAR_MAX __INT_MAX /* max value for a wchar_t */ 152237517Sandrew 153178172Simp/* 154178172Simp * Unusual type definitions. 155178172Simp */ 156178172Simp#ifdef __GNUCLIKE_BUILTIN_VARARGS 157178172Simptypedef __builtin_va_list __va_list; /* internally known to gcc */ 158178172Simp#else 159178172Simptypedef char * __va_list; 160178172Simp#endif /* __GNUCLIKE_BUILTIN_VARARGS */ 161178172Simp#if defined(__GNUC_VA_LIST_COMPATIBILITY) && !defined(__GNUC_VA_LIST) \ 162178172Simp && !defined(__NO_GNUC_VA_LIST) 163178172Simp#define __GNUC_VA_LIST 164178172Simptypedef __va_list __gnuc_va_list; /* compatibility w/GNU headers*/ 165178172Simp#endif 166178172Simp 167178172Simp#endif /* !_MACHINE__TYPES_H_ */ 168