_win95.cfg 8.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322
  1. /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
  2. /* This Source Code Form is subject to the terms of the Mozilla Public
  3. * License, v. 2.0. If a copy of the MPL was not distributed with this
  4. * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
  5. #ifndef nspr_cpucfg___
  6. #define nspr_cpucfg___
  7. #ifndef XP_PC
  8. #define XP_PC
  9. #endif
  10. #ifndef WIN32
  11. #define WIN32
  12. #endif
  13. #ifndef WIN95
  14. #define WIN95
  15. #endif
  16. #define PR_AF_INET6 23 /* same as AF_INET6 */
  17. #if defined(_M_IX86) || defined(_X86_)
  18. #define IS_LITTLE_ENDIAN 1
  19. #undef IS_BIG_ENDIAN
  20. #define PR_BYTES_PER_BYTE 1
  21. #define PR_BYTES_PER_SHORT 2
  22. #define PR_BYTES_PER_INT 4
  23. #define PR_BYTES_PER_INT64 8
  24. #define PR_BYTES_PER_LONG 4
  25. #define PR_BYTES_PER_FLOAT 4
  26. #define PR_BYTES_PER_WORD 4
  27. #define PR_BYTES_PER_DWORD 8
  28. #define PR_BYTES_PER_DOUBLE 8
  29. #define PR_BITS_PER_BYTE 8
  30. #define PR_BITS_PER_SHORT 16
  31. #define PR_BITS_PER_INT 32
  32. #define PR_BITS_PER_INT64 64
  33. #define PR_BITS_PER_LONG 32
  34. #define PR_BITS_PER_FLOAT 32
  35. #define PR_BITS_PER_WORD 32
  36. #define PR_BITS_PER_DWORD 64
  37. #define PR_BITS_PER_DOUBLE 64
  38. #define PR_BITS_PER_BYTE_LOG2 3
  39. #define PR_BITS_PER_SHORT_LOG2 4
  40. #define PR_BITS_PER_INT_LOG2 5
  41. #define PR_BITS_PER_INT64_LOG2 6
  42. #define PR_BITS_PER_LONG_LOG2 5
  43. #define PR_BITS_PER_FLOAT_LOG2 5
  44. #define PR_BITS_PER_WORD_LOG2 5
  45. #define PR_BITS_PER_DWORD_LOG2 6
  46. #define PR_BITS_PER_DOUBLE_LOG2 6
  47. #define PR_ALIGN_OF_SHORT 2
  48. #define PR_ALIGN_OF_INT 4
  49. #define PR_ALIGN_OF_LONG 4
  50. #define PR_ALIGN_OF_INT64 8
  51. #define PR_ALIGN_OF_FLOAT 4
  52. #define PR_ALIGN_OF_WORD 4
  53. #define PR_ALIGN_OF_DWORD 8
  54. #define PR_ALIGN_OF_DOUBLE 4
  55. #define PR_ALIGN_OF_POINTER 4
  56. #define PR_BYTES_PER_WORD_LOG2 2
  57. #define PR_BYTES_PER_DWORD_LOG2 3
  58. #elif defined(_M_X64) || defined(_M_AMD64) || defined(_AMD64_)
  59. #define IS_LITTLE_ENDIAN 1
  60. #undef IS_BIG_ENDIAN
  61. #define IS_64
  62. #define PR_BYTES_PER_BYTE 1
  63. #define PR_BYTES_PER_SHORT 2
  64. #define PR_BYTES_PER_INT 4
  65. #define PR_BYTES_PER_INT64 8
  66. #define PR_BYTES_PER_LONG 4
  67. #define PR_BYTES_PER_FLOAT 4
  68. #define PR_BYTES_PER_WORD 8
  69. #define PR_BYTES_PER_DWORD 8
  70. #define PR_BYTES_PER_DOUBLE 8
  71. #define PR_BITS_PER_BYTE 8
  72. #define PR_BITS_PER_SHORT 16
  73. #define PR_BITS_PER_INT 32
  74. #define PR_BITS_PER_INT64 64
  75. #define PR_BITS_PER_LONG 32
  76. #define PR_BITS_PER_FLOAT 32
  77. #define PR_BITS_PER_WORD 64
  78. #define PR_BITS_PER_DWORD 64
  79. #define PR_BITS_PER_DOUBLE 64
  80. #define PR_BITS_PER_BYTE_LOG2 3
  81. #define PR_BITS_PER_SHORT_LOG2 4
  82. #define PR_BITS_PER_INT_LOG2 5
  83. #define PR_BITS_PER_INT64_LOG2 6
  84. #define PR_BITS_PER_LONG_LOG2 5
  85. #define PR_BITS_PER_FLOAT_LOG2 5
  86. #define PR_BITS_PER_WORD_LOG2 6
  87. #define PR_BITS_PER_DWORD_LOG2 6
  88. #define PR_BITS_PER_DOUBLE_LOG2 6
  89. #define PR_ALIGN_OF_SHORT 2
  90. #define PR_ALIGN_OF_INT 4
  91. #define PR_ALIGN_OF_LONG 4
  92. #define PR_ALIGN_OF_INT64 8
  93. #define PR_ALIGN_OF_FLOAT 4
  94. #define PR_ALIGN_OF_WORD 8
  95. #define PR_ALIGN_OF_DWORD 8
  96. #define PR_ALIGN_OF_DOUBLE 8
  97. #define PR_ALIGN_OF_POINTER 8
  98. #define PR_BYTES_PER_WORD_LOG2 3
  99. #define PR_BYTES_PER_DWORD_LOG2 3
  100. #elif defined(_M_IA64) || defined(_IA64_)
  101. #define IS_LITTLE_ENDIAN 1
  102. #undef IS_BIG_ENDIAN
  103. #define IS_64
  104. #define PR_BYTES_PER_BYTE 1
  105. #define PR_BYTES_PER_SHORT 2
  106. #define PR_BYTES_PER_INT 4
  107. #define PR_BYTES_PER_INT64 8
  108. #define PR_BYTES_PER_LONG 4
  109. #define PR_BYTES_PER_FLOAT 4
  110. #define PR_BYTES_PER_WORD 8
  111. #define PR_BYTES_PER_DWORD 8
  112. #define PR_BYTES_PER_DOUBLE 8
  113. #define PR_BITS_PER_BYTE 8
  114. #define PR_BITS_PER_SHORT 16
  115. #define PR_BITS_PER_INT 32
  116. #define PR_BITS_PER_INT64 64
  117. #define PR_BITS_PER_LONG 32
  118. #define PR_BITS_PER_FLOAT 32
  119. #define PR_BITS_PER_WORD 64
  120. #define PR_BITS_PER_DWORD 64
  121. #define PR_BITS_PER_DOUBLE 64
  122. #define PR_BITS_PER_BYTE_LOG2 3
  123. #define PR_BITS_PER_SHORT_LOG2 4
  124. #define PR_BITS_PER_INT_LOG2 5
  125. #define PR_BITS_PER_INT64_LOG2 6
  126. #define PR_BITS_PER_LONG_LOG2 5
  127. #define PR_BITS_PER_FLOAT_LOG2 5
  128. #define PR_BITS_PER_WORD_LOG2 6
  129. #define PR_BITS_PER_DWORD_LOG2 6
  130. #define PR_BITS_PER_DOUBLE_LOG2 6
  131. #define PR_ALIGN_OF_SHORT 2
  132. #define PR_ALIGN_OF_INT 4
  133. #define PR_ALIGN_OF_LONG 4
  134. #define PR_ALIGN_OF_INT64 8
  135. #define PR_ALIGN_OF_FLOAT 4
  136. #define PR_ALIGN_OF_WORD 8
  137. #define PR_ALIGN_OF_DWORD 8
  138. #define PR_ALIGN_OF_DOUBLE 8
  139. #define PR_ALIGN_OF_POINTER 8
  140. #define PR_BYTES_PER_WORD_LOG2 3
  141. #define PR_BYTES_PER_DWORD_LOG2 3
  142. #elif defined(_M_ARM) || defined(_ARM_)
  143. #define IS_LITTLE_ENDIAN 1
  144. #undef IS_BIG_ENDIAN
  145. #define PR_BYTES_PER_BYTE 1
  146. #define PR_BYTES_PER_SHORT 2
  147. #define PR_BYTES_PER_INT 4
  148. #define PR_BYTES_PER_INT64 8
  149. #define PR_BYTES_PER_LONG 4
  150. #define PR_BYTES_PER_FLOAT 4
  151. #define PR_BYTES_PER_WORD 4
  152. #define PR_BYTES_PER_DWORD 8
  153. #define PR_BYTES_PER_DOUBLE 8
  154. #define PR_BITS_PER_BYTE 8
  155. #define PR_BITS_PER_SHORT 16
  156. #define PR_BITS_PER_INT 32
  157. #define PR_BITS_PER_INT64 64
  158. #define PR_BITS_PER_LONG 32
  159. #define PR_BITS_PER_FLOAT 32
  160. #define PR_BITS_PER_WORD 32
  161. #define PR_BITS_PER_DWORD 64
  162. #define PR_BITS_PER_DOUBLE 64
  163. #define PR_BITS_PER_BYTE_LOG2 3
  164. #define PR_BITS_PER_SHORT_LOG2 4
  165. #define PR_BITS_PER_INT_LOG2 5
  166. #define PR_BITS_PER_INT64_LOG2 6
  167. #define PR_BITS_PER_LONG_LOG2 5
  168. #define PR_BITS_PER_FLOAT_LOG2 5
  169. #define PR_BITS_PER_WORD_LOG2 5
  170. #define PR_BITS_PER_DWORD_LOG2 6
  171. #define PR_BITS_PER_DOUBLE_LOG2 6
  172. #define PR_ALIGN_OF_SHORT 2
  173. #define PR_ALIGN_OF_INT 4
  174. #define PR_ALIGN_OF_LONG 4
  175. #define PR_ALIGN_OF_INT64 8
  176. #define PR_ALIGN_OF_FLOAT 4
  177. #define PR_ALIGN_OF_WORD 4
  178. #define PR_ALIGN_OF_DWORD 8
  179. #define PR_ALIGN_OF_DOUBLE 8
  180. #define PR_ALIGN_OF_POINTER 4
  181. #define PR_BYTES_PER_WORD_LOG2 2
  182. #define PR_BYTES_PER_DWORD_LOG2 3
  183. #elif defined(_M_ARM64) || defined(_ARM64_)
  184. #define IS_LITTLE_ENDIAN 1
  185. #undef IS_BIG_ENDIAN
  186. #define IS_64
  187. #define PR_BYTES_PER_BYTE 1
  188. #define PR_BYTES_PER_SHORT 2
  189. #define PR_BYTES_PER_INT 4
  190. #define PR_BYTES_PER_INT64 8
  191. #define PR_BYTES_PER_LONG 4
  192. #define PR_BYTES_PER_FLOAT 4
  193. #define PR_BYTES_PER_WORD 8
  194. #define PR_BYTES_PER_DWORD 8
  195. #define PR_BYTES_PER_DOUBLE 8
  196. #define PR_BITS_PER_BYTE 8
  197. #define PR_BITS_PER_SHORT 16
  198. #define PR_BITS_PER_INT 32
  199. #define PR_BITS_PER_INT64 64
  200. #define PR_BITS_PER_LONG 32
  201. #define PR_BITS_PER_FLOAT 32
  202. #define PR_BITS_PER_WORD 64
  203. #define PR_BITS_PER_DWORD 64
  204. #define PR_BITS_PER_DOUBLE 64
  205. #define PR_BITS_PER_BYTE_LOG2 3
  206. #define PR_BITS_PER_SHORT_LOG2 4
  207. #define PR_BITS_PER_INT_LOG2 5
  208. #define PR_BITS_PER_INT64_LOG2 6
  209. #define PR_BITS_PER_LONG_LOG2 5
  210. #define PR_BITS_PER_FLOAT_LOG2 5
  211. #define PR_BITS_PER_WORD_LOG2 6
  212. #define PR_BITS_PER_DWORD_LOG2 6
  213. #define PR_BITS_PER_DOUBLE_LOG2 6
  214. #define PR_ALIGN_OF_SHORT 2
  215. #define PR_ALIGN_OF_INT 4
  216. #define PR_ALIGN_OF_LONG 4
  217. #define PR_ALIGN_OF_INT64 8
  218. #define PR_ALIGN_OF_FLOAT 4
  219. #define PR_ALIGN_OF_WORD 8
  220. #define PR_ALIGN_OF_DWORD 8
  221. #define PR_ALIGN_OF_DOUBLE 8
  222. #define PR_ALIGN_OF_POINTER 8
  223. #define PR_BYTES_PER_WORD_LOG2 3
  224. #define PR_BYTES_PER_DWORD_LOG2 3
  225. #else /* defined(_M_IX86) || defined(_X86_) */
  226. #error unknown processor architecture
  227. #endif /* defined(_M_IX86) || defined(_X86_) */
  228. #ifndef HAVE_LONG_LONG
  229. #define HAVE_LONG_LONG
  230. #endif
  231. #ifndef NO_NSPR_10_SUPPORT
  232. #define BYTES_PER_BYTE PR_BYTES_PER_BYTE
  233. #define BYTES_PER_SHORT PR_BYTES_PER_SHORT
  234. #define BYTES_PER_INT PR_BYTES_PER_INT
  235. #define BYTES_PER_INT64 PR_BYTES_PER_INT64
  236. #define BYTES_PER_LONG PR_BYTES_PER_LONG
  237. #define BYTES_PER_FLOAT PR_BYTES_PER_FLOAT
  238. #define BYTES_PER_DOUBLE PR_BYTES_PER_DOUBLE
  239. #define BYTES_PER_WORD PR_BYTES_PER_WORD
  240. #define BYTES_PER_DWORD PR_BYTES_PER_DWORD
  241. #define BITS_PER_BYTE PR_BITS_PER_BYTE
  242. #define BITS_PER_SHORT PR_BITS_PER_SHORT
  243. #define BITS_PER_INT PR_BITS_PER_INT
  244. #define BITS_PER_INT64 PR_BITS_PER_INT64
  245. #define BITS_PER_LONG PR_BITS_PER_LONG
  246. #define BITS_PER_FLOAT PR_BITS_PER_FLOAT
  247. #define BITS_PER_DOUBLE PR_BITS_PER_DOUBLE
  248. #define BITS_PER_WORD PR_BITS_PER_WORD
  249. #define BITS_PER_BYTE_LOG2 PR_BITS_PER_BYTE_LOG2
  250. #define BITS_PER_SHORT_LOG2 PR_BITS_PER_SHORT_LOG2
  251. #define BITS_PER_INT_LOG2 PR_BITS_PER_INT_LOG2
  252. #define BITS_PER_INT64_LOG2 PR_BITS_PER_INT64_LOG2
  253. #define BITS_PER_LONG_LOG2 PR_BITS_PER_LONG_LOG2
  254. #define BITS_PER_FLOAT_LOG2 PR_BITS_PER_FLOAT_LOG2
  255. #define BITS_PER_DOUBLE_LOG2 PR_BITS_PER_DOUBLE_LOG2
  256. #define BITS_PER_WORD_LOG2 PR_BITS_PER_WORD_LOG2
  257. #define ALIGN_OF_SHORT PR_ALIGN_OF_SHORT
  258. #define ALIGN_OF_INT PR_ALIGN_OF_INT
  259. #define ALIGN_OF_LONG PR_ALIGN_OF_LONG
  260. #define ALIGN_OF_INT64 PR_ALIGN_OF_INT64
  261. #define ALIGN_OF_FLOAT PR_ALIGN_OF_FLOAT
  262. #define ALIGN_OF_DOUBLE PR_ALIGN_OF_DOUBLE
  263. #define ALIGN_OF_POINTER PR_ALIGN_OF_POINTER
  264. #define ALIGN_OF_WORD PR_ALIGN_OF_WORD
  265. #define BYTES_PER_WORD_LOG2 PR_BYTES_PER_WORD_LOG2
  266. #define BYTES_PER_DWORD_LOG2 PR_BYTES_PER_DWORD_LOG2
  267. #define WORDS_PER_DWORD_LOG2 PR_WORDS_PER_DWORD_LOG2
  268. #endif /* NO_NSPR_10_SUPPORT */
  269. #endif /* nspr_cpucfg___ */