v.out.h 3.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210
  1. /*
  2. * This file is part of the UCB release of Plan 9. It is subject to the license
  3. * terms in the LICENSE file found in the top-level directory of this
  4. * distribution and at http://akaros.cs.berkeley.edu/files/Plan9License. No
  5. * part of the UCB release of Plan 9, including this file, may be copied,
  6. * modified, propagated, or distributed except according to the terms contained
  7. * in the LICENSE file.
  8. */
  9. #define NSNAME 8
  10. #define NSYM 50
  11. #define NREG 32
  12. #define NOPROF (1<<0)
  13. #define DUPOK (1<<1)
  14. #define REGZERO 0
  15. #define REGRET 1
  16. #define REGARG 1
  17. /* compiler allocates R1 up as temps */
  18. /* compiler allocates register variables R3-R23 */
  19. #define REGEXT 25
  20. /* compiler allocates external registers R25 down */
  21. /* dont use R26 R27 */
  22. #define REGTMP 28
  23. #define REGSP 29
  24. #define REGSB 30
  25. #define REGLINK 31
  26. #define FREGRET 0
  27. /* compiler allocates register variables F4-F22 */
  28. /* compiler allocates external registers F22 down */
  29. #define FREGEXT 22
  30. #define FREGZERO 24 /* both float and double */
  31. #define FREGHALF 26 /* double */
  32. #define FREGONE 28 /* double */
  33. #define FREGTWO 30 /* double */
  34. enum as
  35. {
  36. AXXX,
  37. AABSD,
  38. AABSF,
  39. AABSW,
  40. AADD,
  41. AADDD,
  42. AADDF,
  43. AADDU,
  44. AADDW,
  45. AAND,
  46. ABEQ,
  47. ABFPF,
  48. ABFPT,
  49. ABGEZ,
  50. ABGEZAL,
  51. ABGTZ,
  52. ABLEZ,
  53. ABLTZ,
  54. ABLTZAL,
  55. ABNE,
  56. ABREAK,
  57. ACMPEQD,
  58. ACMPEQF,
  59. ACMPGED,
  60. ACMPGEF,
  61. ACMPGTD,
  62. ACMPGTF,
  63. ADATA,
  64. ADIV,
  65. ADIVD,
  66. ADIVF,
  67. ADIVU,
  68. ADIVW,
  69. AGLOBL,
  70. AGOK,
  71. AHISTORY,
  72. AJAL,
  73. AJMP,
  74. AMOVB,
  75. AMOVBU,
  76. AMOVD,
  77. AMOVDF,
  78. AMOVDW,
  79. AMOVF,
  80. AMOVFD,
  81. AMOVFW,
  82. AMOVH,
  83. AMOVHU,
  84. AMOVW,
  85. AMOVWD,
  86. AMOVWF,
  87. AMOVWL,
  88. AMOVWR,
  89. AMUL,
  90. AMULD,
  91. AMULF,
  92. AMULU,
  93. AMULW,
  94. ANAME,
  95. ANEGD,
  96. ANEGF,
  97. ANEGW,
  98. ANOP,
  99. ANOR,
  100. AOR,
  101. AREM,
  102. AREMU,
  103. ARET,
  104. ARFE,
  105. ASGT,
  106. ASGTU,
  107. ASLL,
  108. ASRA,
  109. ASRL,
  110. ASUB,
  111. ASUBD,
  112. ASUBF,
  113. ASUBU,
  114. ASUBW,
  115. ASYSCALL,
  116. ATEXT,
  117. ATLBP,
  118. ATLBR,
  119. ATLBWI,
  120. ATLBWR,
  121. AWORD,
  122. AXOR,
  123. AEND,
  124. AMOVV,
  125. AMOVVL,
  126. AMOVVR,
  127. ASLLV,
  128. ASRAV,
  129. ASRLV,
  130. ADIVV,
  131. ADIVVU,
  132. AREMV,
  133. AREMVU,
  134. AMULV,
  135. AMULVU,
  136. AADDV,
  137. AADDVU,
  138. ASUBV,
  139. ASUBVU,
  140. ADYNT,
  141. AINIT,
  142. ABCASE,
  143. ACASE,
  144. ATRUNCFV,
  145. ATRUNCDV,
  146. ATRUNCFW,
  147. ATRUNCDW,
  148. AMOVWU,
  149. AMOVFV,
  150. AMOVDV,
  151. AMOVVF,
  152. AMOVVD,
  153. ASIGNAME,
  154. ALAST,
  155. };
  156. /* type/name */
  157. #define D_GOK 0
  158. #define D_NONE 1
  159. /* type */
  160. #define D_BRANCH (D_NONE+1)
  161. #define D_OREG (D_NONE+2)
  162. #define D_EXTERN (D_NONE+3) /* name */
  163. #define D_STATIC (D_NONE+4) /* name */
  164. #define D_AUTO (D_NONE+5) /* name */
  165. #define D_PARAM (D_NONE+6) /* name */
  166. #define D_CONST (D_NONE+7)
  167. #define D_FCONST (D_NONE+8)
  168. #define D_SCONST (D_NONE+9)
  169. #define D_HI (D_NONE+10)
  170. #define D_LO (D_NONE+11)
  171. #define D_REG (D_NONE+12)
  172. #define D_FREG (D_NONE+13)
  173. #define D_FCREG (D_NONE+14)
  174. #define D_MREG (D_NONE+15)
  175. #define D_FILE (D_NONE+16)
  176. #define D_OCONST (D_NONE+17)
  177. #define D_FILE1 (D_NONE+18)
  178. #define D_VCONST (D_NONE+19)
  179. /*
  180. * this is the ranlib header
  181. */
  182. #define SYMDEF "__.SYMDEF"
  183. /*
  184. * this is the simulated IEEE floating point
  185. */
  186. typedef struct ieee Ieee;
  187. struct ieee
  188. {
  189. long l; /* contains ls-man 0xffffffff */
  190. long h; /* contains sign 0x80000000
  191. exp 0x7ff00000
  192. ms-man 0x000fffff */
  193. };