[PATCH] D53815: [TableGen] Better error checking for TIED_TO constraints.

Nicolai Hähnle via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Oct 31 03:28:09 PDT 2018


nhaehnle added a comment.

Yay for better error messages! One comment about unfortunate variable naming...



================
Comment at: utils/TableGen/CodeGenInstruction.cpp:262-269
+  if (SrcOp.first >= Ops.NumDefs)
+    PrintFatalError(
+      Rec->getLoc(), "Input operands '" + SrcOpName + "' and '" + DestOpName +
+      "' of '" + Rec->getName() + "' cannot be tied!");
+  if (DestOp.first < Ops.NumDefs)
+    PrintFatalError(
+      Rec->getLoc(), "Output operands '" + SrcOpName + "' and '" + DestOpName +
----------------
The naming of SrcOp and DestOp should be reversed. It's quite confusing as-is ;)


Repository:
  rL LLVM

https://reviews.llvm.org/D53815





More information about the llvm-commits mailing list