-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[X86][MC,Driver] Support -msse2avx to encode SSE instruction with VEX prefix #96860
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
31 commits
Select commit
Hold shift + click to select a range
b4a534a
[X86][MC] Added support for -msse2avx option in llvm-mc
JaydeepChauhan14 5d47f63
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 95021b6
Addressd review comments
JaydeepChauhan14 acf5a7d
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 0bf7123
Added support for intel syntax
JaydeepChauhan14 f725a31
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 8f2a402
Moved replaceSSE2AVXOpcode inside X86AsmParser::processInstruction
JaydeepChauhan14 5c3cfe0
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 c901194
Addressed review comments
JaydeepChauhan14 5069ffe
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 3623d8d
Added support for instructions BLENDVPD,BLENDVPS,PBLENDVB
JaydeepChauhan14 aeefdfa
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 6ca47cd
Added test for blendvpd instruction
JaydeepChauhan14 528e1f9
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 b0cca0e
Changed SSE2AVX option to bool and sync intel test
JaydeepChauhan14 568899c
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 b62d52d
Added -msse2avx as clang and -x86-sse2avx as llvm-mc options
JaydeepChauhan14 04266aa
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 7faad7f
Removed -mno-sse2avx option
JaydeepChauhan14 1250e44
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 0133d40
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 772da90
Addressed review comments
JaydeepChauhan14 8792643
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 b08971d
Addressed review comments
JaydeepChauhan14 f80b80d
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 d6916eb
Added mapping of BLENDVPD, BLENDVPS ,PBLENDVB in X86ManualInstrMappin…
JaydeepChauhan14 5210873
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 800ae6b
Addressed review comments
JaydeepChauhan14 481d338
Merge branch 'main' into added_msse2avx_option
JaydeepChauhan14 7d067cc
Addressed review comments
JaydeepChauhan14 41f0cba
Removed extra space in testcase
JaydeepChauhan14 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
// RUN: %clang -### -c -march=x86-64 -Xassembler -msse2avx %s 2>&1 | FileCheck %s | ||
// RUN: %clang -### -c -march=x86-64 -x assembler -Xassembler -msse2avx %s 2>&1 | FileCheck %s | ||
|
||
// CHECK: "-msse2avx" | ||
|
||
// RUN: not %clang -### -c --target=aarch64 -march=armv8a -msse2avx %s 2>&1 | FileCheck --check-prefix=ERR %s | ||
// ERR: error: unsupported option '-msse2avx' for target 'aarch64' |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,89 @@ | ||
# RUN: llvm-mc -triple x86_64 -x86-sse2avx %s | FileCheck %s | ||
# RUN: llvm-mc -triple=x86_64 -output-asm-variant=1 %s | llvm-mc -triple=x86_64 -x86-asm-syntax=intel -x86-sse2avx | ||
.text | ||
# CHECK: vmovsd -352(%rbp), %xmm0 | ||
movsd -352(%rbp), %xmm0 # xmm0 = mem[0],zero | ||
# CHECK-NEXT: vunpcklpd %xmm1, %xmm0, %xmm0 # xmm0 = xmm0[0],xmm1[0] | ||
unpcklpd %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0] | ||
# CHECK-NEXT: vmovapd %xmm0, -368(%rbp) | ||
movapd %xmm0, -368(%rbp) | ||
# CHECK-NEXT: vmovapd -368(%rbp), %xmm0 | ||
movapd -368(%rbp), %xmm0 | ||
# CHECK-NEXT: vmovsd -376(%rbp), %xmm1 | ||
movsd -376(%rbp), %xmm1 # xmm1 = mem[0],zero | ||
# CHECK-NEXT: vmovsd -384(%rbp), %xmm0 | ||
movsd -384(%rbp), %xmm0 # xmm0 = mem[0],zero | ||
# CHECK-NEXT: vunpcklpd %xmm1, %xmm0, %xmm0 # xmm0 = xmm0[0],xmm1[0] | ||
unpcklpd %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0] | ||
# CHECK-NEXT: vaddpd %xmm1, %xmm0, %xmm0 | ||
addpd %xmm1, %xmm0 | ||
# CHECK-NEXT: vmovapd %xmm0, -464(%rbp) | ||
movapd %xmm0, -464(%rbp) | ||
# CHECK-NEXT: vmovaps -304(%rbp), %xmm1 | ||
movaps -304(%rbp), %xmm1 | ||
# CHECK-NEXT: vpandn %xmm1, %xmm0, %xmm0 | ||
pandn %xmm1, %xmm0 | ||
# CHECK-NEXT: vmovaps %xmm0, -480(%rbp) | ||
movaps %xmm0, -480(%rbp) | ||
# CHECK-NEXT: vmovss -220(%rbp), %xmm1 | ||
movss -220(%rbp), %xmm1 # xmm1 = mem[0],zero,zero,zero | ||
# CHECK-NEXT: vinsertps $16, %xmm1, %xmm0, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[2,3] | ||
insertps $16, %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[0],xmm0[2,3] | ||
# CHECK-NEXT: vmovaps %xmm0, -496(%rbp) | ||
movaps %xmm0, -496(%rbp) | ||
# CHECK-NEXT: vmovss -256(%rbp), %xmm0 | ||
movss -256(%rbp), %xmm0 # xmm0 = mem[0],zero,zero,zero | ||
# CHECK-NEXT: vmovaps -192(%rbp), %xmm0 | ||
movaps -192(%rbp), %xmm0 | ||
# CHECK-NEXT: vdivss %xmm1, %xmm0, %xmm0 | ||
divss %xmm1, %xmm0 | ||
# CHECK-NEXT: vmovaps %xmm0, -192(%rbp) | ||
movaps %xmm0, -192(%rbp) | ||
# CHECK-NEXT: vmovd -128(%rbp), %xmm0 | ||
movd -128(%rbp), %xmm0 # xmm0 = mem[0],zero,zero,zero | ||
# CHECK-NEXT: vpinsrd $1, %edx, %xmm0, %xmm0 | ||
pinsrd $1, %edx, %xmm0 | ||
# CHECK-NEXT: vmovaps %xmm0, -144(%rbp) | ||
movaps %xmm0, -144(%rbp) | ||
# CHECK-NEXT: vmovd -160(%rbp), %xmm0 | ||
movd -160(%rbp), %xmm0 # xmm0 = mem[0],zero,zero,zero | ||
# CHECK-NEXT: vpblendw $170, %xmm1, %xmm0, %xmm0 # xmm0 = xmm0[0],xmm1[1],xmm0[2],xmm1[3],xmm0[4],xmm1[5],xmm0[6],xmm1[7] | ||
pblendw $170, %xmm1, %xmm0 # xmm0 = xmm0[0],xmm1[1],xmm0[2],xmm1[3],xmm0[4],xmm1[5],xmm0[6],xmm1[7] | ||
# CHECK-NEXT: vmovdqa %xmm0, -576(%rbp) | ||
movdqa %xmm0, -576(%rbp) | ||
# CHECK-NEXT: vphsubw %xmm1, %xmm0, %xmm0 | ||
phsubw %xmm1, %xmm0 | ||
# CHECK-NEXT: vmovdqa %xmm0, -592(%rbp) | ||
movdqa %xmm0, -592(%rbp) | ||
# CHECK-NEXT: vmovaps -496(%rbp), %xmm0 | ||
movaps -496(%rbp), %xmm0 | ||
# CHECK-NEXT: vroundps $8, %xmm0, %xmm0 | ||
roundps $8, %xmm0, %xmm0 | ||
# CHECK-NEXT: vmovaps %xmm0, -608(%rbp) | ||
movaps %xmm0, -608(%rbp) | ||
# CHECK-NEXT: vmovapd -432(%rbp), %xmm0 | ||
movapd -432(%rbp), %xmm0 | ||
# CHECK-NEXT: vpxor %xmm1, %xmm0, %xmm0 | ||
pxor %xmm1, %xmm0 | ||
# CHECK-NEXT: vmovaps %xmm0, -640(%rbp) | ||
movaps %xmm0, -640(%rbp) | ||
# CHECK-NEXT: vmovapd -32(%rbp), %xmm0 | ||
movapd -32(%rbp), %xmm0 | ||
# CHECK-NEXT: vmovupd %xmm0, (%rax) | ||
movupd %xmm0, (%rax) | ||
# CHECK-NEXT: vmovsd -656(%rbp), %xmm0 | ||
movsd -656(%rbp), %xmm0 # xmm0 = mem[0],zero | ||
# CHECK-NEXT: extrq $16, $8, %xmm0 # xmm0 = xmm0[2],zero,zero,zero,zero,zero,zero,zero,xmm0[u,u,u,u,u,u,u,u] | ||
extrq $16, $8, %xmm0 | ||
# CHECK-NEXT: insertq $16, $8, %xmm1, %xmm0 # xmm0 = xmm0[0,1],xmm1[0],xmm0[3,4,5,6,7,u,u,u,u,u,u,u,u] | ||
insertq $16, $8, %xmm1, %xmm0 | ||
# CHECK-NEXT: pshufw $1, %mm0, %mm2 # mm2 = mm0[1,0,0,0] | ||
pshufw $1, %mm0, %mm2 | ||
# CHECK-NEXT: vpblendvb %xmm2, %xmm2, %xmm1, %xmm1 | ||
pblendvb %xmm0, %xmm2, %xmm1 | ||
# CHECK-NEXT: vblendvps %xmm0, %xmm0, %xmm2, %xmm2 | ||
blendvps %xmm0, %xmm0, %xmm2 | ||
# CHECK-NEXT: vblendvpd %xmm0, %xmm0, %xmm2, %xmm2 | ||
blendvpd %xmm0, %xmm0, %xmm2 | ||
# CHECK-NEXT: vblendvpd %xmm0, %xmm0, %xmm2, %xmm2 | ||
blendvpd %xmm0, %xmm2 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.