Переглянути джерело

[WebAssembly] Only call llvm::value::dump() in debug build.

This fixes compile error in r336759. llvm::value::dump is not available
in released build.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@336770 91177308-0d34-0410-b5e6-96231b3b80d8
Eric Liu 7 роки тому
батько
коміт
d07522f042

+ 2 - 0
lib/Target/WebAssembly/WebAssemblyAddMissingPrototypes.cpp

@@ -123,7 +123,9 @@ bool WebAssemblyAddMissingPrototypes::runOnModule(Module &M) {
         Replacements.emplace_back(&F, NewF);
       } else {
         dbgs() << *U.getUser()->getType() << "\n";
+#ifndef NDEBUG
         U.getUser()->dump();
+#endif
         report_fatal_error(
             "unexpected use of prototypeless function: " + F.getName() + "\n");
       }