CS FundamentalsVery hardGATE CS
TLB access 2 ns (looked up first), memory access 50 ns, two-level page table, TLB hit ratio 98%. A fraction 10⁻⁵ of ALL accesses page-fault (these are always TLB misses), and a fault costs 5 ms plus the normal miss path. What is the effective access time, to the nearest ns?
- A. 54 ns
- B. 102 ns
- C. 104 ns
- D. 103 ns
Correct answer: C. 104 ns
No-fault cost: hit 52 ns, miss 2 + 2×50 + 50 = 152 ns, giving 0.98×52 + 0.02×152 = 54 ns. Faults add 10⁻⁵ × 5×10⁶ = 50 ns on average. EAT ≈ 104 ns.
More Operating Systems questions
- A machine has 57-bit virtual addresses (5-level paging style), 4 KB pages and 8-byte page-table entries, with every page table fitting in…
- A system has 46-bit virtual addresses, 16 KB pages and 4-byte PTEs; each page table must fit in one page. How many levels of page tables…
- Segment table (base, length): S0 (219, 600), S1 (2300, 14), S2 (90, 100), S3 (1327, 580), S4 (1952, 96). What are the physical addresses…
- How many times are 'c' and 'p' printed in total? (Every fork() succeeds.) c int main() { for (int i = 0; i < 3; i++) { if (fork() == 0)…
- How many times is each letter printed? (Every fork() succeeds.) c int main() { if (fork() == 0) { if (fork() == 0) printf("A"); else…
- What is the sum of the values printed by all processes? (Every fork() succeeds.) c int main() { int n = 0; for (int i = 0; i < 3; i++) {…