diff options
author | Tom de Vries <tdevries@suse.de> | 2020-12-08 09:29:40 +0100 |
---|---|---|
committer | Tom de Vries <tdevries@suse.de> | 2020-12-08 09:29:40 +0100 |
commit | b46551b20c9617e0cf2fda9a32b2132f3a7fd35c (patch) | |
tree | f014a554f2d32ecb15d15e0e4624624d3334c2ec | |
parent | 8439f446a1f2cbb69bb09535e99d166f94a7fdb4 (diff) | |
download | gdb-b46551b20c9617e0cf2fda9a32b2132f3a7fd35c.zip gdb-b46551b20c9617e0cf2fda9a32b2132f3a7fd35c.tar.gz gdb-b46551b20c9617e0cf2fda9a32b2132f3a7fd35c.tar.bz2 |
[gdb/testsuite] Simplify gdb.arch/amd64-gs_base.exp
Redo fix committed in commit 67748e0f66 "[gdb/testsuite] Make
gdb.arch/amd64-gs_base.exp unsupported for i386" using is_amd64_regs_target.
Tested on x86_64-linux.
gdb/testsuite/ChangeLog:
2020-12-08 Tom de Vries <tdevries@suse.de>
* gdb.arch/amd64-gs_base.exp: Undo commit 67748e0f66, reimplement
using is_amd64_regs_target.
-rw-r--r-- | gdb/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gdb/testsuite/gdb.arch/amd64-gs_base.exp | 28 |
2 files changed, 7 insertions, 26 deletions
diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 2cf25a4..dcbb9b2 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,5 +1,10 @@ 2020-12-08 Tom de Vries <tdevries@suse.de> + * gdb.arch/amd64-gs_base.exp: Undo commit 67748e0f66, reimplement + using is_amd64_regs_target. + +2020-12-08 Tom de Vries <tdevries@suse.de> + * gdb.ada/mi_task_arg.exp: Accept <optimized out> as valid value of self_id. diff --git a/gdb/testsuite/gdb.arch/amd64-gs_base.exp b/gdb/testsuite/gdb.arch/amd64-gs_base.exp index d29043b..a5cf98d 100644 --- a/gdb/testsuite/gdb.arch/amd64-gs_base.exp +++ b/gdb/testsuite/gdb.arch/amd64-gs_base.exp @@ -15,7 +15,7 @@ standard_testfile -if { ![istarget "x86_64-*linux*"] } then { +if { ![is_amd64_regs_target] } then { verbose "Untested x86_64 fs_base and gs_base tests." return } @@ -30,31 +30,6 @@ if ![runto_main] { return -1 } -# Test the presence of fs_base and gs_base on the system -# register group and values. -# -set ws "\[\t \]+" -set info_reg_out [multi_line "info register sys" \ - "fs_base${ws}$hex${ws}$decimal"\ - "gs_base${ws}$hex${ws}$decimal"\ - "orig_rax${ws}$hex${ws}\[-\]$decimal" ] -set info_reg_out_m32 [multi_line "info register sys" \ - "orig_eax${ws}$hex${ws}\[-\]$decimal" ] - -set supported 0 -gdb_test_multiple "info register sys" "" { - -re -wrap $info_reg_out { - set supported 1 - } - -re -wrap $info_reg_out_m32 { - } -} - -if { ! $supported } { - unsupported "target does not support fs_base and gs_base" - return -1 -} - gdb_test "print /x \$fs_base" "= $hex" "print fs_base" gdb_test "print /x \$gs_base" "= $hex" "print gs_base" @@ -64,6 +39,7 @@ gdb_test "print \$gs_base = 3" "= 3" "set gs_base" # Test the presence of fs_base and gs_base on the system # register group and values. # +set ws "\[\t \]+" set info_reg_out [multi_line "info register sys" \ "fs_base${ws}0x2${ws}2"\ "gs_base${ws}0x3${ws}3"\ |