Revert Intel-style assembly back to AT&T-style.
[pintos-anon] / src / tests / userprog / sc-boundary.c
1 #include <syscall-nr.h>
2 #include "tests/userprog/boundary.h"
3 #include "tests/lib.h"
4 #include "tests/main.h"
5
6 void
7 test_main (void) 
8 {
9   /* Put a syscall number at the end of one page
10      and its argument at the beginning of another. */
11   int *p = get_boundary_area ();
12   p--;
13   p[0] = SYS_exit;
14   p[1] = 42;
15
16   /* Invoke the system call. */
17   asm volatile ("movl %0, %%esp; int $0x30" :: "g" (p));
18   fail ("should have called exit(42)");
19 }