[PATCH] D87234: [AMDGPU][MC] Improved diagnostic messages for invalid registers

Dmitry Preobrazhensky via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 8 16:41:45 PDT 2020


dp added inline comments.


================
Comment at: llvm/lib/Target/AMDGPU/AsmParser/AMDGPUAsmParser.cpp:2394
+  if (!subtargetHasRegister(*TRI, Reg)) {
+    if (Reg == AMDGPU::SGPR_NULL) {
+      Error(Loc, "'null' operand is not supported on this GPU");
----------------
arsenm wrote:
> Not sure why we would special case this one
I was not sure if null is a register. So the message "register not available on this GPU" looked a bit weird for null.

Do you think it looks ok? Please advise.


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

https://reviews.llvm.org/D87234



More information about the llvm-commits mailing list