Skip to content

Commit 40f07e2

Browse files
authored
Fix rv64ua-amomaxu_w and rv64ua-amominu_w testcases for rv32 (#611)
Test case 6 of both rv64ua-amomaxu_w and rv64ua-amominu_w test a rv64 specific behaviour that the upper 32 bits must be ignored. This test does not apply for rv32 and this commits disables these tests for rv32.
1 parent 8b9bd7b commit 40f07e2

File tree

2 files changed

+8
-0
lines changed

2 files changed

+8
-0
lines changed

isa/rv64ua/amomaxu_w.S

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ RVTEST_CODE_BEGIN
3131

3232
TEST_CASE(5, a5, 0xffffffffffffffff, lw a5, 0(a3))
3333

34+
# The following two cases check that the upper 32 bits are ignored on rv64
35+
# implementations. Only enable them for rv64.
36+
#if __riscv_xlen == 64
3437
TEST_CASE(6, a4, 1, \
3538
li a0, 0x0000000000000001; \
3639
li a1, 0x8000000000000000; \
@@ -40,6 +43,7 @@ RVTEST_CODE_BEGIN
4043
)
4144

4245
TEST_CASE(7, a5, 1, lw a5, 0(a3))
46+
#endif
4347

4448
TEST_PASSFAIL
4549

isa/rv64ua/amominu_w.S

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,9 @@ RVTEST_CODE_BEGIN
3131

3232
TEST_CASE(5, a5, 0, lw a5, 0(a3))
3333

34+
# The following two cases check that the upper 32 bits are ignored on rv64
35+
# implementations. Only enable them for rv64.
36+
#if __riscv_xlen == 64
3437
TEST_CASE(6, a4, 1, \
3538
li a0, 0x0000000000000001; \
3639
li a1, 0x8000000000000000; \
@@ -40,6 +43,7 @@ RVTEST_CODE_BEGIN
4043
)
4144

4245
TEST_CASE(7, a5, 0, lw a5, 0(a3))
46+
#endif
4347

4448
TEST_PASSFAIL
4549

0 commit comments

Comments
 (0)