answersLogoWhite

0


Best Answer

Bytecode creates an extra level of indirection.

The advantages of this extra level of indirection are:

  • Platform independence
  • Can create any number of programming languages (syntax) and have them compile down to the same bytecode.
  • Could easily create cross language converters
  • x86, x64, and IA64 no longer need to be compiled as seperate binaries. Only the proper virtual machine needs to be installed.
  • Each OS simply needs to create a virtual machine and it will have support for the same program.
  • Just in time compilation allows you to update a program just by replacing a single patched source file. (Very beneficial for web pages)

Some of the disadvantages:

  • Performance
  • Easier to decompile
User Avatar

Wiki User

11y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

12y ago

Java byte code helps portability as it allows any compter, with any system architecture to run the byte code. Instead of having to compile a java program to every different type of architecture or OS, the JVM (Java Virtual Machine) is compiled to each of the different architectures. This takes the burden off the programmer, allowing them to instantly create cross-platform code.

This answer is:
User Avatar

User Avatar

Wiki User

14y ago

The JIT compiler improves the speed.

The JIT compiler improves the speed.

The JIT compiler improves the speed.

The JIT compiler improves the speed.

This answer is:
User Avatar

User Avatar

Wiki User

14y ago

The JIT compiler improves the speed.

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Advantages Java bytecode
Write your answer...
Submit
Still have questions?
magnify glass
imp
Related questions

How many bytes does a Java VM have?

A JVM, or Java Virtual Machine, creates the environment in which programs that run using Java bytecode are processed. It does not itself possess bytes or bytecode.


Where does bytecode come from java?

It is created by the Java compiler, based on the source code (the .java file).


Does the bytecode is different for every processor?

No, Java bytecode, just like the source code, is universal. The only parts that changes between different architectures are the Java Runtime Environment and its sub-components (such as the Java Virtual Machine).


What do you get when you compile a java program?

The java interpreter or JVM (Java Virtual Machine) is not able to execute the java source code for a program. The java source code first needs to be compiled into bytecode that can be processed by JVM. Producing bytecode make the program platform independent as each platform has its own JVM. It is also possible to directly write bytecode, bypassing the need to compile, but that would be tedious job and also not good for security purpose as the compiler checks for various errors in a program.


What translates a Java program into Bytecode?

The Java Runtime Environment (JRE) converts the byte code to machine language.


Why java has compiler and interpreter both?

Java is both compiled and interpreted language.First Java source code has to be translated into Byte code, which is done with the help of a compiler.But these byte codes are not machine instructions. Therefore ,in second stage this byte code has to be translated into machine code.This task is performed by an Interpreter.Hence, Java use both compiler and interpreter.


Why java interpreted?

Java is both compiled and interpreted. At first, the Java source code (in .java files) is compiled into the so-called Bytecode (.class files). The Bytecode is a pre-compiled, platform independent version of your program. The .class files can be used on any operating system. When the Java application is started, the Bytecode is interpreted by the Java Virtual Mashine. Because the Bytecode is pre-compiled, Java does not have the disadvantages of classical interpreted languages, like BASIC.


Why java called platform indeependent?

Platform independent language means once compiled you can execute the program on any platform (OS). Java is platform independent. Because the Java compiler converts the source code to bytecode, which is Intermidiate Language. Bytecode can be executed on any platform (OS) using JVM( Java Virtual Machine).


What do you call a Program that runs Java byte code instruction?

Get the JDK & Bluej from net and the rest will be done by them. Java byte codes are stored as *.class ; where "*" represents the class name, in your hard disk. You can download BlueJ as well as JDK from the related link.


Java is both compiled and interpreted language meaning?

Instead of compiling to machine language, the Java compiler compiles for a "ficticious processor". A program called the Java Virtual Machine then interprets this on every machine. Note that Java is NOT an interpreted language. It is solely a compiled language. Java source code is always run through a compiler (typically 'javac') to be turned into bytecode. This is identical behavior as any other compiled language. The confusion is that Java bytecode is usually run on a Java Virtual Machine, which itself may both act as an interpreter and a compiler for the native instruction set the JVM runs on. However, the Java language itself is NOT dependent on how this bytecode is run - in fact, it is possible (and has been done) to build a hardware machine that runs Java bytecode directly.


What is a bytecode?

In Java, "bytecode" is the name given to the compiled class files. The "compilation" in this case is not for a specific processor, but rather for a kind of fictional processor - and it is meant to be run by a Java Virtual Machine.


What type of file is created by Java?

Java created a file called class, and is identified by having the .class at the end. This file includes a Java bytecode, which then can be used on the Java Virtual Machine.