-
Notifications
You must be signed in to change notification settings - Fork 59
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
Initial support for RISC-V 32 I M #781
Conversation
…s (ADD / ADDI). (#706) * Provides RISCV initial architecture description and first instructions (ADD / ADDI). Co-authored-by: Benjamin Gregoire <[email protected]> Co-authored-by: Jean-Christophe Léchenet <[email protected]> --------- Co-authored-by: Benjamin Gregoire <[email protected]> Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Co-authored-by: LE BRETON Come <[email protected]>
Co-authored-by: LE BRETON Come <[email protected]>
Co-authored-by: Santiago Arranz Olmos <[email protected]>
Add XOR and OR to compiler/riscv_instr_decl.v --------- Co-authored-by: Julian Wälde <[email protected]> Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Renames registers. Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Riscv compiler skeleton
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Co-authored-by: Jean-Christophe Léchenet<[email protected]>
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
+ Fix push / pop ra to stack
It looks like gp may be used to access globals. I don't know for tp, but to be safe I added both of them into the list of callee-saved registers.
Co-authored-by: Jean-Christophe Léchenet <[email protected]>
Taking into account that division by 0 returns -1 for signed and 2ˆL-1 for unsigned.
Did we still have work to do before merging? |
My comments above still need to be addressed. |
This reverts commit 0be66c6.
Let's be generous!
The pass used to systematically introduce an auxiliary register, even for the case of constant 0, while in this case we can use register x0 directly.
+ small fix in error message in pretyping
On RISC-V, sp can be manipulated like any other register, so we can use fewer instructions than on ARM. We use the same code as on x86, except that we have to take special care of large immediates.
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.
Can I squash all these commits into a single one?
Fine with me. |
This needs a bit of work to adapt to current |
Fixes #698 and #503 and #783.