From: Jason Merrill <jason@redhat.com>
To: gcc-patches@gcc.gnu.org
Subject: [pushed] c++: -frounding-math test [PR109359]
Date: Mon, 5 Feb 2024 16:34:34 -0500 [thread overview]
Message-ID: <20240205213458.822987-1-jason@redhat.com> (raw)
Tested x86_64-pc-linux-gnu, applying to trunk.
-- 8< --
This test was fixed by the patch for PR95226, but that patch had no
testcase so let's add this one.
PR c++/109359
gcc/testsuite/ChangeLog:
* g++.dg/ext/frounding-math1.C: New test.
---
gcc/testsuite/g++.dg/ext/frounding-math1.C | 8 ++++++++
1 file changed, 8 insertions(+)
create mode 100644 gcc/testsuite/g++.dg/ext/frounding-math1.C
diff --git a/gcc/testsuite/g++.dg/ext/frounding-math1.C b/gcc/testsuite/g++.dg/ext/frounding-math1.C
new file mode 100644
index 00000000000..ecc46fd6017
--- /dev/null
+++ b/gcc/testsuite/g++.dg/ext/frounding-math1.C
@@ -0,0 +1,8 @@
+// PR c++/109359
+// { dg-additional-options -frounding-math }
+
+// For a while we were emitting two doubles (4 .long directives) as the value
+// of a float array; it should only be two .longs.
+
+// { dg-final { scan-assembler-times "long" 2 { target x86_64-*-* } } }
+float xs[] = {0.001914, 0.630539};
base-commit: c7e8381748f78335e9fef23f363b6a9e4463ce7e
--
2.43.0
reply other threads:[~2024-02-05 21:35 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=20240205213458.822987-1-jason@redhat.com \
--to=jason@redhat.com \
--cc=gcc-patches@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: link
Be 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).