Slide 1.3: Laboratory guidelines
Slide 1.5: Programming language generations (cont.)
Home

Programming Language Generations


1st Generation (Machine Language, Late 1940s)
A machine-language program is read and interpreted by the computer. A program in machine code consists of a sequence of machine instructions, which are binary strings. Execution of machine code may either be The basic execution cycle consists of
  1. fetching the next instruction from main memory,
  2. decoding it, and
  3. executing it.
 Microsoft (R) Macro Assembler Version 8.0		    08/06/08 10:16:56 
 test.asm						    Page 1 - 1
				INCLUDE Irvine32.inc
			      C ; Include file for Irvine32.lib      (Irvine32.inc)
			      C INCLUDE SmallWin.inc
                              C	; MS-Windows prototypes, structures, and constants  
			      C .NOLIST
			      C .LIST
  00000000			.code
  00000000			main PROC
  00000000  B8 00010000		   mov  eax, 10000h
  00000005  05 00040000		   add  eax, 40000h
  0000000A  2D 00020000		   sub  eax, 20000h
				   exit
  00000016			main ENDP
 				END main

2nd Generation (Assembly Language, Late 1940s)
Machine languages are almost impossible for humans to read and write. Assembly languages have the same structure and set of commands as machine languages, but they enable a programmers to use names instead of numbers. Each type of CPU has its own machine and assembly languages, so a program written for one type of CPU will not run on another (not portable). Assembly languages are used when speed is essential or when an operation is needed that is not possible in a high-level language.