Script started on Wed Sep 26 23:01:59 2001 linux3% gdb a.out GNU gdb 19991004 Copyright 1998 Free Software Foundation, Inc. (gdb) disas *pstart Dump of assembler code for function pstart: 0x8048081 : mov %eax,0x80490c0 0x8048086 : call 0x80480a1 0x804808b : mov %eax,0x80490cd 0x8048090 : call 0x80480a1 0x8048095 : mov %eax,0x1 0x804809a : mov %ebx,0x0 0x804809f : int 0x80 End of assembler dump. (gdb) break *pstart Breakpoint 1 at 0x8048081 (gdb) break *print Breakpoint 2 at 0x80480a1 (gdb) run Starting program: /afs/umbc.edu/users/c/h/chang/home/asm/sub/a.out Breakpoint 1, 0x8048081 in pstart () (gdb) print/x $esp $1 = 0x7ffffb90 (gdb) cont Continuing. Breakpoint 2, 0x80480a1 in print () (gdb) print/x $esp $2 = 0x7ffffb8c (gdb) x/1wx $esp 0x7ffffb8c: 0x0804808b (gdb) cont Continuing. Hello World Breakpoint 2, 0x80480a1 in print () (gdb) print/x $eax $3 = 0x80490cd (gdb) x/20cb &msg2 0x80490cd : 71 'G' 111 'o' 111 'o' 100 'd' 45 '-' 98 'b' 121 'y' 101 'e' 0x80490d5 : 44 ',' 32 ' ' 98 'b' 108 'l' 117 'u' 101 'e' 32 ' ' 115 's' 0x80490dd : 107 'k' 121 'y' 10 '\n' 0 '\000' (gdb) x/1wx $esp 0x7ffffb8c: 0x08048095 (gdb) cont Continuing. Good-bye, blue sky Program exited normally. (gdb) quit linux3% exit