Week 12 Flashcards

1
Q

3 main functions of IO Driver:

A

Initialize Device
Manipulates device’s CSRs to start operations when I/O is needed
Handles interupts from devices

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

What are the 2 type of IO devices?

A

Character Oriented: Keyboard, Mouse (Transfer one byte at a time)
Block-oriented: Disk, network interface (Transfer block of data at a time)

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

What are the 3 parts of a device driver?

A

Lower Half, Upper half, shared variables

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

Lower Half:

A

Handler code that is invoked when the device interrupts, communicates directly with device

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

Upper half:

A

Set of functions that are invoked by applications, allows application to request I/O operations

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

shared variables

A

used by both halves to coordinate, contains input and output buffers

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

_____ is needed because interrupts occur asynchronously and multiple applications can attempt I/O on a given device at the same time

A

mutual exclusion: This guarantees only one operation will be performed at any time

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

what is pipelining?

A

pipelining is when you execute multiple instructions at once in order to speed up the overall program (think laundry example)

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

What is instruction-level parallelism?

A

parallelism that exists in machine programs

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

what are the 3 hazards of pipelining?

A

Structural hazard: isufficient hardware exists for parallelism
data hazard: instruction depends on earlier result; pipelining overlap of instructions exposes this dependence
control hazard: caused by branches and instructions that change the PC away from Default_next_instruction

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

what is dependece?

A

A program property whereby a sequential relationship exists between instructions because of the requirement for program correctness, limits ILP

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

data dependece exists when:

A

a result is used (later) as an operand; such dependence is inherent to the algorithm used

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

true data dependence:

A

a result is used later as an operand, a value flows from one instruction to an instruction appearing later in the program listing

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

name dependence:

A

occurs when two instructions use the same storage location, called a name, but no value flows from the first instruction to the subsequent one

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

antidepence from J to K

A

occurs when J reads from the name and K writes to the name

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

output dependence from J to K

A

occurs when J and K both write to the name

17
Q

How do you view dependences as read / write actions:

A

No dependence: Read after Read, this is good and ILP exists
True Data Dependence: Read after Write
Antidependence: Write after Read
Output dependence: Write after Wright

18
Q

True or false: One register can be involved with multiple kinds of dependences simultaneously:

A

TRUE