X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Ftests%2Fvm%2Fpt-grow-bad.c;h=d4beba22ff50e06ff6a31bc4783061ce2abd92b3;hb=b9fefe5e8d7d37e23970070a4614a5d1a6692eb2;hp=2629574cc6f4bb0479cdc7ee4a66746ccee2433c;hpb=615bf3b3d2a8573ed6fb9ddc0055745e163ac999;p=pintos-anon diff --git a/src/tests/vm/pt-grow-bad.c b/src/tests/vm/pt-grow-bad.c index 2629574..d4beba2 100644 --- a/src/tests/vm/pt-grow-bad.c +++ b/src/tests/vm/pt-grow-bad.c @@ -1,3 +1,6 @@ +/* Read from an address 4,096 bytes below the stack pointer. + The process must be terminated with -1 exit code. */ + #include #include "tests/arc4.h" #include "tests/cksum.h" @@ -7,7 +10,5 @@ void test_main (void) { - /* Read from an address 4,096 bytes below the stack pointer. - Must kill the program. */ - asm volatile ("mov %eax, [%esp - 4096]"); + asm volatile ("movl -4096(%esp), %eax"); }