Past-paper question · 2013 May-June · Paper 31 · Q3(d)

Question 3(d) 2013 · May-June · Paper 31 · 5 marks

Original past-paper question for 3(D)
Original past-paper question for 3(D)
Original past-paper question for 3(D)
Original past-paper question for 3(D)
Reveal official mark-scheme answer Official mark-scheme answer for 3(D)

Official answer for Question 3

Part (d)

Part (d)

✓
Memory location
✓
ACC
✓
109
✓
110
✓
Output
✓
(must be the first

Question 19

✓
0
✓
column entry)

Question 20

Question 20

Question 37

Question 38

Question 58

✓
58 /ft
✓
58 /ft

Mark scheme 9691_s13_ms_31.pdf →

Show text version of question

Question 3

Part (d)

Question 3

The table shows the assembly language instructions for a processor which has one general For

purpose register – the Accumulator (ACC), and an index register (IX). Examiner's Use

Instruction Explanation Op Code Operand

LDD <address> Direct addressing. Load the contents of the given address to ACC STO <address> Store the contents of ACC at the given address

LDI <address> Indirect addressing. At the given address is the address to be used. Load the contents of this second address to ACC Indexed addressing. Form the address as <address> + LDX <address> the contents of IX. Copy the contents of this address to ACC INC <register> Add 1 to the contents of the register (ACC or IX)

ADD <address> Add the contents of the given address to the contents of ACC OUT Output the contents of ACC (as a denary number) to the monitor IN Input a denary number from the keyboard and store in ACC

END End the program and return to the operating system

Question 7

The diagram shows a program loaded in main memory starting at location 100. For Examiner's Use Two of the op-codes have been partially blanked out.

Locations 200 onwards contain data which is used by the program.

Part (d)

Trace this assembly language program using the trace table below. For

The user inputs 19 followed by 37. Examiner's Use

100 IN 101 INC ACC 102 STO 109 103 IN 104 INC ACC 105 ADD 109 106 STO 110 107 OUT 108 END

Memory location ACC 109 110 Output

[5]
Topic relevance

Why this question appears here

86% assigned-topic match · Processor fundamentals › Assembly language

Topic-match percentages estimate how closely each question fits the selected syllabus topic. They are a guide for choosing stricter or broader practice.

Permanent source page: Educate A Change · From 9691_s13_qp_31.pdf

Keep practising this topic