[PATCH] D23542: [LTO] Introduce an Output class to wrap the output stream creation (NFC)

Teresa Johnson via llvm-commits llvm-commits at lists.llvm.org
Tue Aug 16 12:43:24 PDT 2016


tejohnson added a comment.

Building gold-plugin exposed a couple issues, one of which will require some changes to interface.


================
Comment at: tools/gold/gold-plugin.cpp:657
@@ -658,3 +656,3 @@
     std::error_code EC =
         sys::fs::createTemporaryFile("lto-llvm", "o", FD, NewFilename);
     if (EC)
----------------
FD was not declared, which exposes an issue - the interface needs to handle this being a temp file that we create here.

================
Comment at: tools/gold/gold-plugin.cpp:732
@@ +731,3 @@
+      message(LDPL_FATAL, "Could not open file: %s", EC.message().c_str());
+    return llvm::make_unique<llvm::raw_fd_ostream>(FD, true)
+  }
----------------
Needs a ';' at end


https://reviews.llvm.org/D23542





More information about the llvm-commits mailing list