riscvarchive / riscv-code-size-reduction

https://jira.riscv.org/browse/RVG-122
150 stars 34 forks source link

[EABI] RV32 only stack support instructions #176

Open jnk0le opened 2 years ago

jnk0le commented 2 years ago

Due to 2xXLEN stack alignment, RV32 eabi needs extra compressed instructions to efficiently operate on 8 byte aligned stack, otherwise non compressed instructions will have to be used when limiting stack waste is important.

tariqkurd-repo commented 2 years ago

why 8-byte aligned? Is this in the EABI proposal?

jnk0le commented 2 years ago

yes https://github.com/riscv-non-isa/riscv-eabi-spec/blob/master/EABI.adoc#4-eabi-stack-alignment

currently 2xXLEN for both RV32 and RV64