which is the only storage that the cpu can address
Geschreven voor
COP 4600
COP 4600
Verkoper
Volgen
Easton
Ontvangen beoordelingen
Voorbeeld van de inhoud
COP 4600 Test 2 Questions And 100% Correct Answers
Which is the only storage that the CPU can address directly? Example?- ANSWER Main
memory; Fetch and execute cycle.
What do we mean by when we say "addressed"?- ANSWER We mean byte of memory
has a location expressible with a number or set of numbers.
Registers - ANSWER They are single words of memory that the CPU can do arithmetic
and logic in - and more importantly for the moment, use to control memory.
Base register - ANSWER - Is used to hold the lowest memory address a process can
access.
- is added to each logical address to obtain the corresponding physical address.
Limit register - ANSWER Is used to hold the size of the range a process can access
***Note: The limit register is not the last physical or logical address that can be
accessed.
Accessing registers can be done in ______________. - ANSWER a cycle
Accessing main memory requires _______________. - ANSWER a stall
Cache - ANSWER is a smaller, faster space of memory used to hold memory "closer" to
the processor
The cache can be accessed only when _______________. - ANSWER No stall or a short
one
,Each _________ needs to be confined to its own _________. How do we? - ANSWER
process; memory; with the base and limit register
Setting the base and limit registers limit to the operating system-make them
_____________. - ANSWER privileged instructions
When does a process get killed? - ANSWER When a process accesses memory below
the base or beyond the limit, it gets killed.
Termination goes by many names, which are? - ANSWER - Segmentation Fault
- General Protection Fault
- Access Violation
A program when residing on a disk is usually __________________. - ANSWER a binary
executable
For a program to run and become a process it has to be? - ANSWER loaded into memory
If swapping is involved, the process? - ANSWER Can be moved between disk and
memory multiple times during execution.
Input queue - ANSWER Is the queue of processes on disk waiting to get into memory.
Process can usually run __________ in memory, but for that to work, its addresses need
to be __________. Eventually, those addresses need to become ____________ - the ones
used in actual memory unit (Even those that are not necessarily physical). - ANSWER
anywhere; bound; physical addresses
Address binding how does it work? The addresses used by un-compiled - or at least
un-assembled - programs are said to be symbolic addresses, and are such things as
variable names and the like. The compiler binds them into relocatable addresses, such
, as "n bytes from the beginning of this module", which the linker in turn binds into
absolute addresses. These "absolute" addresses then need to be bound again when the
operating system deals with the program and subsequently the process.
Binding Times - ANSWER - Compile Time
- Load Time
- Execution Time
Compile Time - ANSWER - Binds all addresses to physical addresses at link time.
- Only works if we know exactly where programs need to be loaded into memory.
Load Time - ANSWER - Leave addresses zero-relative at link time, generating
relocatable code that the OS binds when it loads the program.
- Only works if we know programs will never be moved in memory.
Execution Time - ANSWER - Bind addresses every time they're used.
- All modern general-purpose operating systems use this.
- Requires hardware support.
Execution time binding creates? - ANSWER A distinction between the addresses that the
CPU uses in normal operation ( logical/virtual addresses) and the addresses that are
actually accessed in memory (physical addresses).
Mapping is done by? And has be in? - ANSWER Memory management unit; hardware
Simple Mapping Example - ANSWER - Consider the base register as the relocation
register.
- On every memory access by a process, add the base register
- On every context switch, change the base and limit registers
Voordelen van het kopen van samenvattingen bij Stuvia op een rij:
Verzekerd van kwaliteit door reviews
Stuvia-klanten hebben meer dan 700.000 samenvattingen beoordeeld. Zo weet je zeker dat je de beste documenten koopt!
Snel en makkelijk kopen
Je betaalt supersnel en eenmalig met iDeal, creditcard of Stuvia-tegoed voor de samenvatting. Zonder lidmaatschap.
Focus op de essentie
Samenvattingen worden geschreven voor en door anderen. Daarom zijn de samenvattingen altijd betrouwbaar en actueel. Zo kom je snel tot de kern!
Veelgestelde vragen
Wat krijg ik als ik dit document koop?
Je krijgt een PDF, die direct beschikbaar is na je aankoop. Het gekochte document is altijd, overal en oneindig toegankelijk via je profiel.
Tevredenheidsgarantie: hoe werkt dat?
Onze tevredenheidsgarantie zorgt ervoor dat je altijd een studiedocument vindt dat goed bij je past. Je vult een formulier in en onze klantenservice regelt de rest.
Van wie koop ik deze samenvatting?
Stuvia is een marktplaats, je koop dit document dus niet van ons, maar van verkoper Easton. Stuvia faciliteert de betaling aan de verkoper.
Zit ik meteen vast aan een abonnement?
Nee, je koopt alleen deze samenvatting voor €13,72. Je zit daarna nergens aan vast.