Go Back   TechArena Community > Software > Software Development
Become a Member!
Forgot your username/password?
Tags Active Topics RSS Search Mark Forums Read

Reply
 
Thread Tools Search this Thread
  #1  
Old 12-09-2009
Member
 
Join Date: Dec 2008
Posts: 70
what is the difference between machine code and byte code

what is the difference between machine code and byte code, I heard that Whenever we write any programing code and pass it on to the computer to execute that it convert it into some machine code, and forward the output to us, Is this only procedure does it does then what is role of byte code and machine code.
Reply With Quote
  #2  
Old 12-09-2009
Member
 
Join Date: Oct 2008
Posts: 180
Re: what is the difference between machine code and byte code

Generally, "machine code" refers to the data that can be executed by a certain computer, while "bytecode" refers to data that can be executed by a virtual machine. JAVAC compiles the java file and converts the program in bytecode (machine independent). The virtual machine takes the bytecode and produces machine code appropriate for the actual machine it is running on.
Reply With Quote
  #3  
Old 12-09-2009
Member
 
Join Date: Oct 2008
Posts: 167
Re: what is the difference between machine code and byte code

Byte Code is in the form of binary codes like 0/1 whether ASCII code is in the form of numeric digits which is assigned to characters and alphabets. Byte code is platform independent where ASCII codes are platform dependent. IT is different to a byte code interpreter.

Consider the following C function:

Code:
int sum() {
   return 5 + 6;
}
This will be compiled directly machine code. The exact instructions on say x86 and ARM processors will be different.
Reply With Quote
  #4  
Old 12-09-2009
Member
 
Join Date: Mar 2008
Posts: 258
Re: what is the difference between machine code and byte code

In a bytecode interpreter, the instruction format is usually designed for very fast "parsing" using shift and mask operators. Byte-code is a sort of intermediate code that is more abstract than machine code. It is often treated as a binary file containing an executable program much like an object module , which is a binary file containing a machine code produced by compilers.The interpreter, after "parsing" (I prefer "decoding") the instruction, immediately updates the state of the virtual machine and then begins decoding the next instruction. So after the bytecode gets processed in an interpreter, no remnant remains.
Reply With Quote
Reply

  TechArena Community > Software > Software Development
Tags: , , ,



Thread Tools Search this Thread
Search this Thread:

Advanced Search


Similar Threads for: "what is the difference between machine code and byte code"
Thread Thread Starter Forum Replies Last Post
Need help on removing Activation Required message BlackBerry 9930 Bold with MSL code SPC code Groupism Portable Devices 15 02-05-2014 03:00 PM
startup error code:0x80090006 ,,unable to locate activation code Mr.Walter Windows XP Support 3 04-01-2012 06:08 PM
Running a batch file from a remote machine in a VB code Radhu Software Development 1 14-10-2011 04:54 PM
What is difference between PIN2-PUK-PUK2 code Mansi gala Portable Devices 3 15-09-2009 01:06 PM
Error code 43 unable to open Time Machine Xan Operating Systems 5 03-04-2009 11:05 AM


All times are GMT +5.5. The time now is 07:47 AM.