mirror of
https://github.com/espressif/binutils-gdb.git
synced 2025-06-22 11:00:01 +08:00
* gdb.base/corefile.exp: Always regenerate the core file, since
we always regenerate the coremaker program. Detect special case where registers cannot be read from core file. Change setup_xfail for "print func2:coremaker_local" and "backtrace in corefile.exp" to fail for all i*86 targets.
This commit is contained in:
@ -1,3 +1,11 @@
|
|||||||
|
Tue Mar 19 23:49:31 1996 Fred Fish <fnf@cygnus.com>
|
||||||
|
|
||||||
|
* gdb.base/corefile.exp: Always regenerate the core file, since
|
||||||
|
we always regenerate the coremaker program. Detect special case
|
||||||
|
where registers cannot be read from core file. Change setup_xfail
|
||||||
|
for "print func2:coremaker_local" and "backtrace in corefile.exp"
|
||||||
|
to fail for all i*86 targets.
|
||||||
|
|
||||||
Tue Mar 19 16:52:49 1996 Fred Fish <fnf@cygnus.com>
|
Tue Mar 19 16:52:49 1996 Fred Fish <fnf@cygnus.com>
|
||||||
|
|
||||||
From Peter Schauer <Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE>
|
From Peter Schauer <Peter.Schauer@Regent.E-Technik.TU-Muenchen.DE>
|
||||||
|
@ -45,7 +45,6 @@ if { [compile "-E ${srcdir}/${subdir}/compiler.c > ${binfile}.ci"] != "" } {
|
|||||||
return -1
|
return -1
|
||||||
}
|
}
|
||||||
|
|
||||||
if ![file exists ${objdir}/${subdir}/corefile] then {
|
|
||||||
# Create a core file named "corefile" rather than just "core", to
|
# Create a core file named "corefile" rather than just "core", to
|
||||||
# avoid problems with sys admin types that like to regularly prune all
|
# avoid problems with sys admin types that like to regularly prune all
|
||||||
# files named "core" from the system.
|
# files named "core" from the system.
|
||||||
@ -88,7 +87,6 @@ if ![file exists ${objdir}/${subdir}/corefile] then {
|
|||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Test that we can simply startup with a "-core=corefile" command line arg
|
# Test that we can simply startup with a "-core=corefile" command line arg
|
||||||
@ -121,6 +119,9 @@ expect {
|
|||||||
-re "Core was generated by .*\r\n\#0 .*\(\).*\r\n$prompt $" {
|
-re "Core was generated by .*\r\n\#0 .*\(\).*\r\n$prompt $" {
|
||||||
pass "args: -core=corefile (with bad program name)"
|
pass "args: -core=corefile (with bad program name)"
|
||||||
}
|
}
|
||||||
|
-re ".*registers from core file: File in wrong format.* $" {
|
||||||
|
fail "args: -core=corefile (could not read registers from core file)"
|
||||||
|
}
|
||||||
-re ".*$prompt $" { fail "args: -core=corefile" }
|
-re ".*$prompt $" { fail "args: -core=corefile" }
|
||||||
timeout { fail "(timeout) starting with -core" }
|
timeout { fail "(timeout) starting with -core" }
|
||||||
}
|
}
|
||||||
@ -145,6 +146,9 @@ expect {
|
|||||||
-re "Core was generated by .*\r\n\#0 .*\(\).*\r\n$prompt $" {
|
-re "Core was generated by .*\r\n\#0 .*\(\).*\r\n$prompt $" {
|
||||||
pass "args: execfile -core=corefile (with bad program name)"
|
pass "args: execfile -core=corefile (with bad program name)"
|
||||||
}
|
}
|
||||||
|
-re ".*registers from core file: File in wrong format.* $" {
|
||||||
|
fail "args: execfile -core=corefile (could not read registers from core file)"
|
||||||
|
}
|
||||||
-re ".*$prompt $" { fail "args: execfile -core=corefile" }
|
-re ".*$prompt $" { fail "args: execfile -core=corefile" }
|
||||||
timeout { fail "(timeout) starting with -core" }
|
timeout { fail "(timeout) starting with -core" }
|
||||||
}
|
}
|
||||||
@ -170,6 +174,9 @@ expect {
|
|||||||
-re "Core was generated by .*\r\n\#0 .*\(\).*\r\n$prompt $" {
|
-re "Core was generated by .*\r\n\#0 .*\(\).*\r\n$prompt $" {
|
||||||
pass "core-file command (with bad program name)"
|
pass "core-file command (with bad program name)"
|
||||||
}
|
}
|
||||||
|
-re ".*registers from core file: File in wrong format.* $" {
|
||||||
|
fail "core-file command (could not read registers from core file)"
|
||||||
|
}
|
||||||
-re ".*$prompt $" { fail "core-file command" }
|
-re ".*$prompt $" { fail "core-file command" }
|
||||||
timeout { fail "(timeout) core-file command" }
|
timeout { fail "(timeout) core-file command" }
|
||||||
}
|
}
|
||||||
@ -180,14 +187,16 @@ gdb_test "print coremaker_data" "\\\$$decimal = 202"
|
|||||||
gdb_test "print coremaker_bss" "\\\$$decimal = 10"
|
gdb_test "print coremaker_bss" "\\\$$decimal = 10"
|
||||||
gdb_test "print coremaker_ro" "\\\$$decimal = 201"
|
gdb_test "print coremaker_ro" "\\\$$decimal = 201"
|
||||||
|
|
||||||
setup_xfail "i*86-*-sysv4*"
|
# This fails under at least Unixware (i*86-*-sysv4*) and linux.
|
||||||
|
setup_xfail "i*86-*-*"
|
||||||
gdb_test "print func2::coremaker_local" "\\\$$decimal = {0, 1, 2, 3, 4}"
|
gdb_test "print func2::coremaker_local" "\\\$$decimal = {0, 1, 2, 3, 4}"
|
||||||
|
|
||||||
# Somehow we better test the ability to read the registers out of the core
|
# Somehow we better test the ability to read the registers out of the core
|
||||||
# file correctly. I don't think the other tests do this.
|
# file correctly. I don't think the other tests do this.
|
||||||
|
|
||||||
# Haven't investigated this xfail
|
# Haven't investigated this xfail
|
||||||
setup_xfail "m68k-*-hpux*" "i*86-*-sysv4*"
|
# This fails under at least Unixware (i*86-*-sysv4*) and linux.
|
||||||
|
setup_xfail "m68k-*-hpux*" "i*86-*-*"
|
||||||
gdb_test "bt" "abort.*func2.*func1.*main.*" "backtrace in corefile.exp"
|
gdb_test "bt" "abort.*func2.*func1.*main.*" "backtrace in corefile.exp"
|
||||||
|
|
||||||
# test reinit_frame_cache
|
# test reinit_frame_cache
|
||||||
|
Reference in New Issue
Block a user