This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[PATCH, testsuite]: Committed: Fix gcc.dg/array-init-1.c failure for i386 target
- From: Uros Bizjak <ubizjak at gmail dot com>
- To: GCC Patches <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 28 Sep 2007 20:18:40 +0200
- Subject: [PATCH, testsuite]: Committed: Fix gcc.dg/array-init-1.c failure for i386 target
Hello!
Pure i386 target has too low MOVE_RATIO to trigger the optimization,
checked with gcc.dg/array-init-1.c test. Attached patch adds -mtune=i686
for 32bit x86 targets to fix this failure.
Patch was tested by running the testcase on x86_64 with -m32/-march=i386.
2007-09-28 Uros Bizjak <ubizjak@gmail.com>
* gcc.dg/array-init-1.c: Add -mtune=i686 for 32bit x86 targets.
Uros.
Index: gcc.dg/array-init-1.c
===================================================================
--- gcc.dg/array-init-1.c (revision 128868)
+++ gcc.dg/array-init-1.c (working copy)
@@ -1,6 +1,7 @@
/* Test that both arrays are initialized by store_by_pieces. */
/* { dg-do compile } */
/* { dg-options "-O2" } */
+/* { dg-options "-O2 -mtune=i686" { target { { i?86-*-* x86_64-*-* } &&
ilp32 } } } */
struct A { char c[10]; };
extern void baz (struct A *);