https://gcc.gnu.org/g:a8ae8f9c2ed055b9e4408209f1c724493c5a3e3c
commit r15-3118-ga8ae8f9c2ed055b9e4408209f1c724493c5a3e3c Author: Bernd Edlinger <bernd.edlin...@hotmail.de> Date: Fri Aug 23 06:22:55 2024 +0200 Fix test failure on powerpc targets Apparently due to slightly different optimization levels not always both subroutines have multiple subranges, but having at least one such, and no lexical blocks is sufficient to prove that the fix worked. Q.E.D. So reduce the test expectations to only at least one inlined subroutine with multiple subranges. gcc/testsuite/ChangeLog: PR other/116462 * gcc.dg/debug/dwarf2/inline7.c: Reduce test expectations. Diff: --- gcc/testsuite/gcc.dg/debug/dwarf2/inline7.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gcc/testsuite/gcc.dg/debug/dwarf2/inline7.c b/gcc/testsuite/gcc.dg/debug/dwarf2/inline7.c index 48d457216b10..083df5b586cd 100644 --- a/gcc/testsuite/gcc.dg/debug/dwarf2/inline7.c +++ b/gcc/testsuite/gcc.dg/debug/dwarf2/inline7.c @@ -1,9 +1,9 @@ -/* Verify that both inline instances have a DW_AT_ranges but - no extra DW_TAG_lexical_block. */ +/* Verify that at least one of both inline instances have + a DW_AT_ranges but no extra DW_TAG_lexical_block. */ /* { dg-options "-O -gdwarf -dA" } */ /* { dg-do compile } */ /* { dg-final { scan-assembler-times "\\(DIE \\(\[^\n\]*\\) DW_TAG_inlined_subroutine" 2 } } */ -/* { dg-final { scan-assembler-times " DW_AT_ranges" 2 } } */ +/* { dg-final { scan-assembler " DW_AT_ranges" } } */ /* { dg-final { scan-assembler-times "\\(DIE \\(\[^\n\]*\\) DW_TAG_lexical_block" 0 } } */ static int foo (int i)