-
Notifications
You must be signed in to change notification settings - Fork 13.6k
[RISCV] Add MC layer support for XSfmm*. #133031
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
12 commits
Select commit
Hold shift + click to select a range
bb123ff
[RISCV] Add MC layer support for XSfmm*.
topperc d308dba
fixup! add tests I forgot
topperc 7ebe32c
fixup! Update riscv-target-features-sifive.
topperc b36e65b
fixup! Remove getXSfmmAltFmt which duplicates isAltFmt.
topperc 3ed4141
Merge remote-tracking branch 'origin/main' into pr/xsfmm
topperc dab4832
Merge remote-tracking branch 'origin/main' into pr/xsfmm
topperc 0497985
fixup! remove Xsfmm32a4i and Xsfmm32a.
topperc 4656703
fixup! Address review comments
topperc 268e0c7
fixup! XSfmm64a64f depends on Zve64d.
topperc 89ba8c1
Merge remote-tracking branch 'origin/main' into pr/xsfmm
topperc b40f01f
Merge remote-tracking branch 'origin/main' into pr/xsfmm
topperc 87468b8
fixup! Improve invalid vtype tests
topperc 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm128t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM128T %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm128t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM128T %s | ||
// CHECK-XSFMM128T: __riscv_xsfmm128t 6000{{$}} | ||
// | ||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm16t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM16T %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm16t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM16T %s | ||
// CHECK-XSFMM16T: __riscv_xsfmm16t 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm32a8i -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32a8I %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm32a8i -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32a8I %s | ||
// CHECK-XSFMM32a8I: __riscv_xsfmm32a8i 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm32a8f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32A8F %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm32a8f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32A8F %s | ||
// CHECK-XSFMM32A8F: __riscv_xsfmm32a8f 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm32a16f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32a16F %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm32a16f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32a16F %s | ||
// CHECK-XSFMM32a16F: __riscv_xsfmm32a16f 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm32a32f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32a32F %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm32a32f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32a32F %s | ||
// CHECK-XSFMM32a32F: __riscv_xsfmm32a32f 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm32t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32T %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm32t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM32T %s | ||
// CHECK-XSFMM32T: __riscv_xsfmm32t 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm64a64f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM64a64f %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm64a64f -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM64a64f %s | ||
// CHECK-XSFMM64a64f: __riscv_xsfmm64a64f 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmm64t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM64T %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmm64t -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMM64T %s | ||
// CHECK-XSFMM64T: __riscv_xsfmm64t 6000{{$}} | ||
|
||
// RUN: %clang --target=riscv32 \ | ||
// RUN: -march=rv32i_zve32x_xsfmmbase -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMMBASE %s | ||
// RUN: %clang --target=riscv64 \ | ||
// RUN: -march=rv64i_zve32x_xsfmmbase -E -dM %s \ | ||
// RUN: -o - | FileCheck --check-prefix=CHECK-XSFMMBASE %s | ||
// CHECK-XSFMMBASE: __riscv_xsfmmbase 6000{{$}} |
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
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
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To test whether we handle
AsmToken::EndOfStatement
properly (no duplicate \n in the output), need to have two adjacent instructions in a testand check the MCAsmStreamer output
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe this check was trying to make sure there aren't additional operands left for this instruction. We're parsing multiple comma separated identifiers here as a single custom operand. Looks like we are missing a test for that.