Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does Java byte code look like?

On the Wikipedia page http://en.wikipedia.org/wiki/Java_bytecode#Instructions it says Java byte code looks like this:

0:   iconst_2
1:   istore_1
2:   iload_1
3:   sipush  1000
6:   if_icmpge       44
9:   iconst_2
10:  istore_2
11:  iload_2
12:  iload_1
13:  if_icmpge       31

I thought that Java byte code was executed like a series of integers in hexadecimal or binary?

like image 282
user3318845 Avatar asked Feb 14 '23 14:02

user3318845


1 Answers

What Wikipedia shows is the "assembly language" for a JVM. Not the "machine code" for a JVM.

like image 186
Andres Avatar answered Feb 16 '23 04:02

Andres