[PATCH] D53740: [globalisel][irtranslator] Verify that DILocations aren't lost in translation

Amara Emerson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Oct 29 06:32:13 PDT 2018


aemerson added inline comments.


================
Comment at: lib/CodeGen/GlobalISel/IRTranslator.cpp:124
+           "Inserted instruction without a current MI");
+    LLVM_DEBUG(dbgs() << "Checking DILocation from " << *CurrInst
+                      << " was copied to " << MI);
----------------
I think this debug print is probably unnecessary given it'll print for every instruction translated (and without ASSERTIONS it won't actually do anything).


================
Comment at: lib/CodeGen/GlobalISel/IRTranslator.cpp:1742
+#ifndef NDEBUG
+    Verifier.setCurrentInst(nullptr);
+#endif // ifndef NDEBUG
----------------
This is unnecessary as Verifier goes out of scope immediately after?


Repository:
  rL LLVM

https://reviews.llvm.org/D53740





More information about the llvm-commits mailing list