-
Notifications
You must be signed in to change notification settings - Fork 275
Conversation
Thanks, Kito. I probably won't have time to look at this for a bit, but I appreciate the help :) |
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.
ABI_SPEC in riscv.h also needs to be updated, to get the library paths right for ilp32e.
There is also a MUSL_ABI_SUFFIX in linux.h, but I think rv32e and linux are contradictory, though maybe we should emit an error somewhere if someone tries to use rv32e with linux. This part is optional.
gcc/config.gcc
Outdated
@@ -4056,11 +4057,12 @@ case "${target}" in | |||
# pick a default based on the ISA, preferring soft-float | |||
# unless the D extension is present. | |||
case "${with_abi}" in | |||
ilp32 | ilp32f | ilp32d | lp64 | lp64f | lp64d) | |||
ilp32 | ilp32f | ilp32d | lp64 | lp64f | lp64d | lp64q) |
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.
ilp32e needs to be in this list of valid abis, otherwise you are overriding the user's choice, and won't give an error if the user makes a mistake with non-matching arch/abi.
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.
Fixed, that's my mistake when rebase with Q-extension...
gcc/config/riscv/riscv.c
Outdated
if (riscv_abi == ABI_ILP32E) | ||
{ | ||
for (int r = 16; r <= 31; r++) | ||
call_used_regs[r] = 1; |
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.
An extra space before the =, minor nit.
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.
Fixed :)
a45f189
to
13be76f
Compare
@palmer-dabbelt @jim-wilson thanks for your review :) |
I am unfamiliar with github workflow in general, and riscv github workflow in particular. I was assuming that the person who submitted the patch would merge them after approval. This is how FSF binutils/gcc work. If you are waiting for me to merge them, let me know. |
riscv-non-isa/riscv-toolchain-conventions#3