r201772 - Change parameter type of _mm_prefetch to "const void *".

Daniel Jasper djasper at google.com
Thu Feb 20 02:04:07 PST 2014


Author: djasper
Date: Thu Feb 20 04:04:07 2014
New Revision: 201772

URL: http://llvm.org/viewvc/llvm-project?rev=201772&view=rev
Log:
Change parameter type of _mm_prefetch to "const void *".

Otherwise, this is not backwards compatible to the existing macro and
can break existing code.

Modified:
    cfe/trunk/include/clang/Basic/BuiltinsX86.def
    cfe/trunk/test/Headers/mmprefetch.c

Modified: cfe/trunk/include/clang/Basic/BuiltinsX86.def
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Basic/BuiltinsX86.def?rev=201772&r1=201771&r2=201772&view=diff
==============================================================================
--- cfe/trunk/include/clang/Basic/BuiltinsX86.def (original)
+++ cfe/trunk/include/clang/Basic/BuiltinsX86.def Thu Feb 20 04:04:07 2014
@@ -59,7 +59,7 @@ BUILTIN(__builtin_ia32_pswapdsi, "V2iV2i
 // All MMX instructions will be generated via builtins. Any MMX vector
 // types (<1 x i64>, <2 x i32>, etc.) that aren't used by these builtins will be
 // expanded by the back-end.
-BUILTIN(_mm_prefetch, "vcC*i", "nc")
+BUILTIN(_mm_prefetch, "vvC*i", "nc")
 BUILTIN(__builtin_ia32_emms, "v", "")
 BUILTIN(__builtin_ia32_paddb, "V8cV8cV8c", "")
 BUILTIN(__builtin_ia32_paddw, "V4sV4sV4s", "")

Modified: cfe/trunk/test/Headers/mmprefetch.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Headers/mmprefetch.c?rev=201772&r1=201771&r2=201772&view=diff
==============================================================================
--- cfe/trunk/test/Headers/mmprefetch.c (original)
+++ cfe/trunk/test/Headers/mmprefetch.c Thu Feb 20 04:04:07 2014
@@ -3,7 +3,7 @@
 #include <mmintrin.h>
 
 // Check to make sure that _mm_prefetch survives redeclaration.
-void _mm_prefetch(char const*, int);
+void _mm_prefetch(void const*, int);
 
 void f(char *a) {
   _mm_prefetch(a, 0);





More information about the cfe-commits mailing list