aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorRichard Henderson <rth@redhat.com>2007-03-21 08:52:23 -0700
committerRichard Henderson <rth@gcc.gnu.org>2007-03-21 08:52:23 -0700
commitb5cf27d7ec42156b78369cc0bdaabc34d1885191 (patch)
tree3fd4694ce5ed120d2892be28b11fb013bb783908 /gcc
parentcb717c409821f271ef6119e784b52ee48bf29fa0 (diff)
downloadgcc-b5cf27d7ec42156b78369cc0bdaabc34d1885191.zip
gcc-b5cf27d7ec42156b78369cc0bdaabc34d1885191.tar.gz
gcc-b5cf27d7ec42156b78369cc0bdaabc34d1885191.tar.bz2
re PR target/31245 (SSE2 generation bug with 4.1.2 and -O3)
PR target/31245 * config/i386/emmintrin.h (__m128i, __m128d): Mark may_alias. * config/i386/mmintrin.h (__m64): Likewise. * config/i386/xmmintrin.h (__m128): Likewise. From-SVN: r123112
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog7
-rw-r--r--gcc/config/i386/emmintrin.h6
-rw-r--r--gcc/config/i386/mmintrin.h7
-rw-r--r--gcc/config/i386/xmmintrin.h5
4 files changed, 18 insertions, 7 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 5d93c7d..a53840e 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,10 @@
+2007-03-21 Richard Henderson <rth@redhat.com>
+
+ PR target/31245
+ * config/i386/emmintrin.h (__m128i, __m128d): Mark may_alias.
+ * config/i386/mmintrin.h (__m64): Likewise.
+ * config/i386/xmmintrin.h (__m128): Likewise.
+
2007-03-21 Richard Sandiford <richard@codesourcery.com>
* config/vxworks.h (VXWORKS_ADDITIONAL_CPP_SPEC): Remove -D options.
diff --git a/gcc/config/i386/emmintrin.h b/gcc/config/i386/emmintrin.h
index 43a6262..002e16c 100644
--- a/gcc/config/i386/emmintrin.h
+++ b/gcc/config/i386/emmintrin.h
@@ -44,8 +44,10 @@ typedef int __v4si __attribute__ ((__vector_size__ (16)));
typedef short __v8hi __attribute__ ((__vector_size__ (16)));
typedef char __v16qi __attribute__ ((__vector_size__ (16)));
-typedef __v2di __m128i;
-typedef __v2df __m128d;
+/* The Intel API is flexible enough that we must allow aliasing with other
+ vector types, and their scalar components. */
+typedef long long __m128i __attribute__ ((__vector_size__ (16), __may_alias__));
+typedef double __m128d __attribute__ ((__vector_size__ (16), __may_alias__));
/* Create a selector for use with the SHUFPD instruction. */
#define _MM_SHUFFLE2(fp1,fp0) \
diff --git a/gcc/config/i386/mmintrin.h b/gcc/config/i386/mmintrin.h
index 1a74271..052198d 100644
--- a/gcc/config/i386/mmintrin.h
+++ b/gcc/config/i386/mmintrin.h
@@ -1,4 +1,4 @@
-/* Copyright (C) 2002, 2003, 2004, 2005, 2006
+/* Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007
Free Software Foundation, Inc.
This file is part of GCC.
@@ -34,8 +34,9 @@
#ifndef __MMX__
# error "MMX instruction set not enabled"
#else
-/* The data type intended for user use. */
-typedef int __m64 __attribute__ ((__vector_size__ (8)));
+/* The Intel API is flexible enough that we must allow aliasing with other
+ vector types, and their scalar components. */
+typedef int __m64 __attribute__ ((__vector_size__ (8), __may_alias__));
/* Internal data types for implementing the intrinsics. */
typedef int __v2si __attribute__ ((__vector_size__ (8)));
diff --git a/gcc/config/i386/xmmintrin.h b/gcc/config/i386/xmmintrin.h
index 48b177c..57ef330 100644
--- a/gcc/config/i386/xmmintrin.h
+++ b/gcc/config/i386/xmmintrin.h
@@ -41,8 +41,9 @@
/* Get _mm_malloc () and _mm_free (). */
#include <mm_malloc.h>
-/* The data type intended for user use. */
-typedef float __m128 __attribute__ ((__vector_size__ (16)));
+/* The Intel API is flexible enough that we must allow aliasing with other
+ vector types, and their scalar components. */
+typedef float __m128 __attribute__ ((__vector_size__ (16), __may_alias__));
/* Internal data types for implementing the intrinsics. */
typedef float __v4sf __attribute__ ((__vector_size__ (16)));