-
Notifications
You must be signed in to change notification settings - Fork 14.3k
[RISCV] Add Qualcomm uC Xqciint (Interrupts) extension #122256
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
5 commits
Select commit
Hold shift + click to select a range
0ab7558
[RISCV] Add Qualcomm uC Xqciint (Interrupts) extension
a742e5d
Update RISCVInstrInfoXqci.td
a43cfa4
Replace imm5 with funct5 in RISCVInstrInfoXqci.td
c74e0cb
Adjust indentation in RISCVInstrInfoXqci.td
b5f08aa
Update RISCVInstrInfo.cpp
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
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
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,105 @@ | ||
# Xqciint - Qualcomm uC Interrupts extension | ||
# RUN: not llvm-mc -triple riscv32 -mattr=+experimental-xqciint < %s 2>&1 \ | ||
# RUN: | FileCheck -check-prefixes=CHECK,CHECK-IMM %s | ||
# RUN: not llvm-mc -triple riscv32 -mattr=-experimental-xqciint < %s 2>&1 \ | ||
# RUN: | FileCheck -check-prefixes=CHECK,CHECK-EXT %s | ||
|
||
# CHECK-IMM: :[[@LINE+1]]:12: error: immediate must be an integer in the range [0, 1023] | ||
qc.setinti 1025 | ||
|
||
# CHECK: :[[@LINE+1]]:16: error: invalid operand for instruction | ||
qc.setinti 11, 12 | ||
|
||
# CHECK: :[[@LINE+1]]:1: error: too few operands for instruction | ||
qc.setinti | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.setinti 10 | ||
|
||
|
||
# CHECK-IMM: :[[@LINE+1]]:12: error: immediate must be an integer in the range [0, 1023] | ||
qc.clrinti 2000 | ||
|
||
# CHECK: :[[@LINE+1]]:16: error: invalid operand for instruction | ||
qc.clrinti 22, x4 | ||
|
||
# CHECK: :[[@LINE+1]]:1: error: too few operands for instruction | ||
qc.clrinti | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.clrinti 8 | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:13: error: invalid operand for instruction | ||
qc.c.clrint 22 | ||
|
||
# CHECK: :[[@LINE+1]]:1: error: too few operands for instruction | ||
qc.c.clrint | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.clrint x8 | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:9: error: invalid operand for instruction | ||
qc.c.di 22 | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.di | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:10: error: invalid operand for instruction | ||
qc.c.dir 22 | ||
|
||
# CHECK: :[[@LINE+1]]:1: error: too few operands for instruction | ||
qc.c.dir | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.dir x8 | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:9: error: invalid operand for instruction | ||
qc.c.ei 22 | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.ei | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:10: error: invalid operand for instruction | ||
qc.c.eir 22 | ||
|
||
# CHECK: :[[@LINE+1]]:1: error: too few operands for instruction | ||
qc.c.eir | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.eir x8 | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:19: error: invalid operand for instruction | ||
qc.c.mienter.nest 22 | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.mienter.nest | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:14: error: invalid operand for instruction | ||
qc.c.mienter 22 | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.mienter | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:17: error: invalid operand for instruction | ||
qc.c.mileaveret 22 | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.mileaveret | ||
|
||
|
||
# CHECK: :[[@LINE+1]]:13: error: invalid operand for instruction | ||
qc.c.setint 22 | ||
|
||
# CHECK: :[[@LINE+1]]:1: error: too few operands for instruction | ||
qc.c.setint | ||
|
||
# CHECK-EXT: :[[@LINE+1]]:1: error: instruction requires the following: 'Xqciint' (Qualcomm uC Interrupts Extension) | ||
qc.c.setint x8 |
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,81 @@ | ||
# Xqciint - Qualcomm uC Interrupts extension | ||
# RUN: llvm-mc %s -triple=riscv32 -mattr=+experimental-xqciint -riscv-no-aliases -show-encoding \ | ||
# RUN: | FileCheck -check-prefixes=CHECK-ENC,CHECK-INST %s | ||
# RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+experimental-xqciint < %s \ | ||
# RUN: | llvm-objdump --mattr=+experimental-xqciint -M no-aliases --no-print-imm-hex -d - \ | ||
# RUN: | FileCheck -check-prefix=CHECK-INST %s | ||
# RUN: llvm-mc %s -triple=riscv32 -mattr=+experimental-xqciint -show-encoding \ | ||
# RUN: | FileCheck -check-prefixes=CHECK-ENC,CHECK-INST %s | ||
# RUN: llvm-mc -filetype=obj -triple riscv32 -mattr=+experimental-xqciint < %s \ | ||
# RUN: | llvm-objdump --mattr=+experimental-xqciint --no-print-imm-hex -d - \ | ||
# RUN: | FileCheck -check-prefix=CHECK-INST %s | ||
|
||
# CHECK-INST: qc.setinti 500 | ||
# CHECK-ENC: encoding: [0x73,0x00,0xfa,0xcc] | ||
qc.setinti 500 | ||
|
||
# CHECK-INST: qc.setinti 0 | ||
# CHECK-ENC: encoding: [0x73,0x00,0x00,0xcc] | ||
qc.setinti 0 | ||
|
||
# CHECK-INST: qc.setinti 1023 | ||
# CHECK-ENC: encoding: [0x73,0x80,0xff,0xcd] | ||
qc.setinti 1023 | ||
|
||
|
||
# CHECK-INST: qc.clrinti 500 | ||
# CHECK-ENC: encoding: [0x73,0x00,0xfa,0xce] | ||
qc.clrinti 500 | ||
|
||
# CHECK-INST: qc.clrinti 1023 | ||
# CHECK-ENC: encoding: [0x73,0x80,0xff,0xcf] | ||
qc.clrinti 1023 | ||
|
||
# CHECK-INST: qc.clrinti 0 | ||
# CHECK-ENC: encoding: [0x73,0x00,0x00,0xce] | ||
qc.clrinti 0 | ||
|
||
|
||
# CHECK-INST: qc.c.clrint a0 | ||
# CHECK-ENC: encoding: [0x0e,0x15] | ||
qc.c.clrint x10 | ||
|
||
|
||
# CHECK-INST: qc.c.di | ||
# CHECK-ENC: encoding: [0x12,0x1b] | ||
qc.c.di | ||
|
||
|
||
# CHECK-INST: qc.c.dir a0 | ||
# CHECK-ENC: encoding: [0x02,0x15] | ||
qc.c.dir x10 | ||
|
||
|
||
# CHECK-INST: qc.c.ei | ||
# CHECK-ENC: encoding: [0x92,0x1b] | ||
qc.c.ei | ||
|
||
|
||
# CHECK-INST: qc.c.eir a0 | ||
# CHECK-ENC: encoding: [0x06,0x15] | ||
qc.c.eir x10 | ||
|
||
|
||
# CHECK-INST: qc.c.mienter.nest | ||
# CHECK-ENC: encoding: [0x92,0x18] | ||
qc.c.mienter.nest | ||
|
||
|
||
# CHECK-INST: qc.c.mienter | ||
# CHECK-ENC: encoding: [0x12,0x18] | ||
qc.c.mienter | ||
|
||
|
||
# CHECK-INST: qc.c.mileaveret | ||
# CHECK-ENC: encoding: [0x12,0x1a] | ||
qc.c.mileaveret | ||
|
||
|
||
# CHECK-INST: qc.c.setint a0 | ||
# CHECK-ENC: encoding: [0x0a,0x15] | ||
qc.c.setint x10 |
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.