answersLogoWhite

0

How many no of instructions does the java byte code has?

Updated: 12/12/2022
User Avatar

Anilshavukaru

Lvl 1
14y ago

Best Answer

200 instructions only.

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How many no of instructions does the java byte code has?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

Define the concept of Java Bytecode and its importance?

1. The byte code is intermediate language. 2. It is not understandable by user as well as processor. 3. Tjava program(.java) will get converted to byte-code(.class) after compilation. 4. It is a set of highly optimized instructions. Advantages(impotance) of byte code: 1. It is useful for exchanging java program without disclosing the logic implemented in it to others. 2. The byte code are many times compressed version of actual Java program.Therefore,it is easy and fast to transport them over the internet. 3. Byte codes are not executable and they are platform independent.


Why c plus plus compiler cannot produce byte code?

Byte code would be detrimental to performance because byte code must run in a virtual machine. Java compiles to byte code suitable for the Java Virtual Machine (JVM), but C++ compiles to native machine code. For that reason alone, C++ programs perform many times better than equivalent Java programs. However, the need for a virtual machine also means Java is highly-abstract, with no direct access to specific architecture features. C++ has no such limitations and can therefore produce highly-efficient code specific to any platform. Java simply cannot compete for performance, but Java programs need only be compiled once to run on any platform that supports the JVM, whereas C++ must be compiled separately for each platform, and preprocessor directive code must be written to suit each supported platform. This naturally requires a lot more work on the part of the programmer, but the performance speaks for itself.


Why JVM is platform independent?

by creating a jre spesific to each platform programmers can confidently write code in any platform and assume it willl also work in aany other. theirfore java is platform independent as bytecode would look the same on any platform, however will be implemented by a diffrent interpreter for each platform.


In order to write compile and execute java programs in my PC which software should i install?

Compilation (byte code conversion) and execution (interpretation) of JAVA programs requires a JAVA Compiler and a JAVA runtime. There are many JAVA development systems available, some free, some not free. Two vendors for the PC / Windows platform are Sun and Microsoft, but, again, there are others.


Character use only one byte why Java use two byte for character?

The number of bytes used by a character varies from language to language. Java uses a 16-bit (two-byte) character so that it can represent many non-Latin characters in the Unicode character set.

Related questions

Define the concept of Java Bytecode and its importance?

1. The byte code is intermediate language. 2. It is not understandable by user as well as processor. 3. Tjava program(.java) will get converted to byte-code(.class) after compilation. 4. It is a set of highly optimized instructions. Advantages(impotance) of byte code: 1. It is useful for exchanging java program without disclosing the logic implemented in it to others. 2. The byte code are many times compressed version of actual Java program.Therefore,it is easy and fast to transport them over the internet. 3. Byte codes are not executable and they are platform independent.


How java is fast?

Java is not fast. Compared to equivalent code compiled to native machine code it is extremely slow. However, it is somewhat faster than many other interpreted languages because the source code compiles to Java byte code which is suitable for interpretation by any Java virtual machine. Interpreting byte code is much quicker than interpreting source code and, unlike machine code, byte code is portable.


Why java's code first converted into byte code instead of directly converted into machine code?

Because that's how java works. There are many other languages (C, for example), that work with direct compilation, and others (like PHP) that are interpreted.


What kinds of differences are compiling and running Java vs C programs?

Although Java is often described as a compiled language, it is a language that is both compiled and interpreted. Unlike C++ which typically compiles to native machine code, Java compiles to Java byte code, the native language of the Java virtual machine. The key difference here is that the Java virtual machine is not machine dependent, thus the same byte code can be executed upon any physical machine with a suitable Java virtual machine implementation; it is highly portable. Machine code can only be executed upon the machine architecture for which it was compiled. To support other architectures, the source code must be recompiled for those architectures. In terms of execution, native machine code requires no further translation and can be executed as soon as the code is compiled successfully (including any and all shared libraries required by the executable). Java byte code requires that the Java virtual machine be memory-resident during execution as the byte code must be interpreted to produce native machine code while the byte code is executing within the virtual machine. In terms of memory consumption, C++ programs require no additional memory over and above the program's requirements. Java programs require additional memory for the Java virtual machine runtime. Java programs also consume additional memory to assist in memory management, such as automatic garbage collection. C++ programs manage their own memory using resource handles and smart pointers; the use of a garbage collector is optional. In terms of performance, C++ programs execute many times more quickly than equivalent Java programs due to Java's need to interpret the byte code.


Why c plus plus compiler cannot produce byte code?

Byte code would be detrimental to performance because byte code must run in a virtual machine. Java compiles to byte code suitable for the Java Virtual Machine (JVM), but C++ compiles to native machine code. For that reason alone, C++ programs perform many times better than equivalent Java programs. However, the need for a virtual machine also means Java is highly-abstract, with no direct access to specific architecture features. C++ has no such limitations and can therefore produce highly-efficient code specific to any platform. Java simply cannot compete for performance, but Java programs need only be compiled once to run on any platform that supports the JVM, whereas C++ must be compiled separately for each platform, and preprocessor directive code must be written to suit each supported platform. This naturally requires a lot more work on the part of the programmer, but the performance speaks for itself.


Why JVM is platform independent?

by creating a jre spesific to each platform programmers can confidently write code in any platform and assume it willl also work in aany other. theirfore java is platform independent as bytecode would look the same on any platform, however will be implemented by a diffrent interpreter for each platform.


In order to write compile and execute java programs in my PC which software should i install?

Compilation (byte code conversion) and execution (interpretation) of JAVA programs requires a JAVA Compiler and a JAVA runtime. There are many JAVA development systems available, some free, some not free. Two vendors for the PC / Windows platform are Sun and Microsoft, but, again, there are others.


Why java byte code accepts 200 instructions only?

I am not sure exactly how many instructions it has, but it really doesn't need more. Look how many keywords it has! Most of the work in programming is done by creating objects and invoking different methods; I imagine that at the bytecode level, oneinstruction is needed to call any method. The remainder would be "operands", pressumably after the bytecode instruction: the method name, and any relevant parameters.


Character use only one byte why Java use two byte for character?

The number of bytes used by a character varies from language to language. Java uses a 16-bit (two-byte) character so that it can represent many non-Latin characters in the Unicode character set.


How many bytes are there for jump instruction in 8085?

There are 74 instructions in the 8085 microprocessor.


Advantages of c plus plus over java?

The main advantage is that C++ programs compile to native machine code and therefore execute many times faster than equivalent Java programs, which compile to byte code suitable for interpretation by the Java virtual machine. C++ is also more efficient since it requires no interpretation (and therefore no interpreter), and can use memory just as efficiently as assembler. The main disadvantage is the code must be compiled separately for each platform. With Java, programs need only be compiled once for any platform.


Why c plus plus is still used even though java is introduced?

Java compiles to byte code which must run in a virtual machine. Although this allows Java programs to run on any supported platform without code changes, the level of abstraction is extremely high, with little or no access to a specific architecture features. As a result, a C++ program (which compiles to native machine code) will perform many times faster than an equivalent Java program can. The only downside is that C++ programs must be compiled separately for each supported platform. However, that's a small price to pay for high-performance code.