public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Iain D Sandoe <iains@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-1178] testsuite, Darwin: Allow for two CTOR bodies in array61 test. Date: Mon, 20 Jun 2022 15:21:15 +0000 (GMT) [thread overview] Message-ID: <20220620152115.E40243851AA7@sourceware.org> (raw) https://gcc.gnu.org/g:125bf21299ea6ddad03bcace5982a998d1432c54 commit r13-1178-g125bf21299ea6ddad03bcace5982a998d1432c54 Author: Iain Sandoe <iain@sandoe.co.uk> Date: Sun Jun 19 10:21:28 2022 +0100 testsuite, Darwin: Allow for two CTOR bodies in array61 test. For targets without alias support, we emit two essentially identical function bodies into the gimple (complete and base CTORs). So this test needs to allow for that when the target does not support aliases. The target support alias test does not seem to be usable in the context of a single scan-tree-dump so the fix here uses the target designation. Note that the array has 10 elements, so that if the test were failing (because we were emitting 10 inits instead of a loop) the count would be expected to exceed 2, on Darwin and 1 where there's alias support. Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> gcc/testsuite/ChangeLog: * g++.dg/init/array61.C: Allow for two CTOR bodies on Darwin, where aliases are not currently supported. Diff: --- gcc/testsuite/g++.dg/init/array61.C | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/gcc/testsuite/g++.dg/init/array61.C b/gcc/testsuite/g++.dg/init/array61.C index eaf535c2546..c8f82b9f155 100644 --- a/gcc/testsuite/g++.dg/init/array61.C +++ b/gcc/testsuite/g++.dg/init/array61.C @@ -1,7 +1,8 @@ // PR c++/92385 // { dg-do compile { target c++11 } } // { dg-additional-options -fdump-tree-gimple } -// { dg-final { scan-tree-dump-times "item::item" 1 "gimple" } } +// { dg-final { scan-tree-dump-times "item::item" 1 "gimple" { target { ! *-*-darwin* } } } } +// { dg-final { scan-tree-dump-times "item::item" 2 "gimple" { target { *-*-darwin* } } } } struct item { int i;
reply other threads:[~2022-06-20 15:21 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20220620152115.E40243851AA7@sourceware.org \ --to=iains@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).