[PATCH] D16599: ELF: Define another entry point.

Rafael Ávila de Espíndola via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 26 14:39:36 PST 2016


rafael accepted this revision.
rafael added a comment.
This revision is now accepted and ready to land.

Would it be too bad to use the windows version for unix too for now to avoid the #ifdef?

This is fine from the perspective of providing a safe api with a really small code cost on our side. Please get a LGTM too from an intended user.

Thanks a lot for doing this.


================
Comment at: ELF/Driver.h:28
@@ +27,3 @@
+// The other entry point of the ELF linker which is guaranteed to return.
+bool main(llvm::ArrayRef<const char *> Args, raw_ostream &Diag);
+
----------------
Maybe call this one link and the old link becomes linkOrFali?

================
Comment at: ELF/DriverUtils.cpp:146
@@ +145,3 @@
+    // We are in the child. Plumb stdout and stderr to the pipe.
+    close(Fd[0]);
+    close(0);
----------------
both close and dup can fail, not sure if you care in here.


http://reviews.llvm.org/D16599





More information about the llvm-commits mailing list