computer systems organization. example 1: describe the sequence of events carried out during the...

10
Computer Systems Organization

Upload: joseph-anderson

Post on 17-Jan-2016

212 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

Computer Systems Organization

Page 2: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

• Example 1:

Describe the sequence of events carried out during the machine cycle when executing the following instructions.

Address

Contents

500 LDA 1000

501 ADD 1001

502 STO 1002

503 JMP 510

1000 4

1001 6

1003

Page 3: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

• Instruction #1

LDA 1000 – Load to the accumulator the

contents of the memory location 1000.

Page 4: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

:

:

500 501 502 503LDA 1000

41000 1001 1002 1003

6

ADD 1001 STO 1002 JMP 510::

::

IR

MAR MDR

PC

TMPACC

500

500

CPU

MM

Addressbus

Databus

R W

LDA 1000

LDA 1000

Decode

501

1000 4

4

LDA 1000

4

Page 5: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

• Instruction #2

ADD 1001 – add the contents of location

1001 and the contents of the

accumulator and store the result back in

the accumulator.

Page 6: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

:

:

500 501 502 503

1000 1001 1002 10036

ADD 1001 STO 1002 JMP 510::

::

IR

MAR MDR

PC

TMPACC

501

501

CPU

MM

Addressbus

Databus

R W

502

1001

4

LDA 1000

4

ADD 1001

ADD 1001

ADD 1001

Decode

6

6

6

10

Add

Page 7: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

• Instruction #3

STO 1002 – store the contents of the

accumulator to the memory location

1002.

Page 8: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

:

:

500 501 502 503

1000 1001 1002 10036

ADD 1001 STO 1002 JMP 510::

::

IR

MAR MDR

PC

TMPACC

502

502

CPU

MM

Addressbus

Databus

R W

503

1002

LDA 1000

4

10

STO 1002

STO 1002

STO 1002

Decode

100210

10

Page 9: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

• Instruction #4

JMP 510 – Jump to memory location 510

Page 10: Computer Systems Organization. Example 1: Describe the sequence of events carried out during the machine cycle when executing the following instructions

:

:

500 501 502 503

1000 1001 1002 10036

ADD 1001 STO 1002 JMP 510::

::

IR

MAR MDR

PC

TMPACC

503

503

CPU

MM

Addressbus

Databus

R W

LDA 1000

4

Decode

10

JMP 510

JMP 510

JMP 510504510