Disclaimer: This is an example of a student written essay.
Click here for sample essays written by our professional writers.

Any opinions, findings, conclusions or recommendations expressed in this material are those of the authors and do not necessarily reflect the views of UKEssays.com.

Machine language

Paper Type: Free Essay Subject: Information Technology
Wordcount: 2187 words Published: 1st Jan 2015

Reference this

        Machine Language (a native language of the computer) is a collection of binary byte or bits that the computer can read and interpret. Machine language is a coding system built into the hardware of the computer, requiring no translation before being run. Therefore a machine language can also be a machine code.

        Machine language consists of 1’s and 0’s. For a program to run, it must be presented to the computer as binary coded machine instructions that are specific to that CPU model or family. Although programmers are sometimes able to modify language in order to fix a running program; they do not create it but rather machine language is created by programmers called assemblers, compliers and interpreters which converts the lines of programming code a human writes into the machine language.

        Every processor has its own machine code; therefore machine language differs substantially, i.e. , what may take one instruction in one machine can take 10 instructions in another machine.

A computer is a machine with inbuilt of millions of tiny switches calledtransistor and they can be wired together in such a way that an output from one switch can turn another switch on or off. As a computer computes, these switches turn each other on or off in a pattern determined both by the way they are wired together and by the program that the computer is executing. A computer can work directly with binary numbers because switches can readily represent such numbers: Turn the switch on to represent a one; turn it off to represent a zero. Machine language instructions are stored in memory as patterns of switches turned on or off. When a machine language instruction is loaded into the CPU, all that happens is that certain switches are turned on or off in the pattern that encodes that particular instruction.

Some binary codes used to represent machine language information in a digital computer include:

  1. Binary Coded Decimal (BCD) code
  2. American Standard Code for International Interchange (ASCII) code
  3. Gray code
  4. External Binary Code Decimal Interchange Code (EBCDIC) code
  5. Excess-3 code

American Standard Code for International Interchange:

This represents numbers, letters, punctuation, marks and control characters. A standard ASCII is a 7- bit code (127 characters) while an extended ASCII (IBM ASCII) which is also popular is an 8- bit code. An extended ASCII adds graphics and mathematical symbols to code (total of 256 symbols). An example of ASCII is written below.

External Binary Code Decimal Interchange Code:

This is an extension of binary coded decimal (BCD). EBCDIC, is an eight or one byte wide. Each byte consists of two nibbles, each four bits wide. The first four bits define the class of character, while the second nibble defines the specific character inside that class. And recently, it has been to 16 and 32 bit variants to allow for representation of large non- Latin character sets.

Get Help With Your Essay

If you need assistance with writing your essay, our professional essay writing service is here to help!

Essay Writing Service

Factors like dust, electrical disturbance, etc can cause interference in a circuit that is transmitting a byte. The detection of these errors can be accomplished by the use of parity bit, which is also called a check bit. Parity bit is an extra bit attached to the end of a byte for purpose of checking accuracy. Parity schemes may be odd or even.


In computational linguistics, translation is a subfield that makes use of computer software to translate text or speech from one natural language to the other. Translation is the use of software (translator) to translate a high-level language program or an assembly language program into a machine language program.

Types of translators

  • Assembler
  • Interpreter
  • Compiler

But we will discuss briefly on compiler and interpreter.


A compiler is a program that translates high-level code into machine code.

How does it work :

It produces object code (translated instructions ready for computer) by translating the source code (high level language instruction). The object code is stored in the machine and can be used repeatedly.


  • Source code: This is a computer program which is written by the programmer in some formal programming language.
  • Object code: This is the output from the compiler. It is same as machine language translation of the source program. Files from this code always usually have the extension ‘obj’.
  • A linker or linkage editor: is a program is a program that pulls other programs together so that they can run. For the fact that most programs are very large and consists of several modules, the linker pulls everything together and makes sure that refrences to other parts of the program (code) are resolved.

Compilers parse the instructions into machine code and store them in a separate file for later execution. Many modern compilers can compile (parse) and execute in memory, giving the ‘appearance’ of an interpreted language.


Object program generated by compiler is machine independent, therefore programs compiled for one type of machine will not run in another type, which means every type of machine must have its personal compiler for a particular language.


There are many ways errors are being detected in a compiler. Examples are listed below;


If part of the program is mistyped, the compiler may issue a syntax message by listing the tokens which would be acceptable at that point. The message usually displays the type of the error; the line number where the error was detected, the code on that line, and the position of the error within the code.

For example: This error is omitting a semicolon (;) at the end of the statement. Here is the error that will be written;

Testing.java 13: ‘j’ expected. System.out.println (“Input has ” +count+ “chars”.)^ 1 error.


In addition, verifying that your program is syntactically correct, the compiler checks for other basic correctness. For example the compiler warns you each time for use of a variable that has not been initialized: testing.java:13: variable count must have been initialize. count ++ ^ testing. Java:14: variable count may not have been initialized. System.out.println(“Input has” +count+ “chars”); ^ 2 errors. Therefore your program did not successfully compile.

Common errors reported during semantic analysis “identifier not declared”.


Run-time errors such as division by 0 should be detected.

How it is detected:

Some system provide the hexadecimal address of the offending program, while some do tell the name of the routine the error was in and possibly the name and some give the source line.


Below are some few languages that makes use of compiler:

  • Newer forms of BASIC(such as visual basic)
  • C/C++
  • PASCAL, etc.


Like a compiler, it translates a high level language into machine language but it does translates the program at the time of executing the program instruction by instruction. The translated code is not stored permanently in computer memory, hence before execution interpretation becomes necessary. The fact that object code is not stored in the computer, execution of the program becomes slower because of the need for interpretation before each execution. It eliminates the need for a separate compilation after changes to each program. Normally, it is easier to design an interpreter than a compiler.


It takes one statement of higher level languages; translate it into machine language and immediately execute it. Translation and execution are carried out for each statement.


There are variousprogramming languagesthat use an interpreter but some are listed below. They are as follows:

  • LISP
  • Prolog
  • JavaScript
  • Forth
  • Actionscript, etc.


The output of an interpretation process is an intermediate code that is later executedinto object program. An example is a bytecode.


If the interpreter encounters an error while converting a line of code, an error message will be displayed immediately and the interpretation stops. Here, the programmer can correct the error before the interpreter translates the next line of code.


  • Platform Independence: This implies that it is not restricted or confined to any particular computer’s architecture.
  • Ease of debugging: It is easier to get source code information in interpreted languages. This facilitates debugging of errors.
  • Interpreted programs are flexible.


  • Interpreted programs do not run fast.
  • No object code is produced.



Well, it actually depends on how you want to run your program


  • It spends a lot of time analysing and processing the program
  • The executable result is in form of a machine specific binary code
  • The computer hardware interprets (executes) the resulting code
  • Program execution is fast


  • Little time is spent in analyzing and processing the program
  • The resulting code is some sort of intermediate code
  • The resulting code is interpreted by another program
  • Program execution is slow


Whether using a compiled or interpreted language, you will likely need a text editor in which to enter your instructions. Many compilers come complete with integrated editors optimized for working with the specific language. Using these editors is really not much different from using general text editing tools and word processors, though they may look quite different. One key point here is that so long as you follow the proper format requirements for a given interpreter or compiler, you can use any text editor you chose to construct and edit your source code.



  • http://www.answers.com/topic/machine-language
  • http://dictionary.reference.com/browse/machine+language
  • http://www.answers.com/topic/reduced-instruction-set-computer
  • http://www.computerhope.com/jargon/m/machlang.htmto
  • http://www.economicexpert.com/a/Machine:language.htm
  • http://www.google.com.sg/search?hl=en&q=machine+language+example&meta=&aq=0&oq=machine+language+exa
  • http://onlinedictionary.datasegment.com/word/machine+language
  • http://math.hws.edu/javanotes/c1/s1.html
  • http://www.yourdictionary.com/computer/gray-code
  • http://www.wisegeek.com/what-is-ebcdic.htm
  • http://www.answerbag.com/q_view/375603
  • http://www.nos.org/htm/funda3.htm


  • http://www.answers.com/topic/machine-translation
  • http://publib.boulder.ibm.com/infocenter/comphelp/v7v91/index.jsp?topic=/com.ibm.aix.pli.doc/ibmx2mst127.htm
  • ….DocumentsDownloadslanguages and os.pps
  • http://java.sun.com/docs/books/tutorial/getStarted/problems/
  • http://web.cs.wpi.edu/~gpollice/cs544-f05/CourseNotes/maps/Class1/Structureofacompiler.html
  • http://web.cs.wpi.edu/~gpollice/cs544-f05/CourseNotes/maps/Class1/Compilervs.Interpreter.html


Cite This Work

To export a reference to this article please select a referencing stye below:

Reference Copied to Clipboard.
Reference Copied to Clipboard.
Reference Copied to Clipboard.
Reference Copied to Clipboard.
Reference Copied to Clipboard.
Reference Copied to Clipboard.
Reference Copied to Clipboard.

Related Services

View all

DMCA / Removal Request

If you are the original writer of this essay and no longer wish to have your work published on UKEssays.com then please: