[COMMITTED, PATCH] fuse-caller-save-xmm.c: Disable TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL

"H.J. Lu" <[email protected]>
Newsgroups gmane.comp.gcc.patches
Message-ID <CAMe9rOrLwTLZy8pPSrHJuVs5xQT3YAWp=2kgJrt6UapUT8fuRQ@mail.gmail.com>
Disable TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL for fuse-caller-save-xmm.c
to avoid

FAIL: gcc.target/i386/fuse-caller-save-xmm.c scan-assembler-times
movapd\t%xmm0, %xmm1 1

due to the generated instruction

movaps %xmm0, %xmm1

vs the expected instruction

movapd %xmm0, %xmm1

when TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL is enabled by default.

PR testsuite/126923
* gcc.target/i386/fuse-caller-save-xmm.c (dg-options): Add
-mtune-ctrl=^sse_packed_single_insn_optimal.

-- 
H.J.
0001-fuse-caller-save-xmm.c-Disable-TARGET_SSE_PACKED_SIN.patch (text/x-patch, 1.4 KB)
From dcfc91d43c501523d6241c220b1480a5d93105d4 Mon Sep 17 00:00:00 2001
From: "H.J. Lu" <[email protected]>
Date: Thu, 20 Aug 2026 14:28:07 +0800
Subject: [PATCH] fuse-caller-save-xmm.c: Disable
 TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL

Disable TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL for fuse-caller-save-xmm.c
to avoid

FAIL: gcc.target/i386/fuse-caller-save-xmm.c scan-assembler-times movapd\t%xmm0, %xmm1 1

due to the generated instruction

	movaps	%xmm0, %xmm1

vs the expected instruction

	movapd	%xmm0, %xmm1

when TARGET_SSE_PACKED_SINGLE_INSN_OPTIMAL is enabled by default.

	PR testsuite/126923
	* gcc.target/i386/fuse-caller-save-xmm.c (dg-options): Add
	-mtune-ctrl=^sse_packed_single_insn_optimal.

Signed-off-by: H.J. Lu <[email protected]>
---
 gcc/testsuite/gcc.target/i386/fuse-caller-save-xmm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/gcc/testsuite/gcc.target/i386/fuse-caller-save-xmm.c b/gcc/testsuite/gcc.target/i386/fuse-caller-save-xmm.c
index b0d3dc38a0c..2b616ddd993 100644
--- a/gcc/testsuite/gcc.target/i386/fuse-caller-save-xmm.c
+++ b/gcc/testsuite/gcc.target/i386/fuse-caller-save-xmm.c
@@ -1,5 +1,5 @@
 /* { dg-do compile } */
-/* { dg-options "-O2 -msse2 -mno-avx -fipa-ra -fomit-frame-pointer" } */
+/* { dg-options "-O2 -msse2 -mno-avx -mtune-ctrl=^sse_packed_single_insn_optimal -fipa-ra -fomit-frame-pointer" } */
 
 typedef double v2df __attribute__((vector_size (16)));
 
-- 
2.55.0
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.