- Notifications
You must be signed in to change notification settings - Fork14.5k
[RISCV] Add short forward branch scheduling for Andes45#147890
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
@llvm/pr-subscribers-backend-risc-v Author: Jim Lin (tclin914) ChangesFull diff:https://github.com/llvm/llvm-project/pull/147890.diff 1 Files Affected:
diff --git a/llvm/lib/Target/RISCV/RISCVSchedAndes45.td b/llvm/lib/Target/RISCV/RISCVSchedAndes45.tdindex bd480aacc539e..214fd8158a679 100644--- a/llvm/lib/Target/RISCV/RISCVSchedAndes45.td+++ b/llvm/lib/Target/RISCV/RISCVSchedAndes45.td@@ -54,6 +54,12 @@ def : WriteRes<WriteShiftImm32, [Andes45ALU]>; def : WriteRes<WriteShiftReg, [Andes45ALU]>; def : WriteRes<WriteShiftReg32, [Andes45ALU]>;+// Short forward branch+def : WriteRes<WriteSFB, [Andes45ALU]> {+ let Latency = 1;+ let NumMicroOps = 2;+}+ // Branching def : WriteRes<WriteJmp, [Andes45ALU]>; def : WriteRes<WriteJal, [Andes45ALU]>;@@ -231,6 +237,8 @@ def : ReadAdvance<ReadShiftImm, 0>; def : ReadAdvance<ReadShiftImm32, 0>; def : ReadAdvance<ReadShiftReg, 0>; def : ReadAdvance<ReadShiftReg32, 0>;+def : ReadAdvance<ReadSFBJmp, 0>;+def : ReadAdvance<ReadSFBALU, 0>; def : ReadAdvance<ReadJalr, 0>; def : ReadAdvance<ReadJmp, 0>; def : ReadAdvance<ReadIMul, 0>;@@ -328,7 +336,6 @@ def : ReadAdvance<ReadCSR, 0>; //===----------------------------------------------------------------------===// // Unsupported extensions defm : UnsupportedSchedQ;-defm : UnsupportedSchedSFB; defm : UnsupportedSchedV; defm : UnsupportedSchedXsfvcp; defm : UnsupportedSchedXSfvfnrclipxfqf; |
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.
LGTM
could you also add a simple MCA test if that's not a lot of work? |
I don't know how to add an MCA test to verify the scheduling info used by pseudo instructions (PseudoCC* in this case) :( |
Oops you're right, nvm then |
2886d30
intollvm:mainUh oh!
There was an error while loading.Please reload this page.
No description provided.