Use non-capturing parentheses for the subexpressions used with `scan-assembler-times', to avoid a quirk with double-counting.
gcc/testsuite/ * gcc.target/arm/pr53447-5.c: Use non-capturing parentheses with `scan-assembler-times'. --- Hi, The `scan-assembler-times' quirk is being fixed with <https://gcc.gnu.org/pipermail/gcc-patches/2023-November/637254.html>, but we don't need capturing parentheses here, typically used for back references, so let's just avoid the quirk altogether and make our matching here work either way. Cf. commit 88c888f11379 ("pr53447-5.c: Fix test expectations for neon-fpu."). Verified by proof-reading, with a reference to the commit quoted above. OK to apply? Maciej --- gcc/testsuite/gcc.target/arm/pr53447-5.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) gcc-arm-test-pr53447-5-non-capturing.diff Index: gcc/gcc/testsuite/gcc.target/arm/pr53447-5.c =================================================================== --- gcc.orig/gcc/testsuite/gcc.target/arm/pr53447-5.c +++ gcc/gcc/testsuite/gcc.target/arm/pr53447-5.c @@ -15,8 +15,6 @@ void foo(long long* p) p[9] -= p[10]; } -/* We accept neon instructions vldr.64 and vstr.64 as well. - Note: DejaGnu counts patterns with alternatives twice, - so actually there are only 10 loads and 9 stores. */ -/* { dg-final { scan-assembler-times "(ldrd|vldr\\.64)" 20 } } */ -/* { dg-final { scan-assembler-times "(strd|vstr\\.64)" 18 } } */ +/* We accept neon instructions vldr.64 and vstr.64 as well. */ +/* { dg-final { scan-assembler-times "(?:ldrd|vldr\\.64)" 10 } } */ +/* { dg-final { scan-assembler-times "(?:strd|vstr\\.64)" 9 } } */