Skip to content

Commit e5cc3da

Browse files
committed
[X86][AVX10] Add no-evex512 for MMX intrinsics, NFCI
Some MMX intrinsics like _mm_setzero_si64 will be called by XMM intrinsics, so need to propagate no-evex512 there. Checked locally with a lot of modified tests and no side effect with this change. No extra test needed for the update.
1 parent fa1e49c commit e5cc3da

File tree

1 file changed

+7
-5
lines changed

1 file changed

+7
-5
lines changed

clang/lib/Headers/mmintrin.h

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,9 @@ typedef short __v4hi __attribute__((__vector_size__(8)));
2222
typedef char __v8qi __attribute__((__vector_size__(8)));
2323

2424
/* Define the default attributes for the functions in this file. */
25-
#define __DEFAULT_FN_ATTRS __attribute__((__always_inline__, __nodebug__, __target__("mmx"), __min_vector_width__(64)))
25+
#define __DEFAULT_FN_ATTRS \
26+
__attribute__((__always_inline__, __nodebug__, __target__("mmx,no-evex512"), \
27+
__min_vector_width__(64)))
2628

2729
/// Clears the MMX state by setting the state of the x87 stack registers
2830
/// to empty.
@@ -31,10 +33,10 @@ typedef char __v8qi __attribute__((__vector_size__(8)));
3133
///
3234
/// This intrinsic corresponds to the <c> EMMS </c> instruction.
3335
///
34-
static __inline__ void __attribute__((__always_inline__, __nodebug__, __target__("mmx")))
35-
_mm_empty(void)
36-
{
37-
__builtin_ia32_emms();
36+
static __inline__ void __attribute__((__always_inline__, __nodebug__,
37+
__target__("mmx,no-evex512")))
38+
_mm_empty(void) {
39+
__builtin_ia32_emms();
3840
}
3941

4042
/// Constructs a 64-bit integer vector, setting the lower 32 bits to the

0 commit comments

Comments
 (0)