Closed feathertw closed 2 years ago
The intent of those macros was to cause the test to pass if run with the wrong XLEN. This way, it's possible to run all tests without knowing the target's XLEN. I can understand why you'd find this behavior surprising, but it is doing what it's designed to do.
I understand. Thank you for replying.
I am studying riscv-test and I found that
CHECK_XLEN
inenv/p/riscv_test.h
is weird.I am testing it on spike-riscv64. When I use
# define CHECK_XLEN li a0, 1; slli a0, a0, 31; bltz a0, 1f; RVTEST_PASS; 1:
(this is for riscv32) to test, it still pass. but I thought it should fail.I am doing some fix, I think this will make the code better