Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
home:jcejka:branches:SUSE:SLE-15-SP2:Update
gdb
gdb-testsuite-add-checks-to-gdb.arch-i386-sse.e...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File gdb-testsuite-add-checks-to-gdb.arch-i386-sse.exp.patch of Package gdb
[gdb/testsuite] Add checks to gdb.arch/i386-sse.exp In test-case gdb.arch/i386-sse.exp, add the steps marked with "(added)": - verify data array (added) - initialize regs from data array - verify regs - modify regs - verify modified regs (added) - write back regs to data array - verify updated data array This in the hope to catch more information about failures in this test-case reported in PR28504. Also use gdb_test_no_output instead of gdb_test for the "modify regs" step. Tested on x86_64-linux. --- gdb/testsuite/gdb.arch/i386-sse.exp | 33 ++++++++++++++++++++++++++------- 1 file changed, 26 insertions(+), 7 deletions(-) diff --git a/gdb/testsuite/gdb.arch/i386-sse.exp b/gdb/testsuite/gdb.arch/i386-sse.exp index fca90256505..57f62694e6e 100644 --- a/gdb/testsuite/gdb.arch/i386-sse.exp +++ b/gdb/testsuite/gdb.arch/i386-sse.exp @@ -64,17 +64,26 @@ gdb_expect { } } -gdb_test "break [gdb_get_line_number "first breakpoint here"]" \ - "Breakpoint .* at .*i386-sse.c.*" \ - "set first breakpoint in main" -gdb_continue_to_breakpoint "continue to first breakpoint in main" - if [is_amd64_regs_target] { set nr_regs 16 } else { set nr_regs 8 } +# Verify data array. +for { set r 0 } { $r < $nr_regs } { incr r } { + gdb_test "print data\[$r\]" \ + ".. = \\{f = \\{$r, $r.25, $r.5, $r.75\\}\\}.*" \ + "check contents of data\[$r\]" +} + +# Initialize regs from data array. +gdb_test "break [gdb_get_line_number "first breakpoint here"]" \ + "Breakpoint .* at .*i386-sse.c.*" \ + "set first breakpoint in main" +gdb_continue_to_breakpoint "continue to first breakpoint in main" + +# Verify regs. for { set r 0 } { $r < $nr_regs } { incr r } { gdb_test "print \$xmm$r.v4_float" \ ".. = \\{$r, $r.25, $r.5, $r.75\\}.*" \ @@ -84,17 +93,27 @@ for { set r 0 } { $r < $nr_regs } { incr r } { "check int8 contents of %xmm$r" } +# Modify regs. for { set r 0 } { $r < $nr_regs } { incr r } { - gdb_test "set var \$xmm$r.v4_float\[0\] = $r + 10" "" "set %xmm$r" + gdb_test_no_output "set var \$xmm$r.v4_float\[0\] = $r + 10" "set %xmm$r" } +# Verify modified regs. +for { set r 0 } { $r < $nr_regs } { incr r } { + gdb_test "print \$xmm$r.v4_float" \ + ".. = \\{[expr $r + 10], $r.25, $r.5, $r.75\\}.*" \ + "check contents of %xmm$r" +} + +# Write back regs to data array. gdb_test "break [gdb_get_line_number "second breakpoint here"]" \ "Breakpoint .* at .*i386-sse.c.*" \ "set second breakpoint in main" gdb_continue_to_breakpoint "continue to second breakpoint in main" +# Verify updated data array. for { set r 0 } { $r < $nr_regs } { incr r } { gdb_test "print data\[$r\]" \ ".. = \\{f = \\{[expr $r + 10], $r.25, $r.5, $r.75\\}\\}.*" \ - "check contents of data\[$r\]" + "check contents of updated data\[$r\]" }
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor