public inbox for gcc-cvs@sourceware.org
help / color / mirror / Atom feed
* [gcc r14-5845] Fix gcc.target/aarch64/movk.c testcase after IPA-VRP improvement for return values
@ 2023-11-25 21:36 Andrew Pinski
  0 siblings, 0 replies; only message in thread
From: Andrew Pinski @ 2023-11-25 21:36 UTC (permalink / raw)
  To: gcc-cvs

https://gcc.gnu.org/g:8d559a9b85d9a6de4f358171178a74605f554082

commit r14-5845-g8d559a9b85d9a6de4f358171178a74605f554082
Author: Andrew Pinski <quic_apinski@quicinc.com>
Date:   Tue Nov 21 18:25:24 2023 -0800

    Fix gcc.target/aarch64/movk.c testcase after IPA-VRP improvement for return values
    
    The problem here is dummy_number_generator returns a constant which IPA VRP is now able
    propagate that so we need to mark the funciton as noipa to stop that.
    
    gcc/testsuite/ChangeLog:
    
            PR testsuite/112688
            * gcc.target/aarch64/movk.c: Add noipa on dummy_number_generator
            and remove -fno-inline option.
    
    Signed-off-by: Andrew Pinski <quic_apinski@quicinc.com>

Diff:
---
 gcc/testsuite/gcc.target/aarch64/movk.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/gcc/testsuite/gcc.target/aarch64/movk.c b/gcc/testsuite/gcc.target/aarch64/movk.c
index e6e4e3a8961..1fa11540c6c 100644
--- a/gcc/testsuite/gcc.target/aarch64/movk.c
+++ b/gcc/testsuite/gcc.target/aarch64/movk.c
@@ -1,8 +1,11 @@
 /* { dg-do run } */
-/* { dg-options "-O2 --save-temps -fno-inline" } */
+/* { dg-options "-O2 --save-temps" } */
 
 extern void abort (void);
 
+/* Note GCC can optimize this to -346565474575675 even without inlining so
+   mark it for noipa.  */
+[[gnu::noipa]]
 long long int
 dummy_number_generator ()
 {

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2023-11-25 21:36 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-25 21:36 [gcc r14-5845] Fix gcc.target/aarch64/movk.c testcase after IPA-VRP improvement for return values Andrew Pinski

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).