[PATCH] D54093: [RISCV] Lower inline asm constraints I, J & K for RISC-V

James Clarke via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Fri Feb 15 05:56:32 PST 2019


jrtc27 added a comment.

In D54093#1397875 <https://reviews.llvm.org/D54093#1397875>, @asb wrote:

> Did you check the behaviour of 'J' vs GCC, because for e.g. `asm volatile ("sub a0, a0, %0" :: "J"(0));` I seem to see it using the integer 0 rather than the zero register?
>
> I think it would be worth adding RV64I check lines to inline-asm.ll too.


Yes, the current behaviour of `J` in this patch is wrong, it should always be the constant integer `0`, rather than the `x0`/`zero` register.


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D54093/new/

https://reviews.llvm.org/D54093





More information about the llvm-commits mailing list