9 set srcfile ${srcdir}/$subdir/${testfile}.c
10 set binfile ${objdir}/${subdir}/${testfile}
12 # Create and source the file that provides information about the compiler
13 # used to compile the test case.
14 execute_anywhere "rm -f ${binfile}.ci"
15 if { [compile "-E ${srcdir}/${subdir}/compiler.c >> ${binfile}.ci"] != "" } {
16 perror "Couldn't make ${binfile}.ci"
23 gdb_reinitialize_dir $srcdir/$subdir
26 # This test must be compiled with -O2 if using gcc.
28 if {$gcc_compiled} then {
29 if { [compile "${srcfile} -O2 -g -o ${binfile}"] != "" } {
30 perror "Couldn't compile ${srcfile} with -O2"
34 if { [compile "${srcfile} -g -o ${binfile}"] != "" } {
35 perror "Couldn't compile ${srcfile}"
40 gdb_reinitialize_dir $srcdir/$subdir
43 if [runto middle] then {
45 if {$gcc_compiled} then { setup_xfail "hppa*-*-*" }
46 gdb_test "backtrace" "#0.*middle.*#1.*top.*#2.*main.*"