Which Java bytecode instruction is used to invoke a static method?
Answer
invokestatic
Answer
invokestatic
The Java bytecode instruction used to invoke a static method is `invokestatic`.
Static methods belong to a class rather than to a particular object, so the JVM does not need an object reference such as `this` to call one. The instruction takes a two-byte index into the class file’s runtime constant pool, where a symbolic method reference identifies the class or interface, method name, and descriptor.
The JVM instruction set separates method calls according to dispatch behavior. `invokevirtual` is used for ordinary instance methods with dynamic dispatch, `invokeinterface` handles interface method calls, and `invokespecial` is used for constructors, private methods, and certain superclass calls. `invokestatic` specifically targets class or static methods.
The opcode for `invokestatic` is hexadecimal `0xb8`, or decimal 184. When Java source code calls a static method, the compiler normally emits this instruction. Unlike an instance call, the caller does not pass an implicit receiver object; only the declared method arguments are placed on the operand stack.
Source: Wikipedia · fact-checked Aug. 2026