riscv64: Fix VarHandle.compareAndSet intrinsics.

And enable a test that exposes the bug even for `--ndebug`.

Test: testrunner.py --target --64 --ndebug --optimizing
Bug: 283082089
Bug: 224733324
Change-Id: I34ba41cdf905c2da703f77739758450d8d305bf1
2 files changed