lload_1 0x1f

Pushes the long in local variable 1.

Opcode
0x1f (31)
Family
Loads
Operands
none
Length
1 byte
Operand stack
… → …, value (long)
Can throw
nothing at run time (beyond linking errors)
Spec name
lload_<n>

What it does

Pushes the long in local variable 1. It is a long or double, so it takes two slots: local variables n and n+1, and two stack slots.

Slots 0 to 3 each have a one-byte instruction; the general lload takes a one-byte slot number, and wide extends that to two bytes.

How often javac uses it

In JDK 25.0.5's java.base module, lload_1 appears 2,828 times in 556 of its 7,391 classes: 0.14% of all instructions, the 78th most common of 194 opcodes in use. Some of the methods that use it: java.io.BufferedInputStream.skip, java.io.BufferedReader.skip, java.io.ByteArrayInputStream.skip, java.io.CharArrayReader.skip.

Example

From the sample classes, compiled by javac 25 with -g. Each Java line is shown above the bytecode it compiled to; lload_1 is highlighted.

long assignLongField(long v) in Tour, compiled by javac 25
78return total = v;
0aload_0 // this
1lload_1 // v
3putfield #37// Tour.total : long

Open in the viewer

Related instructions

lstore_1 Pops a long into local variable 1.lload Pushes the long in local variable (operand).wide Makes the next instruction take a two-byte local index (and a two-byte iinc constant).

Specification: JVMS §6.5, lload_<n> (Java SE 25).