[PATCH] D25834: [MC] Make llvm-mc fail cleanly on invalid output asm variant.

Reid Kleckner via llvm-commits llvm-commits at lists.llvm.org
Fri Oct 28 13:12:59 PDT 2016


rnk added inline comments.


================
Comment at: tools/llvm-mc/llvm-mc.cpp:567-568
+    if (!IP) {
+      errs() << "error: invalid output assembly variant " << OutputAsmVariant
+             << " for target triple " << TheTriple.normalize() << "\n";
+      return 1;
----------------
I think this can fail for other reasons, such as the target not having an MCInstPrinter. I'd give a more generic error message, like "unable to create instruction printer for assembly variant N of target triple foo"


https://reviews.llvm.org/D25834





More information about the llvm-commits mailing list