| OLD | NEW |
| 1 //===--- Tools.cpp - Tools Implementations --------------------------------===// | 1 //===--- Tools.cpp - Tools Implementations --------------------------------===// |
| 2 // | 2 // |
| 3 // The LLVM Compiler Infrastructure | 3 // The LLVM Compiler Infrastructure |
| 4 // | 4 // |
| 5 // This file is distributed under the University of Illinois Open Source | 5 // This file is distributed under the University of Illinois Open Source |
| 6 // License. See LICENSE.TXT for details. | 6 // License. See LICENSE.TXT for details. |
| 7 // | 7 // |
| 8 //===----------------------------------------------------------------------===// | 8 //===----------------------------------------------------------------------===// |
| 9 | 9 |
| 10 #include "Tools.h" | 10 #include "Tools.h" |
| (...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 744 (Triple.getOS() == llvm::Triple::UnknownOS && | 744 (Triple.getOS() == llvm::Triple::UnknownOS && |
| 745 Triple.getObjectFormat() == llvm::Triple::MachO) || | 745 Triple.getObjectFormat() == llvm::Triple::MachO) || |
| 746 StringRef(CPUName).startswith("cortex-m")) { | 746 StringRef(CPUName).startswith("cortex-m")) { |
| 747 ABIName = "aapcs"; | 747 ABIName = "aapcs"; |
| 748 } else { | 748 } else { |
| 749 ABIName = "apcs-gnu"; | 749 ABIName = "apcs-gnu"; |
| 750 } | 750 } |
| 751 } else if (Triple.isOSWindows()) { | 751 } else if (Triple.isOSWindows()) { |
| 752 // FIXME: this is invalid for WindowsCE | 752 // FIXME: this is invalid for WindowsCE |
| 753 ABIName = "aapcs"; | 753 ABIName = "aapcs"; |
| 754 } else if (Triple.isOSNaCl()) { // @LOCALMOD | |
| 755 ABIName = "aapcs-linux"; | |
| 756 } else { | 754 } else { |
| 757 // Select the default based on the platform. | 755 // Select the default based on the platform. |
| 758 switch(Triple.getEnvironment()) { | 756 switch(Triple.getEnvironment()) { |
| 759 case llvm::Triple::Android: | 757 case llvm::Triple::Android: |
| 760 case llvm::Triple::GNUEABI: | 758 case llvm::Triple::GNUEABI: |
| 761 case llvm::Triple::GNUEABIHF: | 759 case llvm::Triple::GNUEABIHF: |
| 762 ABIName = "aapcs-linux"; | 760 ABIName = "aapcs-linux"; |
| 763 break; | 761 break; |
| 764 case llvm::Triple::EABIHF: | 762 case llvm::Triple::EABIHF: |
| 765 case llvm::Triple::EABI: | 763 case llvm::Triple::EABI: |
| (...skipping 7403 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 8169 | 8167 |
| 8170 ExceptionSettings EH = exceptionSettings(Args, getToolChain().getTriple()); | 8168 ExceptionSettings EH = exceptionSettings(Args, getToolChain().getTriple()); |
| 8171 if (EH.ShouldUseExceptionTables) | 8169 if (EH.ShouldUseExceptionTables) |
| 8172 CmdArgs.push_back("-fexceptions"); | 8170 CmdArgs.push_back("-fexceptions"); |
| 8173 | 8171 |
| 8174 AddLinkerInputs(getToolChain(), Inputs, Args, CmdArgs); | 8172 AddLinkerInputs(getToolChain(), Inputs, Args, CmdArgs); |
| 8175 | 8173 |
| 8176 const char *Exec = Args.MakeArgString(getToolChain().GetProgramPath("xcc")); | 8174 const char *Exec = Args.MakeArgString(getToolChain().GetProgramPath("xcc")); |
| 8177 C.addCommand(new Command(JA, *this, Exec, CmdArgs)); | 8175 C.addCommand(new Command(JA, *this, Exec, CmdArgs)); |
| 8178 } | 8176 } |
| OLD | NEW |