1 /*===- llvm/Support/Solaris.h ------------------------------------*- C++ -*-===* 2 * 3 * The LLVM Compiler Infrastructure 4 * 5 * This file is distributed under the University of Illinois Open Source 6 * License. See LICENSE.TXT for details. 7 * 8 *===----------------------------------------------------------------------===* 9 * 10 * This file contains portability fixes for Solaris hosts. 11 * 12 *===----------------------------------------------------------------------===*/ 13 14 #ifndef LLVM_SUPPORT_SOLARIS_H 15 #define LLVM_SUPPORT_SOLARIS_H 16 17 #include <sys/types.h> 18 #include <sys/regset.h> 19 20 /* Solaris doesn't have endian.h. SPARC is the only supported big-endian ISA. */ 21 #define BIG_ENDIAN 4321 22 #define LITTLE_ENDIAN 1234 23 #if defined(__sparc) || defined(__sparc__) 24 #define BYTE_ORDER BIG_ENDIAN 25 #else 26 #define BYTE_ORDER LITTLE_ENDIAN 27 #endif 28 29 #undef CS 30 #undef DS 31 #undef ES 32 #undef FS 33 #undef GS 34 #undef SS 35 #undef EAX 36 #undef ECX 37 #undef EDX 38 #undef EBX 39 #undef ESP 40 #undef EBP 41 #undef ESI 42 #undef EDI 43 #undef EIP 44 #undef UESP 45 #undef EFL 46 #undef ERR 47 #undef TRAPNO 48 49 #endif 50