[clang] [X86] Change target of __builtin_ia32_cmp[p|s][s|d] from avx into sse/sse2 (PR #84136)

via cfe-commits cfe-commits at lists.llvm.org
Wed Mar 6 00:16:12 PST 2024


github-actions[bot] wrote:

<!--LLVM CODE FORMAT COMMENT: {clang-format}-->


:warning: C/C++ code formatter, clang-format found issues in your code. :warning:

<details>
<summary>
You can test this locally with the following command:
</summary>

``````````bash
git-clang-format --diff 9a894e7d84892489826375f94c08ab16ccacc4bb 54c78b5ad694946186ba115576a6eea9c8992349 -- clang/test/CodeGen/X86/attribute-cmpsd-no-error.c clang/test/CodeGen/X86/cmp-avx-builtins-error.c clang/lib/CodeGen/CodeGenFunction.cpp clang/lib/Headers/avxintrin.h clang/lib/Headers/emmintrin.h clang/lib/Headers/xmmintrin.h clang/test/CodeGen/X86/avx-builtins.c clang/test/CodeGen/X86/sse-builtins.c clang/test/CodeGen/X86/sse2-builtins.c clang/test/CodeGen/target-features-error-2.c
``````````

</details>

<details>
<summary>
View the diff from clang-format here.
</summary>

``````````diff
diff --git a/clang/lib/Headers/xmmintrin.h b/clang/lib/Headers/xmmintrin.h
index f9894c23ce..0f2370fb39 100644
--- a/clang/lib/Headers/xmmintrin.h
+++ b/clang/lib/Headers/xmmintrin.h
@@ -2941,14 +2941,14 @@ _mm_movemask_ps(__m128 __a)
 }
 
 /* Compare */
-#define _CMP_EQ_OQ    0x00 /* Equal (ordered, non-signaling)  */
-#define _CMP_LT_OS    0x01 /* Less-than (ordered, signaling)  */
-#define _CMP_LE_OS    0x02 /* Less-than-or-equal (ordered, signaling)  */
-#define _CMP_UNORD_Q  0x03 /* Unordered (non-signaling)  */
-#define _CMP_NEQ_UQ   0x04 /* Not-equal (unordered, non-signaling)  */
-#define _CMP_NLT_US   0x05 /* Not-less-than (unordered, signaling)  */
-#define _CMP_NLE_US   0x06 /* Not-less-than-or-equal (unordered, signaling)  */
-#define _CMP_ORD_Q    0x07 /* Ordered (non-signaling)   */
+#define _CMP_EQ_OQ 0x00   /* Equal (ordered, non-signaling)  */
+#define _CMP_LT_OS 0x01   /* Less-than (ordered, signaling)  */
+#define _CMP_LE_OS 0x02   /* Less-than-or-equal (ordered, signaling)  */
+#define _CMP_UNORD_Q 0x03 /* Unordered (non-signaling)  */
+#define _CMP_NEQ_UQ 0x04  /* Not-equal (unordered, non-signaling)  */
+#define _CMP_NLT_US 0x05  /* Not-less-than (unordered, signaling)  */
+#define _CMP_NLE_US 0x06  /* Not-less-than-or-equal (unordered, signaling)  */
+#define _CMP_ORD_Q 0x07   /* Ordered (non-signaling)   */
 
 /// Compares each of the corresponding values of two 128-bit vectors of
 ///    [4 x float], using the operation specified by the immediate integer

``````````

</details>


https://github.com/llvm/llvm-project/pull/84136


More information about the cfe-commits mailing list