This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Fix execution tests using %ll formats on MinGW
- From: "Joseph S. Myers" <joseph at codesourcery dot com>
- To: gcc-patches at gcc dot gnu dot org
- Date: Tue, 26 Feb 2008 23:18:10 +0000 (UTC)
- Subject: Fix execution tests using %ll formats on MinGW
gcc.target/i386/mmx-4.c and gcc.target/i386/sse-6.c fail on MinGW
because of using %llx printf formats that aren't supported there.
This patch makes those tests use %I64x on MinGW instead. OK to
commit?
2008-02-26 Joseph Myers <joseph@codesourcery.com>
* gcc.target/i386/mmx-4.c (dump64_64): Use printf %I64 on MinGW.
* gcc.target/i386/sse-6.c (dump128_64): Likewise.
Index: gcc.target/i386/sse-6.c
===================================================================
--- gcc.target/i386/sse-6.c (revision 132664)
+++ gcc.target/i386/sse-6.c (working copy)
@@ -229,7 +229,11 @@
for (i=0; i<2; i++)
{
+#if defined(_WIN32) && !defined(__CYGWIN__)
+ sprintf (p, "%16.16I64x ", x.u[i]);
+#else
sprintf (p, "%16.16llx ", x.u[i]);
+#endif
p += strlen (p);
}
strcat (p, "\n");
Index: gcc.target/i386/mmx-4.c
===================================================================
--- gcc.target/i386/mmx-4.c (revision 132664)
+++ gcc.target/i386/mmx-4.c (working copy)
@@ -184,7 +184,11 @@
sprintf (p, "%s ", name);
p += strlen (p);
+#if defined(_WIN32) && !defined(__CYGWIN__)
+ sprintf (p, "%16.16I64x\n", x.t);
+#else
sprintf (p, "%16.16llx\n", x.t);
+#endif
}
int
--
Joseph S. Myers
joseph@codesourcery.com