Questions tagged [paging]

Questions about memory-management techniques where the computer manages and transfers data between main memory and secondary storage in pages -- discrete chunks of a fixed size. Operating systems often use paging to implement virtual memory.

Filter by
Sorted by
Tagged with
0
votes
0answers
9 views

How many page-table entries can fit into TLB space

I am looking to calculate how many page-table entries can fit into a corresponding TLB space (Translation Look-aside Buffer ). I just want to make sure I am getting the calculation right, as I fear I ...
0
votes
0answers
10 views

How many page-table entries are needed in case the program uses the whole logical address space

Say I have: page size = 2^12 bytes physical memory = 2^24 bytes logical address space = 2^32 How many page-table entries are needed in case the program uses the whole logical address space?
0
votes
1answer
35 views

Converting physical address to logical

In 8-bit address space there are 16 pages and the page table stores: 68792EA51BD3CF04 (hex) The physical address is 39h, what is the corresponding logical address? I have literally no idea what to ...
0
votes
1answer
1k views

Segmentation and paging

I am given a system with a segmented paging architecture. Both physical and virtual address spaces contain $2^{16}$ bytes each. The virtual address space is divided in $8$ equal size segments. The ...
0
votes
1answer
2k views

What is the difference between caching, buffering and paging? Expecting a detailed answer on the OS level

I have been reading about caching and buffering it seems about the same to me can't get hold of the differences clearly and paging, for now the only difference I understand between paging and caching ...
1
vote
1answer
41 views

How are logical addresses of instruction operands mapped to physical addresses?

Is address translation for all operands in single instruction done only once and then are all operands fetched continuously? For example, consider any dummy instruction ...
0
votes
0answers
16 views

Why we need size of the page table should be some fraction of virtual address space

The Page Table should have all virtual page number which are in its logical address space, Why it's the case? Is it because we want to access Page Table entry fast just like an array where key is ...
0
votes
1answer
34 views

Why does paging not have external fragmentation?

I have read that paging does not suffer from external fragmentation as the frames and the pages are all of the equal sizes, but when we store a last level page table in a frame at that time it may not ...
1
vote
4answers
8k views

Why do we need the valid-invalid bit in a page table?

I'm reading about memory management in Operating System Concepts, by A. Silberschatz. The author says: [...] the user process by definition is unable to access memory it does not own. It has no ...
0
votes
0answers
20 views

Calculate the size of memory protection register

One of the methods for virtual memory protection is using a register of accessible pages for every active process. How many bits should the length of this register be, considering: physical memory ...
0
votes
1answer
72 views

Understanding paging and internal fragmentation

I am currently studing questions but stuck on this one, I hope someone can help me out to understand. Question: Assume that we have a paged virtual memory with a page size of 4Ki byte. Assume that ...
5
votes
3answers
6k views

Look Ahead buffer vs Translation Look aside buffer

I know that Translation look aside buffer is used for address translation in paging to achieve better performance. I came across term called Look Ahead buffer in a document which said it implements ...
1
vote
0answers
94 views

Difference between present - absent bit and valid - invalid bit in a page table?

while reading I found this: Present/Absent bit – Present or absent bit says whether a particular page you are looking for is present or absent. In case if it is not present, that is called Page ...
0
votes
0answers
13 views

Are TLB entries sorted by Virtual Address?

Are TLB entries sorted. if a virtual address needs to be translated into physical address. Does it have to locate all the TLB entries ?
2
votes
1answer
53 views

What does it mean " The outer level page table need not be page aligned?

The question is in context to multilevel page table. I was trying to solve numerical on multi-level paging and noticed that page size might not be same at all levels. I came across the point "Outer ...
0
votes
0answers
28 views

If the string of N requests is repeated many times, which of the following is/are true?

If the string of N requests is repeated many times, which of the following is/are true? I. The fewest page faults occur when M ≥ N. II. LRU (least-recently-used) and FIFO (first-in-first-out) will ...
8
votes
2answers
14k views

Is page size always equal to frame size?

I'm learning about paging. My book says that the logical addresses generated by the CPU are in the form |p|d|(page number, page offset) and the physical addresses ...
0
votes
1answer
196 views

Multi-level Paging

Consider a system which has 2 level paging.The page table is divided into 2K pages and each page is having 4K entries.Memory is word addressable and Physical address space is 64MW which is divided ...
2
votes
1answer
309 views

How does hashed inverted page table work?

I understand hash function and inverted page table, but then the book I read describes something called hashed inverted page table (use hash to accelerate the finding because IPT is large), with TLB ...
0
votes
0answers
14 views

If the number of pages exceeds the number of frames, how can the process finish using Virtual Memory?

Mapping is not for paging, is it? For instance if we have 12 pages and 8 frames. If 7 out of these 12 pages are loaded into the main memory, how can the process terminate?
0
votes
1answer
88 views

Page Replacement optimal verses MRU

A computer has twenty physical page frames which contain pages numbered 101 through 120. Now a program accesses the pages numbered 1, 2, …, 100 in that order, and repeats the access sequence THRICE. ...
1
vote
0answers
186 views

pool of free page frames OS

I read that in a paging scheme memory management, some os's have a paging daemon that wakes up periodically to inspect the memory of the RAM. This is to ensure that modified pages can be scheduled to ...
6
votes
2answers
28k views

How does increasing the page size affect the number of page faults?

If we let the physical memory size remain constant, What effect does the size of the page have on the number of frames? What effect does the number of frames have on the number of page faults? Also,...
2
votes
4answers
8k views

Calculation of effective average instruction execution time in a 2-level paging system

System has a two level paging scheme Average CPU time for a instruction = 100ns Average number of memory accesses per instruction = 2 Regular memory access = 150 ns Page fault service time = ...
3
votes
3answers
3k views

Virtual Address and Physical Address Space

A machine has 48-bit virtual addresses and 32-bit physical addresses. Pages are 8K. How many entries are needed for a conventional page table ? The answer is 2^35 entries Why not (2^32) / (2^13) = ...
1
vote
1answer
1k views

How to find the virtual pages and physical memory frames?

So i am given a system of 20 bits virtual addresses and 18 bits physical addresses using paging with pages size 4Kbytes. I am told to find the maximum number of virtual pages that a process can have ...
0
votes
1answer
35 views

Linux OS/HW VM cooperation

From what i've learned, the HW is responsible for setting the accessed and dirty bits in the PTE of a process, and the OS is responsible for turning them off. My question is why? The first part, i ...
0
votes
1answer
530 views

What does “higher order address bits” and “lower order address bits” mean?

"Assume a system with 4 GB virtual memory and 1 GB physical memory with 32 bit addresses. if the page size is 4 KB, How many bits will be allocated as the Higher Order Address bits and Lower Order ...
0
votes
2answers
465 views

Hierarchical Paging memory requirements

OS Book written by Galvin et all states that if page size is 4KB and size of virtual space is 32 bits then 2^(32-12) page entries would be required which is too huge to store in memory!! Therefore ...
1
vote
2answers
52 views

What is the difference between a page and thread?

"Each process that is executed is divided into blocks of same size, called pages." "Thread is a part of process being executed." Are pages and threads both part(s) of process? Whats the difference ...
1
vote
2answers
211 views

Does the Working Set Paging Algorithm use a separate page table?

I am doing research on paging algorithms. While learning about the working set algorithm from several scientific sources I was not really able to figure out where exactly the working set is defined or ...
0
votes
1answer
318 views

Effectiveness of TLB

This is a book question: Suppose that a machine has 48-bit virtual addresses and 32-bit physical addresses. Suppose this same system has a TLB (Translation Lookaside Buffer) with 32 ...
9
votes
2answers
33k views

Clock page replacement algorithm - Already existing pages

When simulating the clock page replacement algorithm, when a reference comes in which is already in memory, does the clock hand still increment? Here is an example: With 4 slots, using the clock ...
1
vote
1answer
7k views

Explain Hashed page tables in operating system

I have a difficult time understanding hashed page tables used in virtual memory management. Here is picture of the slide that I am referring to: I understand that p is hashed and then the hash is ...
0
votes
1answer
480 views

What happens when all reference bits set to 1 in Second Chance Page Replacement Algorithm?

I have a sequence like 5577334... and there are 3 frames available. After the 6th clock, all pages (5, 7 and 3) will have their reference bits set to 1. Now, when 4 comes in, 5 will go even though ...
3
votes
2answers
2k views

How to calculate the size of a page in a two level paging CPU?

I am having difficulties with understanding the concept of paging. As a result I've got no idea how I can solve the following exercise - I'm lacking one more equation to solve it. I've read a lot ...
1
vote
0answers
302 views

Difference between inverted page table and a standard one?

I know that for standard page tables each process would have its own page table and for inverted the OS would have it. But other than this what are the main differences between a standard page table ...
2
votes
1answer
743 views

Operating system maintains copy of page table for each process

I am quoting a paragraph in Operating System Concepts by Silberschatz, in paging chapter, In addition, the operating system must be aware that user processes operate in user space, and all ...
0
votes
1answer
2k views

Operating System: Performance of Demand Paging

I am reading Operating systems from the book "Operating System Concepts" by Peter Baer Galvin, 7th edition. Performance of Demand Paging: Let p be the probability of a page fault (0 $\leqslant$...
1
vote
2answers
42 views

If you increase the address space for an OS, does the Phys Mem used by the program increase?

I am learning about the OS. I know: that Address Space Size = # of pages x page size So if I increase Address Space Size, then the number of pages increases:(not the page size). However, isn't the ...
0
votes
2answers
501 views

Why page size = size of one cache way?

Why is that the page size equals the size of one cache way? My book states "A direct-mapped cache cannot be bigger than a page".
1
vote
1answer
48 views

Is the term page replacement actually a misnomer?

My understanding is that "page replacement" entails replacing the contents of a frame to bring in a new frame in it's place corresponding to a new page. Since it is not the page, but the frame that ...
2
votes
3answers
60k views

How to work out physical address corresponding to logical address?

I am looking to calculate the physical address corresponding to a logical address in a paging memory management scheme. I just want to make sure I am getting the calculation right, as I fear I could ...
0
votes
3answers
694 views

Operating System Paging concept

I am quoting a paragraph from the book "Operating System Principles" by Galvin. Usually, each page-table entry is 4 bytes long, but that size can vary as well. A 32-bit entry can point to one of $2^...
-2
votes
1answer
2k views

Calculate the size of Logical and Physical Address

Suppose a logical address space of 32 pages of 2048 words. There are 64 frames in the main memory. According to given information calculate the various parameters related to paging. Calculate the ...
3
votes
0answers
243 views

Paging: Does the page table of a process also gets swapped out when the process gets swapped out from main memory?

Does a process's page table too gets swapped out to secondary storage from main memory when the process gets swapped out to secondary storage from main memory? And gets swapped back in when the ...
2
votes
1answer
10k views

Hierarchical Paging

Suppose I have a system with 32-bit logical and 16-bit physical address spaces, and the page size is 512 bytes. For simplicity, ignore the valid/invalid bits in the page table. How many sections will ...
-2
votes
2answers
172 views

page fault while executing machine instruction

A process executing machine instruction Y right after machine instruction x.On executing x It causes a page fault. what is the next instruction that is executed immediately on restarting the process. ?...
0
votes
2answers
1k views

Compute how much memory is needed for a two level page table

Im studying operating systems and i found an exercise that i cant solve. It asks to compute the memory space needed for a two level page table. The logical addresses are 32 bit, Page size is 4KB ...
0
votes
3answers
20k views

Given the logical address, how to extract the page number?

I am studying Computer Systems. I have th following question and its answer: Given the logical address 0xAEF9 (in hexadecimal) with a page size of 256 bytes, what is the page number? Answer: ...