[cfe-commits] r149337 - in /cfe/trunk: include/clang/Driver/ToolChain.h lib/Driver/Driver.cpp lib/Driver/ToolChain.cpp lib/Driver/ToolChains.cpp lib/Driver/ToolChains.h lib/Driver/WindowsToolChain.cpp test/Driver/prefixed-tools.c test/Driver/prefixed-tools.c-helper/x86_64--linux-as test/Driver/prefixed-tools.c-helper/x86_64--linux-ld

Chandler Carruth chandlerc at gmail.com
Mon Jan 30 18:21:20 PST 2012


Author: chandlerc
Date: Mon Jan 30 20:21:20 2012
New Revision: 149337

URL: http://llvm.org/viewvc/llvm-project?rev=149337&view=rev
Log:
Revert r149083 which is not the direction we're going in the Clang
driver based on discussions with Doug Gregor. There are several issues:
1) The patch was not reviewed prior to commit and there were review comments.
2) The design of the functionality (triple-prefixed tool invocation)
   isn't the design we want for Clang going forward: it focuses on the
   "user triple" rather than on the "toolchain triple", and forces that
   bit of state into the API of every single toolchain instead of
   handling it automatically in the common base classes.
3) The tests provided are not stable. They fail on a few Linux variants
   (Gentoo among them) and on mingw32 and some other environments.

I *am* interested in the Clang driver being able to invoke
triple-prefixed tools, but we need to design that feature the right way.
This patch just extends the previous hack without fixing the underlying
problems with it. I'm working on a new design for this that I will mail
for review by tomorrow.

I am aware that this removes functionality that NetBSD relies on, but
this is ToT, not a release. This functionality hasn't been properly
designed, implemented, and tested yet. We can't "regress" until we get
something that really works, both with the immediate use cases and with
long term maintenance of the Clang driver.

For reference, the original commit log:
Keep track of the original target the user specified before
normalization. This used to be captured in DefaultTargetTriple and is
used for the (optional) $triple-$tool lookup for cross-compilation.
Do this properly by making it an attribute of the toolchain and use it
in combination with the computed triple as index for the toolchain
lookup.

Removed:
    cfe/trunk/test/Driver/prefixed-tools.c
    cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-as
    cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-ld
Modified:
    cfe/trunk/include/clang/Driver/ToolChain.h
    cfe/trunk/lib/Driver/Driver.cpp
    cfe/trunk/lib/Driver/ToolChain.cpp
    cfe/trunk/lib/Driver/ToolChains.cpp
    cfe/trunk/lib/Driver/ToolChains.h
    cfe/trunk/lib/Driver/WindowsToolChain.cpp

Modified: cfe/trunk/include/clang/Driver/ToolChain.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/include/clang/Driver/ToolChain.h?rev=149337&r1=149336&r2=149337&view=diff
==============================================================================
--- cfe/trunk/include/clang/Driver/ToolChain.h (original)
+++ cfe/trunk/include/clang/Driver/ToolChain.h Mon Jan 30 20:21:20 2012
@@ -46,9 +46,6 @@
 private:
   const Driver &D;
   const llvm::Triple Triple;
-  /// The target triple originally requested by the user
-  /// before modifications due to -m32 and without normalization.
-  const std::string UserTriple;
 
   /// The list of toolchain specific path prefixes to search for
   /// files.
@@ -59,7 +56,7 @@
   path_list ProgramPaths;
 
 protected:
-  ToolChain(const Driver &D, const llvm::Triple &T, const std::string &UT);
+  ToolChain(const Driver &D, const llvm::Triple &T);
 
   /// \name Utilities for implementing subclasses.
   ///@{
@@ -90,9 +87,6 @@
   std::string getTripleString() const {
     return Triple.getTriple();
   }
-  const std::string &getUserTriple() const {
-    return UserTriple;
-  }
 
   path_list &getFilePaths() { return FilePaths; }
   const path_list &getFilePaths() const { return FilePaths; }

Modified: cfe/trunk/lib/Driver/Driver.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/Driver.cpp?rev=149337&r1=149336&r2=149337&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/Driver.cpp (original)
+++ cfe/trunk/lib/Driver/Driver.cpp Mon Jan 30 20:21:20 2012
@@ -1507,7 +1507,7 @@
 
 std::string Driver::GetProgramPath(const char *Name, const ToolChain &TC,
                                    bool WantFile) const {
-  std::string TargetSpecificExecutable(TC.getUserTriple() + "-" + Name);
+  std::string TargetSpecificExecutable(DefaultTargetTriple + "-" + Name);
   // Respect a limited subset of the '-Bprefix' functionality in GCC by
   // attempting to use this prefix when lokup up program paths.
   for (Driver::prefix_list::const_iterator it = PrefixDirs.begin(),
@@ -1574,10 +1574,13 @@
 ///
 /// This routine provides the logic to compute a target triple from various
 /// args passed to the driver and the default triple string.
-static llvm::Triple computeTargetTriple(StringRef TargetTriple,
+static llvm::Triple computeTargetTriple(StringRef DefaultTargetTriple,
                                         const ArgList &Args,
                                         StringRef DarwinArchName) {
-  llvm::Triple Target(llvm::Triple::normalize(TargetTriple));
+  if (const Arg *A = Args.getLastArg(options::OPT_target))
+    DefaultTargetTriple = A->getValue(Args);
+
+  llvm::Triple Target(llvm::Triple::normalize(DefaultTargetTriple));
 
   // Handle Darwin-specific options available here.
   if (Target.isOSDarwin()) {
@@ -1624,19 +1627,14 @@
 
 const ToolChain &Driver::getToolChain(const ArgList &Args,
                                       StringRef DarwinArchName) const {
-  std::string TargetTriple(DefaultTargetTriple);
-  if (const Arg *A = Args.getLastArg(options::OPT_target))
-    TargetTriple = A->getValue(Args);
-
-  llvm::Triple Target = computeTargetTriple(TargetTriple, Args, DarwinArchName);
-
-  std::string TargetIndex = TargetTriple + "::" + Target.str();
+  llvm::Triple Target = computeTargetTriple(DefaultTargetTriple, Args,
+                                            DarwinArchName);
 
-  ToolChain *&TC = ToolChains[TargetIndex];
+  ToolChain *&TC = ToolChains[Target.str()];
   if (!TC) {
     switch (Target.getOS()) {
     case llvm::Triple::AuroraUX:
-      TC = new toolchains::AuroraUX(*this, Target, TargetTriple);
+      TC = new toolchains::AuroraUX(*this, Target);
       break;
     case llvm::Triple::Darwin:
     case llvm::Triple::MacOSX:
@@ -1645,44 +1643,44 @@
           Target.getArch() == llvm::Triple::x86_64 ||
           Target.getArch() == llvm::Triple::arm ||
           Target.getArch() == llvm::Triple::thumb)
-        TC = new toolchains::DarwinClang(*this, Target, TargetTriple);
+        TC = new toolchains::DarwinClang(*this, Target);
       else
-        TC = new toolchains::Darwin_Generic_GCC(*this, Target, TargetTriple);
+        TC = new toolchains::Darwin_Generic_GCC(*this, Target);
       break;
     case llvm::Triple::DragonFly:
-      TC = new toolchains::DragonFly(*this, Target, TargetTriple);
+      TC = new toolchains::DragonFly(*this, Target);
       break;
     case llvm::Triple::OpenBSD:
-      TC = new toolchains::OpenBSD(*this, Target, TargetTriple);
+      TC = new toolchains::OpenBSD(*this, Target);
       break;
     case llvm::Triple::NetBSD:
-      TC = new toolchains::NetBSD(*this, Target, TargetTriple);
+      TC = new toolchains::NetBSD(*this, Target);
       break;
     case llvm::Triple::FreeBSD:
-      TC = new toolchains::FreeBSD(*this, Target, TargetTriple);
+      TC = new toolchains::FreeBSD(*this, Target);
       break;
     case llvm::Triple::Minix:
-      TC = new toolchains::Minix(*this, Target, TargetTriple);
+      TC = new toolchains::Minix(*this, Target);
       break;
     case llvm::Triple::Linux:
       if (Target.getArch() == llvm::Triple::hexagon)
-        TC = new toolchains::Hexagon_TC(*this, Target, TargetTriple);
+        TC = new toolchains::Hexagon_TC(*this, Target);
       else
-        TC = new toolchains::Linux(*this, Target, TargetTriple);
+        TC = new toolchains::Linux(*this, Target);
       break;
     case llvm::Triple::Win32:
-      TC = new toolchains::Windows(*this, Target, TargetTriple);
+      TC = new toolchains::Windows(*this, Target);
       break;
     case llvm::Triple::MinGW32:
       // FIXME: We need a MinGW toolchain. Fallthrough for now.
     default:
       // TCE is an OSless target
       if (Target.getArchName() == "tce") {
-        TC = new toolchains::TCEToolChain(*this, Target, TargetTriple);
+        TC = new toolchains::TCEToolChain(*this, Target);
         break;
       }
 
-      TC = new toolchains::Generic_GCC(*this, Target, TargetTriple);
+      TC = new toolchains::Generic_GCC(*this, Target);
       break;
     }
   }

Modified: cfe/trunk/lib/Driver/ToolChain.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChain.cpp?rev=149337&r1=149336&r2=149337&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChain.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChain.cpp Mon Jan 30 20:21:20 2012
@@ -20,9 +20,8 @@
 using namespace clang::driver;
 using namespace clang;
 
-ToolChain::ToolChain(const Driver &D, const llvm::Triple &T,
-                     const std::string &UserTriple)
-  : D(D), Triple(T), UserTriple(UserTriple) {
+ToolChain::ToolChain(const Driver &D, const llvm::Triple &T)
+  : D(D), Triple(T) {
 }
 
 ToolChain::~ToolChain() {

Modified: cfe/trunk/lib/Driver/ToolChains.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains.cpp?rev=149337&r1=149336&r2=149337&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains.cpp (original)
+++ cfe/trunk/lib/Driver/ToolChains.cpp Mon Jan 30 20:21:20 2012
@@ -45,9 +45,8 @@
 
 /// Darwin - Darwin tool chain for i386 and x86_64.
 
-Darwin::Darwin(const Driver &D, const llvm::Triple& Triple,
-               const std::string &UserTriple)
-  : ToolChain(D, Triple, UserTriple), TargetInitialized(false),
+Darwin::Darwin(const Driver &D, const llvm::Triple& Triple)
+  : ToolChain(D, Triple), TargetInitialized(false),
     ARCRuntimeForSimulator(ARCSimulator_None),
     LibCXXForSimulator(LibCXXSimulator_None)
 {
@@ -251,9 +250,8 @@
 }
 
 
-DarwinClang::DarwinClang(const Driver &D, const llvm::Triple& Triple,
-                         const std::string &UserTriple)
-  : Darwin(D, Triple, UserTriple)
+DarwinClang::DarwinClang(const Driver &D, const llvm::Triple& Triple)
+  : Darwin(D, Triple)
 {
   getProgramPaths().push_back(getDriver().getInstalledDir());
   if (getDriver().getInstalledDir() != getDriver().Dir)
@@ -1389,9 +1387,8 @@
   }
 }
 
-Generic_GCC::Generic_GCC(const Driver &D, const llvm::Triple& Triple,
-                         const std::string &UserTriple)
-  : ToolChain(D, Triple, UserTriple), GCCInstallation(getDriver(), Triple) {
+Generic_GCC::Generic_GCC(const Driver &D, const llvm::Triple& Triple)
+  : ToolChain(D, Triple), GCCInstallation(getDriver(), Triple) {
   getProgramPaths().push_back(getDriver().getInstalledDir());
   if (getDriver().getInstalledDir() != getDriver().Dir)
     getProgramPaths().push_back(getDriver().Dir);
@@ -1461,9 +1458,8 @@
 }
 /// Hexagon Toolchain
 
-Hexagon_TC::Hexagon_TC(const Driver &D, const llvm::Triple& Triple,
-                       const std::string &UserTriple)
-  : ToolChain(D, Triple, UserTriple) {
+Hexagon_TC::Hexagon_TC(const Driver &D, const llvm::Triple& Triple)
+  : ToolChain(D, Triple) {
   getProgramPaths().push_back(getDriver().getInstalledDir());
   if (getDriver().getInstalledDir() != getDriver().Dir.c_str())
     getProgramPaths().push_back(getDriver().Dir);
@@ -1532,9 +1528,8 @@
 /// all subcommands. See http://tce.cs.tut.fi for our peculiar target.
 /// Currently does not support anything else but compilation.
 
-TCEToolChain::TCEToolChain(const Driver &D, const llvm::Triple& Triple,
-                          const std::string &UserTriple)
-  : ToolChain(D, Triple, UserTriple) {
+TCEToolChain::TCEToolChain(const Driver &D, const llvm::Triple& Triple)
+  : ToolChain(D, Triple) {
   // Path mangling to find libexec
   std::string Path(getDriver().Dir);
 
@@ -1586,9 +1581,8 @@
 
 /// OpenBSD - OpenBSD tool chain which can call as(1) and ld(1) directly.
 
-OpenBSD::OpenBSD(const Driver &D, const llvm::Triple& Triple,
-                 const std::string &UserTriple)
-  : Generic_ELF(D, Triple, UserTriple) {
+OpenBSD::OpenBSD(const Driver &D, const llvm::Triple& Triple)
+  : Generic_ELF(D, Triple) {
   getFilePaths().push_back(getDriver().Dir + "/../lib");
   getFilePaths().push_back("/usr/lib");
 }
@@ -1627,9 +1621,8 @@
 
 /// FreeBSD - FreeBSD tool chain which can call as(1) and ld(1) directly.
 
-FreeBSD::FreeBSD(const Driver &D, const llvm::Triple& Triple,
-                 const std::string &UserTriple)
-  : Generic_ELF(D, Triple, UserTriple) {
+FreeBSD::FreeBSD(const Driver &D, const llvm::Triple& Triple)
+  : Generic_ELF(D, Triple) {
 
   // When targeting 32-bit platforms, look for '/usr/lib32/crt1.o' and fall
   // back to '/usr/lib' if it doesn't exist.
@@ -1674,9 +1667,8 @@
 
 /// NetBSD - NetBSD tool chain which can call as(1) and ld(1) directly.
 
-NetBSD::NetBSD(const Driver &D, const llvm::Triple& Triple,
-               const std::string &UserTriple)
-  : Generic_ELF(D, Triple, UserTriple) {
+NetBSD::NetBSD(const Driver &D, const llvm::Triple& Triple)
+  : Generic_ELF(D, Triple) {
 
   if (getDriver().UseStdLib) {
     // When targeting a 32-bit platform, try the special directory used on
@@ -1725,9 +1717,8 @@
 
 /// Minix - Minix tool chain which can call as(1) and ld(1) directly.
 
-Minix::Minix(const Driver &D, const llvm::Triple& Triple,
-             const std::string &UserTriple)
-  : Generic_ELF(D, Triple, UserTriple) {
+Minix::Minix(const Driver &D, const llvm::Triple& Triple)
+  : Generic_ELF(D, Triple) {
   getFilePaths().push_back(getDriver().Dir + "/../lib");
   getFilePaths().push_back("/usr/lib");
 }
@@ -1757,9 +1748,8 @@
 
 /// AuroraUX - AuroraUX tool chain which can call as(1) and ld(1) directly.
 
-AuroraUX::AuroraUX(const Driver &D, const llvm::Triple& Triple,
-                   const std::string &UserTriple)
-  : Generic_GCC(D, Triple, UserTriple) {
+AuroraUX::AuroraUX(const Driver &D, const llvm::Triple& Triple)
+  : Generic_GCC(D, Triple) {
 
   getProgramPaths().push_back(getDriver().getInstalledDir());
   if (getDriver().getInstalledDir() != getDriver().Dir)
@@ -1974,9 +1964,8 @@
   if (llvm::sys::fs::exists(Path)) Paths.push_back(Path.str());
 }
 
-Linux::Linux(const Driver &D, const llvm::Triple &Triple,
-             const std::string &UserTriple)
-  : Generic_ELF(D, Triple, UserTriple) {
+Linux::Linux(const Driver &D, const llvm::Triple &Triple)
+  : Generic_ELF(D, Triple) {
   llvm::Triple::ArchType Arch = Triple.getArch();
   const std::string &SysRoot = getDriver().SysRoot;
 
@@ -2284,9 +2273,8 @@
 
 /// DragonFly - DragonFly tool chain which can call as(1) and ld(1) directly.
 
-DragonFly::DragonFly(const Driver &D, const llvm::Triple& Triple,
-                     const std::string &UserTriple)
-  : Generic_ELF(D, Triple, UserTriple) {
+DragonFly::DragonFly(const Driver &D, const llvm::Triple& Triple)
+  : Generic_ELF(D, Triple) {
 
   // Path mangling to find libexec
   getProgramPaths().push_back(getDriver().getInstalledDir());

Modified: cfe/trunk/lib/Driver/ToolChains.h
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/ToolChains.h?rev=149337&r1=149336&r2=149337&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/ToolChains.h (original)
+++ cfe/trunk/lib/Driver/ToolChains.h Mon Jan 30 20:21:20 2012
@@ -119,8 +119,7 @@
   mutable llvm::DenseMap<unsigned, Tool*> Tools;
 
 public:
-  Generic_GCC(const Driver &D, const llvm::Triple& Triple,
-              const std::string &UserTriple);
+  Generic_GCC(const Driver &D, const llvm::Triple& Triple);
   ~Generic_GCC();
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
@@ -151,8 +150,7 @@
   mutable llvm::DenseMap<unsigned, Tool*> Tools;
 
 public:
-  Hexagon_TC(const Driver &D, const llvm::Triple& Triple,
-             const std::string &UserTriple);
+  Hexagon_TC(const Driver &D, const llvm::Triple& Triple);
   ~Hexagon_TC();
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
@@ -214,8 +212,7 @@
   void AddDeploymentTarget(DerivedArgList &Args) const;
 
 public:
-  Darwin(const Driver &D, const llvm::Triple& Triple,
-         const std::string &UserTriple);
+  Darwin(const Driver &D, const llvm::Triple& Triple);
   ~Darwin();
 
   std::string ComputeEffectiveClangTriple(const ArgList &Args,
@@ -398,8 +395,7 @@
   void AddGCCLibexecPath(unsigned darwinVersion);
 
 public:
-  DarwinClang(const Driver &D, const llvm::Triple& Triple,
-              const std::string &UserTriple);
+  DarwinClang(const Driver &D, const llvm::Triple& Triple);
 
   /// @name Darwin ToolChain Implementation
   /// {
@@ -426,9 +422,8 @@
 /// Darwin_Generic_GCC - Generic Darwin tool chain using gcc.
 class LLVM_LIBRARY_VISIBILITY Darwin_Generic_GCC : public Generic_GCC {
 public:
-  Darwin_Generic_GCC(const Driver &D, const llvm::Triple& Triple,
-                     const std::string &UserTriple)
-    : Generic_GCC(D, Triple, UserTriple) {}
+  Darwin_Generic_GCC(const Driver &D, const llvm::Triple& Triple)
+    : Generic_GCC(D, Triple) {}
 
   std::string ComputeEffectiveClangTriple(const ArgList &Args,
                                           types::ID InputType) const;
@@ -439,9 +434,8 @@
 class LLVM_LIBRARY_VISIBILITY Generic_ELF : public Generic_GCC {
   virtual void anchor();
 public:
-  Generic_ELF(const Driver &D, const llvm::Triple& Triple,
-              const std::string &UserTriple)
-    : Generic_GCC(D, Triple, UserTriple) {}
+  Generic_ELF(const Driver &D, const llvm::Triple& Triple)
+    : Generic_GCC(D, Triple) {}
 
   virtual bool IsIntegratedAssemblerDefault() const {
     // Default integrated assembler to on for x86.
@@ -452,8 +446,7 @@
 
 class LLVM_LIBRARY_VISIBILITY AuroraUX : public Generic_GCC {
 public:
-  AuroraUX(const Driver &D, const llvm::Triple& Triple,
-           const std::string &UserTriple);
+  AuroraUX(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;
@@ -461,8 +454,7 @@
 
 class LLVM_LIBRARY_VISIBILITY OpenBSD : public Generic_ELF {
 public:
-  OpenBSD(const Driver &D, const llvm::Triple& Triple,
-          const std::string &UserTriple);
+  OpenBSD(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;
@@ -470,8 +462,7 @@
 
 class LLVM_LIBRARY_VISIBILITY FreeBSD : public Generic_ELF {
 public:
-  FreeBSD(const Driver &D, const llvm::Triple& Triple,
-          const std::string &UserTriple);
+  FreeBSD(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;
@@ -479,8 +470,7 @@
 
 class LLVM_LIBRARY_VISIBILITY NetBSD : public Generic_ELF {
 public:
-  NetBSD(const Driver &D, const llvm::Triple& Triple,
-         const std::string &UserTriple);
+  NetBSD(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;
@@ -488,8 +478,7 @@
 
 class LLVM_LIBRARY_VISIBILITY Minix : public Generic_ELF {
 public:
-  Minix(const Driver &D, const llvm::Triple& Triple,
-        const std::string &UserTriple);
+  Minix(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;
@@ -497,8 +486,7 @@
 
 class LLVM_LIBRARY_VISIBILITY DragonFly : public Generic_ELF {
 public:
-  DragonFly(const Driver &D, const llvm::Triple& Triple,
-            const std::string &UserTriple);
+  DragonFly(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;
@@ -506,8 +494,7 @@
 
 class LLVM_LIBRARY_VISIBILITY Linux : public Generic_ELF {
 public:
-  Linux(const Driver &D, const llvm::Triple& Triple,
-        const std::string &UserTriple);
+  Linux(const Driver &D, const llvm::Triple& Triple);
 
   virtual bool HasNativeLLVMSupport() const;
 
@@ -533,8 +520,7 @@
 /// all subcommands. See http://tce.cs.tut.fi for our peculiar target.
 class LLVM_LIBRARY_VISIBILITY TCEToolChain : public ToolChain {
 public:
-  TCEToolChain(const Driver &D, const llvm::Triple& Triple,
-               const std::string &UserTriple);
+  TCEToolChain(const Driver &D, const llvm::Triple& Triple);
   ~TCEToolChain();
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
@@ -553,8 +539,7 @@
   mutable llvm::DenseMap<unsigned, Tool*> Tools;
 
 public:
-  Windows(const Driver &D, const llvm::Triple& Triple,
-          const std::string &UserTriple);
+  Windows(const Driver &D, const llvm::Triple& Triple);
 
   virtual Tool &SelectTool(const Compilation &C, const JobAction &JA,
                            const ActionList &Inputs) const;

Modified: cfe/trunk/lib/Driver/WindowsToolChain.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Driver/WindowsToolChain.cpp?rev=149337&r1=149336&r2=149337&view=diff
==============================================================================
--- cfe/trunk/lib/Driver/WindowsToolChain.cpp (original)
+++ cfe/trunk/lib/Driver/WindowsToolChain.cpp Mon Jan 30 20:21:20 2012
@@ -35,9 +35,8 @@
 using namespace clang::driver::toolchains;
 using namespace clang;
 
-Windows::Windows(const Driver &D, const llvm::Triple& Triple,
-                 const std::string &UserTriple)
-  : ToolChain(D, Triple, UserTriple) {
+Windows::Windows(const Driver &D, const llvm::Triple& Triple)
+  : ToolChain(D, Triple) {
 }
 
 Tool &Windows::SelectTool(const Compilation &C, const JobAction &JA,

Removed: cfe/trunk/test/Driver/prefixed-tools.c
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/prefixed-tools.c?rev=149336&view=auto
==============================================================================
--- cfe/trunk/test/Driver/prefixed-tools.c (original)
+++ cfe/trunk/test/Driver/prefixed-tools.c (removed)
@@ -1,18 +0,0 @@
-// RUN: env PATH=%s-helper %clang -no-integrated-as -target x86_64--linux %s -o - > %t.log
-// RUN: env PATH=%s-helper %clang -no-integrated-as -m32 -target x86_64--linux %s -o - >> %t.log
-// RUN: FileCheck -input-file %t.log %s
-
-// FIXME: It had failed on Win32 due to inability of executing shell scripts.
-// Still it fails even with mingw MSYS bash.
-// REQUIRES: shell
-
-// CHECK: x86_64--linux-as called
-// CHECK: x86_64--linux-ld called
-// CHECK: x86_64--linux-as called
-// CHECK: x86_64--linux-ld called
-
-int
-main(void)
-{
-  return 0;
-}

Removed: cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-as
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-as?rev=149336&view=auto
==============================================================================
--- cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-as (original)
+++ cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-as (removed)
@@ -1,2 +0,0 @@
-#!/bin/sh
-echo "x86_64--linux-as called"

Removed: cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-ld
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-ld?rev=149336&view=auto
==============================================================================
--- cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-ld (original)
+++ cfe/trunk/test/Driver/prefixed-tools.c-helper/x86_64--linux-ld (removed)
@@ -1,2 +0,0 @@
-#!/bin/sh
-echo "x86_64--linux-ld called"





More information about the cfe-commits mailing list