Professional Documents
Culture Documents
Untitled
Untitled
Untitled
LIGHT BULB
00000000:STOP PROGRAM
00000001:TURN BULB ON
00000010:TURN BULB OFF
00000100:DIM BULB BY 10%
00001000:BRIGHTEN BULB BY 10%
Fig.2.1.2 Light blub Programming
ASSEMBLY LANGUAGE
An assembly (or assembler) language, often abbreviated asm, is a low-level programming
language for a computer, or other programmable device, in which there is a very strong (but often
not one-to-one) correspondence between the language and the architecture's machine
code instructions. Each assembly language is specific to a particular computer architecture. In
contrast, most high-level programming languages are generally portable across multiple architectures
but require interpreting or compiling. Assembly language may also be called symbolic machine code.
[2]
COMPILERS
Compiler is a translator which is used to convert programs in high-level language to low-level
language.
HOMEWORK (ASESSMENT)
Q1. ___________ symbol is used to signify write back mode.
A. #
B. ^
C. &
D. !
Answer: A
Q2. In which cycle the memory is read and the contents of memory at the address contained in the PC
regtister are loaded into into IR.
A. Execution Cycle
B. Memory Cycle
C. Fetch Cycle
D. Decode Cycle
Answer: C
Q3. List the assembly language program (of the equivalent binary instructions) generated by a
compiler for the following IF statement:
I F (A - B) 1 0, 2 0, 3 0
The program branches to statement 10 if A - B < 0; to statement 20 if A - B = 0; and to statement
30 if A - B > 0.
References
Reference Books:
Stallings, W., “Computer Organization and Architecture”, Eighth Edition, Pearson Education.
Text Books:
Video References
https://www.youtube.com/watch?v=RHvioCFOzZo
https://www.youtube.com/watch?v=BQleAPh1Z3I