home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / nspr30-v.zip / nspr30-v / include / md / _win95.cfg < prev    next >
Text File  |  1998-07-21  |  5KB  |  180 lines

  1. /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /*
  3.  * The contents of this file are subject to the Netscape Public License
  4.  * Version 1.0 (the "NPL"); you may not use this file except in
  5.  * compliance with the NPL.  You may obtain a copy of the NPL at
  6.  * http://www.mozilla.org/NPL/
  7.  * 
  8.  * Software distributed under the NPL is distributed on an "AS IS" basis,
  9.  * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the NPL
  10.  * for the specific language governing rights and limitations under the
  11.  * NPL.
  12.  * 
  13.  * The Initial Developer of this code under the NPL is Netscape
  14.  * Communications Corporation.  Portions created by Netscape are
  15.  * Copyright (C) 1998 Netscape Communications Corporation.  All Rights
  16.  * Reserved.
  17.  */
  18.  
  19. #ifndef nspr_cpucfg___
  20. #define nspr_cpucfg___
  21.  
  22. #ifndef XP_PC
  23. #define XP_PC
  24. #endif
  25.  
  26. #ifndef WIN32
  27. #define WIN32
  28. #endif
  29.  
  30. #ifndef WIN95
  31. #define WIN95
  32. #endif
  33.  
  34. #if defined(_M_IX86) || defined(_X86_)
  35.  
  36. #define IS_LITTLE_ENDIAN 1
  37. #undef  IS_BIG_ENDIAN
  38.  
  39. #define PR_BYTES_PER_BYTE   1
  40. #define PR_BYTES_PER_SHORT  2
  41. #define PR_BYTES_PER_INT    4
  42. #define PR_BYTES_PER_INT64  8
  43. #define PR_BYTES_PER_LONG   4
  44. #define PR_BYTES_PER_FLOAT  4
  45. #define PR_BYTES_PER_WORD    4
  46. #define PR_BYTES_PER_DWORD    8
  47. #define PR_BYTES_PER_DOUBLE 8
  48.  
  49. #define PR_BITS_PER_BYTE    8
  50. #define PR_BITS_PER_SHORT   16
  51. #define PR_BITS_PER_INT     32
  52. #define PR_BITS_PER_INT64   64
  53. #define PR_BITS_PER_LONG    32
  54. #define PR_BITS_PER_FLOAT   32
  55. #define PR_BITS_PER_WORD    32
  56. #define PR_BITS_PER_DWORD    64
  57. #define PR_BITS_PER_DOUBLE  64
  58.  
  59. #define PR_BITS_PER_BYTE_LOG2   3
  60. #define PR_BITS_PER_SHORT_LOG2  4
  61. #define PR_BITS_PER_INT_LOG2    5
  62. #define PR_BITS_PER_INT64_LOG2  6
  63. #define PR_BITS_PER_LONG_LOG2   5
  64. #define PR_BITS_PER_FLOAT_LOG2  5
  65. #define PR_BITS_PER_WORD_LOG2    5
  66. #define PR_BITS_PER_DWORD_LOG2    6
  67. #define PR_BITS_PER_DOUBLE_LOG2 6
  68.  
  69. #define PR_ALIGN_OF_SHORT   2
  70. #define PR_ALIGN_OF_INT     4
  71. #define PR_ALIGN_OF_LONG    4
  72. #define PR_ALIGN_OF_INT64   8
  73. #define PR_ALIGN_OF_FLOAT   4
  74. #define PR_ALIGN_OF_WORD    4
  75. #define PR_ALIGN_OF_DWORD    8
  76. #define PR_ALIGN_OF_DOUBLE  4
  77. #define PR_ALIGN_OF_POINTER 4
  78.  
  79. #define PR_BYTES_PER_WORD_LOG2    2
  80. #define PR_BYTES_PER_DWORD_LOG2    2
  81.  
  82. #elif defined(_ALPHA_)
  83.  
  84. #define IS_LITTLE_ENDIAN 1
  85. #undef  IS_BIG_ENDIAN
  86.  
  87. #define PR_BYTES_PER_BYTE   1
  88. #define PR_BYTES_PER_SHORT  2
  89. #define PR_BYTES_PER_INT    4
  90. #define PR_BYTES_PER_INT64  8
  91. #define PR_BYTES_PER_LONG   4
  92. #define PR_BYTES_PER_FLOAT  4
  93. #define PR_BYTES_PER_DOUBLE 8
  94. #define PR_BYTES_PER_WORD   4
  95. #define PR_BYTES_PER_DWORD  8
  96.  
  97. #define PR_BITS_PER_BYTE    8
  98. #define PR_BITS_PER_SHORT   16
  99. #define PR_BITS_PER_INT     32
  100. #define PR_BITS_PER_INT64   64
  101. #define PR_BITS_PER_LONG    32
  102. #define PR_BITS_PER_FLOAT   32
  103. #define PR_BITS_PER_DOUBLE  64
  104. #define PR_BITS_PER_WORD    32
  105.  
  106. #define PR_BITS_PER_BYTE_LOG2   3
  107. #define PR_BITS_PER_SHORT_LOG2  4
  108. #define PR_BITS_PER_INT_LOG2    5
  109. #define PR_BITS_PER_INT64_LOG2  6
  110. #define PR_BITS_PER_LONG_LOG2   5
  111. #define PR_BITS_PER_FLOAT_LOG2  5
  112. #define PR_BITS_PER_DOUBLE_LOG2 6
  113. #define PR_BITS_PER_WORD_LOG2   5
  114.  
  115. #define PR_BYTES_PER_WORD_LOG2  2
  116. #define PR_BYTES_PER_DWORD_LOG2 3
  117.  
  118. #define PR_ALIGN_OF_SHORT   2
  119. #define PR_ALIGN_OF_INT     4
  120. #define PR_ALIGN_OF_LONG    4
  121. #define PR_ALIGN_OF_INT64   8
  122. #define PR_ALIGN_OF_FLOAT   4
  123. #define PR_ALIGN_OF_DOUBLE  8
  124. #define PR_ALIGN_OF_POINTER 4
  125.  
  126. #else /* defined(_M_IX86) || defined(_X86_) */
  127.  
  128. #error unknown processor architecture
  129.  
  130. #endif /* defined(_M_IX86) || defined(_X86_) */
  131.  
  132. #define HAVE_LONG_LONG
  133.  
  134. #ifndef NO_NSPR_10_SUPPORT
  135.  
  136. #define BYTES_PER_BYTE      PR_BYTES_PER_BYTE
  137. #define BYTES_PER_SHORT     PR_BYTES_PER_SHORT
  138. #define BYTES_PER_INT       PR_BYTES_PER_INT
  139. #define BYTES_PER_INT64     PR_BYTES_PER_INT64
  140. #define BYTES_PER_LONG      PR_BYTES_PER_LONG
  141. #define BYTES_PER_FLOAT     PR_BYTES_PER_FLOAT
  142. #define BYTES_PER_DOUBLE    PR_BYTES_PER_DOUBLE
  143. #define BYTES_PER_WORD      PR_BYTES_PER_WORD
  144. #define BYTES_PER_DWORD     PR_BYTES_PER_DWORD
  145.  
  146. #define BITS_PER_BYTE       PR_BITS_PER_BYTE
  147. #define BITS_PER_SHORT      PR_BITS_PER_SHORT
  148. #define BITS_PER_INT        PR_BITS_PER_INT
  149. #define BITS_PER_INT64      PR_BITS_PER_INT64
  150. #define BITS_PER_LONG       PR_BITS_PER_LONG
  151. #define BITS_PER_FLOAT      PR_BITS_PER_FLOAT
  152. #define BITS_PER_DOUBLE     PR_BITS_PER_DOUBLE
  153. #define BITS_PER_WORD       PR_BITS_PER_WORD
  154.  
  155. #define BITS_PER_BYTE_LOG2  PR_BITS_PER_BYTE_LOG2
  156. #define BITS_PER_SHORT_LOG2 PR_BITS_PER_SHORT_LOG2
  157. #define BITS_PER_INT_LOG2   PR_BITS_PER_INT_LOG2
  158. #define BITS_PER_INT64_LOG2 PR_BITS_PER_INT64_LOG2
  159. #define BITS_PER_LONG_LOG2  PR_BITS_PER_LONG_LOG2
  160. #define BITS_PER_FLOAT_LOG2 PR_BITS_PER_FLOAT_LOG2
  161. #define BITS_PER_DOUBLE_LOG2    PR_BITS_PER_DOUBLE_LOG2
  162. #define BITS_PER_WORD_LOG2  PR_BITS_PER_WORD_LOG2
  163.  
  164. #define ALIGN_OF_SHORT      PR_ALIGN_OF_SHORT
  165. #define ALIGN_OF_INT        PR_ALIGN_OF_INT
  166. #define ALIGN_OF_LONG       PR_ALIGN_OF_LONG
  167. #define ALIGN_OF_INT64      PR_ALIGN_OF_INT64
  168. #define ALIGN_OF_FLOAT      PR_ALIGN_OF_FLOAT
  169. #define ALIGN_OF_DOUBLE     PR_ALIGN_OF_DOUBLE
  170. #define ALIGN_OF_POINTER    PR_ALIGN_OF_POINTER
  171. #define ALIGN_OF_WORD       PR_ALIGN_OF_WORD
  172.  
  173. #define BYTES_PER_WORD_LOG2        PR_BYTES_PER_WORD_LOG2
  174. #define BYTES_PER_DWORD_LOG2    PR_BYTES_PER_DWORD_LOG2
  175. #define WORDS_PER_DWORD_LOG2    PR_WORDS_PER_DWORD_LOG2
  176.  
  177. #endif /* NO_NSPR_10_SUPPORT */
  178.  
  179. #endif /* nspr_cpucfg___ */
  180.