Add an enable_e setting for the RV32E instruction set.
This limited RISC-V version only has registers %x0 - %x15. Make sure the ABI lowering code doesn't use the banned registers for arguments.
This commit is contained in:
14
filetests/isa/riscv/abi-e.cton
Normal file
14
filetests/isa/riscv/abi-e.cton
Normal file
@@ -0,0 +1,14 @@
|
||||
; Test the legalization of function signatures for RV32E.
|
||||
test legalizer
|
||||
isa riscv enable_e
|
||||
|
||||
; regex: V=v\d+
|
||||
|
||||
function f() {
|
||||
; Spilling into the stack args after %x15 since %16 and up are not
|
||||
; available in RV32E.
|
||||
sig0 = signature(i64, i64, i64, i64) -> i64
|
||||
; check: sig0 = signature(i32 [%x10], i32 [%x11], i32 [%x12], i32 [%x13], i32 [%x14], i32 [%x15], i32 [0], i32 [4]) -> i32 [%x10], i32 [%x11]
|
||||
ebb0:
|
||||
return
|
||||
}
|
||||
Reference in New Issue
Block a user