Elements of the computer how a processor works
Download
1 / 12

Elements of the Computer How a processor works - PowerPoint PPT Presentation


  • 162 Views
  • Updated On :

Elements of the Computer (How a processor works). C.S. French Chapter 19. The Computer itself. Processor. Memory. Control Unit. ALU. 1 2 3 4 5 6 7 8 9 10 11 12. CIR. Accumulator. SCR. Input Output Unit. Peripheral Devices. MAR. MDR. Data Bus. Terms. Memory

Related searches for Elements of the Computer How a processor works

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
Download Presentation

PowerPoint Slideshow about 'Elements of the Computer How a processor works' - libitha


An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.


- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
Elements of the computer how a processor works l.jpg

Elements of the Computer(How a processor works)

C.S. French

Chapter 19


The computer itself l.jpg
The Computer itself.

Processor

Memory

Control

Unit

ALU

1

2

3

4

5

6

7

8

9

10

11

12

CIR

Accumulator

SCR

Input

Output

Unit

Peripheral Devices

MAR

MDR

Data Bus


Terms l.jpg
Terms

  • Memory

    • main memory (RAM), electronic, fast, volatile, expensive, holds data currently in use.

    • made up of many general purpose storage locations.

    • may hold data or instructions.

    • locations referred to by their ‘addresses’.

  • Data Bus

    • a set of wires for transmitting data.

  • Processor

    • controls the computer and carries out processing.

  • Register

    • a special purpose storage location in the processor.

  • Control Unit

    • controls the loading and execution of instructions.

  • MDR (Memory Data Register)

    • holds data temporarily as it enters and leaves the processor.


More terms l.jpg
More Terms

  • ALU (Arithmetic and Logic Unit)

    • carries out arithmetic and logic operations. (add, subtract, AND, NOT etc)

  • Accumulator

    • holds the result of the last operation carried out by the ALU.

  • CIR (Current Instruction Register)

    • holds the instruction that is currently being interpreted and executed by the Control Unit.

  • MAR (Memory Address Register)

    • holds the address of the memory location which is currently connected to the data bus. (controls access to memory)

  • SCR (Sequence Control Register)

    • holds the address of the memory location of the instruction that is to be executed after the current one is finished.

    • this is ‘incremented’ by 1 each time it is copied to the MAR.


Peripheral devices l.jpg
Peripheral Devices

  • Input

    • keyboard, mouse, bar-code readers, camera, microphone etc

  • Output

    • screen, printer, plotter, mechanical device etc.

  • Communications

    • modem, ISDN adaptor, network card etc.

  • Backing Storage

    • slow, non-volatile, usually mechanical, cheap.

    • floppy disk, hard disk, CDROM, magnetic tape, zip disk


How the computer works l.jpg
How the computer works.

  • Machine instructions and data are stored in memory in binary format.

  • A machine instruction consists of 2 parts:

    • Operation code: holds the binary code for the operation that is to be carried out by the processor.

    • Operand address: this is the address in memory where the processor may find the data that is to be operated on.

  • Machine instructions are ‘fetched’ from memory and then ‘executed’ by the processor.

From this slide and the next, 1st years would be expected to be able to describe the principle of the fetch/execute cycle as opposed to the details of how this cycle is implemented.


The fetch execute cycle l.jpg
The Fetch/Execute cycle.

  • The address of the next instruction to be executed is copied from the SCR to the MAR.

  • The SCR is incremented by 1.

  • The information is copied from memory to the MDR.

  • The contents of the MDR is copied to the CIR.

  • The operation code part of the instruction in the MDR is copied to the control unit.

  • The control unit recognises the instruction and executes it (the execution will vary depending on the instruction).


The load instruction not required for 1 st years l.jpg
The LOAD instruction.(Not required for 1st years)

  • Purpose: to load data from memory to the accumulator.

    • The operation address part of the CIR is copied to the MAR.

    • The location in memory is copied to the MDR.

    • The MDR is copied to the accumulator.


The store instruction not required for 1 st years l.jpg
The STORE instruction(Not required for 1st years)

  • Purpose: to copy the contents of the accumulator to a location in memory.

    • The operation address part of the CIR is copied to the MAR.

    • The accumulator is copied to the MDR.

    • The MDR is copied to the location in memory .


The add instruction not required for 1 st years l.jpg
The ADD instruction(Not required for 1st years)

  • Purpose: to add the contents of a memory location to the contents of the accumulator.

    • The operand address in the CIR is copied to the MAR.

    • The contents of memory is copied to the MDR.

    • The MDR contents are copied to the ALU which adds it to the accumulator, placing the result in the accumulator.


The jump instruction not required for 1 st years l.jpg
The JUMP instruction. (Not required for 1st years)

  • Purpose: to transfer control in a program to an instruction other than the next one.

    • The contents of the operand address are copied to the SCR.

  • Variations:

    • JUMP NEGATIVE

    • JUMP ZERO

    • JUMP POSITIVE

    • The contents of the operand address are only copied to the SCR if the accumulator is in the correct condition.


Machine language exercises not required for 1 st years l.jpg
Machine language exercises(Not required for 1st years)

  • Given the binary codes for these machine instructions write the programs described below.

    • LOAD 0001

    • STORE 0010

    • ADD 0011

    • JUMP 0100

    • JUMP + 0101

    • JUMP - 0110

    • JUMP 0 0111

  • Program to add together the contents of memory locations 10 and 11 and store the result in location 12.

  • Program to count down from 9 to zero.


ad