(gdb) break kvmalloc (gdb) next (gdb) print/x kpgdir why is this zero? let's look up a virtual address how about the first instruction of kvmalloc (gdb) x/i kvmalloc 0x80107990
: push %ebp how would we translate 0x80107990 to a physical address? (gdb) print/x 0x80107990 >> 22 $4 = 0x200 (gdb) print/x kpgdir[0x200] $6 = 0x114007 Q: what is this? Q: what is the PPN? Q: what does the 7 mean? (gdb) print/x (0x80107990 >> 12) & 0xfff $6 = 0x107 (gdb) print/x ((int*)0x114000)[0x107] $12 = 0x107001 Q: what is this? Q: why 1 in the low bits? (gdb) print/x 0x107000 + 0x990 $13 = 0x107990 (gdb) x/i 0x107990 why did the physical address work in gdb? back to kvmalloc it called setupkvm to create a page table now it calls switchkvm to start using it switchkvm loads kpgdir into %cr3 and now 0x170990 won't work: (gdb) x/i 0x107990 0x107990: Cannot access memory at address 0x107990 why?
You should now download the
pintos source code
Next, you should submit the base version of pintos
os-submit-pintos script (we need that you submit the base
version to be able to correctly submit your next lab). You will need to
create a Subversion repository for yourself to do this. See
instructions on the tools page for instructions
on using Subversion.
On successful submission, you should have seen a "Congratulations"
message with your submission ID if your submission
was successful. At any time, you can check if your submission
has been made by typing
os-get-submission ". For
future assignments just replace
os-get-submission script should
create a directory with your submission-id. This directory
should contain a
You should build your solution to Lab2 (
on top of the base pintos version that you submitted. We
encourage you to use the
SVN repository actively during development. Use good and
illustrative commit messages. We will examine your repository
log during demos.
Study the grading policy on the
Administrivia page. You
can check your current score using
script. In case of multiple submissions by the
same person/group, we will use the date
of your last
submission to compute the late days. Notice that
late days are counted at the granularity of hours.
So if you are late by 4 hours for
and late by 5 hours for
Lab2, your total late "days" is
only 9 hours (not 2 days).
Nothing to turn in for this part.