Uploaded by TTTWZ Wang

Description of Coursework 03 (Replacement of Quiz)- 10% (7)

advertisement
OFFICE OF ACADEMIC AFFAIRS
Reference No. : XMUM.OAA - 100/2/8-V2.0
Effective Date : 23 APRIL 2018
DESCRIPTION OF COURSEWORK
Course Code
CST301
Course Name
Principles of computer composition
Lecturer
Wang Yiju
Academic Session 2021/09
Assessment Title
Assignment 3
A. Introduction/ Situation/ Background Information
This assignment provides an avenue for students to better understand data representation, computer
organization, computer arithmetic, the functions of CPUs and their working model, registers of
different CPUs and six important status flags, and main memory.
B. Course Learning Outcomes (CLO) covered
At the end of this assessment, students are able to:
CLO 1
Explain the principles underlying computer system design and development.
CLO 3
Evaluate the performance of CPU, memory and I/O operations
CLO4
Design a basic computer system using the major components.
C. University Policy on Academic Misconduct
1. Academic misconduct is a serious offense in Xiamen University Malaysia. It can be defined
as any of the following:
i. Plagiarism is submitting or presenting someone else’s work, words, ideas, data or
information as your own intentionally or unintentionally. This includes incorporating
published and unpublished material, whether in manuscript, printed or electronic form into
your work without acknowledging the source (the person and the work).
ii. Collusion is two or more people collaborating on a piece of work (in part or whole) which
is intended to be wholly individual and passed it off as own individual work.
iii. Cheating is an act of dishonesty or fraud in order to gain an unfair advantage in an
assessment. This includes using or attempting to use, or assisting another to use materials
that are prohibited or inappropriate, commissioning work from a third party, falsifying data,
or breaching any examination rules.
2. All the assessment submitted must be the outcome of the student. Any form of academic
misconduct is a serious offense which will be penalised by being given a zero mark for the
entire assessment in question or part of the assessment in question. If there is more than one
guilty party as in the case of collusion, both you and your collusion partner(s) will be subjected
to the same penalty.
D. Instruction to Students
submission type: Softcopy
submission due date: Dec 27, 2021.
E. Evaluation Breakdown
No.
1.
Component Title
Assignment
TOTAL
Percentage
(%)
10%
10%
F. Task(s)
Question 1 (60 marks) [10 marks each]
Assume that BX, SI, and DI contain the following value:
(BX) = 0200H
(SI) = 8124H
(DI) =FF78H,
(DS)=0000H
The memory locations contain the following values:
mem(1200H) = 82ABH
mem(0200H) = 3CD6H
mem(8324H) = 1AB4H
and that label ALPHA has the following value with address 1000H:
ALPHA 1200H
For each of the following instructions (executed separately), specify the addressing mode used,
write the expression for effective address EA in register transfer language, calculate it, and give
the result of operation.
(a) ADD BX, 1234H
(b) ADD SI, [BX]
(c) SUB DI, [BX][SI]
(d) MOV ALPHA, BX
(e) MOV AX, [BX]ALPHA
(f) LEA AX, ALPHA
Question 2 (20 marks) [4 marks each]
Given two binary signed numbers in two’s compliment representation:
A=01101101 B=10110010
and two labels ALPHA and BETA with addresses 00010100H and 00A8B0C8H for locating A
and B in memory, respectively. Write an instruction or a shortest sequence of instructions with
proper addressing modes for performing each of the following independent activities.
(a) Move number A to register BX
(b) Move number B to memory location whose address is in register EBX
(c) Add number A in register BX to number B in memory with address in register ESI.
(d) Subtract number A in register BX from number B in memory with address BETA.
(e) Move address of ALPHA to register EBX
Question 3 (20 marks) [5 marks each]
Given the following data before execution of instruction,
Address
20002
20004
20006
20008
2000A
Contents
EDBC
345C
08BC
BE60
2CA7
(DS)=(SS)=2000H
(SP)=0006H
BX=0003H
AX=A34DH
for each of the indicated instructions (executed separately), write the expressions for the effective
addresses of the source and destination operands in register transfer language, calculate them,
and give the resulting contents of register and the contents of affected memory locations after
execution.
1)
2)
3)
4)
ADD BX, [0003]
PUSH BX
POP BX
AND AX, [BX+0004H]
Download