X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=doc%2Fuserprog.texi;h=3473e961ac1aeaa4b163e6a4808429305ead487e;hb=1620c6ebfe2751e6793509c44a0abeb3a7f305d9;hp=903d9c53311dcd856860b10a5749ffdbd234d3ab;hpb=da80fdf80c1391c1ac6d878e6a7a13782c6dce35;p=pintos-anon diff --git a/doc/userprog.texi b/doc/userprog.texi index 903d9c5..3473e96 100644 --- a/doc/userprog.texi +++ b/doc/userprog.texi @@ -396,6 +396,14 @@ You may find the code for @func{thread_join} to be useful in implementing the join syscall, but besides that, you can use the original code provided for project 1. +@item +@b{All my user programs die with page faults.} + +This will generally happen if you haven't implemented problem 2-1 +yet. The reason is that the basic C library for user programs tries +to read @var{argc} and @var{argv} off the stack. Because the stack +isn't properly set up yet, this causes a page fault. + @item @b{Is there a way I can disassemble user programs?} @@ -417,7 +425,7 @@ is compiled as a unit.) If you wish to port libraries to Pintos, feel free. @item -@b{How do I compile new user programs? How do I make 'echo' compile?} +@b{How do I compile new user programs?} You need to modify @file{tests/Makefile}.