Home | History | Annotate | Download | only in libdex
      1 /*
      2  * Copyright (C) 2008 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13  * See the License for the specific language governing permissions and
     14  * limitations under the License.
     15  */
     16 
     17 /*
     18  * Dalvik opcode enumeration.
     19  */
     20 #ifndef _LIBDEX_OPCODE
     21 #define _LIBDEX_OPCODE
     22 
     23 /*
     24  * If you add, delete, or renumber instructions, you need to change things
     25  * in various places.  Renumbering really only affects the "unused" opcodes,
     26  * which are given explicit enumeration values to make it easier to find
     27  * the places in the code that need to be updated when making changes --
     28  * if you replace "OP_UNUSED_2D" and neglect to update a switch statement,
     29  * the compiler will complain about an unknown value.
     30  *
     31  * Opcode definitions and attributes:
     32  *  - update the OpCode enum below
     33  *  - update the "goto table" definition macro, DEFINE_GOTO_TABLE(), below
     34  *  - update the instruction info table generators and (if you changed an
     35  *    instruction format) instruction decoder in InstrUtils.c
     36  *  - update the instruction format list in InstrUtils.h, if necessary
     37  *  - update the parallel definitions in the class dalvik.bytecode.Opcodes
     38  *
     39  * Interpreter:
     40  *  - implement/update the instruction in C in mterp/c/...
     41  *    - verify new code by running with "dalvik.vm.execution-mode =
     42  *      int:portable" or "-Xint:portable"
     43  *  - implement/update the instruction in ARM in mterp/armv5/...
     44  *    - verify by enabling ARM handler for that instruction in mterp config
     45  *      and running int:fast as above
     46  *  - repeat for other platforms (x86, ...)
     47  *  (see notes in mterp/ReadMe.txt for rebuilding instructions)
     48  *
     49  * Verifier / optimizer:
     50  *  - update some stuff in analysis/DexOptimize.c, analysis/DexVerify.c,
     51  *    and/or analysis/CodeVerify.c as needed
     52  *    - verify by running with verifier enabled (it's on by default)
     53  *
     54  * Tools:
     55  *  - update the OpCodeNames table in dexdump/OpCodeNames.c
     56  *  - update dexdump/DexDump.c if an instruction format has changed
     57  *
     58  * Note: The Dalvik VM tests (in the tests subdirectory) provide a convenient
     59  * way to test most of the above without doing any rebuilds.  In particular,
     60  * test 003-omnibus-opcodes will exercise most of the opcodes.
     61  */
     62 
     63 /*
     64  * Dalvik opcode list.
     65  */
     66 typedef enum OpCode {
     67     OP_NOP                          = 0x00,
     68 
     69     OP_MOVE                         = 0x01,
     70     OP_MOVE_FROM16                  = 0x02,
     71     OP_MOVE_16                      = 0x03,
     72     OP_MOVE_WIDE                    = 0x04,
     73     OP_MOVE_WIDE_FROM16             = 0x05,
     74     OP_MOVE_WIDE_16                 = 0x06,
     75     OP_MOVE_OBJECT                  = 0x07,
     76     OP_MOVE_OBJECT_FROM16           = 0x08,
     77     OP_MOVE_OBJECT_16               = 0x09,
     78 
     79     OP_MOVE_RESULT                  = 0x0a,
     80     OP_MOVE_RESULT_WIDE             = 0x0b,
     81     OP_MOVE_RESULT_OBJECT           = 0x0c,
     82     OP_MOVE_EXCEPTION               = 0x0d,
     83 
     84     OP_RETURN_VOID                  = 0x0e,
     85     OP_RETURN                       = 0x0f,
     86     OP_RETURN_WIDE                  = 0x10,
     87     OP_RETURN_OBJECT                = 0x11,
     88 
     89     OP_CONST_4                      = 0x12,
     90     OP_CONST_16                     = 0x13,
     91     OP_CONST                        = 0x14,
     92     OP_CONST_HIGH16                 = 0x15,
     93     OP_CONST_WIDE_16                = 0x16,
     94     OP_CONST_WIDE_32                = 0x17,
     95     OP_CONST_WIDE                   = 0x18,
     96     OP_CONST_WIDE_HIGH16            = 0x19,
     97     OP_CONST_STRING                 = 0x1a,
     98     OP_CONST_STRING_JUMBO           = 0x1b,
     99     OP_CONST_CLASS                  = 0x1c,
    100 
    101     OP_MONITOR_ENTER                = 0x1d,
    102     OP_MONITOR_EXIT                 = 0x1e,
    103 
    104     OP_CHECK_CAST                   = 0x1f,
    105     OP_INSTANCE_OF                  = 0x20,
    106 
    107     OP_ARRAY_LENGTH                 = 0x21,
    108 
    109     OP_NEW_INSTANCE                 = 0x22,
    110     OP_NEW_ARRAY                    = 0x23,
    111 
    112     OP_FILLED_NEW_ARRAY             = 0x24,
    113     OP_FILLED_NEW_ARRAY_RANGE       = 0x25,
    114     OP_FILL_ARRAY_DATA              = 0x26,
    115 
    116     OP_THROW                        = 0x27,
    117     OP_GOTO                         = 0x28,
    118     OP_GOTO_16                      = 0x29,
    119     OP_GOTO_32                      = 0x2a,
    120     OP_PACKED_SWITCH                = 0x2b,
    121     OP_SPARSE_SWITCH                = 0x2c,
    122 
    123     OP_CMPL_FLOAT                   = 0x2d,
    124     OP_CMPG_FLOAT                   = 0x2e,
    125     OP_CMPL_DOUBLE                  = 0x2f,
    126     OP_CMPG_DOUBLE                  = 0x30,
    127     OP_CMP_LONG                     = 0x31,
    128 
    129     OP_IF_EQ                        = 0x32,
    130     OP_IF_NE                        = 0x33,
    131     OP_IF_LT                        = 0x34,
    132     OP_IF_GE                        = 0x35,
    133     OP_IF_GT                        = 0x36,
    134     OP_IF_LE                        = 0x37,
    135     OP_IF_EQZ                       = 0x38,
    136     OP_IF_NEZ                       = 0x39,
    137     OP_IF_LTZ                       = 0x3a,
    138     OP_IF_GEZ                       = 0x3b,
    139     OP_IF_GTZ                       = 0x3c,
    140     OP_IF_LEZ                       = 0x3d,
    141 
    142     OP_UNUSED_3E                    = 0x3e,
    143     OP_UNUSED_3F                    = 0x3f,
    144     OP_UNUSED_40                    = 0x40,
    145     OP_UNUSED_41                    = 0x41,
    146     OP_UNUSED_42                    = 0x42,
    147     OP_UNUSED_43                    = 0x43,
    148 
    149     OP_AGET                         = 0x44,
    150     OP_AGET_WIDE                    = 0x45,
    151     OP_AGET_OBJECT                  = 0x46,
    152     OP_AGET_BOOLEAN                 = 0x47,
    153     OP_AGET_BYTE                    = 0x48,
    154     OP_AGET_CHAR                    = 0x49,
    155     OP_AGET_SHORT                   = 0x4a,
    156     OP_APUT                         = 0x4b,
    157     OP_APUT_WIDE                    = 0x4c,
    158     OP_APUT_OBJECT                  = 0x4d,
    159     OP_APUT_BOOLEAN                 = 0x4e,
    160     OP_APUT_BYTE                    = 0x4f,
    161     OP_APUT_CHAR                    = 0x50,
    162     OP_APUT_SHORT                   = 0x51,
    163 
    164     OP_IGET                         = 0x52,
    165     OP_IGET_WIDE                    = 0x53,
    166     OP_IGET_OBJECT                  = 0x54,
    167     OP_IGET_BOOLEAN                 = 0x55,
    168     OP_IGET_BYTE                    = 0x56,
    169     OP_IGET_CHAR                    = 0x57,
    170     OP_IGET_SHORT                   = 0x58,
    171     OP_IPUT                         = 0x59,
    172     OP_IPUT_WIDE                    = 0x5a,
    173     OP_IPUT_OBJECT                  = 0x5b,
    174     OP_IPUT_BOOLEAN                 = 0x5c,
    175     OP_IPUT_BYTE                    = 0x5d,
    176     OP_IPUT_CHAR                    = 0x5e,
    177     OP_IPUT_SHORT                   = 0x5f,
    178 
    179     OP_SGET                         = 0x60,
    180     OP_SGET_WIDE                    = 0x61,
    181     OP_SGET_OBJECT                  = 0x62,
    182     OP_SGET_BOOLEAN                 = 0x63,
    183     OP_SGET_BYTE                    = 0x64,
    184     OP_SGET_CHAR                    = 0x65,
    185     OP_SGET_SHORT                   = 0x66,
    186     OP_SPUT                         = 0x67,
    187     OP_SPUT_WIDE                    = 0x68,
    188     OP_SPUT_OBJECT                  = 0x69,
    189     OP_SPUT_BOOLEAN                 = 0x6a,
    190     OP_SPUT_BYTE                    = 0x6b,
    191     OP_SPUT_CHAR                    = 0x6c,
    192     OP_SPUT_SHORT                   = 0x6d,
    193 
    194     OP_INVOKE_VIRTUAL               = 0x6e,
    195     OP_INVOKE_SUPER                 = 0x6f,
    196     OP_INVOKE_DIRECT                = 0x70,
    197     OP_INVOKE_STATIC                = 0x71,
    198     OP_INVOKE_INTERFACE             = 0x72,
    199 
    200     OP_UNUSED_73                    = 0x73,
    201 
    202     OP_INVOKE_VIRTUAL_RANGE         = 0x74,
    203     OP_INVOKE_SUPER_RANGE           = 0x75,
    204     OP_INVOKE_DIRECT_RANGE          = 0x76,
    205     OP_INVOKE_STATIC_RANGE          = 0x77,
    206     OP_INVOKE_INTERFACE_RANGE       = 0x78,
    207 
    208     OP_UNUSED_79                    = 0x79,
    209     OP_UNUSED_7A                    = 0x7a,
    210 
    211     OP_NEG_INT                      = 0x7b,
    212     OP_NOT_INT                      = 0x7c,
    213     OP_NEG_LONG                     = 0x7d,
    214     OP_NOT_LONG                     = 0x7e,
    215     OP_NEG_FLOAT                    = 0x7f,
    216     OP_NEG_DOUBLE                   = 0x80,
    217     OP_INT_TO_LONG                  = 0x81,
    218     OP_INT_TO_FLOAT                 = 0x82,
    219     OP_INT_TO_DOUBLE                = 0x83,
    220     OP_LONG_TO_INT                  = 0x84,
    221     OP_LONG_TO_FLOAT                = 0x85,
    222     OP_LONG_TO_DOUBLE               = 0x86,
    223     OP_FLOAT_TO_INT                 = 0x87,
    224     OP_FLOAT_TO_LONG                = 0x88,
    225     OP_FLOAT_TO_DOUBLE              = 0x89,
    226     OP_DOUBLE_TO_INT                = 0x8a,
    227     OP_DOUBLE_TO_LONG               = 0x8b,
    228     OP_DOUBLE_TO_FLOAT              = 0x8c,
    229     OP_INT_TO_BYTE                  = 0x8d,
    230     OP_INT_TO_CHAR                  = 0x8e,
    231     OP_INT_TO_SHORT                 = 0x8f,
    232 
    233     OP_ADD_INT                      = 0x90,
    234     OP_SUB_INT                      = 0x91,
    235     OP_MUL_INT                      = 0x92,
    236     OP_DIV_INT                      = 0x93,
    237     OP_REM_INT                      = 0x94,
    238     OP_AND_INT                      = 0x95,
    239     OP_OR_INT                       = 0x96,
    240     OP_XOR_INT                      = 0x97,
    241     OP_SHL_INT                      = 0x98,
    242     OP_SHR_INT                      = 0x99,
    243     OP_USHR_INT                     = 0x9a,
    244 
    245     OP_ADD_LONG                     = 0x9b,
    246     OP_SUB_LONG                     = 0x9c,
    247     OP_MUL_LONG                     = 0x9d,
    248     OP_DIV_LONG                     = 0x9e,
    249     OP_REM_LONG                     = 0x9f,
    250     OP_AND_LONG                     = 0xa0,
    251     OP_OR_LONG                      = 0xa1,
    252     OP_XOR_LONG                     = 0xa2,
    253     OP_SHL_LONG                     = 0xa3,
    254     OP_SHR_LONG                     = 0xa4,
    255     OP_USHR_LONG                    = 0xa5,
    256 
    257     OP_ADD_FLOAT                    = 0xa6,
    258     OP_SUB_FLOAT                    = 0xa7,
    259     OP_MUL_FLOAT                    = 0xa8,
    260     OP_DIV_FLOAT                    = 0xa9,
    261     OP_REM_FLOAT                    = 0xaa,
    262     OP_ADD_DOUBLE                   = 0xab,
    263     OP_SUB_DOUBLE                   = 0xac,
    264     OP_MUL_DOUBLE                   = 0xad,
    265     OP_DIV_DOUBLE                   = 0xae,
    266     OP_REM_DOUBLE                   = 0xaf,
    267 
    268     OP_ADD_INT_2ADDR                = 0xb0,
    269     OP_SUB_INT_2ADDR                = 0xb1,
    270     OP_MUL_INT_2ADDR                = 0xb2,
    271     OP_DIV_INT_2ADDR                = 0xb3,
    272     OP_REM_INT_2ADDR                = 0xb4,
    273     OP_AND_INT_2ADDR                = 0xb5,
    274     OP_OR_INT_2ADDR                 = 0xb6,
    275     OP_XOR_INT_2ADDR                = 0xb7,
    276     OP_SHL_INT_2ADDR                = 0xb8,
    277     OP_SHR_INT_2ADDR                = 0xb9,
    278     OP_USHR_INT_2ADDR               = 0xba,
    279 
    280     OP_ADD_LONG_2ADDR               = 0xbb,
    281     OP_SUB_LONG_2ADDR               = 0xbc,
    282     OP_MUL_LONG_2ADDR               = 0xbd,
    283     OP_DIV_LONG_2ADDR               = 0xbe,
    284     OP_REM_LONG_2ADDR               = 0xbf,
    285     OP_AND_LONG_2ADDR               = 0xc0,
    286     OP_OR_LONG_2ADDR                = 0xc1,
    287     OP_XOR_LONG_2ADDR               = 0xc2,
    288     OP_SHL_LONG_2ADDR               = 0xc3,
    289     OP_SHR_LONG_2ADDR               = 0xc4,
    290     OP_USHR_LONG_2ADDR              = 0xc5,
    291 
    292     OP_ADD_FLOAT_2ADDR              = 0xc6,
    293     OP_SUB_FLOAT_2ADDR              = 0xc7,
    294     OP_MUL_FLOAT_2ADDR              = 0xc8,
    295     OP_DIV_FLOAT_2ADDR              = 0xc9,
    296     OP_REM_FLOAT_2ADDR              = 0xca,
    297     OP_ADD_DOUBLE_2ADDR             = 0xcb,
    298     OP_SUB_DOUBLE_2ADDR             = 0xcc,
    299     OP_MUL_DOUBLE_2ADDR             = 0xcd,
    300     OP_DIV_DOUBLE_2ADDR             = 0xce,
    301     OP_REM_DOUBLE_2ADDR             = 0xcf,
    302 
    303     OP_ADD_INT_LIT16                = 0xd0,
    304     OP_RSUB_INT                     = 0xd1, /* no _LIT16 suffix for this */
    305     OP_MUL_INT_LIT16                = 0xd2,
    306     OP_DIV_INT_LIT16                = 0xd3,
    307     OP_REM_INT_LIT16                = 0xd4,
    308     OP_AND_INT_LIT16                = 0xd5,
    309     OP_OR_INT_LIT16                 = 0xd6,
    310     OP_XOR_INT_LIT16                = 0xd7,
    311 
    312     OP_ADD_INT_LIT8                 = 0xd8,
    313     OP_RSUB_INT_LIT8                = 0xd9,
    314     OP_MUL_INT_LIT8                 = 0xda,
    315     OP_DIV_INT_LIT8                 = 0xdb,
    316     OP_REM_INT_LIT8                 = 0xdc,
    317     OP_AND_INT_LIT8                 = 0xdd,
    318     OP_OR_INT_LIT8                  = 0xde,
    319     OP_XOR_INT_LIT8                 = 0xdf,
    320     OP_SHL_INT_LIT8                 = 0xe0,
    321     OP_SHR_INT_LIT8                 = 0xe1,
    322     OP_USHR_INT_LIT8                = 0xe2,
    323 
    324     OP_UNUSED_E3                    = 0xe3,
    325     OP_UNUSED_E4                    = 0xe4,
    326     OP_UNUSED_E5                    = 0xe5,
    327     OP_UNUSED_E6                    = 0xe6,
    328     OP_UNUSED_E7                    = 0xe7,
    329     OP_UNUSED_E8                    = 0xe8,
    330     OP_UNUSED_E9                    = 0xe9,
    331     OP_UNUSED_EA                    = 0xea,
    332     OP_UNUSED_EB                    = 0xeb,
    333 
    334     /*
    335      * The "breakpoint" instruction is special, in that it should never
    336      * be seen by anything but the debug interpreter.  During debugging
    337      * it takes the place of an arbitrary opcode, which means operations
    338      * like "tell me the opcode width so I can find the next instruction"
    339      * aren't possible.  (This is correctable, but probably not useful.)
    340      */
    341     OP_BREAKPOINT                   = 0xec,
    342 
    343     /* optimizer output -- these are never generated by "dx" */
    344     OP_THROW_VERIFICATION_ERROR     = 0xed,
    345     OP_EXECUTE_INLINE               = 0xee,
    346     OP_EXECUTE_INLINE_RANGE         = 0xef,
    347 
    348     OP_INVOKE_DIRECT_EMPTY          = 0xf0,
    349     OP_UNUSED_F1                    = 0xf1, /* OP_INVOKE_DIRECT_EMPTY_RANGE? */
    350     OP_IGET_QUICK                   = 0xf2,
    351     OP_IGET_WIDE_QUICK              = 0xf3,
    352     OP_IGET_OBJECT_QUICK            = 0xf4,
    353     OP_IPUT_QUICK                   = 0xf5,
    354     OP_IPUT_WIDE_QUICK              = 0xf6,
    355     OP_IPUT_OBJECT_QUICK            = 0xf7,
    356 
    357     OP_INVOKE_VIRTUAL_QUICK         = 0xf8,
    358     OP_INVOKE_VIRTUAL_QUICK_RANGE   = 0xf9,
    359     OP_INVOKE_SUPER_QUICK           = 0xfa,
    360     OP_INVOKE_SUPER_QUICK_RANGE     = 0xfb,
    361     OP_UNUSED_FC                    = 0xfc, /* OP_INVOKE_DIRECT_QUICK? */
    362     OP_UNUSED_FD                    = 0xfd, /* OP_INVOKE_DIRECT_QUICK_RANGE? */
    363     OP_UNUSED_FE                    = 0xfe, /* OP_INVOKE_INTERFACE_QUICK? */
    364     OP_UNUSED_FF                    = 0xff, /* OP_INVOKE_INTERFACE_QUICK_RANGE*/
    365 } OpCode;
    366 
    367 #define kNumDalvikInstructions 256
    368 
    369 
    370 /*
    371  * Switch-statement signatures are a "NOP" followed by a code.  (A true NOP
    372  * is 0x0000.)
    373  */
    374 #define kPackedSwitchSignature  0x0100
    375 #define kSparseSwitchSignature  0x0200
    376 #define kArrayDataSignature     0x0300
    377 
    378 /*
    379  * Macro used to generate computed goto tables for the C interpreter.
    380  *
    381  * The labels here must match up with the labels in the interpreter
    382  * implementation.  There is no direct connection between these and the
    383  * numeric definitions above, but if the two get out of sync strange things
    384  * will happen.
    385  */
    386 #define DEFINE_GOTO_TABLE(_name) \
    387     static const void* _name[kNumDalvikInstructions] = {                    \
    388         /* 00..0f */                                                        \
    389         H(OP_NOP),                                                          \
    390         H(OP_MOVE),                                                         \
    391         H(OP_MOVE_FROM16),                                                  \
    392         H(OP_MOVE_16),                                                      \
    393         H(OP_MOVE_WIDE),                                                    \
    394         H(OP_MOVE_WIDE_FROM16),                                             \
    395         H(OP_MOVE_WIDE_16),                                                 \
    396         H(OP_MOVE_OBJECT),                                                  \
    397         H(OP_MOVE_OBJECT_FROM16),                                           \
    398         H(OP_MOVE_OBJECT_16),                                               \
    399         H(OP_MOVE_RESULT),                                                  \
    400         H(OP_MOVE_RESULT_WIDE),                                             \
    401         H(OP_MOVE_RESULT_OBJECT),                                           \
    402         H(OP_MOVE_EXCEPTION),                                               \
    403         H(OP_RETURN_VOID),                                                  \
    404         H(OP_RETURN),                                                       \
    405         /* 10..1f */                                                        \
    406         H(OP_RETURN_WIDE),                                                  \
    407         H(OP_RETURN_OBJECT),                                                \
    408         H(OP_CONST_4),                                                      \
    409         H(OP_CONST_16),                                                     \
    410         H(OP_CONST),                                                        \
    411         H(OP_CONST_HIGH16),                                                 \
    412         H(OP_CONST_WIDE_16),                                                \
    413         H(OP_CONST_WIDE_32),                                                \
    414         H(OP_CONST_WIDE),                                                   \
    415         H(OP_CONST_WIDE_HIGH16),                                            \
    416         H(OP_CONST_STRING),                                                 \
    417         H(OP_CONST_STRING_JUMBO),                                           \
    418         H(OP_CONST_CLASS),                                                  \
    419         H(OP_MONITOR_ENTER),                                                \
    420         H(OP_MONITOR_EXIT),                                                 \
    421         H(OP_CHECK_CAST),                                                   \
    422         /* 20..2f */                                                        \
    423         H(OP_INSTANCE_OF),                                                  \
    424         H(OP_ARRAY_LENGTH),                                                 \
    425         H(OP_NEW_INSTANCE),                                                 \
    426         H(OP_NEW_ARRAY),                                                    \
    427         H(OP_FILLED_NEW_ARRAY),                                             \
    428         H(OP_FILLED_NEW_ARRAY_RANGE),                                       \
    429         H(OP_FILL_ARRAY_DATA),                                              \
    430         H(OP_THROW),                                                        \
    431         H(OP_GOTO),                                                         \
    432         H(OP_GOTO_16),                                                      \
    433         H(OP_GOTO_32),                                                      \
    434         H(OP_PACKED_SWITCH),                                                \
    435         H(OP_SPARSE_SWITCH),                                                \
    436         H(OP_CMPL_FLOAT),                                                   \
    437         H(OP_CMPG_FLOAT),                                                   \
    438         H(OP_CMPL_DOUBLE),                                                  \
    439         /* 30..3f */                                                        \
    440         H(OP_CMPG_DOUBLE),                                                  \
    441         H(OP_CMP_LONG),                                                     \
    442         H(OP_IF_EQ),                                                        \
    443         H(OP_IF_NE),                                                        \
    444         H(OP_IF_LT),                                                        \
    445         H(OP_IF_GE),                                                        \
    446         H(OP_IF_GT),                                                        \
    447         H(OP_IF_LE),                                                        \
    448         H(OP_IF_EQZ),                                                       \
    449         H(OP_IF_NEZ),                                                       \
    450         H(OP_IF_LTZ),                                                       \
    451         H(OP_IF_GEZ),                                                       \
    452         H(OP_IF_GTZ),                                                       \
    453         H(OP_IF_LEZ),                                                       \
    454         H(OP_UNUSED_3E),                                                    \
    455         H(OP_UNUSED_3F),                                                    \
    456         /* 40..4f */                                                        \
    457         H(OP_UNUSED_40),                                                    \
    458         H(OP_UNUSED_41),                                                    \
    459         H(OP_UNUSED_42),                                                    \
    460         H(OP_UNUSED_43),                                                    \
    461         H(OP_AGET),                                                         \
    462         H(OP_AGET_WIDE),                                                    \
    463         H(OP_AGET_OBJECT),                                                  \
    464         H(OP_AGET_BOOLEAN),                                                 \
    465         H(OP_AGET_BYTE),                                                    \
    466         H(OP_AGET_CHAR),                                                    \
    467         H(OP_AGET_SHORT),                                                   \
    468         H(OP_APUT),                                                         \
    469         H(OP_APUT_WIDE),                                                    \
    470         H(OP_APUT_OBJECT),                                                  \
    471         H(OP_APUT_BOOLEAN),                                                 \
    472         H(OP_APUT_BYTE),                                                    \
    473         /* 50..5f */                                                        \
    474         H(OP_APUT_CHAR),                                                    \
    475         H(OP_APUT_SHORT),                                                   \
    476         H(OP_IGET),                                                         \
    477         H(OP_IGET_WIDE),                                                    \
    478         H(OP_IGET_OBJECT),                                                  \
    479         H(OP_IGET_BOOLEAN),                                                 \
    480         H(OP_IGET_BYTE),                                                    \
    481         H(OP_IGET_CHAR),                                                    \
    482         H(OP_IGET_SHORT),                                                   \
    483         H(OP_IPUT),                                                         \
    484         H(OP_IPUT_WIDE),                                                    \
    485         H(OP_IPUT_OBJECT),                                                  \
    486         H(OP_IPUT_BOOLEAN),                                                 \
    487         H(OP_IPUT_BYTE),                                                    \
    488         H(OP_IPUT_CHAR),                                                    \
    489         H(OP_IPUT_SHORT),                                                   \
    490         /* 60..6f */                                                        \
    491         H(OP_SGET),                                                         \
    492         H(OP_SGET_WIDE),                                                    \
    493         H(OP_SGET_OBJECT),                                                  \
    494         H(OP_SGET_BOOLEAN),                                                 \
    495         H(OP_SGET_BYTE),                                                    \
    496         H(OP_SGET_CHAR),                                                    \
    497         H(OP_SGET_SHORT),                                                   \
    498         H(OP_SPUT),                                                         \
    499         H(OP_SPUT_WIDE),                                                    \
    500         H(OP_SPUT_OBJECT),                                                  \
    501         H(OP_SPUT_BOOLEAN),                                                 \
    502         H(OP_SPUT_BYTE),                                                    \
    503         H(OP_SPUT_CHAR),                                                    \
    504         H(OP_SPUT_SHORT),                                                   \
    505         H(OP_INVOKE_VIRTUAL),                                               \
    506         H(OP_INVOKE_SUPER),                                                 \
    507         /* 70..7f */                                                        \
    508         H(OP_INVOKE_DIRECT),                                                \
    509         H(OP_INVOKE_STATIC),                                                \
    510         H(OP_INVOKE_INTERFACE),                                             \
    511         H(OP_UNUSED_73),                                                    \
    512         H(OP_INVOKE_VIRTUAL_RANGE),                                         \
    513         H(OP_INVOKE_SUPER_RANGE),                                           \
    514         H(OP_INVOKE_DIRECT_RANGE),                                          \
    515         H(OP_INVOKE_STATIC_RANGE),                                          \
    516         H(OP_INVOKE_INTERFACE_RANGE),                                       \
    517         H(OP_UNUSED_79),                                                    \
    518         H(OP_UNUSED_7A),                                                    \
    519         H(OP_NEG_INT),                                                      \
    520         H(OP_NOT_INT),                                                      \
    521         H(OP_NEG_LONG),                                                     \
    522         H(OP_NOT_LONG),                                                     \
    523         H(OP_NEG_FLOAT),                                                    \
    524         /* 80..8f */                                                        \
    525         H(OP_NEG_DOUBLE),                                                   \
    526         H(OP_INT_TO_LONG),                                                  \
    527         H(OP_INT_TO_FLOAT),                                                 \
    528         H(OP_INT_TO_DOUBLE),                                                \
    529         H(OP_LONG_TO_INT),                                                  \
    530         H(OP_LONG_TO_FLOAT),                                                \
    531         H(OP_LONG_TO_DOUBLE),                                               \
    532         H(OP_FLOAT_TO_INT),                                                 \
    533         H(OP_FLOAT_TO_LONG),                                                \
    534         H(OP_FLOAT_TO_DOUBLE),                                              \
    535         H(OP_DOUBLE_TO_INT),                                                \
    536         H(OP_DOUBLE_TO_LONG),                                               \
    537         H(OP_DOUBLE_TO_FLOAT),                                              \
    538         H(OP_INT_TO_BYTE),                                                  \
    539         H(OP_INT_TO_CHAR),                                                  \
    540         H(OP_INT_TO_SHORT),                                                 \
    541         /* 90..9f */                                                        \
    542         H(OP_ADD_INT),                                                      \
    543         H(OP_SUB_INT),                                                      \
    544         H(OP_MUL_INT),                                                      \
    545         H(OP_DIV_INT),                                                      \
    546         H(OP_REM_INT),                                                      \
    547         H(OP_AND_INT),                                                      \
    548         H(OP_OR_INT),                                                       \
    549         H(OP_XOR_INT),                                                      \
    550         H(OP_SHL_INT),                                                      \
    551         H(OP_SHR_INT),                                                      \
    552         H(OP_USHR_INT),                                                     \
    553         H(OP_ADD_LONG),                                                     \
    554         H(OP_SUB_LONG),                                                     \
    555         H(OP_MUL_LONG),                                                     \
    556         H(OP_DIV_LONG),                                                     \
    557         H(OP_REM_LONG),                                                     \
    558         /* a0..af */                                                        \
    559         H(OP_AND_LONG),                                                     \
    560         H(OP_OR_LONG),                                                      \
    561         H(OP_XOR_LONG),                                                     \
    562         H(OP_SHL_LONG),                                                     \
    563         H(OP_SHR_LONG),                                                     \
    564         H(OP_USHR_LONG),                                                    \
    565         H(OP_ADD_FLOAT),                                                    \
    566         H(OP_SUB_FLOAT),                                                    \
    567         H(OP_MUL_FLOAT),                                                    \
    568         H(OP_DIV_FLOAT),                                                    \
    569         H(OP_REM_FLOAT),                                                    \
    570         H(OP_ADD_DOUBLE),                                                   \
    571         H(OP_SUB_DOUBLE),                                                   \
    572         H(OP_MUL_DOUBLE),                                                   \
    573         H(OP_DIV_DOUBLE),                                                   \
    574         H(OP_REM_DOUBLE),                                                   \
    575         /* b0..bf */                                                        \
    576         H(OP_ADD_INT_2ADDR),                                                \
    577         H(OP_SUB_INT_2ADDR),                                                \
    578         H(OP_MUL_INT_2ADDR),                                                \
    579         H(OP_DIV_INT_2ADDR),                                                \
    580         H(OP_REM_INT_2ADDR),                                                \
    581         H(OP_AND_INT_2ADDR),                                                \
    582         H(OP_OR_INT_2ADDR),                                                 \
    583         H(OP_XOR_INT_2ADDR),                                                \
    584         H(OP_SHL_INT_2ADDR),                                                \
    585         H(OP_SHR_INT_2ADDR),                                                \
    586         H(OP_USHR_INT_2ADDR),                                               \
    587         H(OP_ADD_LONG_2ADDR),                                               \
    588         H(OP_SUB_LONG_2ADDR),                                               \
    589         H(OP_MUL_LONG_2ADDR),                                               \
    590         H(OP_DIV_LONG_2ADDR),                                               \
    591         H(OP_REM_LONG_2ADDR),                                               \
    592         /* c0..cf */                                                        \
    593         H(OP_AND_LONG_2ADDR),                                               \
    594         H(OP_OR_LONG_2ADDR),                                                \
    595         H(OP_XOR_LONG_2ADDR),                                               \
    596         H(OP_SHL_LONG_2ADDR),                                               \
    597         H(OP_SHR_LONG_2ADDR),                                               \
    598         H(OP_USHR_LONG_2ADDR),                                              \
    599         H(OP_ADD_FLOAT_2ADDR),                                              \
    600         H(OP_SUB_FLOAT_2ADDR),                                              \
    601         H(OP_MUL_FLOAT_2ADDR),                                              \
    602         H(OP_DIV_FLOAT_2ADDR),                                              \
    603         H(OP_REM_FLOAT_2ADDR),                                              \
    604         H(OP_ADD_DOUBLE_2ADDR),                                             \
    605         H(OP_SUB_DOUBLE_2ADDR),                                             \
    606         H(OP_MUL_DOUBLE_2ADDR),                                             \
    607         H(OP_DIV_DOUBLE_2ADDR),                                             \
    608         H(OP_REM_DOUBLE_2ADDR),                                             \
    609         /* d0..df */                                                        \
    610         H(OP_ADD_INT_LIT16),                                                \
    611         H(OP_RSUB_INT),                                                     \
    612         H(OP_MUL_INT_LIT16),                                                \
    613         H(OP_DIV_INT_LIT16),                                                \
    614         H(OP_REM_INT_LIT16),                                                \
    615         H(OP_AND_INT_LIT16),                                                \
    616         H(OP_OR_INT_LIT16),                                                 \
    617         H(OP_XOR_INT_LIT16),                                                \
    618         H(OP_ADD_INT_LIT8),                                                 \
    619         H(OP_RSUB_INT_LIT8),                                                \
    620         H(OP_MUL_INT_LIT8),                                                 \
    621         H(OP_DIV_INT_LIT8),                                                 \
    622         H(OP_REM_INT_LIT8),                                                 \
    623         H(OP_AND_INT_LIT8),                                                 \
    624         H(OP_OR_INT_LIT8),                                                  \
    625         H(OP_XOR_INT_LIT8),                                                 \
    626         /* e0..ef */                                                        \
    627         H(OP_SHL_INT_LIT8),                                                 \
    628         H(OP_SHR_INT_LIT8),                                                 \
    629         H(OP_USHR_INT_LIT8),                                                \
    630         H(OP_UNUSED_E3),                                                    \
    631         H(OP_UNUSED_E4),                                                    \
    632         H(OP_UNUSED_E5),                                                    \
    633         H(OP_UNUSED_E6),                                                    \
    634         H(OP_UNUSED_E7),                                                    \
    635         H(OP_UNUSED_E8),                                                    \
    636         H(OP_UNUSED_E9),                                                    \
    637         H(OP_UNUSED_EA),                                                    \
    638         H(OP_UNUSED_EB),                                                    \
    639         H(OP_BREAKPOINT),                                                   \
    640         H(OP_THROW_VERIFICATION_ERROR),                                     \
    641         H(OP_EXECUTE_INLINE),                                               \
    642         H(OP_EXECUTE_INLINE_RANGE),                                         \
    643         /* f0..ff */                                                        \
    644         H(OP_INVOKE_DIRECT_EMPTY),                                          \
    645         H(OP_UNUSED_F1),                                                    \
    646         H(OP_IGET_QUICK),                                                   \
    647         H(OP_IGET_WIDE_QUICK),                                              \
    648         H(OP_IGET_OBJECT_QUICK),                                            \
    649         H(OP_IPUT_QUICK),                                                   \
    650         H(OP_IPUT_WIDE_QUICK),                                              \
    651         H(OP_IPUT_OBJECT_QUICK),                                            \
    652         H(OP_INVOKE_VIRTUAL_QUICK),                                         \
    653         H(OP_INVOKE_VIRTUAL_QUICK_RANGE),                                   \
    654         H(OP_INVOKE_SUPER_QUICK),                                           \
    655         H(OP_INVOKE_SUPER_QUICK_RANGE),                                     \
    656         H(OP_UNUSED_FC),                                                    \
    657         H(OP_UNUSED_FD),                                                    \
    658         H(OP_UNUSED_FE),                                                    \
    659         H(OP_UNUSED_FF),                                                    \
    660     };
    661 
    662 #endif /*_LIBDEX_OPCODE*/
    663