Introduction Flashcards

1
Q

CPU (Central Processing Unit)

A

the “overworked clerk” performs simple tasks
(ADD/SUB/MUL/DIV/LOGIC).
The task to perform is also known as an “instruction.”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

Memory

A

the clerk’s “desk drawers,” a.k.a. the clerk’s “memory.” Each drawer has a number, also known as an address.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Program memory

A

contains instructions for the clerk and tells it what to do.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Data memory

A

contains data for the clerk to work on.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

Program Counter (PC)

A

tells the clerk which program memory drawer to open

up and execute.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

basic parts of a CPU

A

○ ALU (has no own memory, can only do arithmetic and logic operations)
○ PC
○ Memory for data
○ Memory for instruction

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

Basic Operation of a CPU

A

○ Program Counter tells clerk which drawer to open up
■ Referred to as instruction “fetching”
○ Clerk examines instruction and performs operation
■ Referred to as instruction “decoding” and “execution”
○ Stores result of instruction in data memory drawer
■ Optional part of the execution of an instruction
○ Updates the program counter (PC)
■ PC = PC + 1 ; so we advance to next instruction upon repeat
■ optionally: PC = some other value ; if we wish to ‘jump’ around to
another part of our program.
○ Repeats this process until instructions are complete
■ Instructions constitute a “program”

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Algorithm

A

Step-by-step procedure that is guaranteed to terminate
Procedure:
-Definiteness: each step is precisely stated
-Effective computability: each step can be carried out by computer
- finiteness: procedure terminates

How well did you know this?
1
Not at all
2
3
4
5
Perfectly