diff options
author | Andrew Waterman <waterman@eecs.berkeley.edu> | 2014-02-10 19:02:28 -0800 |
---|---|---|
committer | Andrew Waterman <waterman@eecs.berkeley.edu> | 2014-02-10 19:02:28 -0800 |
commit | c50db79a8e549d7dd2112ff22d48be5e4b501fea (patch) | |
tree | 1309badb3c30935a5457e8659b0e46e66f310216 /isa | |
parent | 65487f641d7ca228938106d7c4d36a78e3990055 (diff) | |
download | riscv-tests-c50db79a8e549d7dd2112ff22d48be5e4b501fea.zip riscv-tests-c50db79a8e549d7dd2112ff22d48be5e4b501fea.tar.gz riscv-tests-c50db79a8e549d7dd2112ff22d48be5e4b501fea.tar.bz2 |
Revert to old AUIPC definition
Diffstat (limited to 'isa')
-rw-r--r-- | isa/Makefile | 2 | ||||
-rw-r--r-- | isa/rv32ui/auipc.S | 16 | ||||
-rw-r--r-- | isa/rv64ui/auipc.S | 16 |
3 files changed, 13 insertions, 21 deletions
diff --git a/isa/Makefile b/isa/Makefile index 8cecab9..b876406 100644 --- a/isa/Makefile +++ b/isa/Makefile @@ -19,7 +19,7 @@ default: all #-------------------------------------------------------------------- RISCV_GCC = riscv-gcc -RISCV_GCC_OPTS = -nostdlib -nostartfiles -Wa,-march=RVIMAFDXhwacha +RISCV_GCC_OPTS = -fpic -nostdlib -nostartfiles -Wa,-march=RVIMAFDXhwacha RISCV_OBJDUMP = riscv-objdump --disassemble-all --section=.text --section=.data --section=.bss RISCV_SIM = spike --extension=hwacha diff --git a/isa/rv32ui/auipc.S b/isa/rv32ui/auipc.S index b5dbf88..cca7781 100644 --- a/isa/rv32ui/auipc.S +++ b/isa/rv32ui/auipc.S @@ -11,22 +11,18 @@ RVTEST_RV32U RVTEST_CODE_BEGIN - TEST_CASE(2, a0, 1<<12, \ + TEST_CASE(2, a0, 10000, \ .align 3; \ - auipc a0, 0x00001; \ + lla a0, 1f + 10000; \ jal a1, 1f; \ - 1: srl a1, a1, 12; \ - sll a1, a1, 12; \ - sub a0, a0, a1; \ + 1: sub a0, a0, a1; \ ) - TEST_CASE(3, a0, -1<<12, \ + TEST_CASE(3, a0, -10000, \ .align 3; \ - auipc a0, 0xfffff; \ + lla a0, 1f - 10000; \ jal a1, 1f; \ - 1: srl a1, a1, 12; \ - sll a1, a1, 12; \ - sub a0, a0, a1; \ + 1: sub a0, a0, a1; \ ) TEST_PASSFAIL diff --git a/isa/rv64ui/auipc.S b/isa/rv64ui/auipc.S index c2b5157..f5d28ec 100644 --- a/isa/rv64ui/auipc.S +++ b/isa/rv64ui/auipc.S @@ -11,22 +11,18 @@ RVTEST_RV64U RVTEST_CODE_BEGIN - TEST_CASE(2, a0, 1<<12, \ + TEST_CASE(2, a0, 10000, \ .align 3; \ - auipc a0, 0x00001; \ + lla a0, 1f + 10000; \ jal a1, 1f; \ - 1: srl a1, a1, 12; \ - sll a1, a1, 12; \ - sub a0, a0, a1; \ + 1: sub a0, a0, a1; \ ) - TEST_CASE(3, a0, -1<<12, \ + TEST_CASE(3, a0, -10000, \ .align 3; \ - auipc a0, 0xfffff; \ + lla a0, 1f - 10000; \ jal a1, 1f; \ - 1: srl a1, a1, 12; \ - sll a1, a1, 12; \ - sub a0, a0, a1; \ + 1: sub a0, a0, a1; \ ) TEST_PASSFAIL |