java-insns.h 4.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249
  1. // java-insns.h - Instruction encodings. This is -*- c++ -*-
  2. /* Copyright (C) 1999, 2001, 2002, 2006 Free Software Foundation
  3. This file is part of libgcj.
  4. This software is copyrighted work licensed under the terms of the
  5. Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
  6. details. */
  7. #ifndef __JAVA_INSNS_H__
  8. #define __JAVA_INSNS_H__
  9. enum java_opcode
  10. {
  11. op_nop = 0x00,
  12. op_aconst_null = 0x01,
  13. op_iconst_m1 = 0x02,
  14. op_iconst_0 = 0x03,
  15. op_iconst_1 = 0x04,
  16. op_iconst_2 = 0x05,
  17. op_iconst_3 = 0x06,
  18. op_iconst_4 = 0x07,
  19. op_iconst_5 = 0x08,
  20. op_lconst_0 = 0x09,
  21. op_lconst_1 = 0x0a,
  22. op_fconst_0 = 0x0b,
  23. op_fconst_1 = 0x0c,
  24. op_fconst_2 = 0x0d,
  25. op_dconst_0 = 0x0e,
  26. op_dconst_1 = 0x0f,
  27. op_bipush = 0x10,
  28. op_sipush = 0x11,
  29. op_ldc = 0x12,
  30. op_ldc_w = 0x13,
  31. op_ldc2_w = 0x14,
  32. op_iload = 0x15,
  33. op_lload = 0x16,
  34. op_fload = 0x17,
  35. op_dload = 0x18,
  36. op_aload = 0x19,
  37. op_iload_0 = 0x1a,
  38. op_iload_1 = 0x1b,
  39. op_iload_2 = 0x1c,
  40. op_iload_3 = 0x1d,
  41. op_lload_0 = 0x1e,
  42. op_lload_1 = 0x1f,
  43. op_lload_2 = 0x20,
  44. op_lload_3 = 0x21,
  45. op_fload_0 = 0x22,
  46. op_fload_1 = 0x23,
  47. op_fload_2 = 0x24,
  48. op_fload_3 = 0x25,
  49. op_dload_0 = 0x26,
  50. op_dload_1 = 0x27,
  51. op_dload_2 = 0x28,
  52. op_dload_3 = 0x29,
  53. op_aload_0 = 0x2a,
  54. op_aload_1 = 0x2b,
  55. op_aload_2 = 0x2c,
  56. op_aload_3 = 0x2d,
  57. op_iaload = 0x2e,
  58. op_laload = 0x2f,
  59. op_faload = 0x30,
  60. op_daload = 0x31,
  61. op_aaload = 0x32,
  62. op_baload = 0x33,
  63. op_caload = 0x34,
  64. op_saload = 0x35,
  65. op_istore = 0x36,
  66. op_lstore = 0x37,
  67. op_fstore = 0x38,
  68. op_dstore = 0x39,
  69. op_astore = 0x3a,
  70. op_istore_0 = 0x3b,
  71. op_istore_1 = 0x3c,
  72. op_istore_2 = 0x3d,
  73. op_istore_3 = 0x3e,
  74. op_lstore_0 = 0x3f,
  75. op_lstore_1 = 0x40,
  76. op_lstore_2 = 0x41,
  77. op_lstore_3 = 0x42,
  78. op_fstore_0 = 0x43,
  79. op_fstore_1 = 0x44,
  80. op_fstore_2 = 0x45,
  81. op_fstore_3 = 0x46,
  82. op_dstore_0 = 0x47,
  83. op_dstore_1 = 0x48,
  84. op_dstore_2 = 0x49,
  85. op_dstore_3 = 0x4a,
  86. op_astore_0 = 0x4b,
  87. op_astore_1 = 0x4c,
  88. op_astore_2 = 0x4d,
  89. op_astore_3 = 0x4e,
  90. op_iastore = 0x4f,
  91. op_lastore = 0x50,
  92. op_fastore = 0x51,
  93. op_dastore = 0x52,
  94. op_aastore = 0x53,
  95. op_bastore = 0x54,
  96. op_castore = 0x55,
  97. op_sastore = 0x56,
  98. op_pop = 0x57,
  99. op_pop2 = 0x58,
  100. op_dup = 0x59,
  101. op_dup_x1 = 0x5a,
  102. op_dup_x2 = 0x5b,
  103. op_dup2 = 0x5c,
  104. op_dup2_x1 = 0x5d,
  105. op_dup2_x2 = 0x5e,
  106. op_swap = 0x5f,
  107. op_iadd = 0x60,
  108. op_ladd = 0x61,
  109. op_fadd = 0x62,
  110. op_dadd = 0x63,
  111. op_isub = 0x64,
  112. op_lsub = 0x65,
  113. op_fsub = 0x66,
  114. op_dsub = 0x67,
  115. op_imul = 0x68,
  116. op_lmul = 0x69,
  117. op_fmul = 0x6a,
  118. op_dmul = 0x6b,
  119. op_idiv = 0x6c,
  120. op_ldiv = 0x6d,
  121. op_fdiv = 0x6e,
  122. op_ddiv = 0x6f,
  123. op_irem = 0x70,
  124. op_lrem = 0x71,
  125. op_frem = 0x72,
  126. op_drem = 0x73,
  127. op_ineg = 0x74,
  128. op_lneg = 0x75,
  129. op_fneg = 0x76,
  130. op_dneg = 0x77,
  131. op_ishl = 0x78,
  132. op_lshl = 0x79,
  133. op_ishr = 0x7a,
  134. op_lshr = 0x7b,
  135. op_iushr = 0x7c,
  136. op_lushr = 0x7d,
  137. op_iand = 0x7e,
  138. op_land = 0x7f,
  139. op_ior = 0x80,
  140. op_lor = 0x81,
  141. op_ixor = 0x82,
  142. op_lxor = 0x83,
  143. op_iinc = 0x84,
  144. op_i2l = 0x85,
  145. op_i2f = 0x86,
  146. op_i2d = 0x87,
  147. op_l2i = 0x88,
  148. op_l2f = 0x89,
  149. op_l2d = 0x8a,
  150. op_f2i = 0x8b,
  151. op_f2l = 0x8c,
  152. op_f2d = 0x8d,
  153. op_d2i = 0x8e,
  154. op_d2l = 0x8f,
  155. op_d2f = 0x90,
  156. op_i2b = 0x91,
  157. op_i2c = 0x92,
  158. op_i2s = 0x93,
  159. op_lcmp = 0x94,
  160. op_fcmpl = 0x95,
  161. op_fcmpg = 0x96,
  162. op_dcmpl = 0x97,
  163. op_dcmpg = 0x98,
  164. op_ifeq = 0x99,
  165. op_ifne = 0x9a,
  166. op_iflt = 0x9b,
  167. op_ifge = 0x9c,
  168. op_ifgt = 0x9d,
  169. op_ifle = 0x9e,
  170. op_if_icmpeq = 0x9f,
  171. op_if_icmpne = 0xa0,
  172. op_if_icmplt = 0xa1,
  173. op_if_icmpge = 0xa2,
  174. op_if_icmpgt = 0xa3,
  175. op_if_icmple = 0xa4,
  176. op_if_acmpeq = 0xa5,
  177. op_if_acmpne = 0xa6,
  178. op_goto = 0xa7,
  179. op_jsr = 0xa8,
  180. op_ret = 0xa9,
  181. op_tableswitch = 0xaa,
  182. op_lookupswitch = 0xab,
  183. op_ireturn = 0xac,
  184. op_lreturn = 0xad,
  185. op_freturn = 0xae,
  186. op_dreturn = 0xaf,
  187. op_areturn = 0xb0,
  188. op_return = 0xb1,
  189. op_getstatic = 0xb2,
  190. op_putstatic = 0xb3,
  191. op_getfield = 0xb4,
  192. op_putfield = 0xb5,
  193. op_invokevirtual = 0xb6,
  194. op_invokespecial = 0xb7,
  195. op_invokestatic = 0xb8,
  196. op_invokeinterface = 0xb9,
  197. op_breakpoint = 0xba,
  198. op_new = 0xbb,
  199. op_newarray = 0xbc,
  200. op_anewarray = 0xbd,
  201. op_arraylength = 0xbe,
  202. op_athrow = 0xbf,
  203. op_checkcast = 0xc0,
  204. op_instanceof = 0xc1,
  205. op_monitorenter = 0xc2,
  206. op_monitorexit = 0xc3,
  207. op_wide = 0xc4,
  208. op_multianewarray = 0xc5,
  209. op_ifnull = 0xc6,
  210. op_ifnonnull = 0xc7,
  211. op_goto_w = 0xc8,
  212. op_jsr_w = 0xc9,
  213. // new opcodes
  214. op_putfield_1 = 0xca,
  215. op_putfield_2 = 0xcb,
  216. op_putfield_4 = 0xcc,
  217. op_putfield_8 = 0xcd,
  218. op_putfield_a = 0xce,
  219. op_putstatic_1 = 0xcf,
  220. op_putstatic_2 = 0xd0,
  221. op_putstatic_4 = 0xd1,
  222. op_putstatic_8 = 0xd2,
  223. op_putstatic_a = 0xd3,
  224. op_getfield_1 = 0xd4,
  225. op_getfield_2s = 0xd5,
  226. op_getfield_2u = 0xd6,
  227. op_getfield_4 = 0xd7,
  228. op_getfield_8 = 0xd8,
  229. op_getfield_a = 0xd9,
  230. op_getstatic_1 = 0xda,
  231. op_getstatic_2s = 0xdb,
  232. op_getstatic_2u = 0xdc,
  233. op_getstatic_4 = 0xdd,
  234. op_getstatic_8 = 0xde,
  235. op_getstatic_a = 0xdf
  236. };
  237. #endif /* __JAVA_INSNS_H__ */