Skip to content
Snippets Groups Projects
Commit 7b0d27b6 authored by Tom de Vries's avatar Tom de Vries
Browse files

[gdb/testsuite] Fix gdb.arch/i386-pkru.exp for native-gdbserver

With test-case gdb.arch/i386-pkru.exp and target board native-gdbserver we run
into:
...
FAIL: gdb.arch/i386-pkru.exp: variable after reading pkru
...

This looks similar to the the problem for which there's already an xfail, so
fix this by extending the xfail matching.

Tested on x86_64-linux.

Also tested on openSUSE Tumbleweed, where all tests in the test-case pass.
parent 86091eae
No related branches found
No related tags found
No related merge requests found
......@@ -80,7 +80,6 @@ gdb_test "info register pkru" ".*pkru.*$val1.*" "read pkru register"
set val2 0x44444444
gdb_test "print /x \$pkru = $val2" "= $val2" "set pkru value"
set xval $val2
gdb_test_multiple "info register pkru" "read value after setting value" {
-re -wrap ".*pkru.*$val2.*" {
pass $gdb_test_name
......@@ -91,11 +90,21 @@ gdb_test_multiple "info register pkru" "read value after setting value" {
} else {
fail $gdb_test_name
}
set xval $val1
}
}
gdb_breakpoint [ gdb_get_line_number "break here 2" ]
gdb_continue_to_breakpoint "break here 2" ".*break here 2.*"
gdb_test "print /x rd_value" "= $xval" "variable after reading pkru"
gdb_test_multiple "print /x rd_value" "variable after reading pkru" {
-re -wrap "= $val2" {
pass $gdb_test_name
}
-re -wrap "= $val1" {
if { $have_xfail } {
xfail $gdb_test_name
} else {
fail $gdb_test_name
}
}
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment