Virtual Memory: 5 Page Tables

preview_player
Показать описание
Translation with page tables. Making the translation table size manageable with pages. Page Table Entries and page offset address.
Рекомендации по теме
Комментарии
Автор

For anyone confused about the conversion in the question in the beginning of this video:

MIPS has a 32bit word size (4bytes) and a 32bit address space. However, MIPS is a byte-addressable architecture, with each of those 2^32 addresses pointing to a specific byte, not a word.
To figure out how many 4-byte words can fit within a 32bit byte-addressable address space, you simply divide.
In this case:



wordcount=(2^32)/4

wordcount=(2^32)/(2^2)=2^30

You can fit 2^30 4byte words within MIPS’s 32bit address space, hence the limit you mentioned.

-L. Boulesteix, Quora.

opus_X
Автор

I think I can speak for everyone that the explanation was a tad confusing initially due to the conversions which weren't done explicitly by the presenter. Thankfully I have figured it out and I will elaborate below.

In a 32-bit machine, there are 2^32 byte addresses in virtual memory (VM) made available to the programs. This is also equivalent to 2^30 word addresses since each word = 32-bits = 4bytes (i.e. we can store 2^30 words).

Here, we have 2^30 words to map from VM to physical memory (PM). This also means that we need a total of 2^30 (= 10^9 = 1billion) VM-to-PM mappings. Using a one-page table entry (i.e. each entry maps 1 word address from VM to PM), this is equivalent to 1billion entries in the page table.

However, if we were instead do the mappings in chunks (in the video example, 1 entry maps 1000 word addresses from VM to PM), the number of entries required would reduce by 1000 times (i.e. 1million entries required).

Hope my explanation helps :-)

cheeweng
Автор

These videos are absolutely brilliant, very clearly explained and presented. Thanks!

basementhermit
Автор

Thank you so much, tried understanding the professor and the book and i couldn't get anything, but this, wow, very straightforward

BarakaAndrew
Автор

its 2023 and this guy is still carring my CS studies more then any professor haha
Thank you very much. Your videos are great

Note: I just choose that one to comment, but I watched ALOT so referr it to the others as well

crust
Автор

Just dropped to let you know, this is by far the best explanation of virtual memory till this date and it's already 6 years old !!!

abir
Автор

Man, you have no idea how helpful and easy to understand your videos are !!

saiprasadduduka
Автор

Back to this lectures (The full Virtual Memory Lectures) after years that i've learnt it in the University inorder to refresh the memory, The best as Usual!

AdvaTced
Автор

You OWNED that explanation. THANK YOU David!!

ulysses_grant
Автор

You are one of the best teachers I've seen.

morphykg
Автор

1:11 The size of the page table is: We have 2^32 virtual addresses => we have 2^32*(number of bits for VA + number of bits for PA) that equals (if we have 1G addresses in RAM) 2^32*(32b+30b) so it's much more than billion.

aleksagordic
Автор

Thank you so much for taking the time and putting all that effort into these videos. You're really good at teaching. I personally like a lot how you keep me engaged with the questions.

DTX_
Автор

Thank you so much for making these videos. You saved me from failure

bansheehalo
Автор

Brilliant stuff. made the VM cocepts very clear. Kudos to the presenter for explaining so nicely.Great material.

soniasusmitha
Автор

bless your spirit for this video ***typed while cramming for an OS midterm***

leilenah
Автор

Clear bottom up explanation and Brilliant popup quiz!!

evkffyu
Автор

For convenience, 8 bits are usually grouped into a single block, conventionally called a byte. The next-largest named block of bits is a word. The definition and size of a word are not absolute, but vary from computer to computer. A word is the size of the most convenient block of data for the computer to deal with.

Here’s the quick tour: A bit is a single binary digit, 0 or 1. A byte is 8 bits side by side. A word is 2 bytes side by side. A double word is 2 words side by side. A quad word is 2 double words side by side.

seeyouagainv
Автор

life saver videos for comp sci majors, thank u!

perfectfalls
Автор

This just made something click for me. That is why databases store items in memory as pages which correspond to the page size of the OS. If you want to move from memory to disk, it is easier to just do scalar * page size on the page table just once.

kwakubiney
Автор

This is extremely helpful. I wish this were how they taught us in school.

geoph