# PyJVM (pyjvm.org) Java Virtual Machine implemented in pure Python
# Copyright (C) 2014 Andrew Romanenco (andrew@romanenco.com)
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program.  If not, see <http://www.gnu.org/licenses/>.
'''Java bytecode implementation'''

ops_name = {}

ops_name["op_0x1"] = "aconst_null"
ops_name["op_0x2"] = "iconst_m1"
ops_name["op_0x3"] = "iconst_0"
ops_name["op_0x4"] = "iconst_1"
ops_name["op_0x5"] = "iconst_2"
ops_name["op_0x6"] = "iconst_3"
ops_name["op_0x7"] = "iconst_4"
ops_name["op_0x8"] = "iconst_5"
ops_name["op_0x9"] = "lconst_0"
ops_name["op_0xa"] = "lconst_1"
ops_name["op_0xb"] = "fconst_0"
ops_name["op_0xc"] = "fconst_1"
ops_name["op_0xd"] = "fconst_2"
ops_name["op_0xe"] = "dconst_0"
ops_name["op_0xf"] = "dconst_1"
ops_name["op_0x10"] = "bipush"
ops_name["op_0x11"] = "sipush"
ops_name["op_0x12"] = "ldc"
ops_name["op_0x13"] = "ldc_w"
ops_name["op_0x14"] = "ldc2_w"
ops_name["op_0x15"] = "iload"
ops_name["op_0x16"] = "lload"
ops_name["op_0x17"] = "fload"
ops_name["op_0x18"] = "dload"
ops_name["op_0x19"] = "aload"
ops_name["op_0x1a"] = "iload_0"
ops_name["op_0x1b"] = "iload_1"
ops_name["op_0x1c"] = "iload_2"
ops_name["op_0x1d"] = "iload_3"
ops_name["op_0x1e"] = "lload_0"
ops_name["op_0x1f"] = "lload_1"
ops_name["op_0x20"] = "lload_2"
ops_name["op_0x21"] = "lload_3"
ops_name["op_0x22"] = "fload_0"
ops_name["op_0x23"] = "fload_1"
ops_name["op_0x24"] = "fload_2"
ops_name["op_0x25"] = "fload_3"
ops_name["op_0x26"] = "dload_0"
ops_name["op_0x27"] = "dload_1"
ops_name["op_0x28"] = "dload_2"
ops_name["op_0x29"] = "dload_3"
ops_name["op_0x2a"] = "aload_0"
ops_name["op_0x2b"] = "aload_1"
ops_name["op_0x2c"] = "aload_2"
ops_name["op_0x2d"] = "aload_3"
ops_name["op_0x2e"] = "iaload"
ops_name["op_0x2f"] = "laload"
ops_name["op_0x30"] = "faload"
ops_name["op_0x31"] = "daload"
ops_name["op_0x32"] = "aaload"
ops_name["op_0x33"] = "baload"
ops_name["op_0x34"] = "caload"
ops_name["op_0x35"] = "saload"
ops_name["op_0x36"] = "istore"
ops_name["op_0x37"] = "lstore"
ops_name["op_0x38"] = "fstore"
ops_name["op_0x39"] = "dstore"
ops_name["op_0x3a"] = "astore"
ops_name["op_0x3b"] = "istore_0"
ops_name["op_0x3c"] = "istore_1"
ops_name["op_0x3d"] = "istore_2"
ops_name["op_0x3e"] = "istore_3"
ops_name["op_0x3f"] = "lstore_0"
ops_name["op_0x40"] = "lstore_1"
ops_name["op_0x41"] = "lstore_2"
ops_name["op_0x42"] = "lstore_3"
ops_name["op_0x43"] = "fstore_0"
ops_name["op_0x44"] = "fstore_1"
ops_name["op_0x45"] = "fstore_2"
ops_name["op_0x46"] = "fstore_3"
ops_name["op_0x47"] = "dstore_0"
ops_name["op_0x48"] = "dstore_1"
ops_name["op_0x49"] = "dstore_2"
ops_name["op_0x4a"] = "dstore_3"
ops_name["op_0x4b"] = "astore_0"
ops_name["op_0x4c"] = "astore_1"
ops_name["op_0x4d"] = "astore_2"
ops_name["op_0x4e"] = "astore_3"
ops_name["op_0x4f"] = "iastore"
ops_name["op_0x50"] = "lastore"
ops_name["op_0x51"] = "fastore"
ops_name["op_0x52"] = "dastore"
ops_name["op_0x53"] = "aastore"
ops_name["op_0x54"] = "bastore"
ops_name["op_0x55"] = "castore"
ops_name["op_0x56"] = "sastore"
ops_name["op_0x57"] = "pop"
ops_name["op_0x58"] = "pop2"
ops_name["op_0x59"] = "dup"
ops_name["op_0x5a"] = "dup_x1"
ops_name["op_0x5b"] = "dup_x2"
ops_name["op_0x5c"] = "dup2"
ops_name["op_0x5d"] = "dup2_x1"
ops_name["op_0x5e"] = "dup2_x2"
ops_name["op_0x5f"] = "swap"
ops_name["op_0x60"] = "iadd"
ops_name["op_0x61"] = "ladd"
ops_name["op_0x62"] = "fadd"
ops_name["op_0x63"] = "dadd"
ops_name["op_0x64"] = "isub"
ops_name["op_0x65"] = "lsub"
ops_name["op_0x66"] = "fsub"
ops_name["op_0x67"] = "dsub"
ops_name["op_0x68"] = "imul"
ops_name["op_0x69"] = "lmul"
ops_name["op_0x6a"] = "fmul"
ops_name["op_0x6b"] = "dmul"
ops_name["op_0x6c"] = "idiv"
ops_name["op_0x6d"] = "ldiv"
ops_name["op_0x6e"] = "fdiv"
ops_name["op_0x6f"] = "ddiv"
ops_name["op_0x70"] = "irem"
ops_name["op_0x71"] = "lrem"
ops_name["op_0x72"] = "frem"
ops_name["op_0x73"] = "drem"
ops_name["op_0x74"] = "ineg"
ops_name["op_0x75"] = "lneg"
ops_name["op_0x76"] = "fneg"
ops_name["op_0x77"] = "dneg"
ops_name["op_0x78"] = "ishl"
ops_name["op_0x79"] = "lshl"
ops_name["op_0x7a"] = "ishr"
ops_name["op_0x7b"] = "lshr"
ops_name["op_0x7c"] = "iushr"
ops_name["op_0x7d"] = "lushr"
ops_name["op_0x7e"] = "iand"
ops_name["op_0x7f"] = "land"
ops_name["op_0x80"] = "ior"
ops_name["op_0x81"] = "lor"
ops_name["op_0x82"] = "ixor"
ops_name["op_0x83"] = "lxor"
ops_name["op_0x84"] = "iinc"
ops_name["op_0x85"] = "i2l"
ops_name["op_0x86"] = "i2f"
ops_name["op_0x87"] = "i2d"
ops_name["op_0x88"] = "l2i"
ops_name["op_0x89"] = "l2f"
ops_name["op_0x8a"] = "l2d"
ops_name["op_0x8b"] = "f2i"
ops_name["op_0x8c"] = "f2l"
ops_name["op_0x8d"] = "f2d"
ops_name["op_0x8e"] = "d2i"
ops_name["op_0x8f"] = "d2l"
ops_name["op_0x90"] = "d2f"
ops_name["op_0x91"] = "i2b"
ops_name["op_0x92"] = "i2c"
ops_name["op_0x93"] = "i2s"
ops_name["op_0x94"] = "lcmp"
ops_name["op_0x95"] = "fcmpl"
ops_name["op_0x96"] = "fcmpg"
ops_name["op_0x97"] = "dcmpl"
ops_name["op_0x98"] = "dcmpg"
ops_name["op_0x99"] = "ifeq"
ops_name["op_0x9a"] = "ifne"
ops_name["op_0x9b"] = "iflt"
ops_name["op_0x9c"] = "ifge"
ops_name["op_0x9d"] = "ifgt"
ops_name["op_0x9e"] = "ifle"
ops_name["op_0x9f"] = "if_icmpeq"
ops_name["op_0xa0"] = "if_icmpne"
ops_name["op_0xa1"] = "if_icmplt"
ops_name["op_0xa2"] = "if_icmpge"
ops_name["op_0xa3"] = "if_icmpgt"
ops_name["op_0xa4"] = "if_icmple"
ops_name["op_0xa5"] = "if_acmpeq"
ops_name["op_0xa6"] = "if_acmpne"
ops_name["op_0xa7"] = "goto"
ops_name["op_0xa8"] = "jsr"
ops_name["op_0xa9"] = "ret"
ops_name["op_0xaa"] = "tableswitch"
ops_name["op_0xab"] = "lookupswitch"
ops_name["op_0xac"] = "ireturn"
ops_name["op_0xad"] = "lreturn"
ops_name["op_0xae"] = "freturn"
ops_name["op_0xaf"] = "dreturn"
ops_name["op_0xb0"] = "areturn"
ops_name["op_0xb1"] = "return"
ops_name["op_0xb2"] = "getstatic"
ops_name["op_0xb3"] = "putstatic"
ops_name["op_0xb4"] = "getfield"
ops_name["op_0xb5"] = "putfield"
ops_name["op_0xb6"] = "invokevirtual"
ops_name["op_0xb7"] = "invokespecial"
ops_name["op_0xb8"] = "invokestatic"
ops_name["op_0xb9"] = "invokeinterface"
ops_name["op_0xba"] = "invokedynamic"
ops_name["op_0xbb"] = "new"
ops_name["op_0xbc"] = "newarray"
ops_name["op_0xbd"] = "anewarray"
ops_name["op_0xbe"] = "arraylength"
ops_name["op_0xbf"] = "athrow"
ops_name["op_0xc0"] = "checkcast"
ops_name["op_0xc1"] = "instanceof"
ops_name["op_0xc2"] = "monitorenter"
ops_name["op_0xc3"] = "monitorexit"
ops_name["op_0xc4"] = "wide"
ops_name["op_0xc5"] = "multianewarray"
ops_name["op_0xc6"] = "ifnull"
ops_name["op_0xc7"] = "ifnonnull"
ops_name["op_0xc8"] = "goto_w"
ops_name["op_0xc9"] = "jsr_w"
ops_name["op_0xca"] = "breakpoint"
ops_name["op_0xfe"] = "impdep1"
ops_name["op_0xff"] = "impdep2"
