riscv-software-src / riscv-tests

Other
902 stars 463 forks source link

Benchmarks: parameterise ABI based on XLEN #566

Closed TommyMurphyTM1234 closed 5 months ago

TommyMurphyTM1234 commented 5 months ago

Addresses this issue:

Parameterise ABI based on selected XLEN unless it has already been passed in.

Note that since RISCV_PREFIX has always been parameterised using XLEN, this means that XLEN == 32 expects, by default, to use a riscv32-unknown-elf- prefixed toolchain. If necessary, this can be overridden as follows:

./configure ... --with-xlen=32
make benchmarks RISCV_PREFIX=riscv64-unknown-elf-

Obviously, whatever toolchain prefix is used the toolchain needs to support the selected arch/abi - e.g. rv64gcv/lp64d or rv32gcv/ilp32d or whatever other ABI is passed in - via the toolchain's default arch/abi or via multilibs for the selected arch/abi.

I didn't consider XLEN == 128 since, as far as I can see, it isn't considered elswhere in the test suite but it would be trivial to extend this mod to cover it if necessary.

TommyMurphyTM1234 commented 5 months ago

Thanks @aswaterman. đź‘Ť

aswaterman commented 5 months ago

You’re welcome!