Test 2 Part 1 Flashcards

(42 cards)

1
Q

Size of the cache in blocks?

A

Bytes / Bytes per block

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

How many writes occur?

A

Every time it gives a variable a value it is writing to it, so multiply the for loops

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

Capacity Miss?

A

Capacity misses occur when the amount of data referenced by a program exceeds the capacity of the cache

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

Cold Miss

A

This happens when an object is given a value

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

Synchronous Events are Caused by?

A

instruction currently being executed

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

Asynchronous events are caused by

A

Something outside of the program

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

Trap

A

Is intentional and requested by running program

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

Fault

A

Is unintentional and recoverable

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

Abort

A

Unintentional and unrecoverable

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

Fork outputs must include

A

Both the parent and child processes

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

What does wait(NULL) do?

A

Waits for child process to terminate

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

What does flush() do?

A

Flushs input after it is printed

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

Size of points array

A

(64*64)/bytes per block

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

hardware multiprocessing

A

System Timer: At regular intervals, the system timer goes off which causes control to be transferred to the OS scheduler.

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

Software multiprocessing

A

Schedular: Chooses a process to run from a set of ready to run processes.

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

SIGCHLD

A

The SIGCHLD signal is sent to a process when a child processterminates, is interrupted, or resumes after being interrupted.

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

What process reaps the parent process

18
Q

what process reaps the child process

19
Q

What process reaps the grandchild

A

process the child process

20
Q

What process executes the handler

A

The process that receives the SIGCHLD process

21
Q

Where is a.out executed?

A

foreground, & makes it run in the background

22
Q

What are the two primary system functions that the shell causes when a.out is ran, and what do they do

A

Fork: Creates child process
Exec: Called by child to run a different program

23
Q

What prevents the shell from redisplaying the shell prompt right away rather than after a few seconds when the program completes?

A

the shell has a loop to wait for the child process to terminate

24
Q

how is a builtin cmd handled differently by the shell

A

it doesn’t run either fork or exec

25
what signal will be sent to the shell when ctrlC is pressed? what signal will be sent to the loopforever process?
Sends a SIGINT & SIGCHLD SIGINT
26
What is Internal Fragmentation
This is space that isn't used for the payload (headers, footers, padding) inside an allocated block (fixed block)
27
What is external fragmentation
When there is enough heap memory but not enough space in a single free block
28
What is memory utilization?
Memory utilization is the % of heap that is used for payloads, fragmentation decreases this.
29
Define throughput
Number of requests per unit of time
30
Which free list provides a higher throughput?
Explicit, it uses pointer which is faster
31
Difference between explicit and implicit free list?
Explicit only contains free blocks Implicit contains free blocks and allocated blocks
32
Define virtual memory
Mechanism that allows process to share primary memory so they are executed concurrently (execution times overlay)
33
what is a page fault?
address is good but page is not, in DRAM
34
what is a seg fault?
address is bad
35
Coalescing is performed to avoid?
External fragmentation
36
Why is the footer important?
Helps find previous block to coalesce, only needed on free blocks.
37
Physical Page
Same as page frame, same size as VP (in bytes)
38
Values that are initialized already when ready to use are stored
in the data section
39
Memory pointed to by a pointer is stored
in the heap
40
Misc variables are stored in the
stack
41
Breakdown physical block
ppn[ct], ppo[ct, ci, c0(0)]
42
Breakdown virtual block
vpn[index(15), tag], vpo