fload <varnum>
or
wide
fload <varnum>
In
the first form, <varnum> is an unsigned integer in the range 0 to 0xFF.
In the second (wide) form, <varnum> is an unsigned integer in the range 0
to 0xFFFF.
Stack
Before
Description
After
...
float-value
...
Pushes the float value held in a local variable onto the operand stack. The fload instruction takes a single parameter, <varnum>, an unsigned integer which indicates which local variable to retrieve. The single-word float held in that local variable is retrieved and placed on the stack. <varnum> must be a valid local variable number in the current frame.
Example
fconst_2 ; push 2.0 onto the stack
fstore 1 ; pop 2.0 off of the stack and store in local variable 1
fload 1 ; push the value from local variable 1 (the value 2.0)
; back onto the stack
BytecodeFor local variable numbers in the range 0-255, use:
Type
|
Description
|
|
u1
|
fload
opcode = 0x17 (23)
|
|
u1
|
<varnum>
|
Type
|
Description
|
| u1
|
wide
opcode = 0xC4 (196)
|
|
u1
|
fload
opcode = 0x17 (23)
|
|
u2
|
<varnum>
|
iload, lload, aload, dload, wide