[PATCH] D13642: [Bugpoint] Allow fallback to clang

Davide Italiano via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 13 17:48:18 PDT 2015


davide removed rL LLVM as the repository for this revision.
davide updated this revision to Diff 37305.
davide added a comment.

I think your idea is much better, thanks.


http://reviews.llvm.org/D13642

Files:
  tools/bugpoint/ExecutionDriver.cpp

Index: tools/bugpoint/ExecutionDriver.cpp
===================================================================
--- tools/bugpoint/ExecutionDriver.cpp
+++ tools/bugpoint/ExecutionDriver.cpp
@@ -124,7 +124,7 @@
                cl::ZeroOrMore, cl::PositionalEatsArgs);
 
   cl::opt<std::string>
-  GCCBinary("gcc", cl::init("gcc"),
+  GCCBinary("gcc", cl::init(""),
               cl::desc("The gcc binary to use. (default 'gcc')"));
 
   cl::list<std::string>
@@ -148,6 +148,10 @@
   SafeInterpreter = nullptr;
   std::string Message;
 
+  // Try to fall-back to clang if the user didn't pass GCC as option.
+  if (GCCBinary == "")
+    GCCBinary = "clang";
+
   switch (InterpreterSel) {
   case AutoPick:
     if (!Interpreter) {


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D13642.37305.patch
Type: text/x-patch
Size: 729 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20151014/3f7cc538/attachment.bin>


More information about the llvm-commits mailing list