public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Jan Beulich" <JBeulich@novell.com>
To: <gcc-patches@gcc.gnu.org>
Subject: x86 MMX/SSE testsuite additions/modifications
Date: Thu, 08 Jul 2004 13:38:00 -0000	[thread overview]
Message-ID: <s0ed4ae4.098@emea1-mh.id2.novell.com> (raw)

[-- 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>

                 reply	other threads:[~2004-07-08 12:23 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=s0ed4ae4.098@emea1-mh.id2.novell.com \
    --to=jbeulich@novell.com \
    --cc=gcc-patches@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).