aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2021-01-23 09:41:58 +0100
committerJakub Jelinek <jakub@redhat.com>2021-01-23 09:41:58 +0100
commitc63f091db89a56ae56b2bfa2ba4d9e956bd9693f (patch)
treec25c6d8add37e5841cae1f55c104280bb6c46d7a /gcc
parenta8cef3cba6945730c69e15dcdad726e74b50fe58 (diff)
downloadgcc-c63f091db89a56ae56b2bfa2ba4d9e956bd9693f.zip
gcc-c63f091db89a56ae56b2bfa2ba4d9e956bd9693f.tar.gz
gcc-c63f091db89a56ae56b2bfa2ba4d9e956bd9693f.tar.bz2
rs6000: Fix up __m64 typedef in mmintrin.h [PR97301]
The x86 __m64 type is defined as: /* 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__)); and so matches the comment above it in that reads and stores through pointers to __m64 can alias anything. But in the rs6000 headers that is the case only for __m128, but not __m64. The following patch adds that attribute, which fixes the FAIL: gcc.target/powerpc/sse-movhps-1.c execution test FAIL: gcc.target/powerpc/sse-movlps-1.c execution test regressions that appeared when Honza improved ipa-modref. 2021-01-23 Jakub Jelinek <jakub@redhat.com> PR testsuite/97301 * config/rs6000/mmintrin.h (__m64): Add __may_alias__ attribute.
Diffstat (limited to 'gcc')
-rw-r--r--gcc/config/rs6000/mmintrin.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/config/rs6000/mmintrin.h b/gcc/config/rs6000/mmintrin.h
index 60d1a25..0bd929c 100644
--- a/gcc/config/rs6000/mmintrin.h
+++ b/gcc/config/rs6000/mmintrin.h
@@ -58,7 +58,8 @@
#include <altivec.h>
/* The Intel API is flexible enough that we must allow aliasing with other
vector types, and their scalar components. */
-typedef __attribute__ ((__aligned__ (8))) unsigned long long __m64;
+typedef __attribute__ ((__aligned__ (8),
+ __may_alias__)) unsigned long long __m64;
typedef __attribute__ ((__aligned__ (8)))
union