* gdb.arch/i386-prologue.c (standard): New prototype and function.
(main): Call new function.
+2004-08-01 Mark Kettenis <kettenis@gnu.org>
+
+ * gdb.arch/i386-prologue.exp: Add testcase for standard prolgue.
+ * gdb.arch/i386-prologue.c (standard): New prototype and function.
+ (main): Call new function.
+
2004-07-31 Michael Chastain <mec.gnu@mindspring.com>
* gdb.cp/namespace.exp: Accept more varieties of ptype output.
int
main (void)
{
+ standard ();
gdb1253 ();
gdb1718 ();
gdb1338 ();
return 0;
}
+/* A normal prologue. */
+
+asm(".text\n"
+ " .align 8\n"
+ SYMBOL (standard) ":\n"
+ " pushl %ebp\n"
+ " movl %esp, %ebp\n"
+ " pushl %edi\n"
+ " int $0x03\n"
+ " leave\n"
+ " ret\n");
+
/* Relevant part of the prologue from symtab/1253. */
asm(".text\n"
gdb_suppress_tests
}
+# Testcase for standard prologue.
+
+gdb_test "continue" "Program received signal SIGTRAP.*" "continue to standard"
+
+gdb_test "backtrace 10" \
+ "#0\[ \t\]*$hex in standard.*\r\n#1\[ \t\]*$hex in main.*" \
+ "backtrace in standard"
+
+gdb_test "info frame" \
+ ".*Saved registers:.*ebp at.*edi at.*eip at.*" \
+ "saved registers in standard"
+
# Testcase from symtab/1253.
gdb_test "continue" "Program received signal SIGTRAP.*" "continue to gdb1253"