On 6/11/25 2:47 AM, Umesh Kalappa wrote:
gcc/ChangeLog:

         * config/riscv/sync.md (lrsc_atomic_exchange<mode>):
         Use the scratch reg for rd.

gcc/testsuite/ChangeLog:

         * gcc.target/riscv/zalrsc.c: New test.
I was about to push this to the trunk when I realized the test isn't really all that useful.

The net of this change is we get to drop the unnecessary mv. But the test just verifies that we have a lr/sc pair, which was true both before and after this change.

Is it possible to improve the test such that it fails without this change and passes with this change?

Thanks,
jeff

Reply via email to