Solaris.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  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. #ifndef LLVM_SUPPORT_SOLARIS_H
  14. #define LLVM_SUPPORT_SOLARIS_H
  15. #include <sys/types.h>
  16. #include <sys/regset.h>
  17. /* Solaris doesn't have endian.h. SPARC is the only supported big-endian ISA. */
  18. #define BIG_ENDIAN 4321
  19. #define LITTLE_ENDIAN 1234
  20. #if defined(__sparc) || defined(__sparc__)
  21. #define BYTE_ORDER BIG_ENDIAN
  22. #else
  23. #define BYTE_ORDER LITTLE_ENDIAN
  24. #endif
  25. #undef CS
  26. #undef DS
  27. #undef ES
  28. #undef FS
  29. #undef GS
  30. #undef SS
  31. #undef EAX
  32. #undef ECX
  33. #undef EDX
  34. #undef EBX
  35. #undef ESP
  36. #undef EBP
  37. #undef ESI
  38. #undef EDI
  39. #undef EIP
  40. #undef UESP
  41. #undef EFL
  42. #undef ERR
  43. #undef TRAPNO
  44. #endif