From 891615f060ff6cf8ea5497fd5f07138a52fe4ede Mon Sep 17 00:00:00 2001 From: Tom de Vries Date: Mon, 23 Nov 2020 20:09:50 +0100 Subject: [PATCH] [gdb/testsuite] Fix minimal encodings KPASSes With current master I see a couple of KPASSes: ... KPASS: gdb.ada/enum_idx_packed.exp: scenario=minimal: ptype small \ (PRMS minimal encodings) ... KPASS: gdb.ada/mod_from_name.exp: scenario=minimal: print xp \ (PRMS minimal encodings) KPASS: gdb.ada/pckd_arr_ren.exp: scenario=minimal: print var \ (PRMS minimal encodings) ... The corresponding setup_kfail is called for everything before gnat 11. However, the test-cases also PASS for me with gnat-4.8, gnat-7.5.0 and gnat-8.4.0. Fix the KPASSes by limiting the setup_kfail to gnat 9 and 10. Tested on x86_64-linux. gdb/testsuite/ChangeLog: 2020-11-23 Tom de Vries * gdb.ada/enum_idx_packed.exp: Limit setup_kfail to gnat 9 and 10. * gdb.ada/mod_from_name.exp: Same. * gdb.ada/pckd_arr_ren.exp: Same. --- gdb/testsuite/ChangeLog | 6 ++++++ gdb/testsuite/gdb.ada/enum_idx_packed.exp | 5 +++-- gdb/testsuite/gdb.ada/mod_from_name.exp | 5 +++-- gdb/testsuite/gdb.ada/pckd_arr_ren.exp | 5 +++-- 4 files changed, 15 insertions(+), 6 deletions(-) diff --git a/gdb/testsuite/ChangeLog b/gdb/testsuite/ChangeLog index 185d7cd79c..da7823fddf 100644 --- a/gdb/testsuite/ChangeLog +++ b/gdb/testsuite/ChangeLog @@ -1,3 +1,9 @@ +2020-11-23 Tom de Vries + + * gdb.ada/enum_idx_packed.exp: Limit setup_kfail to gnat 9 and 10. + * gdb.ada/mod_from_name.exp: Same. + * gdb.ada/pckd_arr_ren.exp: Same. + 2020-11-22 Simon Marchi * gdb.base/template.exp: New. diff --git a/gdb/testsuite/gdb.ada/enum_idx_packed.exp b/gdb/testsuite/gdb.ada/enum_idx_packed.exp index 2e5a85e76b..f32c488e17 100644 --- a/gdb/testsuite/gdb.ada/enum_idx_packed.exp +++ b/gdb/testsuite/gdb.ada/enum_idx_packed.exp @@ -28,8 +28,9 @@ foreach_with_prefix scenario {all minimal} { clean_restart ${testfile} - # GNAT >= 11.0 has the needed fix here. - if {$scenario == "minimal" && ![test_compiler_info {gcc-1[1-9]-*}]} { + # GNAT 9 and 10 are known to fail. + if {$scenario == "minimal" && ([test_compiler_info {gcc-9-*}] \ + || [test_compiler_info {gcc-10-*}])} { set old_compiler 1 } else { set old_compiler 0 diff --git a/gdb/testsuite/gdb.ada/mod_from_name.exp b/gdb/testsuite/gdb.ada/mod_from_name.exp index 43d81e0026..5f779c3084 100644 --- a/gdb/testsuite/gdb.ada/mod_from_name.exp +++ b/gdb/testsuite/gdb.ada/mod_from_name.exp @@ -34,8 +34,9 @@ foreach_with_prefix scenario {all minimal} { return } - # GNAT >= 11.0 has the needed fix here. - if {$scenario == "minimal" && ![test_compiler_info {gcc-1[1-9]-*}]} { + # GNAT 9 and 10 are known to fail. + if {$scenario == "minimal" && ([test_compiler_info {gcc-9-*}] \ + || [test_compiler_info {gcc-10-*}])} { setup_kfail "minimal encodings" *-*-* } gdb_test "print xp" \ diff --git a/gdb/testsuite/gdb.ada/pckd_arr_ren.exp b/gdb/testsuite/gdb.ada/pckd_arr_ren.exp index 13e599b6a5..8c53f857be 100644 --- a/gdb/testsuite/gdb.ada/pckd_arr_ren.exp +++ b/gdb/testsuite/gdb.ada/pckd_arr_ren.exp @@ -31,8 +31,9 @@ foreach_with_prefix scenario {all minimal} { set bp_location [gdb_get_line_number "STOP" ${testdir}/foo.adb] runto "foo.adb:$bp_location" - # GNAT >= 11.0 has the needed fix here. - if {$scenario == "minimal" && ![test_compiler_info {gcc-1[1-9]-*}]} { + # GNAT 9 and 10 are known to fail. + if {$scenario == "minimal" && ([test_compiler_info {gcc-9-*}] \ + || [test_compiler_info {gcc-10-*}])} { setup_kfail "minimal encodings" *-*-* } gdb_test "print A2" \ -- 2.34.1