Java Quick Guide

 
 
This guide contains useful Java information.

rss feed






JVM instruction set



JVM



Decimal value Opcode (hex) Category Mnemonic Operand Description Stack before Stack after
0 0 miscellaneous nop do nothing
1 1 load and store instructions aconst_null push a null object reference onto the operand stack null
2 2 load and store instructions iconst_m1 push int -1 constant onto the operand stack -1
3 3 load and store instructions iconst_0 push int 0 constant onto the operand stack 0
4 4 load and store instructions iconst_1 push int 1 constant onto the operand stack 1
5 5 load and store instructions iconst_2 push int 2 constant onto the operand stack 2
6 6 load and store instructions iconst_3 push int 3 constant onto the operand stack 3
7 7 load and store instructions iconst_4 push int 4 constant onto the operand stack 4
8 8 load and store instructions iconst_5 push int 5 constant onto the operand stack 5
9 9 load and store instructions lconst_0 push long 0 constant onto the operand stack 0L
10 A load and store instructions lconst_1 push long 1 constant onto the operand stack 1L
11 B load and store instructions fconst_0 push float 0.0 onto the operand stack 0.0f
12 C load and store instructions fconst_1 push float 1.0 onto the operand stack 1.0f
13 D load and store instructions fconst_2 push float 2.0 onto the operand stack 2.0f
14 E load and store instructions dconst_0 push double 0.0 onto the operand stack 0.0
15 F load and store instructions dconst_1 push double 1.0 onto the operand stack 1.0
16 10 load and store instructions bipush index byte convert index byte (signed 8-bit integer) to an int and push it onto the operand stack integer value
17 11 load and store instructions sipush highbyte, lowbyte convert short (highbyte, lowbyte) (signed 16-bit integer = highbyte <<8) | lowbyte) to an int and pushes it onto the operand stack. integer value
18 12 load and store instructions ldc index byte resolve the string from the String Ref or resolve the Class type from the Class Ref or get the int or float found in the constant pool at the address indicated by the index byte, the string, class type, int or float is pushed onto the operand stack string class int float value
19 13 load and store instructions ldc_w highbyte, lowbyte resolve the string from the String Ref or resolve the Class type from the Class Ref or get the int or float found in the constant pool at the address indicated by highbyte and lowbyte, the string, class type, int or float is pushed onto the operand stack string class int float value
20 14 load and store instructions ldc2_w highbyte, lowbyte get long or double found in the constant pool at the address indicated by highbyte and lowbyte, the long or double is pushed onto the operand stack long double value
21 15 load and store instructions iload index byte load int from local variable at index indicated by index byte (unsigned 8-bit integer) and push onto operand stack integer value
22 16 load and store instructions lload index byte load long from local variable at index indicated by index byte (unsigned 8-bit integer) and push onto operand stack long value
23 17 load and store instructions fload index byte load float from local variable at index indicated by index byte (unsigned 8-bit integer) and push onto operand stack float value
24 18 load and store instructions dload index byte load double from local variable at index indicated by index byte (unsigned 8-bit integer) and push onto operand stack double value
25 19 load and store instructions aload index byte load reference from local variable at index indicated by index byte (unsigned 8-bit integer) and push onto operand stack object ref
26 1A load and store instructions iload_0 load int from local variable at index 0 and push onto operand stack integer value
27 1B load and store instructions iload_1 load int from local variable at index 1 and push onto operand stack integer value
28 1C load and store instructions iload_2 load int from local variable at index 2 and push onto operand stack integer value
29 1D load and store instructions iload_3 load int from local variable at index 3 and push onto operand stack integer value
30 1E load and store instructions lload_0 load long from local variable at index 0 and push onto operand stack long value
31 1F load and store instructions lload_1 load long from local variable at index 1 and push onto operand stack long value
32 20 load and store instructions lload_2 load long from local variable at index 2 and push onto operand stack long value
33 21 load and store instructions lload_3 load long from local variable at index 3 and push onto operand stack long value
34 22 load and store instructions fload_0 load float from local variable at index 0 and push onto operand stack float value
35 23 load and store instructions fload_1 load float from local variable at index 1 and push onto operand stack float value
36 24 load and store instructions fload_2 load float from local variable at index 2 and push onto operand stack float value
37 25 load and store instructions fload_3 load float from local variable at index 3 and push onto operand stack float value
38 26 load and store instructions dload_0 load double from local variable at index 0 and push onto operand stack double value
39 27 load and store instructions dload_1 load double from local variable at index 1 and push onto operand stack double value
40 28 load and store instructions dload_2 load double from local variable at index 2 and push onto operand stack double value
41 29 load and store instructions dload_3 load double from local variable at index 3 and push onto operand stack double value
42 2A load and store instructions aload_0 load object reference from local variable at index 0 and push onto operand stack object ref
43 2B load and store instructions aload_1 load object reference from local variable at index 1 and push onto operand stack object ref
44 2C load and store instructions aload_2 load object reference from local variable at index 2 and push onto operand stack object ref
45 2D load and store instructions aload_3 load object reference from local variable at index 3 and push onto operand stack object ref
46 2E object creation and manipulation iaload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get int value from array and push this onto operand stack array object ref, array index integer value
47 2F object creation and manipulation laload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get long value from array and push this onto operand stack array object ref, array index long value
48 30 object creation and manipulation faload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get float value from array and push this onto operand stack array object ref, array index float value
49 31 object creation and manipulation daload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get double value from array and push this onto operand stack array object ref, array index double value
50 32 object creation and manipulation aaload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get object reference from array and push this onto operand stack array object ref, array index object ref
51 33 object creation and manipulation baload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get boolean or byte value from array and push this onto operand stack array object ref, array index boolean byte value
52 34 object creation and manipulation caload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get char value from array and push this onto operand stack array object ref, array index char value
53 35 object creation and manipulation saload The array object refererence and array index value are previously pushed on the operand stack (aload_x, iconst_x). Get short value from array and push this onto operand stack array object ref, array index short value
54 36 load and store instructions istore index byte store int from operand stack into local variable at index indicated by index byte (unsigned 8-bit integer) integer value
55 37 load and store instructions lstore index byte store long from operand stack into local variable at index indicated by index byte (unsigned 8-bit integer) long value
56 38 load and store instructions fstore index byte store float from operand stack into local variable at index indicated by index byte (unsigned 8-bit integer) float value
57 39 load and store instructions dstore index byte store double from operand stack into local variable at index indicated by index byte (unsigned 8-bit integer) double value
58 3A load and store instructions astore index byte store object reference from operand stack into local variable at index indicated by index byte (unsigned 8-bit integer) object ref
59 3B load and store instructions istore_0 store int from operand stack into local variable at index 0 integer value
60 3C load and store instructions istore_1 store int from operand stack into local variable at index 1 integer value
61 3D load and store instructions istore_2 store int from operand stack into local variable at index 2 integer value
62 3E load and store instructions istore_3 store int from operand stack into local variable at index 3 integer value
63 3F load and store instructions lstore_0 store long from operand stack into local variable at index 0 long value
64 40 load and store instructions lstore_1 store long from operand stack into local variable at index 1 long value
65 41 load and store instructions lstore_2 store long from operand stack into local variable at index 2 long value
66 42 load and store instructions lstore_3 store long from operand stack into local variable at index 3 long value
67 43 load and store instructions fstore_0 store float from operand stack into local variable at index 0 float value
68 44 load and store instructions fstore_1 store float from operand stack into local variable at index 1 float value
69 45 load and store instructions fstore_2 store float from operand stack into local variable at index 2 float value
70 46 load and store instructions fstore_3 store float from operand stack into local variable at index 3 float value
71 47 load and store instructions dstore_0 store double from operand stack into local variable at index 0 double value
72 48 load and store instructions dstore_1 store double from operand stack into local variable at index 1 double value
73 49 load and store instructions dstore_2 store double from operand stack into local variable at index 2 double value
74 4A load and store instructions dstore_3 store double from operand stack into local variable at index 3 double value
75 4B load and store instructions astore_0 store object reference from operand stack into local variable at index 0 object ref
76 4C load and store instructions astore_1 store object reference from operand stack into local variable at index 1 object ref
77 4D load and store instructions astore_2 store object reference from operand stack into local variable at index 2 object ref
78 4E load and store instructions astore_3 store object reference from operand stack into local variable at index 3 object ref
79 4F object creation and manipulation iastore The array object refererence, array index and int value are previously pushed on the operand stack (aload_x, iconst_x). Store int value in array at array index array object ref, array index, integer value
80 50 object creation and manipulation lastore The array object refererence, array index and long value are previously pushed on the operand stack (aload_x, iconst_x). Store long value in array at array index array object ref, array index, long value
81 51 object creation and manipulation fastore The array object refererence, array index and float value are previously pushed on the operand stack (aload_x, iconst_x). Store float value in array at array index array object ref, array index, float value
82 52 object creation and manipulation dastore The array object refererence, array index and double value are previously pushed on the operand stack (aload_x, iconst_x). Store double value in array at array index array object ref, array index, double value
83 53 object creation and manipulation aastore The array object refererence, array index and object ref value are previously pushed on the operand stack (aload_x, iconst_x). Store object ref value in array at array index array object ref, array index, object ref value
84 54 object creation and manipulation bastore The array object refererence, array index and byte or boolean value are previously pushed on the operand stack (aload_x, iconst_x). Store byte or boolean value in array at array index array object ref, array index, byte boolean value
85 55 object creation and manipulation castore The array object refererence, array index and char value are previously pushed on the operand stack (aload_x, iconst_x). Store char value in array at array index array object ref, array index, char value
86 56 object creation and manipulation sastore The array object refererence, array index and short value are previously pushed on the operand stack (aload_x, iconst_x). Store short value in array at array index array object ref, array index, short value
87 57 operand stack management pop pop (=discard) the top operand stack value value
88 58 operand stack management pop2 pop (=discard) the top one or two operand stack values

Form1 applies when both values are of type: int, float, reference or returnAdress

Form2 applies when value is a double or long
Form1: value1, value2

Form2: value
Form1:

Form2:
89 59 operand stack management dup duplicate the top operand stack value value value, value
90 5A operand stack management dup_x1 duplicate the top value on the operand stack and insert the duplicated value two values down in the operand stack. value1, value2 value2, value1, value2
91 5B operand stack management dup_x2 Duplicate the top value on the operand stack and insert the duplicated value two or three values down in the operand stack.

Form1 applies when all values are of type: int, float, reference or returnAdress

Form2 applies when value1 is a double or long and value2 is of type: int, float, reference or returnAddress
Form1: value1, value2, value3

Form2: value1, value2
Form1: value3, value1, value2, value3

Form2: value2, value1, value2
92 5C operand stack management dup2 Duplicate the top one or two values on the operand stack and push the duplicated value or values back onto the operand stack in the original order.

Form1 applies when both values are of type: int, float, reference or returnAdress

Form2 applies when value is a double or long
Form1: value1, value2

Form2: value
Form1:
value1, value2, value1, value2

Form2:
value, value
93 5D operand stack management dup2_x1 Duplicate the top one or two values on the operand stack and insert the duplicated values, in the original order, one value beneath the original value or values in the operand stack.

Form1 applies when all values are of type: int, float, reference or returnAdress

Form2 applies when value1 is a double or long and value2 is of type: int, float, reference or returnAddress
Form1: value1, value2, value3

Form2: value1, value2
Form1: value2, value3, value1, value2, value3

Form2: value2, value1, value2
94 5E operand stack management dup2_x2 Duplicate the top one or two values on the operand stack and insert the duplicated values, in the original order, into the operand stack.

Form1 applies when all values are of type: int, float, reference or returnAdress

Form2 applies when value3 is a double or long and value1+2 is of type: int, float, reference or returnAddress

Form3 applies when value1 is of type double or long and value2+3 are of type: int, float, reference or returnAdress

Form4 applies when both values are of type: double or long
Form1: value1, value2, value3, value4

Form2: value1, value2, value3

Form3: value1, value2, value3

Form4: value1, value2
Form1: value3, value4, value1, value2, value3, value4

Form2: value3, value1, value2, value3

Form3: value2, value3, value1, value2, value3

Form4: value2, value1, value2
95 5F operand stack management swap swap the top two operand stack values. Both values are of type: int, float, reference or returnAdress value1, value2 value2, value1
96 60 arithmetic operations iadd pop the first 2 ints from the operand stack, add them and place the int result onto the operand stack integer value, integer value integer result
97 61 arithmetic operations ladd pop the first 2 longs from the operand stack, add them and place the long result onto the operand stack long value, long value long result
98 62 arithmetic operations fadd pop the first 2 floats from the operand stack, add them and place the float result onto the operand stack float value, float value float result
99 63 arithmetic operations dadd pop the first 2 doubles from the operand stack, add them and place the double result onto the operand stack double value, double value double result
100 64 arithmetic operations isub pop the first 2 ints from the operand stack, subtract them and place the int result onto the operand stack integer value, integer value integer result
101 65 arithmetic operations lsub pop the first 2 longs from the operand stack, subtract them and place the long result onto the operand stack long value, long value long result
102 66 arithmetic operations fsub pop the first 2 floats from the operand stack, subtract them and place the float result onto the operand stack float value, float value float result
103 67 arithmetic operations dsub pop the first 2 doubles from the operand stack, subtract them and place the double result onto the operand stack double value, double value double result
104 68 arithmetic operations imul pop the first 2 ints from the operand stack, multiply them and place the integer result onto the operand stack integer value, integer value integer result
105 69 arithmetic operations lmul pop the first 2 longs from the operand stack, multiply them and place the long result onto the operand stack long value, long value long result
106 6A arithmetic operations fmul pop the first 2 floats from the operand stack, multiply them and place the float result onto the operand stack float value, float value float result
107 6B arithmetic operations dmul pop the first 2 doubles from the operand stack, multiply them and place the double result onto the operand stack double value, double value double result
108 6C arithmetic operations idiv pop the first 2 ints from the operand stack, divide them and place the int result onto the operand stack integer value, integer value integer result
109 6D arithmetic operations ldiv pop the first 2 longs from the operand stack, divide them and place the long result onto the operand stack long value, long value long result
110 6E arithmetic operations fdiv pop the first 2 floats from the operand stack, divide them and place the float result onto the operand stack float value, float value float result
111 6F arithmetic operations ddiv pop the first 2 doubles from the operand stack, divide them and place the double result onto the operand stack double value, double value double result
112 70 arithmetic operations irem pop the first 2 ints from the operand stack, divide them and place the int remainder onto the operand stack integer value, integer value integer result
113 71 arithmetic operations lrem pop the first 2 longs from the operand stack, divide them and place the long remainder onto the operand stack long value, long value long result
114 72 arithmetic operations frem pop the first 2 floats from the operand stack, divide them and place the float remainder onto the operand stack float value, float value float result
115 73 arithmetic operations drem pop the first 2 doubles from the operand stack, divide them and place the double remainder onto the operand stack double value, double value double result
116 74 arithmetic operations ineg pop int from operand stack, negate int and push the int result onto operand stack integer value integer result
117 75 arithmetic operations lneg pop long from operand stack, negate long and push the long result onto operand stack long value long result
118 76 arithmetic operations fneg pop float from operand stack, negate float and push the float result onto operand stack float value float result
119 77 arithmetic operations dneg pop double from operand stack, negate double and push the double result onto operand stack double value double result
120 78 bitwise operations ishl pop int1 and int2 from operand stack, shift int1 left by s bit positions where s is the value of the low 5 bits of int2 and push the int result onto operand stack integer value1, integer value2 integer result
121 79 bitwise operations lshl pop long and int from operand stack, shift long left by s bit positions where s is the value of the low 6 bits of int and push the long result onto operand stack long value_1, integer value2 long result
122 7A bitwise operations ishr pop int1 and int2 from operand stack, shift int1 right by s bit positions (while keeping the sign bit the same) where s is the value of the low 5 bits of int2 and push the int result onto operand stack integer value1, integer value2 integer result
123 7B bitwise operations lshr pop long and int from operand stack, shift long right by s bit positions (while keeing the signbit the same) where s is the value of the low 6 bits of int and push the long result onto operand stack long value1, integer value2 long result
124 7C bitwise operations iushr pop int1 and int2 from operand stack, shift int1 right by s bit positions (ignore sign bit, add 0 extension) where s is the value of the low 5 bits of int2 and push the int result onto operand stack integer value1, integer value2 integer result
125 7D bitwise operations lushr pop long and int from operand stack, shift long right by s bit positions (ignore sign bit, add 0 extension) where s is the value of the low 6 bits of int and push the long result onto operand stack long value1, integer value2 long result
126 7E bitwise operations iand pop two integer values from operand stack and apply AND operation. Push the result onto the operand stack. integer value1, integer value2 integer result
127 7F bitwise operations land pop two long values from operand stack and apply AND operation. Push the result onto the operand stack. long value1, long value2 long result
128 80 bitwise operations ior pop two integer values from operand stack and apply OR operation. Push the result onto the operand stack. integer value1, integer value2 integer result
129 81 bitwise operations lor pop two long values from operand stack and apply OR operation. Push the result onto the operand stack. long value1, long value2 long result
130 82 bitwise operations ixor pop two integer values from operand stack and apply XOR operation. Push the result onto the operand stack. integer value1, integer value2 integer result
131 83 bitwise operations lxor pop two long values from operand stack and apply XOR operation. Push the result onto the operand stack. long value1, long value2 long result
132 84 arithmetic operations iinc index byte, constbyte increment the int from the local variable at index indicated by the index byte (unsigned 8-bit integer), with constbyte (signed 8-bit integer)
133 85 widening operations i2l pop int from operand stack and sign-extend to a long. Push the result onto the operand stack integer value long value
134 86 widening operations i2f pop int from operand stack and convert to a float using IEEE 754 and round to nearest mode. Push the result onto the operand stack integer value float value
135 87 widening operations i2d pop int from operand stack and convert to a double. Push the result onto the operand stack integer value double value
136 88 narrowing operations l2i pop long from operand stack and convert to an int by taking the low-order 32 bits of the long value and discarding the high-order 32 bits. Push the result onto the operand stack long value integer value
137 89 widening operations l2f pop long from operand stack and convert to a float using IEEE 754 and round to nearest mode. Push the result onto the operand stack long value float value
138 8A widening operations l2d pop long from operand stack and convert to a double using IEEE 754 and round to nearest mode. Push the result onto the operand stack long value double value
139 8B narrowing operations f2i pop float from operand stack and convert to an int. Push the result onto the operand stack float value integer value
140 8C narrowing operations f2l pop float from operand stack and convert to a long. Push the result onto the operand stack float value long value
141 8D widening operations f2d pop float from operand stack and convert to a double. Push the result onto the operand stack float value double value
142 8E narrowing operations d2i pop double from operand stack and convert to an int. Push the result onto the operand stack double value integer value
143 8F narrowing operations d2l pop double from operand stack and convert to a long. Push the result onto the operand stack double value long value
144 90 narrowing operations d2f pop double from operand stack and convert to a float. Push the result onto the operand stack double value float value
145 91 narrowing operations i2b pop int from operand stack and truncate to a byte, then sign-extend to an int. Push the result onto the operand stack integer value integer value
146 92 narrowing operations i2c pop int from operand stack and truncate to a char, then zero-extend to an int. Push the result onto the operand stack integer value integer value
147 93 narrowing operations i2s pop int from operand stack and truncate to a short, then sign-extend to an int. Push the result onto the operand stack integer value integer value
148 94 comparison operations lcmp pop two long values from operand stack.

If value1 > value2, the int value 1 is pushed onto the operand stack.

If value1 == value2, the int value 0 is pushed onto the operand stack.

If value1 < value2, the int value -1 is pushed onto the operand stack.
long value1, long value2 integer value
149 95 comparison operations fcmpl pop two float values from operand stack.

If value1 > value2, the int value 1 is pushed onto the operand stack.

If value1 == value2, the int value 0 is pushed onto the operand stack.

If value1 < value2, the int value -1 is pushed onto the operand stack.

If value1 or value2 is NaN, the int value -1 is pushed onto the operand stack.
float value1, float value2 integer value
150 96 comparison operations fcmpg pop two float values from operand stack.

If value1 > value2, the int value 1 is pushed onto the operand stack.

If value1 == value2, the int value 0 is pushed onto the operand stack.

If value1 < value2, the int value -1 is pushed onto the operand stack.

If value1 or value2 is NaN, the int value 1 is pushed onto the operand stack.
float value1, float value2 integer value
151 97 comparison operations dcmpl pop two double values from operand stack.

If value1 > value2, the int value 1 is pushed onto the operand stack.

If value1 == value2, the int value 0 is pushed onto the operand stack.

If value1 < value2, the int value -1 is pushed onto the operand stack.

If value1 or value2 is NaN, the int value -1 is pushed onto the operand stack.
double value1, double value2 integer value
152 98 comparison operations dcmpg pop two double values from operand stack.

If value1 > value2, the int value 1 is pushed onto the operand stack.

If value1 == value2, the int value 0 is pushed onto the operand stack.

If value1 < value2, the int value -1 is pushed onto the operand stack.

If value1 or value2 is NaN, the int value 1 is pushed onto the operand stack.
double value1, double value2 integer value
153 99 control transfer ifeq highbyte, lowbyte pop int value from operand stack, if equal to 0 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value
154 9A control transfer ifne highbyte, lowbyte pop int value from operand stack, if not equal to 0 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value
155 9B control transfer iflt highbyte, lowbyte pop int value from operand stack, if less than 0 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value
156 9C control transfer ifge highbyte, lowbyte pop int value from operand stack, if greater or equal than 0 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value
157 9D control transfer ifgt highbyte, lowbyte pop int value from operand stack, if greater than 0 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value
158 9E control transfer ifle highbyte, lowbyte pop int value from operand stack, if less or equal than 0 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value
159 9F control transfer if_icmpeq highbyte, lowbyte pop two int value from operand stack, if value1 == value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value1, integer value2
160 A0 control transfer if_icmpne highbyte, lowbyte pop two int value from operand stack, if value1 != value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value1, integer value2
161 A1 control transfer if_icmplt highbyte, lowbyte pop two int value from operand stack, if value1 < value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value1, integer value2
162 A2 control transfer if_icmpge highbyte, lowbyte pop two int value from operand stack, if value1 >= value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value1, integer value2
163 A3 control transfer if_icmpgt highbyte, lowbyte pop two int value from operand stack, if value1 > value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value1, integer value2
164 A4 control transfer if_icmple highbyte, lowbyte pop two int value from operand stack, if value1 <= value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction integer value1, integer value2
165 A5 control transfer if_acmpeq highbyte, lowbyte pop two reference values from operand stack, if value1 == value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction reference value1, reference value2
166 A6 control transfer if_acmpne highbyte, lowbyte pop two reference values from operand stack, if value1 != value2 then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction reference value1, reference value2
167 A7 control transfer goto highbyte, lowbyte Jump to the operand stack address indicated by highbyte and lowbyte and execute the opcode at that address
168 A8 control transfer jsr highbyte, lowbyte The address of the opcode of the instruction immediately following this jsr instruction is pushed onto the operand stack as a value of type returnAddress. Then jump to operand stack address indicated by highbyte and lowbyte return address
169 A9 control transfer ret index byte load returnAddress from local variable at index indicated by index byte (unsigned 8-bit integer) and write this value into the Java virtual machine's pc register, and execution continues there.
170 AA switch statement implementation tableswitch access jump table by index and jump label 2
171 AB switch statement implementation lookupswitch access jump table by key match and jump label 2
172 AC method invocation and return ireturn pop int from operand stack of the current frame (= method) and push onto the operand stack of the frame of the invoker integer value [operand stack empty]
173 AD method invocation and return lreturn pop long from operand stack of the current frame (=method) and push onto the operand stack of the frame of the invoker long value [operand stack empty]
174 AE method invocation and return freturn pop float from operand stack of the current frame (=method) and push onto the operand stack of the frame of the invoker float value [operand stack empty]
175 AF method invocation and return dreturn pop double from operand stack of the current frame (=method) and push onto the operand stack of the frame of the invoker double value [operand stack empty]
176 B0 method invocation and return areturn pop object reference from operand stack of the current frame (=method) and push onto the operand stack of the frame of the invoker object ref [operand stack empty]
177 B1 method invocation and return return exit operand stack of the current frame (=method) and goto the operand stack of the frame of the invoker [operand stack empty]
178 B2 object creation and manipulation getstatic highbyte, lowbyte resolve the class or interface from the Field Ref found in the constant pool at the address indicated by highbyte and lowbyte, the class or interface value is pushed onto the operand stack class interface value
179 B3 object creation and manipulation putstatic highbyte, lowbyte the type descriptor referenced by the Field Ref found in the constant pool at the address indicated by highbyte and lowbyte is updated by the value popped from the operand stack value
180 B4 object creation and manipulation getfield highbyte, lowbyte fetch field from object object ref value
181 B5 object creation and manipulation putfield set field in object field reference
182 B6 method invocation and return invokevirtual invoke instance method; dispatch based on class method reference
183 B7 method invocation and return invokespecial invoke instance method; special handling for superclass, private, and instance initialization method invocations method reference
184 B8 method invocation and return invokestatic invoke a class (static) method method reference
185 B9 method invocation and return invokeinterface invoke interface method method reference 2
186 BA ***unused*** reserved for historical reasons
187 BB object creation and manipulation new index byte1, index byte2 resolve the Class type from the Class Ref found in the constant pool at the address indicated by indexbyte1 and index byte2. Memory for a new instance of that class is allocated from the garbage-collected heap, and the instance variables of the new object are initialized to their default initial values. The objectref, a reference to the instance, is pushed onto the operand stack. object ref
188 BC object creation and manipulation newarray atype pop an int value (=count) from the operand stack. This value represents the number of elements in the array to be created. The array type is indicated by the atype value:

BOOLEAN 4
CHAR 5
FLOAT 6
DOUBLE 7
BYTE 8
SHORT 9
INT 10
LONG 11

A new array whose components are of type atype and of length count is allocated from the garbage-collected heap. A reference arrayref to this new array object is pushed into the operand stack.
integer value array ref
189 BD object creation and manipulation anewarray index byte1, index byte2 pop an int value (=count) from the operand stack. This value represents the number of elements in the array to be created. Indexbyte1 and indexbyte2 are used to construct an index into the constant pool The array type can be a class, array, or interface. A new array with components of that type, of length count, is allocated from the garbage-collected heap, and a reference arrayref to this new array object is pushed onto the operand stack. All components of the new array are initialized to null, the default value for reference types. integer value array ref
190 BE object creation and manipulation arraylength The arrayref must be of type reference and must refer to an array. It is popped from the operand stack. The length of the array it references is determined. That length is pushed onto the operand stack as an int. array ref integer value
191 BF athrow The objectref must be of type reference and must refer to an object that is an instance of class Throwable or of a subclass of Throwable. It is popped from the operand stack. The objectref is then thrown by searching the current method for the first exception handler that matches the class of objectref. If an exception handler that matches objectref is found, it contains the location of the code intended to handle this exception. The pc register is reset to that location, the operand stack of the current frame is cleared, objectref is pushed back onto the operand stack, and execution continues. If no matching exception handler is found in the current frame, that frame is popped. If the current frame represents an invocation of a synchronized method, the monitor acquired or reentered on invocation of the method is released or exited (respectively) as if by execution of a monitorexit instruction. Finally, the frame of its invoker is reinstated, if such a frame exists, and the objectref is rethrown. If no such frame exists, the current thread exits. object ref [operand stack empty], object ref
192 C0 object creation and manipulation checkcast index byte1, index byte2 check whether object is of given type object ref object ref
193 C1 object creation and manipulation instanceof determine if object is of given type class name, or array type
194 C2 monitorenter enter monitor for object
195 C3 monitorexit exit monitor for object
196 C4 load and store instructions wide Format1: <opcode>, index byte1, index byte2

Format2: <opcode>, index byte1, index byte2, const_byte1, const_byte2
The opcodes iload, fload, aload, lload, dload, istore, fstore, astore, lstore, dstore, ret and iic are all using one index byte to access 256 addresses in the local variable.

The wide instruction extends the local variable index for the above mentioned opcodes by 65536.

Format 1:
The wide opcode is followed by one of the <opcodes> iload, fload, aload, lload, dload, istore, fstore, astore, lstore, dstore, or ret. Following the <opcodes> are two unsigned bytes index byte1 and index byte2 which are assembled into a 16-bit unsigned index to a local variable. These 2 bytes extends the local variable index by 65536.
More information about each <opcodes> can be found elsewhere in this table.

Format 2:
The wide opcode is followed by the opcode iinc, followed by two unsigned bytes index byte1 and index byte2 which are assembled into a 16-bit unsigned index to a local variable. Then two unsigned bytes const_byte1 and const_byte2 are folowed which are also assembled into a signed 16-bit constant.

More information about opcode iinc can be found elsewhere in this table.
Same as modified instruction Same as modified instruction
197 C5 object creation and manipulation multianewarray index byte1, indexbyte2, dimension create new multi- dimensional array class name, or array type 2
198 C6 control transfer ifnull highbyte, lowbyte pop reference value from operand stack, if equal to null then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction reference value
199 C7 control transfer ifnonnull highbyte, lowbyte pop reference value from operand stack, if not equal to null then jump to operand stack address indicated by highbyte and lowbyte, else continue with next instruction reference value
200 C8 control transfer goto_w branchbyte1, branchbyte2, brachbyte3, branchbyte4 Jump to the operand stack address indicated by (branchbyte1 << 24) | (branchbyte2 << 16) | (branchbyte3 << 8) | branchbyte4 and execute the opcode at that address.
201 C9 control transfer jsr_w branchbyte1, branchbyte2, brachbyte3, branchbyte4 The address of the opcode of the instruction immediately following this jsr_w instruction is pushed onto the operand stack as a value of type returnAddress. Then jump to operand stack address indicated by branchbyte1, branchbyte2, branchbyte3, branchbyte4 return address
202 CA ***reserved opcodes*** breakpoint reserved for breakpoints in Java debuggers; should not appear in any class file
203-253 CB-FD (no name) these values are currently unassigned for opcodes and are reserved for future use
254 FE ***reserved opcodes*** impdep1 reserved for implemen- tation dependent operations within debuggers; should not appear in any class file
255 FF ***reserved opcodes*** impdep2 reserved for implemen- tation dependent operations within debuggers; should not appear in any class file


More information about the JVM instruction set can be found at: