Skip to content

Commit

Permalink
qtrvsim_tester: CLANG and GCC options to match real 32 and 64-bit tar…
Browse files Browse the repository at this point in the history
…gets

The ABI for 32-bit target should use 32-bit size for int, long and pointer
types, that is selected by ilp32 variant.

The ABI for 64-bit target should use 64-bit size for long and pointer
types and leaved int as 32-bit, that is lp64 variant.

Signed-off-by: Pavel Pisa <pisa@cmp.felk.cvut.cz>
  • Loading branch information
ppisa committed Sep 11, 2022
1 parent e34300d commit 4869107
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tests/riscv-official/isa/toolchain_setup
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ RISCV_SIM ?= spike
USE_CLANG_OPTS ?= false

ifeq ($(USE_CLANG_OPTS), true)
MARCH_OPTS_32 = -march=rv64g --target=riscv32 -mno-relax -fuse-ld=lld
MARCH_OPTS_64 = -march=rv64g --target=riscv64 -mno-relax -fuse-ld=lld
MARCH_OPTS_32 = -march=rv32g -mabi=ilp32 --target=riscv32 -mno-relax -fuse-ld=lld
MARCH_OPTS_64 = -march=rv64g -mabi=lp64 --target=riscv64 -mno-relax -fuse-ld=lld
else
MARCH_OPTS_32 = -march=rv32g -mabi=ilp32
MARCH_OPTS_64 = -march=rv64g -mabi=ilp64
MARCH_OPTS_64 = -march=rv64g -mabi=lp64
endif

0 comments on commit 4869107

Please sign in to comment.