[PATCH] D122924: [lld] Add version info to generic driver output

Keith Smiley via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Apr 4 21:09:42 PDT 2022


keith updated this revision to Diff 420374.
keith added a comment.
Herald added subscribers: aheejin, dschuff.

Improve formatting


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D122924/new/

https://reviews.llvm.org/D122924

Files:
  lld/tools/lld/lld.cpp


Index: lld/tools/lld/lld.cpp
===================================================================
--- lld/tools/lld/lld.cpp
+++ lld/tools/lld/lld.cpp
@@ -28,6 +28,7 @@
 #include "lld/Common/Driver.h"
 #include "lld/Common/ErrorHandler.h"
 #include "lld/Common/Memory.h"
+#include "lld/Common/Version.h"
 #include "llvm/ADT/STLExtras.h"
 #include "llvm/ADT/SmallVector.h"
 #include "llvm/ADT/StringSwitch.h"
@@ -156,9 +157,9 @@
     else if (f == Wasm)
       return lld::wasm::link;
     else
-      die("lld is a generic driver.\n"
-          "Invoke ld.lld (Unix), ld64.lld (macOS), lld-link (Windows), wasm-ld"
-          " (WebAssembly) instead");
+      die("lld is a generic driver. (" + getLLDVersion() +
+          ")\nInvoke ld.lld (Unix), ld64.lld (macOS), lld-link (Windows), "
+          "wasm-ld (WebAssembly) instead");
   }();
   // Run the driver. If an error occurs, false will be returned.
   bool r = link(args, stdoutOS, stderrOS, exitEarly, inTestOutputDisabled);


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D122924.420374.patch
Type: text/x-patch
Size: 984 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20220405/c5363c5c/attachment.bin>


More information about the llvm-commits mailing list