aboutsummaryrefslogtreecommitdiff
path: root/Driver/Targets.cpp
AgeCommit message (Collapse)Author
2007-12-12Moved construction of TargetInfo objects out of the DriverTed Kremenek
and into the "Basic" library. TargetInfo objects are now constructed from triples by calling the static method TargetInfo::CreateTargetInfo. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44940 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-11Mega-patch: ripped SourceManager out of Diagnostic/DiagnosticClient. NowTed Kremenek
SourceManager is passed by reference, allowing the SourceManager to be associated with a specific translation unit, and not the entire execution of the driver. Modified all users of Diagnostics to comply with this new interface. Integrated SourceManager as a member variable of TargetInfo. TargetInfo will eventually be associated with a single translation unit (just like SourceManager). Made the SourceManager reference in ASTContext private. Provided accessor getSourceManager() for clients to use instead. Modified clients to comply with new interface. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44878 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-11properly namespacify.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44845 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-09Move target specific builtin IDs to TargetBuiltins.h so that they can be ↵Anders Carlsson
used by CGBuiltin.cpp git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44748 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-08Add getTargetPrefix to TargetInfo, to be used with target specific intrinsics.Anders Carlsson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44712 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-05Modified: CreateTargetInfo(). Now takes Diagnostic* instead of Diagnostic&.Ted Kremenek
Modified: ctor of SerializationTest: Now takes LangOptions argument. We will eventually serialize this as well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44630 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-05I'm apparently the only sad lonely ppc user left :)Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44622 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-04Removed searching for "darwin" keyword in target triple. We don't really supportTed Kremenek
any alternative targets at this point other than "darwin," so we now default to Darwin targets (for now). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44572 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-03For target processing, on non-Darwin systems instead of using the host triple,Ted Kremenek
we default to "i386-apple-darwin". This is an interim solution. Removed processing of "linux" triples from Targets.cpp, since we don't have any sensical Linux target support (yet). Cleaned up error processing of targets; added better diagnostics. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44560 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-03Implemented initial support for "-triple" option to the clang driver. ThisTed Kremenek
replaces the functionality previously provided by just "-arch" (which is still supported but has different semantics). The new behavior is as follows: (1) If the user does not specify -triple: (a) If no -arch options are specified, the target triple used is the host triple (in llvm/Config/config.h). (b) If one or more -arch's are specified (and no -triple), then there is one triple for each -arch, where the specified arch is substituted for the arch in the host triple. Example: host triple = i686-apple-darwin9 command: clang -arch ppc -arch ppc64 ... triples used: ppc-apple-darwin9 ppc64-apple-darwin9 (2) The user does specify a -triple (only one allowed): (a) If no -arch options are specified, the triple specified by -triple is used. E.g clang -triple i686-apple-darwin9 (b) If one or more -arch options are specified, then the triple specified by -triple is used as the primary target, and the arch's specified by -arch are used to create secondary targets. For example: clang -triple i686-apple-darwin9 -arch ppc -arch ppc64 has the following targets: i686-apple-darwin9 (primary target) ppc-apple-darwin9 ppc64-apple-darwin9 Other changes related to the changes to the driver: - TargetInfoImpl now includes the triple string. - TargetInfo::getTargetTriple returns the triple for its primary target. - test case test/Parser/portability.c has been updated because "-arch linux" is no longer valid ("linux" is an OS, not an arch); instead we use a bogus architecture "bogusW16W16" where WCharWidth=16 and WCharAlign=16. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44551 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-27Add more semantic analysis for inline asm statements.Anders Carlsson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44349 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-25Forgot some X86 registersAnders Carlsson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44309 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-24Add tables for GCC register names and aliases. This will be used for inline asmAnders Carlsson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@44308 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-17fix problems with test/sema/Cocoa.m etc on non-apple machines.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@43067 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-13Add __builtin_va_list definitions for x86_64 and ppc64.Anders Carlsson
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@42943 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-06speed up clang startup another 28% by avoiding std::vector<std::string> Chris Lattner
for holding builtin target-specific macros. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@42689 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-15non-apple targets should be like i386, not the mythical, bogus, linux target.Chris Lattner
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@39865 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-14A significant refactoring of the type size stuff to also Chris Lattner
compute type alignment. This info is needed for struct layout. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@39850 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-11Stage two of getting CFE top correct.Reid Spencer
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@39734 91177308-0d34-0410-b5e6-96231b3b80d8