diff --git a/clang/docs/ReleaseNotes.rst b/clang/docs/ReleaseNotes.rst --- a/clang/docs/ReleaseNotes.rst +++ b/clang/docs/ReleaseNotes.rst @@ -550,6 +550,7 @@ -------------------- - Support ``-mindirect-branch-cs-prefix`` for call and jmp to indirect thunk. - Fix 32-bit ``__fastcall`` and ``__vectorcall`` ABI mismatch with MSVC. +- Support ISA of ``CMPCCXADD``. DWARF Support in Clang ---------------------- diff --git a/clang/include/clang/Basic/BuiltinsX86_64.def b/clang/include/clang/Basic/BuiltinsX86_64.def --- a/clang/include/clang/Basic/BuiltinsX86_64.def +++ b/clang/include/clang/Basic/BuiltinsX86_64.def @@ -133,6 +133,8 @@ TARGET_BUILTIN(__builtin_ia32_tdpbf16ps, "vIUcIUcIUc", "n", "amx-bf16") TARGET_BUILTIN(__builtin_ia32_ptwrite64, "vUOi", "n", "ptwrite") +TARGET_BUILTIN(__builtin_ia32_cmpccxadd32, "Siv*SiSiIi", "n", "cmpccxadd") +TARGET_BUILTIN(__builtin_ia32_cmpccxadd64, "SLLiv*SLLiSLLiIi", "n", "cmpccxadd") #undef BUILTIN #undef TARGET_BUILTIN #undef TARGET_HEADER_BUILTIN diff --git a/clang/include/clang/Driver/Options.td b/clang/include/clang/Driver/Options.td --- a/clang/include/clang/Driver/Options.td +++ b/clang/include/clang/Driver/Options.td @@ -4527,6 +4527,8 @@ def mno_amx_int8 : Flag<["-"], "mno-amx-int8">, Group; def mamx_tile : Flag<["-"], "mamx-tile">, Group; def mno_amx_tile : Flag<["-"], "mno-amx-tile">, Group; +def mcmpccxadd : Flag<["-"], "mcmpccxadd">, Group; +def mno_cmpccxadd : Flag<["-"], "mno-cmpccxadd">, Group; def msse : Flag<["-"], "msse">, Group; def mno_sse : Flag<["-"], "mno-sse">, Group; def msse2 : Flag<["-"], "msse2">, Group; diff --git a/clang/lib/Basic/Targets/X86.h b/clang/lib/Basic/Targets/X86.h --- a/clang/lib/Basic/Targets/X86.h +++ b/clang/lib/Basic/Targets/X86.h @@ -135,6 +135,7 @@ bool HasPTWRITE = false; bool HasINVPCID = false; bool HasENQCMD = false; + bool HasCMPCCXADD = false; bool HasKL = false; // For key locker bool HasWIDEKL = false; // For wide key locker bool HasHRESET = false; diff --git a/clang/lib/Basic/Targets/X86.cpp b/clang/lib/Basic/Targets/X86.cpp --- a/clang/lib/Basic/Targets/X86.cpp +++ b/clang/lib/Basic/Targets/X86.cpp @@ -330,6 +330,8 @@ HasAMXINT8 = true; } else if (Feature == "+amx-tile") { HasAMXTILE = true; + } else if (Feature == "+cmpccxadd") { + HasCMPCCXADD = true; } else if (Feature == "+avxvnni") { HasAVXVNNI = true; } else if (Feature == "+serialize") { @@ -774,6 +776,9 @@ Builder.defineMacro("__AMXINT8__"); if (HasAMXBF16) Builder.defineMacro("__AMXBF16__"); + if (HasCMPCCXADD) + Builder.defineMacro("__CMPCCXADD__"); + Builder.defineMacro("__CMPCCXADD_SUPPORTED__"); if (HasAVXVNNI) Builder.defineMacro("__AVXVNNI__"); if (HasSERIALIZE) @@ -963,6 +968,7 @@ .Case("xsavec", true) .Case("xsaves", true) .Case("xsaveopt", true) + .Case("cmpccxadd", true) .Default(false); } @@ -992,6 +998,7 @@ .Case("avx512vbmi2", HasAVX512VBMI2) .Case("avx512ifma", HasAVX512IFMA) .Case("avx512vp2intersect", HasAVX512VP2INTERSECT) + .Case("cmpccxadd", HasCMPCCXADD) .Case("bmi", HasBMI) .Case("bmi2", HasBMI2) .Case("cldemote", HasCLDEMOTE) diff --git a/clang/lib/Headers/CMakeLists.txt b/clang/lib/Headers/CMakeLists.txt --- a/clang/lib/Headers/CMakeLists.txt +++ b/clang/lib/Headers/CMakeLists.txt @@ -150,6 +150,7 @@ clflushoptintrin.h clwbintrin.h clzerointrin.h + cmpccxaddintrin.h crc32intrin.h emmintrin.h enqcmdintrin.h diff --git a/clang/lib/Headers/cmpccxaddintrin.h b/clang/lib/Headers/cmpccxaddintrin.h new file mode 100644 --- /dev/null +++ b/clang/lib/Headers/cmpccxaddintrin.h @@ -0,0 +1,69 @@ +/*===--------------- cmpccxaddintrin.h - CMPCCXADD intrinsics--------------=== + * + * + * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. + * See https://llvm.org/LICENSE.txt for license information. + * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + * + *===-----------------------------------------------------------------------=== + */ +#ifndef __IMMINTRIN_H +#error "Never use directly; include instead." +#endif // __IMMINTRIN_H + +#ifndef __CMPCCXADDINTRIN_H +#define __CMPCCXADDINTRIN_H +#ifdef __x86_64__ + +typedef enum { + _CMPCCX_BE, /* Below or equal. */ + _CMPCCX_B, /* Below. */ + _CMPCCX_LE, /* Less or equal. */ + _CMPCCX_L, /* Less. */ + _CMPCCX_NBE, /* Neither below nor equal. */ + _CMPCCX_NB, /* Not below. */ + _CMPCCX_NLE, /* Neither less nor equal. */ + _CMPCCX_NL, /* Not less. */ + _CMPCCX_NO, /* No overflow. */ + _CMPCCX_NP, /* No parity. */ + _CMPCCX_NS, /* No sign. */ + _CMPCCX_NZ, /* Not zero. */ + _CMPCCX_O, /* Overflow. */ + _CMPCCX_P, /* Parity. */ + _CMPCCX_S, /* Sign. */ + _CMPCCX_Z, /* Zero. */ +} _CMPCCX_ENUM; + +/// Compares the value from the memory __A with the value of __B. If the +/// specified condition __D is met, then add the third operand __C to the +/// __A and write it into __A, else the value of __A is unchanged. The return +/// value is the original value of __A. +/// +/// \headerfile +/// +/// This intrinsic corresponds to the \c CMPCCXADD instructions. +/// +/// \param __A +/// __A pointer specifying the memory address. +/// +/// \param __B +/// A integer operand. +/// +/// \param __C +/// A integer operand. +/// +/// \param __D +/// The specified condition. +/// +/// \returns a integer which is the original value of first operand. + +#define __cmpccxadd_epi32(__A, __B, __C, __D) \ + ((int)(__builtin_ia32_cmpccxadd32((void *)(__A), (int)(__B), (int)(__C), \ + (int)(__D)))) + +#define __cmpccxadd_epi64(__A, __B, __C, __D) \ + ((long long)(__builtin_ia32_cmpccxadd64((void *)(__A), (long long)(__B), \ + (long long)(__C), (int)(__D)))) + +#endif // __x86_64__ +#endif // __CMPCCXADDINTRIN_H diff --git a/clang/lib/Headers/cpuid.h b/clang/lib/Headers/cpuid.h --- a/clang/lib/Headers/cpuid.h +++ b/clang/lib/Headers/cpuid.h @@ -202,6 +202,7 @@ /* Features in %eax for leaf 7 sub-leaf 1 */ #define bit_AVXVNNI 0x00000010 #define bit_AVX512BF16 0x00000020 +#define bit_CMPCCXADD 0x00000080 #define bit_HRESET 0x00400000 /* Features in %eax for leaf 13 sub-leaf 1 */ diff --git a/clang/lib/Headers/immintrin.h b/clang/lib/Headers/immintrin.h --- a/clang/lib/Headers/immintrin.h +++ b/clang/lib/Headers/immintrin.h @@ -508,6 +508,12 @@ defined(__INVPCID__) #include #endif +#if defined(__CMPCCXADD_SUPPORTED__) +#if !(defined(_MSC_VER) || defined(__SCE__)) || __has_feature(modules) || \ + defined(__CMPCCXADD__) || defined(__M_INTRINSIC_PROMOTE__) +#include +#endif +#endif #if !(defined(_MSC_VER) || defined(__SCE__)) || __has_feature(modules) || \ defined(__KL__) || defined(__WIDEKL__) diff --git a/clang/lib/Sema/SemaChecking.cpp b/clang/lib/Sema/SemaChecking.cpp --- a/clang/lib/Sema/SemaChecking.cpp +++ b/clang/lib/Sema/SemaChecking.cpp @@ -5410,6 +5410,10 @@ case X86::BI__builtin_ia32_reducesh_mask: i = 4; l = 0; u = 255; break; + case X86::BI__builtin_ia32_cmpccxadd32: + case X86::BI__builtin_ia32_cmpccxadd64: + i = 3; l = 0; u = 15; + break; } // Note that we don't force a hard error on the range check here, allowing diff --git a/clang/test/CodeGen/X86/cmpccxadd-builtins-error.c b/clang/test/CodeGen/X86/cmpccxadd-builtins-error.c new file mode 100644 --- /dev/null +++ b/clang/test/CodeGen/X86/cmpccxadd-builtins-error.c @@ -0,0 +1,12 @@ +// RUN: %clang_cc1 %s -ffreestanding -triple=x86_64-unknown-unknown \ +// RUN: -target-feature +cmpccxadd -emit-llvm -fsyntax-only -verify + +#include + +int test_cmpccxadd32(void *__A, int __B, int __C) { + return __cmpccxadd_epi32(__A, __B, __C, 16); // expected-error {{argument value 16 is outside the valid range [0, 15]}} +} + +long long test_cmpccxadd64(void *__A, long long __B, long long __C) { + return __cmpccxadd_epi64(__A, __B, __C, 16); // expected-error {{argument value 16 is outside the valid range [0, 15]}} +} diff --git a/clang/test/CodeGen/X86/cmpccxadd-builtins.c b/clang/test/CodeGen/X86/cmpccxadd-builtins.c new file mode 100644 --- /dev/null +++ b/clang/test/CodeGen/X86/cmpccxadd-builtins.c @@ -0,0 +1,197 @@ +// RUN: %clang_cc1 %s -ffreestanding -triple=x86_64-unknown-unknown -target-feature +cmpccxadd \ +// RUN: -emit-llvm -o - -Wall -Werror -pedantic -Wno-gnu-statement-expression | FileCheck %s + +#include +#include + +int test_cmpbexadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpbexadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 0) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_BE); +} + +long long test_cmpbexadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpbexadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 0) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_BE); +} + +int test_cmpbxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpbxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 1) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_B); +} + +long long test_cmpbxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpbxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 1) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_B); +} + +int test_cmplexadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmplexadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 2) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_LE); +} + +long long test_cmplexadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmplexadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 2) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_LE); +} + +int test_cmplxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmplxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 3) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_L); +} + +long long test_cmplxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmplxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 3) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_L); +} + +int test_cmpnbexadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnbexadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 4) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NBE); +} + +long long test_cmpnbexadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnbexadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 4) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NBE); +} + +int test_cmpnbxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnbxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 5) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NB); +} + +long long test_cmpnbxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnbxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 5) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NB); +} + +int test_cmpnlexadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnlexadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 6) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NLE); +} + +long long test_cmpnlexadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnlexadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 6) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NLE); +} + +int test_cmpnlxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnlxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 7) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NL); +} + +long long test_cmpnlxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnlxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 7) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NL); +} + +int test_cmpnoxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnoxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 8) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NO); +} + +long long test_cmpnoxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnoxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 8) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NO); +} + +int test_cmpnpxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnpxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 9) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NP); +} + +long long test_cmpnpxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnpxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 9) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NP); +} + +int test_cmpnsxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnsxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 10) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NS); +} + +long long test_cmpnsxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnsxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 10) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NS); +} + +int test_cmpnzxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpnzxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 11) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_NZ); +} + +long long test_cmpnzxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpnzxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 11) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_NZ); +} + +int test_cmpoxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpoxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 12) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_O); +} + +long long test_cmpoxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpoxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 12) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_O); +} + +int test_cmppxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmppxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 13) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_P); +} + +long long test_cmppxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmppxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 13) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_P); +} + +int test_cmpsxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpsxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 14) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_S); +} + +long long test_cmpsxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpsxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 14) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_S); +} + +int test_cmpzxadd32(void *__A, int __B, int __C) { + // CHECK-LABEL: @test_cmpzxadd32( + // CHECK: call i32 @llvm.x86.cmpccxadd32(ptr %{{.*}}, i32 %{{.*}}, i32 %{{.*}}, i32 15) + return __cmpccxadd_epi32(__A, __B, __C, _CMPCCX_Z); +} + +long long test_cmpzxadd64(void *__A, long long __B, long long __C) { + // CHECK-LABEL: @test_cmpzxadd64( + // CHECK: call i64 @llvm.x86.cmpccxadd64(ptr %{{.*}}, i64 %{{.*}}, i64 %{{.*}}, i32 15) + return __cmpccxadd_epi64(__A, __B, __C, _CMPCCX_Z); +} diff --git a/clang/test/CodeGen/attr-target-x86.c b/clang/test/CodeGen/attr-target-x86.c --- a/clang/test/CodeGen/attr-target-x86.c +++ b/clang/test/CodeGen/attr-target-x86.c @@ -54,9 +54,9 @@ // CHECK: #0 = {{.*}}"target-cpu"="i686" "target-features"="+cx8,+x87" "tune-cpu"="i686" // CHECK: #1 = {{.*}}"target-cpu"="ivybridge" "target-features"="+avx,+crc32,+cx16,+cx8,+f16c,+fsgsbase,+fxsr,+mmx,+pclmul,+popcnt,+rdrnd,+sahf,+sse,+sse2,+sse3,+sse4.1,+sse4.2,+ssse3,+x87,+xsave,+xsaveopt" // CHECK-NOT: tune-cpu -// CHECK: #2 = {{.*}}"target-cpu"="i686" "target-features"="+cx8,+x87,-aes,-avx,-avx2,-avx512bf16,-avx512bitalg,-avx512bw,-avx512cd,-avx512dq,-avx512er,-avx512f,-avx512fp16,-avx512ifma,-avx512pf,-avx512vbmi,-avx512vbmi2,-avx512vl,-avx512vnni,-avx512vp2intersect,-avx512vpopcntdq,-avxvnni,-f16c,-fma,-fma4,-gfni,-kl,-pclmul,-sha,-sse2,-sse3,-sse4.1,-sse4.2,-sse4a,-ssse3,-vaes,-vpclmulqdq,-widekl,-xop" "tune-cpu"="i686" +// CHECK: #2 = {{.*}}"target-cpu"="i686" "target-features"="+cx8,+x87,-aes,-avx,-avx2,-avx512bf16,-avx512bitalg,-avx512bw,-avx512cd,-avx512dq,-avx512er,-avx512f,-avx512fp16,-avx512ifma,-avx512pf,-avx512vbmi,-avx512vbmi2,-avx512vl,-avx512vnni,-avx512vp2intersect,-avx512vpopcntdq,-avxvnni,-cmpccxadd,-f16c,-fma,-fma4,-gfni,-kl,-pclmul,-sha,-sse2,-sse3,-sse4.1,-sse4.2,-sse4a,-ssse3,-vaes,-vpclmulqdq,-widekl,-xop" "tune-cpu"="i686" // CHECK: #3 = {{.*}}"target-cpu"="i686" "target-features"="+crc32,+cx8,+mmx,+popcnt,+sse,+sse2,+sse3,+sse4.1,+sse4.2,+ssse3,+x87" "tune-cpu"="i686" -// CHECK: #4 = {{.*}}"target-cpu"="i686" "target-features"="+cx8,+x87,-avx,-avx2,-avx512bf16,-avx512bitalg,-avx512bw,-avx512cd,-avx512dq,-avx512er,-avx512f,-avx512fp16,-avx512ifma,-avx512pf,-avx512vbmi,-avx512vbmi2,-avx512vl,-avx512vnni,-avx512vp2intersect,-avx512vpopcntdq,-avxvnni,-f16c,-fma,-fma4,-sse4.1,-sse4.2,-vaes,-vpclmulqdq,-xop" "tune-cpu"="i686" +// CHECK: #4 = {{.*}}"target-cpu"="i686" "target-features"="+cx8,+x87,-avx,-avx2,-avx512bf16,-avx512bitalg,-avx512bw,-avx512cd,-avx512dq,-avx512er,-avx512f,-avx512fp16,-avx512ifma,-avx512pf,-avx512vbmi,-avx512vbmi2,-avx512vl,-avx512vnni,-avx512vp2intersect,-avx512vpopcntdq,-avxvnni,-cmpccxadd,-f16c,-fma,-fma4,-sse4.1,-sse4.2,-vaes,-vpclmulqdq,-xop" "tune-cpu"="i686" // CHECK: #5 = {{.*}}"target-cpu"="ivybridge" "target-features"="+avx,+crc32,+cx16,+cx8,+f16c,+fsgsbase,+fxsr,+mmx,+pclmul,+popcnt,+rdrnd,+sahf,+sse,+sse2,+sse3,+sse4.1,+sse4.2,+ssse3,+x87,+xsave,+xsaveopt,-aes,-vaes" // CHECK-NOT: tune-cpu // CHECK: #6 = {{.*}}"target-cpu"="i686" "target-features"="+cx8,+x87,-3dnow,-3dnowa,-mmx" diff --git a/clang/test/Driver/x86-target-features.c b/clang/test/Driver/x86-target-features.c --- a/clang/test/Driver/x86-target-features.c +++ b/clang/test/Driver/x86-target-features.c @@ -305,6 +305,11 @@ // AVX512FP16: "-target-feature" "+avx512fp16" // NO-AVX512FP16: "-target-feature" "-avx512fp16" +// RUN: %clang -target i686-unknown-linux-gnu -mcmpccxadd %s -### -o %t.o 2>&1 | FileCheck -check-prefix=CMPCCXADD %s +// RUN: %clang -target i686-unknown-linux-gnu -mno-cmpccxadd %s -### -o %t.o 2>&1 | FileCheck -check-prefix=NO-CMPCCXADD %s +// CMPCCXADD: "-target-feature" "+cmpccxadd" +// NO-CMPCCXADD: "-target-feature" "-cmpccxadd" + // RUN: %clang --target=i386 -march=i386 -mcrc32 %s -### 2>&1 | FileCheck -check-prefix=CRC32 %s // RUN: %clang --target=i386 -march=i386 -mno-crc32 %s -### 2>&1 | FileCheck -check-prefix=NO-CRC32 %s // CRC32: "-target-feature" "+crc32" diff --git a/clang/test/Preprocessor/x86_target_features.c b/clang/test/Preprocessor/x86_target_features.c --- a/clang/test/Preprocessor/x86_target_features.c +++ b/clang/test/Preprocessor/x86_target_features.c @@ -581,6 +581,15 @@ // AVX512FP16NOAVX512DQ-NOT: #define __AVX512DQ__ 1 // AVX512FP16NOAVX512DQ-NOT: #define __AVX512FP16__ 1 +// RUN: %clang -target x86_64-unknown-linux-gnu -march=atom -mcmpccxadd -x c -E -dM -o - %s | FileCheck -check-prefix=CMPCCXADD %s + +// CMPCCXADD: #define __CMPCCXADD__ 1 + +// RUN: %clang -target x86_64-unknown-linux-gnu -march=atom -mno-cmpccxadd -x c -E -dM -o - %s | FileCheck -check-prefix=NO-CMPCCXADD %s +// RUN: %clang -target x86_64-unknown-linux-gnu -march=atom -mcmpccxadd -mno-avx2 -x c -E -dM -o - %s | FileCheck -check-prefix=NO-CMPCCXADD %s + +// NO-CMPCCXADD-NOT: #define __CMPCCXADD__ 1 + // RUN: %clang -target i386-unknown-linux-gnu -march=i386 -mcrc32 -x c -E -dM -o - %s | FileCheck -check-prefix=CRC32 %s // CRC32: #define __CRC32__ 1 diff --git a/llvm/CMakeLists.txt b/llvm/CMakeLists.txt --- a/llvm/CMakeLists.txt +++ b/llvm/CMakeLists.txt @@ -883,6 +883,8 @@ include(HandleLLVMOptions) ###### + list(APPEND features_enabled_by_default + ${LLVM_INTELFEATURE_PREFIX}_ISA_CMPCCXADD) # Configure all of the various header file fragments LLVM uses which depend on # configuration variables. diff --git a/llvm/docs/ReleaseNotes.rst b/llvm/docs/ReleaseNotes.rst --- a/llvm/docs/ReleaseNotes.rst +++ b/llvm/docs/ReleaseNotes.rst @@ -131,6 +131,8 @@ Changes to the X86 Backend -------------------------- +* Support ISA of ``CMPCCXADD``. + Changes to the OCaml bindings ----------------------------- diff --git a/llvm/include/llvm/IR/IntrinsicsX86.td b/llvm/include/llvm/IR/IntrinsicsX86.td --- a/llvm/include/llvm/IR/IntrinsicsX86.td +++ b/llvm/include/llvm/IR/IntrinsicsX86.td @@ -5115,6 +5115,19 @@ Intrinsic<[llvm_anyvector_ty], [llvm_x86amx_ty], [IntrNoMem]>; } +let TargetPrefix = "x86" in { +def int_x86_cmpccxadd32 + : ClangBuiltin<"__builtin_ia32_cmpccxadd32">, + Intrinsic<[llvm_i32_ty], + [llvm_ptr_ty, llvm_i32_ty, llvm_i32_ty, llvm_i32_ty], + [IntrArgMemOnly, ImmArg>]>; + +def int_x86_cmpccxadd64 + : ClangBuiltin<"__builtin_ia32_cmpccxadd64">, + Intrinsic<[llvm_i64_ty], + [llvm_ptr_ty, llvm_i64_ty, llvm_i64_ty, llvm_i32_ty], + [IntrArgMemOnly, ImmArg>]>; +} //===----------------------------------------------------------------------===// // UINTR - User Level Interrupt diff --git a/llvm/include/llvm/Support/X86TargetParser.def b/llvm/include/llvm/Support/X86TargetParser.def --- a/llvm/include/llvm/Support/X86TargetParser.def +++ b/llvm/include/llvm/Support/X86TargetParser.def @@ -201,6 +201,7 @@ X86_FEATURE (XSAVES, "xsaves") X86_FEATURE (HRESET, "hreset") X86_FEATURE (AVX512FP16, "avx512fp16") +X86_FEATURE (CMPCCXADD, "cmpccxadd") X86_FEATURE (AVXVNNI, "avxvnni") // These features aren't really CPU features, but the frontend can set them. X86_FEATURE (RETPOLINE_EXTERNAL_THUNK, "retpoline-external-thunk") diff --git a/llvm/lib/Support/Host.cpp b/llvm/lib/Support/Host.cpp --- a/llvm/lib/Support/Host.cpp +++ b/llvm/lib/Support/Host.cpp @@ -1807,6 +1807,7 @@ MaxLevel >= 7 && !getX86CpuIDAndInfoEx(0x7, 0x1, &EAX, &EBX, &ECX, &EDX); Features["avxvnni"] = HasLeaf7Subleaf1 && ((EAX >> 4) & 1) && HasAVXSave; Features["avx512bf16"] = HasLeaf7Subleaf1 && ((EAX >> 5) & 1) && HasAVX512Save; + Features["cmpccxadd"] = HasLeaf7Subleaf1 && ((EAX >> 7) & 1); Features["hreset"] = HasLeaf7Subleaf1 && ((EAX >> 22) & 1); bool HasLeafD = MaxLevel >= 0xd && diff --git a/llvm/lib/Support/X86TargetParser.cpp b/llvm/lib/Support/X86TargetParser.cpp --- a/llvm/lib/Support/X86TargetParser.cpp +++ b/llvm/lib/Support/X86TargetParser.cpp @@ -581,6 +581,7 @@ constexpr FeatureBitset ImpliedFeaturesAMX_INT8 = FeatureAMX_TILE; constexpr FeatureBitset ImpliedFeaturesHRESET = {}; +static constexpr FeatureBitset ImpliedFeaturesCMPCCXADD = FeatureAVX2; static constexpr FeatureBitset ImpliedFeaturesAVX512FP16 = FeatureAVX512BW | FeatureAVX512DQ | FeatureAVX512VL; // Key Locker Features diff --git a/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h b/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h --- a/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h +++ b/llvm/lib/Target/X86/MCTargetDesc/X86BaseInfo.h @@ -630,6 +630,12 @@ /// byte like data16 or rep. PrefixByte = 10, + /// MRMDestMem4VOp3 - This form is used for instructions that use the Mod/RM + /// byte to specify a destination which in this case is memory and operand 3 + /// with VEX.VVVV. + /// + MRMDestMem4VOp3 = 18, + /// MRM[0-7][rm] - These forms are used to represent instructions that use /// a Mod/RM byte, and use the middle field to hold extended opcode /// information. In the intel manual these are represented as /0, /1, ... @@ -1112,6 +1118,7 @@ return -1; case X86II::MRMDestMem: case X86II::MRMDestMemFSIB: + case X86II::MRMDestMem4VOp3: return 0; case X86II::MRMSrcMem: case X86II::MRMSrcMemFSIB: diff --git a/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp b/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp --- a/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp +++ b/llvm/lib/Target/X86/MCTargetDesc/X86MCCodeEmitter.cpp @@ -801,6 +801,25 @@ switch (TSFlags & X86II::FormMask) { default: llvm_unreachable("Unexpected form in emitVEXOpcodePrefix!"); + case X86II::MRMDestMem4VOp3: { + // MemAddr, src1(ModR/M), src2(VEX_4V) + unsigned BaseRegEnc = getX86RegEncoding(MI, MemOperand + X86::AddrBaseReg); + VEX_B = ~(BaseRegEnc >> 3) & 1; + unsigned IndexRegEnc = + getX86RegEncoding(MI, MemOperand + X86::AddrIndexReg); + VEX_X = ~(IndexRegEnc >> 3) & 1; + + CurOp += X86::AddrNumOperands; + + unsigned RegEnc = getX86RegEncoding(MI, CurOp++); + VEX_R = ~(RegEnc >> 3) & 1; + EVEX_R2 = ~(RegEnc >> 4) & 1; + + unsigned VRegEnc = getX86RegEncoding(MI, CurOp++); + VEX_4V = ~VRegEnc & 0xf; + EVEX_V2 = ~(VRegEnc >> 4) & 1; + break; + } case X86II::MRM_C0: case X86II::RawFrm: case X86II::PrefixByte: @@ -1429,6 +1448,14 @@ CurOp = SrcRegNum + 1; break; } + case X86II::MRMDestMem4VOp3: { + emitByte(BaseOpcode, OS); + unsigned SrcRegNum = CurOp + X86::AddrNumOperands; + emitMemModRMByte(MI, CurOp, getX86RegNum(MI.getOperand(SrcRegNum)), TSFlags, + HasREX, StartByte, OS, Fixups, STI, false); + CurOp = SrcRegNum + 2; // skip VEX_V4 + break; + } case X86II::MRMDestMemFSIB: case X86II::MRMDestMem: { emitByte(BaseOpcode, OS); diff --git a/llvm/lib/Target/X86/X86.td b/llvm/lib/Target/X86/X86.td --- a/llvm/lib/Target/X86/X86.td +++ b/llvm/lib/Target/X86/X86.td @@ -254,6 +254,9 @@ def FeatureAMXBF16 : SubtargetFeature<"amx-bf16", "HasAMXBF16", "true", "Support AMX-BF16 instructions", [FeatureAMXTILE]>; +def FeatureCMPCCXADD : SubtargetFeature<"cmpccxadd", "HasCMPCCXADD", "true", + "Support CMPCCXADD instructions", + [FeatureAVX2]>; def FeatureINVPCID : SubtargetFeature<"invpcid", "HasINVPCID", "true", "Invalidate Process-Context Identifier">; def FeatureSGX : SubtargetFeature<"sgx", "HasSGX", "true", diff --git a/llvm/lib/Target/X86/X86InstrFormats.td b/llvm/lib/Target/X86/X86InstrFormats.td --- a/llvm/lib/Target/X86/X86InstrFormats.td +++ b/llvm/lib/Target/X86/X86InstrFormats.td @@ -28,6 +28,7 @@ def RawFrmImm16 : Format<8>; def AddCCFrm : Format<9>; def PrefixByte : Format<10>; +def MRMDestMem4VOp3 : Format<18>; def MRMr0 : Format<21>; def MRMSrcMemFSIB : Format<22>; def MRMDestMemFSIB : Format<23>; diff --git a/llvm/lib/Target/X86/X86InstrInfo.td b/llvm/lib/Target/X86/X86InstrInfo.td --- a/llvm/lib/Target/X86/X86InstrInfo.td +++ b/llvm/lib/Target/X86/X86InstrInfo.td @@ -979,6 +979,7 @@ def HasCX16 : Predicate<"Subtarget->hasCX16()">; def HasPCONFIG : Predicate<"Subtarget->hasPCONFIG()">; def HasENQCMD : Predicate<"Subtarget->hasENQCMD()">; +def HasCMPCCXADD : Predicate<"Subtarget->hasCMPCCXADD()">; def HasKL : Predicate<"Subtarget->hasKL()">; def HasWIDEKL : Predicate<"Subtarget->hasWIDEKL()">; def HasHRESET : Predicate<"Subtarget->hasHRESET()">; diff --git a/llvm/lib/Target/X86/X86InstrSSE.td b/llvm/lib/Target/X86/X86InstrSSE.td --- a/llvm/lib/Target/X86/X86InstrSSE.td +++ b/llvm/lib/Target/X86/X86InstrSSE.td @@ -8115,3 +8115,101 @@ X86GF2P8affineqb>, TAPD; } +let Predicates = [HasCMPCCXADD, In64BitMode], Constraints = "$dstsrc2 = $dst" in +multiclass CMPCCXADD_BASE Opc, string OpcodeStr> { +def mr32 : I, VEX_4V, T8PD, Sched<[WriteXCHG]>; + +def mr64 : I, VEX_4V, VEX_W, T8PD, Sched<[WriteXCHG]>; +} + +defm CMPBEXADD : CMPCCXADD_BASE<0xe6, "cmpbexadd">; +defm CMPBXADD : CMPCCXADD_BASE<0xe2, "cmpbxadd">; +defm CMPLEXADD : CMPCCXADD_BASE<0xee, "cmplexadd">; +defm CMPLXADD : CMPCCXADD_BASE<0xec, "cmplxadd">; +defm CMPNBEXADD : CMPCCXADD_BASE<0xe7, "cmpnbexadd">; +defm CMPNBXADD : CMPCCXADD_BASE<0xe3, "cmpnbxadd">; +defm CMPNLEXADD : CMPCCXADD_BASE<0xef, "cmpnlexadd">; +defm CMPNLXADD : CMPCCXADD_BASE<0xed, "cmpnlxadd">; +defm CMPNOXADD : CMPCCXADD_BASE<0xe1, "cmpnoxadd">; +defm CMPNPXADD : CMPCCXADD_BASE<0xeb, "cmpnpxadd">; +defm CMPNSXADD : CMPCCXADD_BASE<0xe9, "cmpnsxadd">; +defm CMPNZXADD : CMPCCXADD_BASE<0xe5, "cmpnzxadd">; +defm CMPOXADD : CMPCCXADD_BASE<0xe0, "cmpoxadd">; +defm CMPPXADD : CMPCCXADD_BASE<0xea, "cmppxadd">; +defm CMPSXADD : CMPCCXADD_BASE<0xe8, "cmpsxadd">; +defm CMPZXADD : CMPCCXADD_BASE<0xe4, "cmpzxadd">; + + +let Predicates = [HasCMPCCXADD, In64BitMode] in { +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 0))), + (CMPBEXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 0))), + (CMPBEXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 1))), + (CMPBXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 1))), + (CMPBXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 2))), + (CMPLEXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 2))), + (CMPLEXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 3))), + (CMPLXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 3))), + (CMPLXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 4))), + (CMPNBEXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 4))), + (CMPNBEXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 5))), + (CMPNBXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 5))), + (CMPNBXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 6))), + (CMPNLEXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 6))), + (CMPNLEXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 7))), + (CMPNLXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 7))), + (CMPNLXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 8))), + (CMPNOXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 8))), + (CMPNOXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 9))), + (CMPNPXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 9))), + (CMPNPXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 10))), + (CMPNSXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 10))), + (CMPNSXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 11))), + (CMPNZXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 11))), + (CMPNZXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 12))), + (CMPOXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 12))), + (CMPOXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 13))), + (CMPPXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 13))), + (CMPPXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 14))), + (CMPSXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 14))), + (CMPSXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +def : Pat<(i32 (int_x86_cmpccxadd32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3, (i32 15))), + (CMPZXADDmr32 addr:$dstsrc1, GR32:$dstsrc2, GR32:$src3)>; +def : Pat<(i64 (int_x86_cmpccxadd64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3, (i32 15))), + (CMPZXADDmr64 addr:$dstsrc1, GR64:$dstsrc2, GR64:$src3)>; +} + diff --git a/llvm/test/CodeGen/X86/cmpccxadd-intrinsics.ll b/llvm/test/CodeGen/X86/cmpccxadd-intrinsics.ll new file mode 100644 --- /dev/null +++ b/llvm/test/CodeGen/X86/cmpccxadd-intrinsics.ll @@ -0,0 +1,358 @@ +; NOTE: Assertions have been autogenerated by utils/update_llc_test_checks.py +; RUN: llc < %s -verify-machineinstrs -mtriple=x86_64-unknown-unknown --show-mc-encoding -mattr=+cmpccxadd | FileCheck %s + +define dso_local i32 @test_cmpbexadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpbexadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpbexadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe6,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 0) + ret i32 %0 +} + +declare i32 @llvm.x86.cmpccxadd32(i8*, i32, i32, i32 immarg) + +define dso_local i64 @test_cmpbexadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpbexadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpbexadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe6,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 0) + ret i64 %0 +} + +declare i64 @llvm.x86.cmpccxadd64(i8*, i64, i64, i32 immarg) + +define dso_local i32 @test_cmpbxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpbxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpbxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe2,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 1) + ret i32 %0 +} + +define dso_local i64 @test_cmpbxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpbxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpbxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe2,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 1) + ret i64 %0 +} + +define dso_local i32 @test_cmplexadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmplexadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmplexadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xee,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 2) + ret i32 %0 +} + +define dso_local i64 @test_cmplexadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmplexadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmplexadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xee,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 2) + ret i64 %0 +} + +define dso_local i32 @test_cmplxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmplxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmplxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xec,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 3) + ret i32 %0 +} + +define dso_local i64 @test_cmplxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmplxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmplxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xec,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 3) + ret i64 %0 +} + +define dso_local i32 @test_cmpnbexadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnbexadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnbexadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe7,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 4) + ret i32 %0 +} + +define dso_local i64 @test_cmpnbexadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnbexadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnbexadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe7,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 4) + ret i64 %0 +} + +define dso_local i32 @test_cmpnbxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnbxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnbxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe3,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 5) + ret i32 %0 +} + +define dso_local i64 @test_cmpnbxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnbxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnbxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe3,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 5) + ret i64 %0 +} + +define dso_local i32 @test_cmpnlexadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnlexadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnlexadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xef,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 6) + ret i32 %0 +} + +define dso_local i64 @test_cmpnlexadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnlexadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnlexadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xef,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 6) + ret i64 %0 +} + +define dso_local i32 @test_cmpnlxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnlxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnlxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xed,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 7) + ret i32 %0 +} + +define dso_local i64 @test_cmpnlxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnlxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnlxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xed,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 7) + ret i64 %0 +} + +define dso_local i32 @test_cmpnoxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnoxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnoxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe1,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 8) + ret i32 %0 +} + +define dso_local i64 @test_cmpnoxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnoxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnoxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe1,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 8) + ret i64 %0 +} + +define dso_local i32 @test_cmpnpxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnpxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnpxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xeb,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 9) + ret i32 %0 +} + +define dso_local i64 @test_cmpnpxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnpxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnpxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xeb,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 9) + ret i64 %0 +} + +define dso_local i32 @test_cmpnsxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnsxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnsxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe9,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 10) + ret i32 %0 +} + +define dso_local i64 @test_cmpnsxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnsxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnsxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe9,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 10) + ret i64 %0 +} + +define dso_local i32 @test_cmpnzxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpnzxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpnzxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe5,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 11) + ret i32 %0 +} + +define dso_local i64 @test_cmpnzxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpnzxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpnzxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe5,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 11) + ret i64 %0 +} + +define dso_local i32 @test_cmpoxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpoxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpoxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe0,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 12) + ret i32 %0 +} + +define dso_local i64 @test_cmpoxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpoxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpoxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe0,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 12) + ret i64 %0 +} + +define dso_local i32 @test_cmppxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmppxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmppxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xea,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 13) + ret i32 %0 +} + +define dso_local i64 @test_cmppxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmppxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmppxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xea,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 13) + ret i64 %0 +} + +define dso_local i32 @test_cmpsxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpsxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpsxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe8,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 14) + ret i32 %0 +} + +define dso_local i64 @test_cmpsxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpsxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpsxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe8,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 14) + ret i64 %0 +} + +define dso_local i32 @test_cmpzxadd32(i8* %__A, i32 %__B, i32 %__C) nounwind { +; CHECK-LABEL: test_cmpzxadd32: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movl %esi, %eax # encoding: [0x89,0xf0] +; CHECK-NEXT: cmpzxadd %edx, %eax, (%rdi) # encoding: [0xc4,0xe2,0x69,0xe4,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i32 @llvm.x86.cmpccxadd32(i8* %__A, i32 %__B, i32 %__C, i32 15) + ret i32 %0 +} + +define dso_local i64 @test_cmpzxadd64(i8* %__A, i64 %__B, i64 %__C) nounwind { +; CHECK-LABEL: test_cmpzxadd64: +; CHECK: # %bb.0: # %entry +; CHECK-NEXT: movq %rsi, %rax # encoding: [0x48,0x89,0xf0] +; CHECK-NEXT: cmpzxadd %rdx, %rax, (%rdi) # encoding: [0xc4,0xe2,0xe9,0xe4,0x07] +; CHECK-NEXT: retq # encoding: [0xc3] +entry: + %0 = tail call i64 @llvm.x86.cmpccxadd64(i8* %__A, i64 %__B, i64 %__C, i32 15) + ret i64 %0 +} diff --git a/llvm/test/MC/Disassembler/X86/x86-64-cmpccxadd.txt b/llvm/test/MC/Disassembler/X86/x86-64-cmpccxadd.txt new file mode 100644 --- /dev/null +++ b/llvm/test/MC/Disassembler/X86/x86-64-cmpccxadd.txt @@ -0,0 +1,773 @@ +# RUN: llvm-mc --disassemble %s -triple=x86_64 | FileCheck %s --check-prefixes=ATT +# RUN: llvm-mc --disassemble %s -triple=x86_64 -x86-asm-syntax=intel --output-asm-variant=1 | FileCheck %s --check-prefixes=INTEL + +# isadb version: a01616c03d3a51125c82c4869c7349eef74c79ed + +# ATT: cmpbexadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpbexadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe6,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpbexadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpbexadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe6,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpbexadd %eax, %ecx, (%rip) +# INTEL: cmpbexadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe6,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpbexadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpbexadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe6,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpbexadd %eax, %ecx, 508(%rcx) +# INTEL: cmpbexadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe6,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpbexadd %eax, %ecx, -512(%rdx) +# INTEL: cmpbexadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe6,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpbexadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpbexadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe6,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpbexadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpbexadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe6,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpbexadd %r10, %r9, (%rip) +# INTEL: cmpbexadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe6,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpbexadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpbexadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe6,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpbexadd %r10, %r9, 1016(%rcx) +# INTEL: cmpbexadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe6,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpbexadd %r10, %r9, -1024(%rdx) +# INTEL: cmpbexadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe6,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpbxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpbxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe2,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpbxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpbxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe2,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpbxadd %eax, %ecx, (%rip) +# INTEL: cmpbxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe2,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpbxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpbxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe2,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpbxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpbxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe2,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpbxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpbxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe2,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpbxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpbxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe2,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpbxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpbxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe2,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpbxadd %r10, %r9, (%rip) +# INTEL: cmpbxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe2,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpbxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpbxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe2,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpbxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpbxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe2,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpbxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpbxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe2,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmplexadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmplexadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xee,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmplexadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmplexadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xee,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmplexadd %eax, %ecx, (%rip) +# INTEL: cmplexadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xee,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmplexadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmplexadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xee,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmplexadd %eax, %ecx, 508(%rcx) +# INTEL: cmplexadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xee,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmplexadd %eax, %ecx, -512(%rdx) +# INTEL: cmplexadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xee,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmplexadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmplexadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xee,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmplexadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmplexadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xee,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmplexadd %r10, %r9, (%rip) +# INTEL: cmplexadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xee,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmplexadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmplexadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xee,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmplexadd %r10, %r9, 1016(%rcx) +# INTEL: cmplexadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xee,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmplexadd %r10, %r9, -1024(%rdx) +# INTEL: cmplexadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xee,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmplxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmplxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xec,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmplxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmplxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xec,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmplxadd %eax, %ecx, (%rip) +# INTEL: cmplxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xec,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmplxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmplxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xec,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmplxadd %eax, %ecx, 508(%rcx) +# INTEL: cmplxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xec,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmplxadd %eax, %ecx, -512(%rdx) +# INTEL: cmplxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xec,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmplxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmplxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xec,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmplxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmplxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xec,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmplxadd %r10, %r9, (%rip) +# INTEL: cmplxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xec,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmplxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmplxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xec,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmplxadd %r10, %r9, 1016(%rcx) +# INTEL: cmplxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xec,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmplxadd %r10, %r9, -1024(%rdx) +# INTEL: cmplxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xec,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnbexadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnbexadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe7,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnbexadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnbexadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe7,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnbexadd %eax, %ecx, (%rip) +# INTEL: cmpnbexadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe7,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnbexadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnbexadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe7,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnbexadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnbexadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe7,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnbexadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnbexadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe7,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnbexadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnbexadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe7,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnbexadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnbexadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe7,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnbexadd %r10, %r9, (%rip) +# INTEL: cmpnbexadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe7,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnbexadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnbexadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe7,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnbexadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnbexadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe7,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnbexadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnbexadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe7,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnbxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnbxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe3,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnbxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnbxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe3,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnbxadd %eax, %ecx, (%rip) +# INTEL: cmpnbxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe3,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnbxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnbxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe3,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnbxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnbxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe3,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnbxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnbxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe3,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnbxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnbxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe3,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnbxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnbxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe3,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnbxadd %r10, %r9, (%rip) +# INTEL: cmpnbxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe3,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnbxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnbxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe3,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnbxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnbxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe3,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnbxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnbxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe3,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnlexadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnlexadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xef,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnlexadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnlexadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xef,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnlexadd %eax, %ecx, (%rip) +# INTEL: cmpnlexadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xef,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnlexadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnlexadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xef,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnlexadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnlexadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xef,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnlexadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnlexadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xef,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnlexadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnlexadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xef,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnlexadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnlexadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xef,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnlexadd %r10, %r9, (%rip) +# INTEL: cmpnlexadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xef,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnlexadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnlexadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xef,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnlexadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnlexadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xef,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnlexadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnlexadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xef,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnlxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnlxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xed,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnlxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnlxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xed,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnlxadd %eax, %ecx, (%rip) +# INTEL: cmpnlxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xed,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnlxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnlxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xed,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnlxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnlxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xed,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnlxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnlxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xed,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnlxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnlxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xed,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnlxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnlxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xed,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnlxadd %r10, %r9, (%rip) +# INTEL: cmpnlxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xed,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnlxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnlxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xed,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnlxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnlxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xed,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnlxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnlxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xed,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnoxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnoxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe1,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnoxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnoxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe1,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnoxadd %eax, %ecx, (%rip) +# INTEL: cmpnoxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe1,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnoxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnoxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe1,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnoxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnoxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe1,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnoxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnoxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe1,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnoxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnoxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe1,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnoxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnoxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe1,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnoxadd %r10, %r9, (%rip) +# INTEL: cmpnoxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe1,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnoxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnoxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe1,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnoxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnoxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe1,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnoxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnoxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe1,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnpxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnpxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xeb,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnpxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnpxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xeb,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnpxadd %eax, %ecx, (%rip) +# INTEL: cmpnpxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xeb,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnpxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnpxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xeb,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnpxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnpxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xeb,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnpxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnpxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xeb,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnpxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnpxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xeb,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnpxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnpxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xeb,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnpxadd %r10, %r9, (%rip) +# INTEL: cmpnpxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xeb,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnpxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnpxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xeb,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnpxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnpxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xeb,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnpxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnpxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xeb,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnsxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnsxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe9,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnsxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnsxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe9,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnsxadd %eax, %ecx, (%rip) +# INTEL: cmpnsxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe9,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnsxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnsxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe9,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnsxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnsxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe9,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnsxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnsxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe9,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnsxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnsxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe9,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnsxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnsxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe9,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnsxadd %r10, %r9, (%rip) +# INTEL: cmpnsxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe9,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnsxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnsxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe9,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnsxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnsxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe9,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnsxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnsxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe9,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpnzxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpnzxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe5,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnzxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpnzxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe5,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnzxadd %eax, %ecx, (%rip) +# INTEL: cmpnzxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe5,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnzxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpnzxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe5,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpnzxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpnzxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe5,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpnzxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpnzxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe5,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpnzxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpnzxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe5,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpnzxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpnzxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe5,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpnzxadd %r10, %r9, (%rip) +# INTEL: cmpnzxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe5,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpnzxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpnzxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe5,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpnzxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpnzxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe5,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpnzxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpnzxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe5,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpoxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpoxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe0,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpoxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpoxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe0,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpoxadd %eax, %ecx, (%rip) +# INTEL: cmpoxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe0,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpoxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpoxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe0,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpoxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpoxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe0,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpoxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpoxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe0,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpoxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpoxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe0,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpoxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpoxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe0,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpoxadd %r10, %r9, (%rip) +# INTEL: cmpoxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe0,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpoxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpoxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe0,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpoxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpoxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe0,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpoxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpoxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe0,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmppxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmppxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xea,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmppxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmppxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xea,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmppxadd %eax, %ecx, (%rip) +# INTEL: cmppxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xea,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmppxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmppxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xea,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmppxadd %eax, %ecx, 508(%rcx) +# INTEL: cmppxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xea,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmppxadd %eax, %ecx, -512(%rdx) +# INTEL: cmppxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xea,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmppxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmppxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xea,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmppxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmppxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xea,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmppxadd %r10, %r9, (%rip) +# INTEL: cmppxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xea,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmppxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmppxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xea,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmppxadd %r10, %r9, 1016(%rcx) +# INTEL: cmppxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xea,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmppxadd %r10, %r9, -1024(%rdx) +# INTEL: cmppxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xea,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpsxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpsxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe8,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpsxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpsxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe8,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpsxadd %eax, %ecx, (%rip) +# INTEL: cmpsxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe8,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpsxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpsxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe8,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpsxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpsxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe8,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpsxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpsxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe8,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpsxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpsxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe8,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpsxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpsxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe8,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpsxadd %r10, %r9, (%rip) +# INTEL: cmpsxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe8,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpsxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpsxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe8,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpsxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpsxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe8,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpsxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpsxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe8,0x8a,0x00,0xfc,0xff,0xff + +# ATT: cmpzxadd %eax, %ecx, 268435456(%rbp,%r14,8) +# INTEL: cmpzxadd dword ptr [rbp + 8*r14 + 268435456], ecx, eax +0xc4,0xa2,0x79,0xe4,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpzxadd %eax, %ecx, 291(%r8,%rax,4) +# INTEL: cmpzxadd dword ptr [r8 + 4*rax + 291], ecx, eax +0xc4,0xc2,0x79,0xe4,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpzxadd %eax, %ecx, (%rip) +# INTEL: cmpzxadd dword ptr [rip], ecx, eax +0xc4,0xe2,0x79,0xe4,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpzxadd %eax, %ecx, -128(,%rbp,2) +# INTEL: cmpzxadd dword ptr [2*rbp - 128], ecx, eax +0xc4,0xe2,0x79,0xe4,0x0c,0x6d,0x80,0xff,0xff,0xff + +# ATT: cmpzxadd %eax, %ecx, 508(%rcx) +# INTEL: cmpzxadd dword ptr [rcx + 508], ecx, eax +0xc4,0xe2,0x79,0xe4,0x89,0xfc,0x01,0x00,0x00 + +# ATT: cmpzxadd %eax, %ecx, -512(%rdx) +# INTEL: cmpzxadd dword ptr [rdx - 512], ecx, eax +0xc4,0xe2,0x79,0xe4,0x8a,0x00,0xfe,0xff,0xff + +# ATT: cmpzxadd %r10, %r9, 268435456(%rbp,%r14,8) +# INTEL: cmpzxadd qword ptr [rbp + 8*r14 + 268435456], r9, r10 +0xc4,0x22,0xa9,0xe4,0x8c,0xf5,0x00,0x00,0x00,0x10 + +# ATT: cmpzxadd %r10, %r9, 291(%r8,%rax,4) +# INTEL: cmpzxadd qword ptr [r8 + 4*rax + 291], r9, r10 +0xc4,0x42,0xa9,0xe4,0x8c,0x80,0x23,0x01,0x00,0x00 + +# ATT: cmpzxadd %r10, %r9, (%rip) +# INTEL: cmpzxadd qword ptr [rip], r9, r10 +0xc4,0x62,0xa9,0xe4,0x0d,0x00,0x00,0x00,0x00 + +# ATT: cmpzxadd %r10, %r9, -256(,%rbp,2) +# INTEL: cmpzxadd qword ptr [2*rbp - 256], r9, r10 +0xc4,0x62,0xa9,0xe4,0x0c,0x6d,0x00,0xff,0xff,0xff + +# ATT: cmpzxadd %r10, %r9, 1016(%rcx) +# INTEL: cmpzxadd qword ptr [rcx + 1016], r9, r10 +0xc4,0x62,0xa9,0xe4,0x89,0xf8,0x03,0x00,0x00 + +# ATT: cmpzxadd %r10, %r9, -1024(%rdx) +# INTEL: cmpzxadd qword ptr [rdx - 1024], r9, r10 +0xc4,0x62,0xa9,0xe4,0x8a,0x00,0xfc,0xff,0xff + diff --git a/llvm/test/MC/X86/x86-64-cmpccxadd-att.s b/llvm/test/MC/X86/x86-64-cmpccxadd-att.s new file mode 100644 --- /dev/null +++ b/llvm/test/MC/X86/x86-64-cmpccxadd-att.s @@ -0,0 +1,770 @@ +// RUN: llvm-mc -triple x86_64 --show-encoding %s | FileCheck %s + +// CHECK: cmpbexadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe6,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpbexadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpbexadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe6,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpbexadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpbexadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe6,0x0d,0x00,0x00,0x00,0x00] + cmpbexadd %eax, %ecx, (%rip) + +// CHECK: cmpbexadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe6,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpbexadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpbexadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe6,0x89,0xfc,0x01,0x00,0x00] + cmpbexadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpbexadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe6,0x8a,0x00,0xfe,0xff,0xff] + cmpbexadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpbexadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe6,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpbexadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpbexadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe6,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpbexadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpbexadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe6,0x0d,0x00,0x00,0x00,0x00] + cmpbexadd %r10, %r9, (%rip) + +// CHECK: cmpbexadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe6,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpbexadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpbexadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe6,0x89,0xf8,0x03,0x00,0x00] + cmpbexadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpbexadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe6,0x8a,0x00,0xfc,0xff,0xff] + cmpbexadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpbxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe2,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpbxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpbxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe2,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpbxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpbxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe2,0x0d,0x00,0x00,0x00,0x00] + cmpbxadd %eax, %ecx, (%rip) + +// CHECK: cmpbxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe2,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpbxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpbxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe2,0x89,0xfc,0x01,0x00,0x00] + cmpbxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpbxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe2,0x8a,0x00,0xfe,0xff,0xff] + cmpbxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpbxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe2,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpbxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpbxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe2,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpbxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpbxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe2,0x0d,0x00,0x00,0x00,0x00] + cmpbxadd %r10, %r9, (%rip) + +// CHECK: cmpbxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe2,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpbxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpbxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe2,0x89,0xf8,0x03,0x00,0x00] + cmpbxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpbxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe2,0x8a,0x00,0xfc,0xff,0xff] + cmpbxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmplexadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xee,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmplexadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmplexadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xee,0x8c,0x80,0x23,0x01,0x00,0x00] + cmplexadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmplexadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xee,0x0d,0x00,0x00,0x00,0x00] + cmplexadd %eax, %ecx, (%rip) + +// CHECK: cmplexadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xee,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmplexadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmplexadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xee,0x89,0xfc,0x01,0x00,0x00] + cmplexadd %eax, %ecx, 508(%rcx) + +// CHECK: cmplexadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xee,0x8a,0x00,0xfe,0xff,0xff] + cmplexadd %eax, %ecx, -512(%rdx) + +// CHECK: cmplexadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xee,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmplexadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmplexadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xee,0x8c,0x80,0x23,0x01,0x00,0x00] + cmplexadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmplexadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xee,0x0d,0x00,0x00,0x00,0x00] + cmplexadd %r10, %r9, (%rip) + +// CHECK: cmplexadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xee,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmplexadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmplexadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xee,0x89,0xf8,0x03,0x00,0x00] + cmplexadd %r10, %r9, 1016(%rcx) + +// CHECK: cmplexadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xee,0x8a,0x00,0xfc,0xff,0xff] + cmplexadd %r10, %r9, -1024(%rdx) + +// CHECK: cmplxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xec,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmplxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmplxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xec,0x8c,0x80,0x23,0x01,0x00,0x00] + cmplxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmplxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xec,0x0d,0x00,0x00,0x00,0x00] + cmplxadd %eax, %ecx, (%rip) + +// CHECK: cmplxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xec,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmplxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmplxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xec,0x89,0xfc,0x01,0x00,0x00] + cmplxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmplxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xec,0x8a,0x00,0xfe,0xff,0xff] + cmplxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmplxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xec,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmplxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmplxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xec,0x8c,0x80,0x23,0x01,0x00,0x00] + cmplxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmplxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xec,0x0d,0x00,0x00,0x00,0x00] + cmplxadd %r10, %r9, (%rip) + +// CHECK: cmplxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xec,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmplxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmplxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xec,0x89,0xf8,0x03,0x00,0x00] + cmplxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmplxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xec,0x8a,0x00,0xfc,0xff,0xff] + cmplxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnbexadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe7,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnbexadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnbexadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe7,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnbexadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnbexadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe7,0x0d,0x00,0x00,0x00,0x00] + cmpnbexadd %eax, %ecx, (%rip) + +// CHECK: cmpnbexadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe7,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnbexadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnbexadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe7,0x89,0xfc,0x01,0x00,0x00] + cmpnbexadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnbexadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe7,0x8a,0x00,0xfe,0xff,0xff] + cmpnbexadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnbexadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe7,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnbexadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnbexadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe7,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnbexadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnbexadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe7,0x0d,0x00,0x00,0x00,0x00] + cmpnbexadd %r10, %r9, (%rip) + +// CHECK: cmpnbexadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe7,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnbexadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnbexadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe7,0x89,0xf8,0x03,0x00,0x00] + cmpnbexadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnbexadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe7,0x8a,0x00,0xfc,0xff,0xff] + cmpnbexadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnbxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe3,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnbxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnbxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe3,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnbxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnbxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe3,0x0d,0x00,0x00,0x00,0x00] + cmpnbxadd %eax, %ecx, (%rip) + +// CHECK: cmpnbxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe3,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnbxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnbxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe3,0x89,0xfc,0x01,0x00,0x00] + cmpnbxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnbxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe3,0x8a,0x00,0xfe,0xff,0xff] + cmpnbxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnbxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe3,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnbxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnbxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe3,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnbxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnbxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe3,0x0d,0x00,0x00,0x00,0x00] + cmpnbxadd %r10, %r9, (%rip) + +// CHECK: cmpnbxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe3,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnbxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnbxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe3,0x89,0xf8,0x03,0x00,0x00] + cmpnbxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnbxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe3,0x8a,0x00,0xfc,0xff,0xff] + cmpnbxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnlexadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xef,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnlexadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnlexadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xef,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnlexadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnlexadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xef,0x0d,0x00,0x00,0x00,0x00] + cmpnlexadd %eax, %ecx, (%rip) + +// CHECK: cmpnlexadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xef,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnlexadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnlexadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xef,0x89,0xfc,0x01,0x00,0x00] + cmpnlexadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnlexadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xef,0x8a,0x00,0xfe,0xff,0xff] + cmpnlexadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnlexadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xef,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnlexadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnlexadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xef,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnlexadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnlexadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xef,0x0d,0x00,0x00,0x00,0x00] + cmpnlexadd %r10, %r9, (%rip) + +// CHECK: cmpnlexadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xef,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnlexadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnlexadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xef,0x89,0xf8,0x03,0x00,0x00] + cmpnlexadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnlexadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xef,0x8a,0x00,0xfc,0xff,0xff] + cmpnlexadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnlxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xed,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnlxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnlxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xed,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnlxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnlxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xed,0x0d,0x00,0x00,0x00,0x00] + cmpnlxadd %eax, %ecx, (%rip) + +// CHECK: cmpnlxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xed,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnlxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnlxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xed,0x89,0xfc,0x01,0x00,0x00] + cmpnlxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnlxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xed,0x8a,0x00,0xfe,0xff,0xff] + cmpnlxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnlxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xed,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnlxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnlxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xed,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnlxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnlxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xed,0x0d,0x00,0x00,0x00,0x00] + cmpnlxadd %r10, %r9, (%rip) + +// CHECK: cmpnlxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xed,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnlxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnlxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xed,0x89,0xf8,0x03,0x00,0x00] + cmpnlxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnlxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xed,0x8a,0x00,0xfc,0xff,0xff] + cmpnlxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnoxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe1,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnoxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnoxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe1,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnoxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnoxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe1,0x0d,0x00,0x00,0x00,0x00] + cmpnoxadd %eax, %ecx, (%rip) + +// CHECK: cmpnoxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe1,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnoxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnoxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe1,0x89,0xfc,0x01,0x00,0x00] + cmpnoxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnoxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe1,0x8a,0x00,0xfe,0xff,0xff] + cmpnoxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnoxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe1,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnoxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnoxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe1,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnoxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnoxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe1,0x0d,0x00,0x00,0x00,0x00] + cmpnoxadd %r10, %r9, (%rip) + +// CHECK: cmpnoxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe1,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnoxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnoxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe1,0x89,0xf8,0x03,0x00,0x00] + cmpnoxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnoxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe1,0x8a,0x00,0xfc,0xff,0xff] + cmpnoxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnpxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xeb,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnpxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnpxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xeb,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnpxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnpxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xeb,0x0d,0x00,0x00,0x00,0x00] + cmpnpxadd %eax, %ecx, (%rip) + +// CHECK: cmpnpxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xeb,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnpxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnpxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xeb,0x89,0xfc,0x01,0x00,0x00] + cmpnpxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnpxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xeb,0x8a,0x00,0xfe,0xff,0xff] + cmpnpxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnpxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xeb,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnpxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnpxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xeb,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnpxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnpxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xeb,0x0d,0x00,0x00,0x00,0x00] + cmpnpxadd %r10, %r9, (%rip) + +// CHECK: cmpnpxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xeb,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnpxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnpxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xeb,0x89,0xf8,0x03,0x00,0x00] + cmpnpxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnpxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xeb,0x8a,0x00,0xfc,0xff,0xff] + cmpnpxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnsxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe9,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnsxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnsxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe9,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnsxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnsxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe9,0x0d,0x00,0x00,0x00,0x00] + cmpnsxadd %eax, %ecx, (%rip) + +// CHECK: cmpnsxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe9,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnsxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnsxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe9,0x89,0xfc,0x01,0x00,0x00] + cmpnsxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnsxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe9,0x8a,0x00,0xfe,0xff,0xff] + cmpnsxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnsxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe9,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnsxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnsxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe9,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnsxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnsxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe9,0x0d,0x00,0x00,0x00,0x00] + cmpnsxadd %r10, %r9, (%rip) + +// CHECK: cmpnsxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe9,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnsxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnsxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe9,0x89,0xf8,0x03,0x00,0x00] + cmpnsxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnsxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe9,0x8a,0x00,0xfc,0xff,0xff] + cmpnsxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpnzxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe5,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnzxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpnzxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe5,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnzxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpnzxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe5,0x0d,0x00,0x00,0x00,0x00] + cmpnzxadd %eax, %ecx, (%rip) + +// CHECK: cmpnzxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe5,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpnzxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpnzxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe5,0x89,0xfc,0x01,0x00,0x00] + cmpnzxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpnzxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe5,0x8a,0x00,0xfe,0xff,0xff] + cmpnzxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpnzxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe5,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpnzxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpnzxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe5,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpnzxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpnzxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe5,0x0d,0x00,0x00,0x00,0x00] + cmpnzxadd %r10, %r9, (%rip) + +// CHECK: cmpnzxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe5,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpnzxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpnzxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe5,0x89,0xf8,0x03,0x00,0x00] + cmpnzxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpnzxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe5,0x8a,0x00,0xfc,0xff,0xff] + cmpnzxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpoxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe0,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpoxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpoxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe0,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpoxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpoxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe0,0x0d,0x00,0x00,0x00,0x00] + cmpoxadd %eax, %ecx, (%rip) + +// CHECK: cmpoxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe0,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpoxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpoxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe0,0x89,0xfc,0x01,0x00,0x00] + cmpoxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpoxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe0,0x8a,0x00,0xfe,0xff,0xff] + cmpoxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpoxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe0,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpoxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpoxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe0,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpoxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpoxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe0,0x0d,0x00,0x00,0x00,0x00] + cmpoxadd %r10, %r9, (%rip) + +// CHECK: cmpoxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe0,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpoxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpoxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe0,0x89,0xf8,0x03,0x00,0x00] + cmpoxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpoxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe0,0x8a,0x00,0xfc,0xff,0xff] + cmpoxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmppxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xea,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmppxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmppxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xea,0x8c,0x80,0x23,0x01,0x00,0x00] + cmppxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmppxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xea,0x0d,0x00,0x00,0x00,0x00] + cmppxadd %eax, %ecx, (%rip) + +// CHECK: cmppxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xea,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmppxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmppxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xea,0x89,0xfc,0x01,0x00,0x00] + cmppxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmppxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xea,0x8a,0x00,0xfe,0xff,0xff] + cmppxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmppxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xea,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmppxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmppxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xea,0x8c,0x80,0x23,0x01,0x00,0x00] + cmppxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmppxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xea,0x0d,0x00,0x00,0x00,0x00] + cmppxadd %r10, %r9, (%rip) + +// CHECK: cmppxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xea,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmppxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmppxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xea,0x89,0xf8,0x03,0x00,0x00] + cmppxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmppxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xea,0x8a,0x00,0xfc,0xff,0xff] + cmppxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpsxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe8,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpsxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpsxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe8,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpsxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpsxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe8,0x0d,0x00,0x00,0x00,0x00] + cmpsxadd %eax, %ecx, (%rip) + +// CHECK: cmpsxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe8,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpsxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpsxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe8,0x89,0xfc,0x01,0x00,0x00] + cmpsxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpsxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe8,0x8a,0x00,0xfe,0xff,0xff] + cmpsxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpsxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe8,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpsxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpsxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe8,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpsxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpsxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe8,0x0d,0x00,0x00,0x00,0x00] + cmpsxadd %r10, %r9, (%rip) + +// CHECK: cmpsxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe8,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpsxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpsxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe8,0x89,0xf8,0x03,0x00,0x00] + cmpsxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpsxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe8,0x8a,0x00,0xfc,0xff,0xff] + cmpsxadd %r10, %r9, -1024(%rdx) + +// CHECK: cmpzxadd %eax, %ecx, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0xa2,0x79,0xe4,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpzxadd %eax, %ecx, 268435456(%rbp,%r14,8) + +// CHECK: cmpzxadd %eax, %ecx, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0xc2,0x79,0xe4,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpzxadd %eax, %ecx, 291(%r8,%rax,4) + +// CHECK: cmpzxadd %eax, %ecx, (%rip) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe4,0x0d,0x00,0x00,0x00,0x00] + cmpzxadd %eax, %ecx, (%rip) + +// CHECK: cmpzxadd %eax, %ecx, -128(,%rbp,2) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe4,0x0c,0x6d,0x80,0xff,0xff,0xff] + cmpzxadd %eax, %ecx, -128(,%rbp,2) + +// CHECK: cmpzxadd %eax, %ecx, 508(%rcx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe4,0x89,0xfc,0x01,0x00,0x00] + cmpzxadd %eax, %ecx, 508(%rcx) + +// CHECK: cmpzxadd %eax, %ecx, -512(%rdx) +// CHECK: encoding: [0xc4,0xe2,0x79,0xe4,0x8a,0x00,0xfe,0xff,0xff] + cmpzxadd %eax, %ecx, -512(%rdx) + +// CHECK: cmpzxadd %r10, %r9, 268435456(%rbp,%r14,8) +// CHECK: encoding: [0xc4,0x22,0xa9,0xe4,0x8c,0xf5,0x00,0x00,0x00,0x10] + cmpzxadd %r10, %r9, 268435456(%rbp,%r14,8) + +// CHECK: cmpzxadd %r10, %r9, 291(%r8,%rax,4) +// CHECK: encoding: [0xc4,0x42,0xa9,0xe4,0x8c,0x80,0x23,0x01,0x00,0x00] + cmpzxadd %r10, %r9, 291(%r8,%rax,4) + +// CHECK: cmpzxadd %r10, %r9, (%rip) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe4,0x0d,0x00,0x00,0x00,0x00] + cmpzxadd %r10, %r9, (%rip) + +// CHECK: cmpzxadd %r10, %r9, -256(,%rbp,2) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe4,0x0c,0x6d,0x00,0xff,0xff,0xff] + cmpzxadd %r10, %r9, -256(,%rbp,2) + +// CHECK: cmpzxadd %r10, %r9, 1016(%rcx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe4,0x89,0xf8,0x03,0x00,0x00] + cmpzxadd %r10, %r9, 1016(%rcx) + +// CHECK: cmpzxadd %r10, %r9, -1024(%rdx) +// CHECK: encoding: [0xc4,0x62,0xa9,0xe4,0x8a,0x00,0xfc,0xff,0xff] + cmpzxadd %r10, %r9, -1024(%rdx) + diff --git a/llvm/utils/TableGen/X86RecognizableInstr.h b/llvm/utils/TableGen/X86RecognizableInstr.h --- a/llvm/utils/TableGen/X86RecognizableInstr.h +++ b/llvm/utils/TableGen/X86RecognizableInstr.h @@ -106,6 +106,7 @@ RawFrmImm16 = 8, AddCCFrm = 9, PrefixByte = 10, + MRMDestMem4VOp3 = 18, MRMr0 = 21, MRMSrcMemFSIB = 22, MRMDestMemFSIB = 23, diff --git a/llvm/utils/TableGen/X86RecognizableInstr.cpp b/llvm/utils/TableGen/X86RecognizableInstr.cpp --- a/llvm/utils/TableGen/X86RecognizableInstr.cpp +++ b/llvm/utils/TableGen/X86RecognizableInstr.cpp @@ -546,6 +546,16 @@ HANDLE_OPERAND(roRegister) HANDLE_OPTIONAL(immediate) break; + case X86Local::MRMDestMem4VOp3: + // Operand 1 is a sibmem/memory operand + // Operand 2 is a mod/r + // Operand 3 is VEX.vvvv + assert(numPhysicalOperands == 3 && + "Unexpected number of operands for MRMDestMem4VOp3"); + HANDLE_OPERAND(memory) + HANDLE_OPERAND(roRegister) + HANDLE_OPERAND(vvvvRegister) + break; case X86Local::MRMDestMem: case X86Local::MRMDestMemFSIB: // Operand 1 is a memory operand (possibly SIB-extended) @@ -808,6 +818,7 @@ filter = std::make_unique(true); break; case X86Local::MRMDestMem: + case X86Local::MRMDestMem4VOp3: case X86Local::MRMDestMemFSIB: case X86Local::MRMSrcMem: case X86Local::MRMSrcMemFSIB: