public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* x86 MMX/SSE testsuite additions/modifications
@ 2004-07-08 13:38 Jan Beulich
  0 siblings, 0 replies; only message in thread
From: Jan Beulich @ 2004-07-08 13:38 UTC (permalink / raw)
  To: gcc-patches

[-- Attachment #1: Type: text/plain, Size: 5845 bytes --]

This adds validation tests for the inline functions for SSE2/SSE3 and
verification that no undefined builtin functions are referenced by the
respective MMX/SSE tests. I would have (to uncover more problems)
changed
the "dg-do compile" to "dg-do assemble" (to also cover the case of bad
assembly generated) if I wasn't told not to modify pre-existing tests.

This patch alone will cause various failure for ix86 and x86-64 in the
modified tests, but since the fixes for these failures are independent
of one another they will be subsequently submitted.

Jan

testsuite:
2004-07-08 Jan Beulich <jbeulich@novell.com>

	* gcc.dg/i386-mmx-[12].c: Force error for references to
undefined builtins.
	* gcc.dg/i386-sse-[12].c: Dito.
	* gcc.dg/i386-sse2-[12].c: New tests to validate SSE2 inline
functions.
	* gcc.dg/i386-sse3-[12].c: New tests to validate SSE3 inline
functions.

---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-1.c	2002-01-15
07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-1.c	2004-06-15
15:34:49.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O2 -mmmx" } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -mmmx" }
*/
 
 /* Test that the intrinsics compile with optimization.  All of them
are
    defined as inline functions in mmintrin.h that reference the
proper
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-2.c	2002-01-15
07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-2.c	2004-06-15
15:34:53.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O0 -mmmx" } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -mmmx" }
*/
 
 /* Test that the intrinsics compile without optimization.  All of them
are
    defined as inline functions in mmintrin.h that reference the
proper
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-1.c	2002-01-15
07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-1.c	2004-06-15
15:35:15.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O2 -msse" } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -msse" }
*/
 
 /* Test that the intrinsics compile with optimization.  All of them
are
    defined as inline functions in mmintrin.h that reference the
proper
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-2.c	2002-01-15
07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-2.c	2004-06-15
15:35:21.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O0 -msse" } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -msse" }
*/
 
 /* Test that the intrinsics compile without optimization.  All of them
are
    defined as inline functions in mmintrin.h that reference the
proper
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-1.c	1970-01-01
01:00:00.000000000 +0100
+++
2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-1.c	2004-06-15
15:35:28.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -msse2" }
*/
+
+/* Test that the intrinsics compile with optimization.  All of them
are
+   defined as inline functions in mmintrin.h that reference the
proper
+   builtin functions.  Defining away "static" and "__inline" results
in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <emmintrin.h>
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-2.c	1970-01-01
01:00:00.000000000 +0100
+++
2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-2.c	2004-06-15
15:35:30.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -msse2" }
*/
+
+/* Test that the intrinsics compile without optimization.  All of them
are
+   defined as inline functions in mmintrin.h that reference the
proper
+   builtin functions.  Defining away "static" and "__inline" results
in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <emmintrin.h>
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-1.c	1970-01-01
01:00:00.000000000 +0100
+++
2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-1.c	2004-06-15
15:35:34.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -msse3" }
*/
+
+/* Test that the intrinsics compile with optimization.  All of them
are
+   defined as inline functions in mmintrin.h that reference the
proper
+   builtin functions.  Defining away "static" and "__inline" results
in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <pmmintrin.h>
---
/home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-2.c	1970-01-01
01:00:00.000000000 +0100
+++
2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-2.c	2004-06-15
15:35:37.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -msse3" }
*/
+
+/* Test that the intrinsics compile without optimization.  All of them
are
+   defined as inline functions in mmintrin.h that reference the
proper
+   builtin functions.  Defining away "static" and "__inline" results
in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <pmmintrin.h>


[-- Attachment #2: gcc-mainline-x86-mm-testsuite.patch --]
[-- Type: application/octet-stream, Size: 5844 bytes --]

This adds validation tests for the inline functions for SSE2/SSE3 and
verification that no undefined builtin functions are referenced by the
respective MMX/SSE tests. I would have (to uncover more problems) changed
the "dg-do compile" to "dg-do assemble" (to also cover the case of bad
assembly generated) if I wasn't told not to modify pre-existing tests.

This patch alone will cause various failure for ix86 and x86-64 in the
modified tests, but since the fixes for these failures are independent
of one another they will be subsequently submitted.

Jan

testsuite:
2004-07-08 Jan Beulich <jbeulich@novell.com>

	* gcc.dg/i386-mmx-[12].c: Force error for references to undefined builtins.
	* gcc.dg/i386-sse-[12].c: Dito.
	* gcc.dg/i386-sse2-[12].c: New tests to validate SSE2 inline functions.
	* gcc.dg/i386-sse3-[12].c: New tests to validate SSE3 inline functions.

--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-1.c	2002-01-15 07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-1.c	2004-06-15 15:34:49.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O2 -mmmx" } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -mmmx" } */
 
 /* Test that the intrinsics compile with optimization.  All of them are
    defined as inline functions in mmintrin.h that reference the proper
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-2.c	2002-01-15 07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-mmx-2.c	2004-06-15 15:34:53.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O0 -mmmx" } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -mmmx" } */
 
 /* Test that the intrinsics compile without optimization.  All of them are
    defined as inline functions in mmintrin.h that reference the proper
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-1.c	2002-01-15 07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-1.c	2004-06-15 15:35:15.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O2 -msse" } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -msse" } */
 
 /* Test that the intrinsics compile with optimization.  All of them are
    defined as inline functions in mmintrin.h that reference the proper
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-2.c	2002-01-15 07:17:04.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse-2.c	2004-06-15 15:35:21.000000000 +0200
@@ -1,5 +1,5 @@
 /* { dg-do compile { target i?86-*-* x86_64-*-* } } */
-/* { dg-options "-O0 -msse" } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -msse" } */
 
 /* Test that the intrinsics compile without optimization.  All of them are
    defined as inline functions in mmintrin.h that reference the proper
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-1.c	1970-01-01 01:00:00.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-1.c	2004-06-15 15:35:28.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -msse2" } */
+
+/* Test that the intrinsics compile with optimization.  All of them are
+   defined as inline functions in mmintrin.h that reference the proper
+   builtin functions.  Defining away "static" and "__inline" results in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <emmintrin.h>
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-2.c	1970-01-01 01:00:00.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse2-2.c	2004-06-15 15:35:30.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -msse2" } */
+
+/* Test that the intrinsics compile without optimization.  All of them are
+   defined as inline functions in mmintrin.h that reference the proper
+   builtin functions.  Defining away "static" and "__inline" results in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <emmintrin.h>
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-1.c	1970-01-01 01:00:00.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-1.c	2004-06-15 15:35:34.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O2 -Werror-implicit-function-declaration -msse3" } */
+
+/* Test that the intrinsics compile with optimization.  All of them are
+   defined as inline functions in mmintrin.h that reference the proper
+   builtin functions.  Defining away "static" and "__inline" results in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <pmmintrin.h>
--- /home/jbeulich/src/gcc/mainline/2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-2.c	1970-01-01 01:00:00.000000000 +0100
+++ 2004-07-05.10.09/gcc/testsuite/gcc.dg/i386-sse3-2.c	2004-06-15 15:35:37.000000000 +0200
@@ -0,0 +1,12 @@
+/* { dg-do assemble { target i?86-*-* x86_64-*-* } } */
+/* { dg-options "-O0 -Werror-implicit-function-declaration -msse3" } */
+
+/* Test that the intrinsics compile without optimization.  All of them are
+   defined as inline functions in mmintrin.h that reference the proper
+   builtin functions.  Defining away "static" and "__inline" results in
+   all of them being compiled as proper functions.  */
+
+#define static
+#define __inline
+
+#include <pmmintrin.h>

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

only message in thread, other threads:[~2004-07-08 12:23 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-07-08 13:38 x86 MMX/SSE testsuite additions/modifications Jan Beulich

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