bb1b797d2e432293563747bd9704b22cf0787061 |
|
04-Aug-2013 |
Timur Iskhodzhanov <timurrrr@google.com> |
Emit the constructor for abstract classes when using -cxx-abi microsoft, fixes PR16735 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@187709 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a4130baad9d10b7feabb7e003da53424e986d269 |
|
22-Jul-2013 |
Reid Kleckner <reid@kleckner.net> |
[ms-cxxabi] Emit linkonce complete dtors in TUs that need them Based on Peter Collingbourne's destructor patches. Prior to this change, clang was considering ?1 to be the complete destructor and the base destructor, which was wrong. This lead to crashes when clang tried to emit two LLVM functions with the same name. In this ABI, TUs with non-inline dtors might not emit a complete destructor. They are emitted as inline thunks in TUs that need them, and they always delegate to the base dtors of the complete class and its virtual bases. This change uses the DeferredDecls machinery to emit complete dtors as needed. Currently in clang try body destructors can catch exceptions thrown by virtual base destructors. In the Microsoft C++ ABI, clang may not have the destructor definition, in which case clang won't wrap the virtual virtual base destructor calls in a try-catch. Diagnosing this in user code is TODO. Finally, for classes that don't use virtual inheritance, MSVC always calls the base destructor (?1) directly. This is a useful code size optimization that avoids emitting lots of extra thunks or aliases. Implementing it also means our existing tests continue to pass, and is consistent with MSVC's output. We can do the same for Itanium by tweaking GetAddrOfCXXDestructor, but it will require further testing. Reviewers: rjmccall CC: cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D1066 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@186828 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a967935303e6b36dcc0490073e47fdd5a5eff93e |
|
10-Jul-2013 |
Peter Collingbourne <peter@pcc.me.uk> |
Apply BlackList -> SpecialCaseList rename in Clang. Differential Revision: http://llvm-reviews.chandlerc.com/D1095 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@185979 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7a36a5913f045bfaf6d26ed874e39a3e7c1ad9ae |
|
01-Jul-2013 |
Eli Friedman <eli.friedman@gmail.com> |
Simplify linkage code for static local vars. The key insight here is that weak linkage for a static local variable should always mean linkonce_odr, because every file that needs it will generate a definition. We don't actually care about the precise linkage of the parent context. I feel a bit silly that I didn't realize this before. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@185381 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
07369dde9d72213bf8a48288cd8b29999af9a40c |
|
01-Jul-2013 |
Eli Friedman <eli.friedman@gmail.com> |
Fix mangling for block literals. Blocks, like lambdas, can be written in contexts which are required to be treated as the same under ODR. Unlike lambdas, it isn't possible to actually take the address of a block, so the mangling of the block itself doesn't matter. However, objects like static variables inside a block do need to be mangled in a consistent way. There are basically three components here. One, block literals need a consistent numbering. Two, objects/types inside a block literal need to be mangled using it. Three, objects/types inside a block literal need to have their linkage computed correctly. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@185372 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
678eca456bc62900dc7407bdbc9fa282da9d2f8f |
|
13-Jun-2013 |
Eli Friedman <eli.friedman@gmail.com> |
Fix the linkage of static locals inside a CapturedStmt. (Found in the process of trying to fix the related issue for block literals.) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183951 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7c3e615f01e8f9f587315800fdaf2305ed824568 |
|
13-Jun-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
PR12086, PR15117 Introduce CXXStdInitializerListExpr node, representing the implicit construction of a std::initializer_list<T> object from its underlying array. The AST representation of such an expression goes from an InitListExpr with a flag set, to a CXXStdInitializerListExpr containing a MaterializeTemporaryExpr containing an InitListExpr (possibly wrapped in a CXXBindTemporaryExpr). This more detailed representation has several advantages, the most important of which is that the new MaterializeTemporaryExpr allows us to directly model lifetime extension of the underlying temporary array. Using that, this patch *drastically* simplifies the IR generation of this construct, provides IR generation support for nested global initializer_list objects, fixes several bugs where the destructors for the underlying array would accidentally not get invoked, and provides constant expression evaluation support for std::initializer_list objects. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183872 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
144a31f53b0a97a2c46bfcb1e2a40fa8327b8e89 |
|
05-Jun-2013 |
Peter Collingbourne <peter@pcc.me.uk> |
[ms-cxxabi] Thread GlobalDecls through to CodeGenModule::getFunctionLinkage. This is so that we can give destructor variants different linkage later. Differential Revision: http://llvm-reviews.chandlerc.com/D819 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183324 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
211c8ddb5b500ed84833751363d0cfe1115f4dd3 |
|
05-Jun-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Model temporary lifetime-extension explicitly in the AST. Use this model to handle temporaries which have been lifetime-extended to static storage duration within constant expressions. This correctly handles nested lifetime extension (through reference members of aggregates in aggregate initializers) but non-constant-expression emission hasn't yet been updated to do the same. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183283 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
785f1e7e0631f34d5bbbed9d10e90d56d838f722 |
|
04-Jun-2013 |
Benjamin Kramer <benny.kra@googlemail.com> |
Fix typo in comment. Found by -Wdocumentation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183217 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a7ff62f9443efa3b13a28a1e566d4625b15b8553 |
|
04-Jun-2013 |
Aaron Ballman <aaron@aaronballman.com> |
Adding support for MSVC #pragma detect_mismatch functionality by emitting a FAILIFMISMATCH linker command into the object file. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@183178 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0a050f7d56039bab7556e08b359e06d329977b6b |
|
10-May-2013 |
Adrian Prantl <aprantl@apple.com> |
Debug Info: Fix a problem that resulted in missing DW_AT_specifications for C++ constructors. If the DIType for a class was generated by CGDebugInfo::createContextChain(), the cache contains only a limited DIType wihtout any declarations. Since EmitFunctionStart() needs to find the canonical declaration for each method, we construct the complete type before emitting any method. rdar://problem/13116508 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@181561 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3190ca922d3743137e15fe0c525c04b177b9983b |
|
08-May-2013 |
Reid Kleckner <reid@kleckner.net> |
Forward #pragma comment(lib/linker) through as flags metadata Summary: Most of this change is wiring the pragma all the way through from the lexer, parser, and sema to codegen. I considered adding a Decl AST node for this, but it seemed too heavyweight. Mach-O already uses a metadata flag called "Linker Options" to do this kind of auto-linking. This change follows that pattern. LLVM knows how to forward the "Linker Options" metadata into the COFF .drectve section where these flags belong. ELF support is not implemented, but possible. This is related to auto-linking, which is http://llvm.org/PR13016. CC: cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D723 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@181426 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6b20351a1d6178addfaa86716aaba36f2e9ea188 |
|
06-May-2013 |
Ulrich Weigand <ulrich.weigand@de.ibm.com> |
Allow targets to define minimum alignment for global variables This patch adds a new common code feature that allows platform code to request minimum alignment of global symbols. The background for this is that on SystemZ, the most efficient way to load addresses of global symbol is the LOAD ADDRESS RELATIVE LONG (LARL) instruction. This instruction provides PC-relative addressing, but only to *even* addresses. For this reason, existing compilers will guarantee that global symbols are always aligned to at least 2. [ Since symbols would otherwise already use a default alignment based on their type, this will usually only affect global objects of character type or character arrays. ] GCC also allows creating symbols without that extra alignment by using explicit "aligned" attributes (which then need to be used on both definition and each use of the symbol). To enable support for this with Clang, this patch adds a TargetInfo::MinGlobalAlign variable that provides a global minimum for the alignment of every global object (unless overridden via explicit alignment attribute), and adds code to respect this setting. Within this patch, no platform actually sets the value to anything but the default 1, resulting in no change in behaviour on any existing target. This version of the patch incorporates feedback from reviews by Eric Christopher and John McCall. Thanks to all reviewers! Patch by Richard Sandiford. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@181210 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5543169296beeb183b9c9392debc774fcf493eeb |
|
05-May-2013 |
Dmitri Gribenko <gribozavr@gmail.com> |
Replace ArrayRef<T>() with None, now that we have an implicit ArrayRef constructor from None Patch by Robert Wilhelm. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@181139 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8f4bdc0e37b4b24a58a15ecf41d1355a3b3fdcbb |
|
30-Apr-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Revert r180739 and r180748: they broke C++11 thread_local on non-Darwin systems and did not do the right thing on Darwin. Original commit message: Emit the TLS intialization functions into a list. Add the TLS initialization functions to a list of initialization functions. The back-end takes this list and places the function pointers into the correct section. This way they're called before `main().' <rdar://problem/13733006> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@180809 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7c6b7ba5f5410d4b552ee53c60d0690522c99959 |
|
30-Apr-2013 |
Bill Wendling <isanbard@gmail.com> |
Emit the TLS intialization functions into a list. Add the TLS initialization functions to a list of initialization functions. The back-end takes this list and places the function pointers into the correct section. This way they're called before `main().' <rdar://problem/13733006> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@180739 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b80a16eadd0dacabfc1c32412e243ccb99dd664d |
|
19-Apr-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Implement CodeGen for C++11 thread_local, following the Itanium ABI specification as discussed on cxx-abi-dev. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179858 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3abae0995b5d4faa3d8cfb1f06118d71a60c7dab |
|
17-Apr-2013 |
John McCall <rjmccall@apple.com> |
Don't propagate around TargetOptions in IR-gen; we don't use it. Patch by Stephen Lin! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179639 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
64aa4b3ec7e62288e2e66c1935487ece995ca94b |
|
17-Apr-2013 |
John McCall <rjmccall@apple.com> |
Standardize accesses to the TargetInfo in IR-gen. Patch by Stephen Lin! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179638 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
428edb7f7599b4ee44eaad00bb3c330495fc1ad6 |
|
16-Apr-2013 |
Fariborz Jahanian <fjahanian@apple.com> |
Objective-C IRGen. Use llvm::WeakVH for caching couple of global symbols used for generation of CF/NS string meta-data so they are not released prematuely in certain corner cases. // rdar:// 13598026. Reviewed by John M. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179599 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
84083b74abc4a2d1a9013ce4c75d63ee7d6d1da3 |
|
13-Apr-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Use MapVector rather than simulating it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179438 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ca835180412eb4382fe4cc97e9374489b9ad3946 |
|
12-Apr-2013 |
Manman Ren <mren@apple.com> |
Struct-path aware TBAA: uniformize scalar tag and path tag. For struct-path aware TBAA, we used to use scalar type node as the scalar tag, which has an incompatible format with the struct path tag. We now use the same format: base type, access type and offset. We also uniformize the scalar type node and the struct type node: name, a list of pairs (offset + pointer to MDNode). For scalar type, we have a single pair. These are to make implementaiton of aliasing rules easier. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@179335 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6797204b89c0edb9496249fba557b45d8cc9ec76 |
|
06-Apr-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Remove nondeterminism introduced in r178950. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178952 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0024937dbb23752f606846f4a12aafc712bcde33 |
|
06-Apr-2013 |
Richard Smith <richard-llvm@metafoo.co.uk> |
When an internal-linkage function or variable is declared within an extern "C" linkage specification, and is marked as __attribute__((used)), try to also give it the unmangled name (by emitting an internal linkage alias) if nothing else within the translation unit would use that name. This allows inline asm in that translation unit to use the entity via its unmangled name, which people apparently rely on. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178950 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b37a73d5c6a0c8bb1f6e363d3b53980e4fa0cead |
|
04-Apr-2013 |
Manman Ren <mren@apple.com> |
Initial support for struct-path aware TBAA. Added TBAABaseType and TBAAOffset in LValue. These two fields are initialized to the actual type and 0, and are updated in EmitLValueForField. Path-aware TBAA tags are enabled for EmitLoadOfScalar and EmitStoreOfScalar. Added command line option -struct-path-tbaa. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178797 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7cc0a110bcf3fe9c4d1269ea2ae7e72aa7f37531 |
|
04-Apr-2013 |
Manman Ren <mren@apple.com> |
revert r178784 since it does not have a commit message git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178796 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ab4ffe242935ae0dd66fbe0dcc792c1ad38b00c1 |
|
04-Apr-2013 |
Manman Ren <mren@apple.com> |
Index: include/clang/Driver/CC1Options.td =================================================================== --- include/clang/Driver/CC1Options.td (revision 178718) +++ include/clang/Driver/CC1Options.td (working copy) @@ -161,6 +161,8 @@ HelpText<"Use register sized accesses to bit-fields, when possible.">; def relaxed_aliasing : Flag<["-"], "relaxed-aliasing">, HelpText<"Turn off Type Based Alias Analysis">; +def struct_path_tbaa : Flag<["-"], "struct-path-tbaa">, + HelpText<"Turn on struct-path aware Type Based Alias Analysis">; def masm_verbose : Flag<["-"], "masm-verbose">, HelpText<"Generate verbose assembly output">; def mcode_model : Separate<["-"], "mcode-model">, Index: include/clang/Driver/Options.td =================================================================== --- include/clang/Driver/Options.td (revision 178718) +++ include/clang/Driver/Options.td (working copy) @@ -587,6 +587,7 @@ Flags<[CC1Option]>, HelpText<"Disable spell-checking">; def fno_stack_protector : Flag<["-"], "fno-stack-protector">, Group<f_Group>; def fno_strict_aliasing : Flag<["-"], "fno-strict-aliasing">, Group<f_Group>; +def fstruct_path_tbaa : Flag<["-"], "fstruct-path-tbaa">, Group<f_Group>; def fno_strict_enums : Flag<["-"], "fno-strict-enums">, Group<f_Group>; def fno_strict_overflow : Flag<["-"], "fno-strict-overflow">, Group<f_Group>; def fno_threadsafe_statics : Flag<["-"], "fno-threadsafe-statics">, Group<f_Group>, Index: include/clang/Frontend/CodeGenOptions.def =================================================================== --- include/clang/Frontend/CodeGenOptions.def (revision 178718) +++ include/clang/Frontend/CodeGenOptions.def (working copy) @@ -85,6 +85,7 @@ VALUE_CODEGENOPT(OptimizeSize, 2, 0) ///< If -Os (==1) or -Oz (==2) is specified. CODEGENOPT(RelaxAll , 1, 0) ///< Relax all machine code instructions. CODEGENOPT(RelaxedAliasing , 1, 0) ///< Set when -fno-strict-aliasing is enabled. +CODEGENOPT(StructPathTBAA , 1, 0) ///< Whether or not to use struct-path TBAA. CODEGENOPT(SaveTempLabels , 1, 0) ///< Save temporary labels. CODEGENOPT(SanitizeAddressZeroBaseShadow , 1, 0) ///< Map shadow memory at zero ///< offset in AddressSanitizer. Index: lib/CodeGen/CGExpr.cpp =================================================================== --- lib/CodeGen/CGExpr.cpp (revision 178718) +++ lib/CodeGen/CGExpr.cpp (working copy) @@ -1044,7 +1044,8 @@ llvm::Value *CodeGenFunction::EmitLoadOfScalar(LValue lvalue) { return EmitLoadOfScalar(lvalue.getAddress(), lvalue.isVolatile(), lvalue.getAlignment().getQuantity(), - lvalue.getType(), lvalue.getTBAAInfo()); + lvalue.getType(), lvalue.getTBAAInfo(), + lvalue.getTBAABaseType(), lvalue.getTBAAOffset()); } static bool hasBooleanRepresentation(QualType Ty) { @@ -1106,7 +1107,9 @@ llvm::Value *CodeGenFunction::EmitLoadOfScalar(llvm::Value *Addr, bool Volatile, unsigned Alignment, QualType Ty, - llvm::MDNode *TBAAInfo) { + llvm::MDNode *TBAAInfo, + QualType TBAABaseType, + uint64_t TBAAOffset) { // For better performance, handle vector loads differently. if (Ty->isVectorType()) { llvm::Value *V; @@ -1158,8 +1161,11 @@ Load->setVolatile(true); if (Alignment) Load->setAlignment(Alignment); - if (TBAAInfo) - CGM.DecorateInstruction(Load, TBAAInfo); + if (TBAAInfo) { + llvm::MDNode *TBAAPath = CGM.getTBAAStructTagInfo(TBAABaseType, TBAAInfo, + TBAAOffset); + CGM.DecorateInstruction(Load, TBAAPath); + } if ((SanOpts->Bool && hasBooleanRepresentation(Ty)) || (SanOpts->Enum && Ty->getAs<EnumType>())) { @@ -1217,7 +1223,8 @@ bool Volatile, unsigned Alignment, QualType Ty, llvm::MDNode *TBAAInfo, - bool isInit) { + bool isInit, QualType TBAABaseType, + uint64_t TBAAOffset) { // Handle vectors differently to get better performance. if (Ty->isVectorType()) { @@ -1268,15 +1275,19 @@ llvm::StoreInst *Store = Builder.CreateStore(Value, Addr, Volatile); if (Alignment) Store->setAlignment(Alignment); - if (TBAAInfo) - CGM.DecorateInstruction(Store, TBAAInfo); + if (TBAAInfo) { + llvm::MDNode *TBAAPath = CGM.getTBAAStructTagInfo(TBAABaseType, TBAAInfo, + TBAAOffset); + CGM.DecorateInstruction(Store, TBAAPath); + } } void CodeGenFunction::EmitStoreOfScalar(llvm::Value *value, LValue lvalue, bool isInit) { EmitStoreOfScalar(value, lvalue.getAddress(), lvalue.isVolatile(), lvalue.getAlignment().getQuantity(), lvalue.getType(), - lvalue.getTBAAInfo(), isInit); + lvalue.getTBAAInfo(), isInit, lvalue.getTBAABaseType(), + lvalue.getTBAAOffset()); } /// EmitLoadOfLValue - Given an expression that represents a value lvalue, this @@ -2494,9 +2505,12 @@ llvm::Value *addr = base.getAddress(); unsigned cvr = base.getVRQualifiers(); + bool TBAAPath = CGM.getCodeGenOpts().StructPathTBAA; if (rec->isUnion()) { // For unions, there is no pointer adjustment. assert(!type->isReferenceType() && "union has reference member"); + // TODO: handle path-aware TBAA for union. + TBAAPath = false; } else { // For structs, we GEP to the field that the record layout suggests. unsigned idx = CGM.getTypes().getCGRecordLayout(rec).getLLVMFieldNo(field); @@ -2508,6 +2522,8 @@ if (cvr & Qualifiers::Volatile) load->setVolatile(true); load->setAlignment(alignment.getQuantity()); + // Loading the reference will disable path-aware TBAA. + TBAAPath = false; if (CGM.shouldUseTBAA()) { llvm::MDNode *tbaa; if (mayAlias) @@ -2541,6 +2557,16 @@ LValue LV = MakeAddrLValue(addr, type, alignment); LV.getQuals().addCVRQualifiers(cvr); + if (TBAAPath) { + const ASTRecordLayout &Layout = + getContext().getASTRecordLayout(field->getParent()); + // Set the base type to be the base type of the base LValue and + // update offset to be relative to the base type. + LV.setTBAABaseType(base.getTBAABaseType()); + LV.setTBAAOffset(base.getTBAAOffset() + + Layout.getFieldOffset(field->getFieldIndex()) / + getContext().getCharWidth()); + } // __weak attribute on a field is ignored. if (LV.getQuals().getObjCGCAttr() == Qualifiers::Weak) Index: lib/CodeGen/CGValue.h =================================================================== --- lib/CodeGen/CGValue.h (revision 178718) +++ lib/CodeGen/CGValue.h (working copy) @@ -157,6 +157,11 @@ Expr *BaseIvarExp; + /// Used by struct-path-aware TBAA. + QualType TBAABaseType; + /// Offset relative to the base type. + uint64_t TBAAOffset; + /// TBAAInfo - TBAA information to attach to dereferences of this LValue. llvm::MDNode *TBAAInfo; @@ -175,6 +180,10 @@ this->ImpreciseLifetime = false; this->ThreadLocalRef = false; this->BaseIvarExp = 0; + + // Initialize fields for TBAA. + this->TBAABaseType = Type; + this->TBAAOffset = 0; this->TBAAInfo = TBAAInfo; } @@ -232,6 +241,12 @@ Expr *getBaseIvarExp() const { return BaseIvarExp; } void setBaseIvarExp(Expr *V) { BaseIvarExp = V; } + QualType getTBAABaseType() const { return TBAABaseType; } + void setTBAABaseType(QualType T) { TBAABaseType = T; } + + uint64_t getTBAAOffset() const { return TBAAOffset; } + void setTBAAOffset(uint64_t O) { TBAAOffset = O; } + llvm::MDNode *getTBAAInfo() const { return TBAAInfo; } void setTBAAInfo(llvm::MDNode *N) { TBAAInfo = N; } Index: lib/CodeGen/CodeGenFunction.h =================================================================== --- lib/CodeGen/CodeGenFunction.h (revision 178718) +++ lib/CodeGen/CodeGenFunction.h (working copy) @@ -2211,7 +2211,9 @@ /// the LLVM value representation. llvm::Value *EmitLoadOfScalar(llvm::Value *Addr, bool Volatile, unsigned Alignment, QualType Ty, - llvm::MDNode *TBAAInfo = 0); + llvm::MDNode *TBAAInfo = 0, + QualType TBAABaseTy = QualType(), + uint64_t TBAAOffset = 0); /// EmitLoadOfScalar - Load a scalar value from an address, taking /// care to appropriately convert from the memory representation to @@ -2224,7 +2226,9 @@ /// the LLVM value representation. void EmitStoreOfScalar(llvm::Value *Value, llvm::Value *Addr, bool Volatile, unsigned Alignment, QualType Ty, - llvm::MDNode *TBAAInfo = 0, bool isInit=false); + llvm::MDNode *TBAAInfo = 0, bool isInit = false, + QualType TBAABaseTy = QualType(), + uint64_t TBAAOffset = 0); /// EmitStoreOfScalar - Store a scalar value to an address, taking /// care to appropriately convert from the memory representation to Index: lib/CodeGen/CodeGenModule.cpp =================================================================== --- lib/CodeGen/CodeGenModule.cpp (revision 178718) +++ lib/CodeGen/CodeGenModule.cpp (working copy) @@ -227,6 +227,20 @@ return TBAA->getTBAAStructInfo(QTy); } +llvm::MDNode *CodeGenModule::getTBAAStructTypeInfo(QualType QTy) { + if (!TBAA) + return 0; + return TBAA->getTBAAStructTypeInfo(QTy); +} + +llvm::MDNode *CodeGenModule::getTBAAStructTagInfo(QualType BaseTy, + llvm::MDNode *AccessN, + uint64_t O) { + if (!TBAA) + return 0; + return TBAA->getTBAAStructTagInfo(BaseTy, AccessN, O); +} + void CodeGenModule::DecorateInstruction(llvm::Instruction *Inst, llvm::MDNode *TBAAInfo) { Inst->setMetadata(llvm::LLVMContext::MD_tbaa, TBAAInfo); Index: lib/CodeGen/CodeGenModule.h =================================================================== --- lib/CodeGen/CodeGenModule.h (revision 178718) +++ lib/CodeGen/CodeGenModule.h (working copy) @@ -501,6 +501,11 @@ llvm::MDNode *getTBAAInfo(QualType QTy); llvm::MDNode *getTBAAInfoForVTablePtr(); llvm::MDNode *getTBAAStructInfo(QualType QTy); + /// Return the MDNode in the type DAG for the given struct type. + llvm::MDNode *getTBAAStructTypeInfo(QualType QTy); + /// Return the path-aware tag for given base type, access node and offset. + llvm::MDNode *getTBAAStructTagInfo(QualType BaseTy, llvm::MDNode *AccessN, + uint64_t O); bool isTypeConstant(QualType QTy, bool ExcludeCtorDtor); Index: lib/CodeGen/CodeGenTBAA.cpp =================================================================== --- lib/CodeGen/CodeGenTBAA.cpp (revision 178718) +++ lib/CodeGen/CodeGenTBAA.cpp (working copy) @@ -21,6 +21,7 @@ #include "clang/AST/Mangle.h" #include "clang/AST/RecordLayout.h" #include "clang/Frontend/CodeGenOptions.h" +#include "llvm/ADT/SmallSet.h" #include "llvm/IR/Constants.h" #include "llvm/IR/LLVMContext.h" #include "llvm/IR/Metadata.h" @@ -225,3 +226,87 @@ // For now, handle any other kind of type conservatively. return StructMetadataCache[Ty] = NULL; } + +/// Check if the given type can be handled by path-aware TBAA. +static bool isTBAAPathStruct(QualType QTy) { + if (const RecordType *TTy = QTy->getAs<RecordType>()) { + const RecordDecl *RD = TTy->getDecl()->getDefinition(); + // RD can be struct, union, class, interface or enum. + // For now, we only handle struct. + if (RD->isStruct() && !RD->hasFlexibleArrayMember()) + return true; + } + return false; +} + +llvm::MDNode * +CodeGenTBAA::getTBAAStructTypeInfo(QualType QTy) { + const Type *Ty = Context.getCanonicalType(QTy).getTypePtr(); + assert(isTBAAPathStruct(QTy)); + + if (llvm::MDNode *N = StructTypeMetadataCache[Ty]) + return N; + + if (const RecordType *TTy = QTy->getAs<RecordType>()) { + const RecordDecl *RD = TTy->getDecl()->getDefinition(); + + const ASTRecordLayout &Layout = Context.getASTRecordLayout(RD); + SmallVector <std::pair<uint64_t, llvm::MDNode*>, 4> Fields; + // To reduce the size of MDNode for a given struct type, we only output + // once for all the fields with the same scalar types. + // Offsets for scalar fields in the type DAG are not used. + llvm::SmallSet <llvm::MDNode*, 4> ScalarFieldTypes; + unsigned idx = 0; + for (RecordDecl::field_iterator i = RD->field_begin(), + e = RD->field_end(); i != e; ++i, ++idx) { + QualType FieldQTy = i->getType(); + llvm::MDNode *FieldNode; + if (isTBAAPathStruct(FieldQTy)) + FieldNode = getTBAAStructTypeInfo(FieldQTy); + else { + FieldNode = getTBAAInfo(FieldQTy); + // Ignore this field if the type already exists. + if (ScalarFieldTypes.count(FieldNode)) + continue; + ScalarFieldTypes.insert(FieldNode); + } + if (!FieldNode) + return StructTypeMetadataCache[Ty] = NULL; + Fields.push_back(std::make_pair( + Layout.getFieldOffset(idx) / Context.getCharWidth(), FieldNode)); + } + + // TODO: This is using the RTTI name. Is there a better way to get + // a unique string for a type? + SmallString<256> OutName; + llvm::raw_svector_ostream Out(OutName); + MContext.mangleCXXRTTIName(QualType(Ty, 0), Out); + Out.flush(); + // Create the struct type node with a vector of pairs (offset, type). + return StructTypeMetadataCache[Ty] = + MDHelper.createTBAAStructTypeNode(OutName, Fields); + } + + return StructMetadataCache[Ty] = NULL; +} + +llvm::MDNode * +CodeGenTBAA::getTBAAStructTagInfo(QualType BaseQTy, llvm::MDNode *AccessNode, + uint64_t Offset) { + if (!CodeGenOpts.StructPathTBAA) + return AccessNode; + + const Type *BTy = Context.getCanonicalType(BaseQTy).getTypePtr(); + TBAAPathTag PathTag = TBAAPathTag(BTy, AccessNode, Offset); + if (llvm::MDNode *N = StructTagMetadataCache[PathTag]) + return N; + + llvm::MDNode *BNode = 0; + if (isTBAAPathStruct(BaseQTy)) + BNode = getTBAAStructTypeInfo(BaseQTy); + if (!BNode) + return StructTagMetadataCache[PathTag] = AccessNode; + + return StructTagMetadataCache[PathTag] = + MDHelper.createTBAAStructTagNode(BNode, AccessNode, Offset); +} Index: lib/CodeGen/CodeGenTBAA.h =================================================================== --- lib/CodeGen/CodeGenTBAA.h (revision 178718) +++ lib/CodeGen/CodeGenTBAA.h (working copy) @@ -35,6 +35,14 @@ namespace CodeGen { class CGRecordLayout; + struct TBAAPathTag { + TBAAPathTag(const Type *B, const llvm::MDNode *A, uint64_t O) + : BaseT(B), AccessN(A), Offset(O) {} + const Type *BaseT; + const llvm::MDNode *AccessN; + uint64_t Offset; + }; + /// CodeGenTBAA - This class organizes the cross-module state that is used /// while lowering AST types to LLVM types. class CodeGenTBAA { @@ -46,8 +54,13 @@ // MDHelper - Helper for creating metadata. llvm::MDBuilder MDHelper; - /// MetadataCache - This maps clang::Types to llvm::MDNodes describing them. + /// MetadataCache - This maps clang::Types to scalar llvm::MDNodes describing + /// them. llvm::DenseMap<const Type *, llvm::MDNode *> MetadataCache; + /// This maps clang::Types to a struct node in the type DAG. + llvm::DenseMap<const Type *, llvm::MDNode *> StructTypeMetadataCache; + /// This maps TBAAPathTags to a tag node. + llvm::DenseMap<TBAAPathTag, llvm::MDNode *> StructTagMetadataCache; /// StructMetadataCache - This maps clang::Types to llvm::MDNodes describing /// them for struct assignments. @@ -89,9 +102,49 @@ /// getTBAAStructInfo - Get the TBAAStruct MDNode to be used for a memcpy of /// the given type. llvm::MDNode *getTBAAStructInfo(QualType QTy); + + /// Get the MDNode in the type DAG for given struct type QType. + llvm::MDNode *getTBAAStructTypeInfo(QualType QType); + /// Get the tag MDNode for a given base type, the actual sclar access MDNode + /// and offset into the base type. + llvm::MDNode *getTBAAStructTagInfo(QualType BaseQType, + llvm::MDNode *AccessNode, uint64_t Offset); }; } // end namespace CodeGen } // end namespace clang +namespace llvm { + +template<> struct DenseMapInfo<clang::CodeGen::TBAAPathTag> { + static clang::CodeGen::TBAAPathTag getEmptyKey() { + return clang::CodeGen::TBAAPathTag( + DenseMapInfo<const clang::Type *>::getEmptyKey(), + DenseMapInfo<const MDNode *>::getEmptyKey(), + DenseMapInfo<uint64_t>::getEmptyKey()); + } + + static clang::CodeGen::TBAAPathTag getTombstoneKey() { + return clang::CodeGen::TBAAPathTag( + DenseMapInfo<const clang::Type *>::getTombstoneKey(), + DenseMapInfo<const MDNode *>::getTombstoneKey(), + DenseMapInfo<uint64_t>::getTombstoneKey()); + } + + static unsigned getHashValue(const clang::CodeGen::TBAAPathTag &Val) { + return DenseMapInfo<const clang::Type *>::getHashValue(Val.BaseT) ^ + DenseMapInfo<const MDNode *>::getHashValue(Val.AccessN) ^ + DenseMapInfo<uint64_t>::getHashValue(Val.Offset); + } + + static bool isEqual(const clang::CodeGen::TBAAPathTag &LHS, + const clang::CodeGen::TBAAPathTag &RHS) { + return LHS.BaseT == RHS.BaseT && + LHS.AccessN == RHS.AccessN && + LHS.Offset == RHS.Offset; + } +}; + +} // end namespace llvm + #endif Index: lib/Driver/Tools.cpp =================================================================== --- lib/Driver/Tools.cpp (revision 178718) +++ lib/Driver/Tools.cpp (working copy) @@ -2105,6 +2105,8 @@ options::OPT_fno_strict_aliasing, getToolChain().IsStrictAliasingDefault())) CmdArgs.push_back("-relaxed-aliasing"); + if (Args.hasArg(options::OPT_fstruct_path_tbaa)) + CmdArgs.push_back("-struct-path-tbaa"); if (Args.hasFlag(options::OPT_fstrict_enums, options::OPT_fno_strict_enums, false)) CmdArgs.push_back("-fstrict-enums"); Index: lib/Frontend/CompilerInvocation.cpp =================================================================== --- lib/Frontend/CompilerInvocation.cpp (revision 178718) +++ lib/Frontend/CompilerInvocation.cpp (working copy) @@ -324,6 +324,7 @@ Opts.UseRegisterSizedBitfieldAccess = Args.hasArg( OPT_fuse_register_sized_bitfield_access); Opts.RelaxedAliasing = Args.hasArg(OPT_relaxed_aliasing); + Opts.StructPathTBAA = Args.hasArg(OPT_struct_path_tbaa); Opts.DwarfDebugFlags = Args.getLastArgValue(OPT_dwarf_debug_flags); Opts.MergeAllConstants = !Args.hasArg(OPT_fno_merge_all_constants); Opts.NoCommon = Args.hasArg(OPT_fno_common); Index: test/CodeGen/tbaa.cpp =================================================================== --- test/CodeGen/tbaa.cpp (revision 0) +++ test/CodeGen/tbaa.cpp (working copy) @@ -0,0 +1,217 @@ +// RUN: %clang_cc1 -O1 -disable-llvm-optzns %s -emit-llvm -o - | FileCheck %s +// RUN: %clang_cc1 -O1 -struct-path-tbaa -disable-llvm-optzns %s -emit-llvm -o - | FileCheck %s -check-prefix=PATH +// Test TBAA metadata generated by front-end. + +#include <stdint.h> +typedef struct +{ + uint16_t f16; + uint32_t f32; + uint16_t f16_2; + uint32_t f32_2; +} StructA; +typedef struct +{ + uint16_t f16; + StructA a; + uint32_t f32; +} StructB; +typedef struct +{ + uint16_t f16; + StructB b; + uint32_t f32; +} StructC; +typedef struct +{ + uint16_t f16; + StructB b; + uint32_t f32; + uint8_t f8; +} StructD; + +typedef struct +{ + uint16_t f16; + uint32_t f32; +} StructS; +typedef struct +{ + uint16_t f16; + uint32_t f32; +} StructS2; + +uint32_t g(uint32_t *s, StructA *A, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !5 + *s = 1; + A->f32 = 4; + return *s; +} + +uint32_t g2(uint32_t *s, StructA *A, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i16 4, i16* %{{.*}}, align 2, !tbaa !5 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: store i16 4, i16* %{{.*}}, align 2, !tbaa !8 + *s = 1; + A->f16 = 4; + return *s; +} + +uint32_t g3(StructA *A, StructB *B, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !5 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !9 + A->f32 = 1; + B->a.f32 = 4; + return A->f32; +} + +uint32_t g4(StructA *A, StructB *B, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i16 4, i16* %{{.*}}, align 2, !tbaa !5 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !5 +// PATH: store i16 4, i16* %{{.*}}, align 2, !tbaa !11 + A->f32 = 1; + B->a.f16 = 4; + return A->f32; +} + +uint32_t g5(StructA *A, StructB *B, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !5 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !12 + A->f32 = 1; + B->f32 = 4; + return A->f32; +} + +uint32_t g6(StructA *A, StructB *B, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !5 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !13 + A->f32 = 1; + B->a.f32_2 = 4; + return A->f32; +} + +uint32_t g7(StructA *A, StructS *S, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !5 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !14 + A->f32 = 1; + S->f32 = 4; + return A->f32; +} + +uint32_t g8(StructA *A, StructS *S, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i16 4, i16* %{{.*}}, align 2, !tbaa !5 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !5 +// PATH: store i16 4, i16* %{{.*}}, align 2, !tbaa !16 + A->f32 = 1; + S->f16 = 4; + return A->f32; +} + +uint32_t g9(StructS *S, StructS2 *S2, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !14 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !17 + S->f32 = 1; + S2->f32 = 4; + return S->f32; +} + +uint32_t g10(StructS *S, StructS2 *S2, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i16 4, i16* %{{.*}}, align 2, !tbaa !5 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !14 +// PATH: store i16 4, i16* %{{.*}}, align 2, !tbaa !19 + S->f32 = 1; + S2->f16 = 4; + return S->f32; +} + +uint32_t g11(StructC *C, StructD *D, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !20 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !22 + C->b.a.f32 = 1; + D->b.a.f32 = 4; + return C->b.a.f32; +} + +uint32_t g12(StructC *C, StructD *D, uint64_t count) { +// CHECK: define i32 @{{.*}}( +// CHECK: store i32 1, i32* %{{.*}}, align 4, !tbaa !4 +// CHECK: store i32 4, i32* %{{.*}}, align 4, !tbaa !4 +// TODO: differentiate the two accesses. +// PATH: define i32 @{{.*}}( +// PATH: store i32 1, i32* %{{.*}}, align 4, !tbaa !9 +// PATH: store i32 4, i32* %{{.*}}, align 4, !tbaa !9 + StructB *b1 = &(C->b); + StructB *b2 = &(D->b); + // b1, b2 have different context. + b1->a.f32 = 1; + b2->a.f32 = 4; + return b1->a.f32; +} + +// CHECK: !1 = metadata !{metadata !"omnipotent char", metadata !2} +// CHECK: !2 = metadata !{metadata !"Simple C/C++ TBAA"} +// CHECK: !4 = metadata !{metadata !"int", metadata !1} +// CHECK: !5 = metadata !{metadata !"short", metadata !1} + +// PATH: !1 = metadata !{metadata !"omnipotent char", metadata !2} +// PATH: !4 = metadata !{metadata !"int", metadata !1} +// PATH: !5 = metadata !{metadata !6, metadata !4, i64 4} +// PATH: !6 = metadata !{metadata !"_ZTS7StructA", i64 0, metadata !7, i64 4, metadata !4} +// PATH: !7 = metadata !{metadata !"short", metadata !1} +// PATH: !8 = metadata !{metadata !6, metadata !7, i64 0} +// PATH: !9 = metadata !{metadata !10, metadata !4, i64 8} +// PATH: !10 = metadata !{metadata !"_ZTS7StructB", i64 0, metadata !7, i64 4, metadata !6, i64 20, metadata !4} +// PATH: !11 = metadata !{metadata !10, metadata !7, i64 4} +// PATH: !12 = metadata !{metadata !10, metadata !4, i64 20} +// PATH: !13 = metadata !{metadata !10, metadata !4, i64 16} +// PATH: !14 = metadata !{metadata !15, metadata !4, i64 4} +// PATH: !15 = metadata !{metadata !"_ZTS7StructS", i64 0, metadata !7, i64 4, metadata !4} +// PATH: !16 = metadata !{metadata !15, metadata !7, i64 0} +// PATH: !17 = metadata !{metadata !18, metadata !4, i64 4} +// PATH: !18 = metadata !{metadata !"_ZTS8StructS2", i64 0, metadata !7, i64 4, metadata !4} +// PATH: !19 = metadata !{metadata !18, metadata !7, i64 0} +// PATH: !20 = metadata !{metadata !21, metadata !4, i64 12} +// PATH: !21 = metadata !{metadata !"_ZTS7StructC", i64 0, metadata !7, i64 4, metadata !10, i64 28, metadata !4} +// PATH: !22 = metadata !{metadata !23, metadata !4, i64 12} +// PATH: !23 = metadata !{metadata !"_ZTS7StructD", i64 0, metadata !7, i64 4, metadata !10, i64 28, metadata !4, i64 32, metadata !1} git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@178784 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
495cfa46300979642acde8d93a1f21c9291dac98 |
|
23-Mar-2013 |
Nadav Rotem <nrotem@apple.com> |
Make clang to mark static stack allocations with lifetime markers to enable a more aggressive stack coloring. Patch by John McCall with help by Shuxin Yang. rdar://13115369 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177819 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b6a6079449a5275c283982e19b0c38e165833bb2 |
|
23-Mar-2013 |
John McCall <rjmccall@apple.com> |
Under ARC, when we're passing the address of a strong variable to an out-parameter using the indirect-writeback conversion, and we copied the current value of the variable to the temporary, make sure that we register an intrinsic use of that value with the optimizer so that the value won't get released until we have a chance to retain it. rdar://13195034 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@177813 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9eda3abe7e183b05834947391c0cdc291f4ee0d8 |
|
07-Mar-2013 |
John McCall <rjmccall@apple.com> |
Promote atomic type sizes up to a power of two, capped by MaxAtomicPromoteWidth. Fix a ton of terrible bugs with _Atomic types and (non-intrinsic-mediated) loads and stores thereto. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@176658 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bd7370a78604e9a20d698bfe328c1e43f12a0613 |
|
28-Feb-2013 |
John McCall <rjmccall@apple.com> |
Use the actual ABI-determined C calling convention for runtime calls and declarations. LLVM has a default CC determined by the target triple. This is not always the actual default CC for the ABI we've been asked to target, and so we sometimes find ourselves annotating all user functions with an explicit calling convention. Since these calling conventions usually agree for the simple set of argument types passed to most runtime functions, using the LLVM-default CC in principle has no effect. However, the LLVM optimizer goes into histrionics if it sees this kind of formal CC mismatch, since it has no concept of CC compatibility. Therefore, if this module happens to define the "runtime" function, or got LTO'ed with such a definition, we can miscompile; so it's quite important to get this right. Defining runtime functions locally is quite common in embedded applications. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@176286 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
94236e7393d5cd4acbc5f0b503d23bbe78d9aeec |
|
22-Feb-2013 |
Bill Wendling <isanbard@gmail.com> |
Apply the 'nobuiltin' attribute to call sites when the user specifies `-fno-builtin' on the command line. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@175836 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e1092dfee2bbcc2243421c553bca488880324280 |
|
14-Feb-2013 |
Bill Wendling <isanbard@gmail.com> |
Pass the target options through to code generation. The code generation stuff is going to set attributes on the functions it generates. To do that it needs the target options. Pass them through. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@175141 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c4c62fd78a4728c9e4d4df14911a2ced9bdd2031 |
|
31-Jan-2013 |
Bill Wendling <isanbard@gmail.com> |
Make sure that the Attribute object represents one attribute only. Several places were still treating the Attribute object as respresenting multiple attributes. Those places now use the AttributeSet to represent multiple attributes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174004 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d5617eeafc93209a26b9f88276c88cf997c3a0a7 |
|
25-Jan-2013 |
John McCall <rjmccall@apple.com> |
The standard ARM C++ ABI dictates that inline functions are never key functions. We did not implement that rule for the iOS ABI, which was driven by what was implemented in gcc-4.2. However, implement it now for other ARM-based platforms. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@173515 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4f45bc099f2665bc6e4bcbb169aa452390dbf3fe |
|
18-Jan-2013 |
Will Dietz <wdietz2@illinois.edu> |
[ubsan] Add support for -fsanitize-blacklist git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172808 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
858afb3c22144027bcd8ba75e27262eede093a60 |
|
14-Jan-2013 |
Douglas Gregor <dgregor@apple.com> |
Topologically sort the link options generated for modules based on module-import dependencies, so we'll get the link order correct for those silly linkers that need it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172459 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5d75ea72d6eee3df0c6acdb282145dc4cc3a9a1b |
|
14-Jan-2013 |
Douglas Gregor <dgregor@apple.com> |
Switch autolinking metadata format over to actual linker options, e.g., !0 = metadata !{metadata !"-lautolink"} !1 = metadata !{metadata !"-framework", metadata !"autolink_framework"} referenced from llvm.module.linkoptions, e.g., !llvm.module.linkoptions = !{!0, !1, !2, !3} This conceptually moves the logic for figuring out the syntax the linker will accept from LLVM into Clang. Moreover, it makes it easier to support MSVC's #pragma comment(linker, "some option") in the future, should anyone care to do so. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172441 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b6cbe517237c3c223beb064d60d5b49e56d65c06 |
|
14-Jan-2013 |
Douglas Gregor <dgregor@apple.com> |
Implement parsing, AST, (de-)serialization, and placeholder global metadata for linking against the libraries/frameworks for imported modules. The module map language is extended with a new "link" directive that specifies what library or framework to link against when a module is imported, e.g., link "clangAST" or link framework "MyFramework" Importing the corresponding module (or any of its submodules) will eventually link against the named library/framework. For now, I've added some placeholder global metadata that encodes the imported libraries/frameworks, so that we can test that this information gets through to the IR. The format of the data is still under discussion. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172437 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
cfa88f893915ceb8ae4ce2f17c46c24a4d67502f |
|
12-Jan-2013 |
Dmitri Gribenko <gribozavr@gmail.com> |
Remove useless 'llvm::' qualifier from names like StringRef and others that are brought into 'clang' namespace by clang/Basic/LLVM.h git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@172323 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3b844ba7d5be205a9b4f5f0b0d1b7978977f4b8c |
|
02-Jan-2013 |
Chandler Carruth <chandlerc@gmail.com> |
Rewrite #includes for llvm/Foo.h to llvm/IR/Foo.h as appropriate to reflect the migration in r171366. Re-sort the #include lines to reflect the new paths. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@171369 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
72390b39c545426023ec104afe8706395d732bad |
|
20-Dec-2012 |
Bill Wendling <isanbard@gmail.com> |
Rename llvm::Attributes to llvm::Attribute. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@170722 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ad017fa7a4df7389d245d02a49b3c79ed70bedb9 |
|
20-Dec-2012 |
Bill Wendling <isanbard@gmail.com> |
Revert r170500. It over-zealously converted *ALL* things named Attributes, which is wrong here. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@170721 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
094dbf917127a1228147587076d59ca45b7c258d |
|
19-Dec-2012 |
Bill Wendling <isanbard@gmail.com> |
Rename the 'Attributes' class to 'Attribute'. It's going to represent a single attribute in the future. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@170500 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
55fc873017f10f6f566b182b70f6fc22aefa3464 |
|
04-Dec-2012 |
Chandler Carruth <chandlerc@gmail.com> |
Sort all of Clang's files under 'lib', and fix up the broken headers uncovered. This required manually correcting all of the incorrect main-module headers I could find, and running the new llvm/utils/sort_includes.py script over the files. I also manually added quite a few missing headers that were uncovered by shuffling the order or moving headers up to be main-module-headers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@169237 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c4a77906c259cba58c147d8468c406a430ecdcbb |
|
15-Nov-2012 |
Dmitri Gribenko <gribozavr@gmail.com> |
Use empty parens for empty function parameter list instead of '(void)'. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@168041 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4179ddd5752ec5a252ca1e1eb77a5c34b5835d3b |
|
06-Nov-2012 |
Anton Korobeynikov <asl@math.spbu.ru> |
Implement codegen for init_priority attribute properly - make sure it works between the modules. No functionality change on Darwin/Windows. This fixes PR11480. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@167496 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c5f804636e367ef744fd24cf88f7c956a5af0434 |
|
11-Oct-2012 |
Nico Weber <nicolasweber@gmx.de> |
Add codegen support for __uuidof(). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165710 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
603571a2d6daca43162bf1d9469baf919697c00a |
|
10-Oct-2012 |
Bill Wendling <isanbard@gmail.com> |
Remove the final bits of Attributes being declared in the Attribute namespace. Use the attribute's enum value instead. No functionality change intended. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165611 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
25a6a84cf5067b32c271e3ba078676dee838798d |
|
08-Oct-2012 |
Micah Villmow <villmow@gmail.com> |
Move TargetData to DataLayout. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165395 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b22c7dc707cf3770ff3b5e5f11f11fd0aaa06d9b |
|
28-Sep-2012 |
Dan Gohman <gohman@apple.com> |
Add basic support for adding !tbaa.struct metadata on llvm.memcpy calls for struct assignment. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@164853 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f3477c13eeaf11b32a41f181398fb5deffd0dd73 |
|
27-Sep-2012 |
Sylvestre Ledru <sylvestre@debian.org> |
Revert 'Fix a typo 'iff' => 'if''. iff is an abreviation of if and only if. See: http://en.wikipedia.org/wiki/If_and_only_if Commit 164766 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@164769 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
94ff8e1f57c6382d91d0de981a4f311509d83e37 |
|
27-Sep-2012 |
Sylvestre Ledru <sylvestre@debian.org> |
Fix a typo 'iff' => 'if' git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@164766 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f56faa01936b9cf909623d7f06e3c2569ca4a78e |
|
15-Sep-2012 |
Dmitri Gribenko <gribozavr@gmail.com> |
Use LLVM_DELETED_FUNCTION in place of 'DO NOT IMPLEMENT' comments. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@163983 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
de981f3ff163bc9ec69e4c5e7316e94276412993 |
|
28-Jun-2012 |
Hans Wennborg <hans@hanshq.net> |
Add -ftls-model command-line flag. This allows for setting the default TLS model. (PR9788) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159336 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4904bf4e84cfb48080270ebaa9005327f18ab0e5 |
|
26-Jun-2012 |
Fariborz Jahanian <fjahanian@apple.com> |
block literal irgen: several improvements on naming block literal helper functions. All helper functions (global and locals) use block_invoke as their prefix. Local literal helper names are prefixed by their enclosing mangled function names. Blocks in non-local initializers (e.g. a global variable or a C++11 field) are prefixed by their mangled variable name. The descriminator number added to end of the name starts off with blank (for first block) and _<N> (for the N+2-th block). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159206 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5e2d5dec7736f6f9292d4212dec67295909f1328 |
|
23-Jun-2012 |
Hans Wennborg <hans@hanshq.net> |
Support the tls_model attribute (PR9788) This adds support for the tls_model attribute. This allows the user to choose a TLS model that is better than what LLVM would select by default. For example, a variable might be declared as: __thread int x __attribute__((tls_model("initial-exec"))); if it will not be used in a shared library that is dlopen'ed. This depends on LLVM r159077. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@159078 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4dc34ebf2a0716bf77ba110dab6777a3fc4397dd |
|
20-May-2012 |
Peter Collingbourne <peter@pcc.me.uk> |
CUDA: add CodeGen support for global variable address spaces. Because in CUDA types do not have associated address spaces, globals are declared in their "native" address space, and accessed by bitcasting the pointer to address space 0. This relies on address space 0 being a unified address space. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@157167 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e2b45e2a43ae46bc00026b63ba7c04ef2b78c3ff |
|
01-May-2012 |
John McCall <rjmccall@apple.com> |
Refactor the C++ ABI code a little bit to take advantage of what I'm going to treat as basically universal properties of array-cookie code. Implement MS array cookies on top of that. Based on a patch by Timur Iskhodzhanov! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@155886 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
355bba72ca52c4a70ca3c3802412c03a6ec31f24 |
|
30-Mar-2012 |
John McCall <rjmccall@apple.com> |
Make sure we unique static-local decls across multiple emissions of the function body, but do so in a way that doesn't make any assumptions about the static local actually having a proper, unique mangling, since apparently we don't do that correctly at all. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@153776 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0f30a12ce7b3d4d86c9ca9072f587da77c8eef34 |
|
30-Mar-2012 |
Chandler Carruth <chandlerc@gmail.com> |
Revert r153723, and its follow-ups r153728 and r153733. These patches cause us to miscompile and/or reject code with static function-local variables in an extern-C context. Previously, we were papering over this as long as the variables are within the same translation unit, and had not seen any failures in the wild. We still need a proper fix, which involves mangling static locals inside of an extern-C block (as GCC already does), but this patch causes pretty widespread regressions. Firefox, and many other applications no longer build. Lots of test cases have been posted to the list in response to this commit, so there should be no problem reproducing the issues. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@153768 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
49d26d2817180ccde605c987f79cd3a5b57639cd |
|
30-Mar-2012 |
John McCall <rjmccall@apple.com> |
Do the static-locals thing properly in the face of unions and other things which might mess with the variable's type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@153733 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8cb4a070d491ddd671b049110cc8d0accb08b905 |
|
26-Mar-2012 |
Kostya Serebryany <kcc@google.com> |
add tbaa metadata to vtable pointer loads/stores git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@153447 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4e4d08403ca5cfd4d558fa2936215d3a4e5a528d |
|
11-Mar-2012 |
David Blaikie <dblaikie@gmail.com> |
Unify naming of LangOptions variable/get function across the Clang stack (Lex to AST). The member variable is always "LangOpts" and the member function is always "getLangOpts". Reviewed by Chris Lattner git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152536 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
71cba34b6e2d3fb81860bd2176ab7003eaf2e918 |
|
09-Mar-2012 |
Eli Friedman <eli.friedman@gmail.com> |
Make sure we update the static local decl address map when we are forced to rebuild a global because of the initializer. <rdar://problem/10957867>. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152372 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
025039377d7247620750205dbd61ca1ba336f7e0 |
|
08-Mar-2012 |
Rafael Espindola <rafael.espindola@gmail.com> |
Replace MarkVarRequired with a more generic HandleCXXStaticMemberVarInstantiation. Suggested by Argyrios. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152320 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
234fe654a3dd2888be42ae5db34db96c5c2c4ba3 |
|
05-Mar-2012 |
Rafael Espindola <rafael.espindola@gmail.com> |
Fix a small difference in sema and codegen views of what needs to be output. In the included testcase, soma thinks that we already have a definition after we see the out of line decl. Codegen puts it in a deferred list, to be output if a use is seen. This would break when we saw an explicit template instantiation definition, since codegen would not be notified. This patch adds a method to the consumer interface so that soma can notify codegen that this decl is now required. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@152024 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a3ca41f0c2bd1c4a752df88b283332f3b757d21e |
|
03-Mar-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Reinstate r151879, r151880, reverted in r151922, along with a bugfix for scalar emission of DeclRefExprs to const bools: emit scalar bools as i1, not as i8. In addition to the extra unit testing, this has successfully bootstrapped. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151955 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
19b1a6eb2c90fab7cefe74bea5b6de490b65ac9d |
|
25-Feb-2012 |
Sebastian Redl <sebastian.redl@getdesigned.at> |
CodeGen support for global variables of type std::initializer_list<X>. This emits a backing array with internal linkage and fills it with data, then has the initializer_list point at the array. Dynamic initialization and global destructors are correctly supported. What doesn't work is nested initializer_lists. I have no idea how to get them to work, either. However, these should be very rare, and so I'll just call it a known bug and declare generalized initializers DONE! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@151457 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a9b21d22bb9337649723a8477b5cb15f83451e7d |
|
17-Feb-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Bug fix: do not emit static const local variables with mutable members as constants. Refactor and simplify all the separate checks for whether a type can be emitted as a constant. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150793 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b49bd27b334a6c4e3bf9d810a7d5b022578f1194 |
|
16-Feb-2012 |
Dan Gohman <gohman@apple.com> |
Teach clang to add metadata tags to calls and invokes in ObjC with -fno-objc-arc-exceptions. This will allow the optimizer to perform optimizations which are only safe under that flag. This is a part of rdar://10803830. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150644 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7ca4850a3e3530fa6c93b64b740446e32c97f992 |
|
13-Feb-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Deal with a horrible C++11 special case. If a non-literal type has a constexpr constructor, and that constructor is used to initialize an object of static storage duration such that all members and bases are initialized by constant expressions, constant initialization is performed. In this case, the object can still have a non-trivial destructor, and if it does, we must emit a dynamic initializer which performs no initialization and instead simply registers that destructor. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@150419 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8b418685e9e4f02f4eb2a76e1ec063e07552b68d |
|
07-Feb-2012 |
Chris Lattner <sabre@nondot.org> |
simplify a bunch of code to use the well-known LLVM IR types computed by CodeGenModule. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149943 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0b2397132efe74ee11c1b371dd9033820c54240f |
|
06-Feb-2012 |
Chris Lattner <sabre@nondot.org> |
use cheaper llvm APIs for various bits of IR generation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@149916 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3026348bd4c13a0f83b59839f64065e0fcbea253 |
|
20-Jan-2012 |
David Blaikie <dblaikie@gmail.com> |
More dead code removal (using -Wunreachable-code) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148577 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2d6a5670465cb3f1d811695a9f23e372508240d2 |
|
14-Jan-2012 |
Richard Smith <richard-llvm@metafoo.co.uk> |
constexpr irgen: Add irgen support for APValue::Struct, APValue::Union, APValue::Array and APValue::MemberPointer. All APValue values can now be emitted as constants. Add new CGCXXABI entry point for emitting an APValue MemberPointer. The other entrypoints dealing with constant member pointers are no longer necessary and will be removed in a later change. Switch codegen from using EvaluateAsRValue/EvaluateAsLValue to VarDecl::evaluateValue. This performs caching and deals with the nasty cases in C++11 where a non-const object's initializer can refer indirectly to previously-initialized fields within the same object. Building the intermediate APValue object incurs a measurable performance hit on pathological testcases with huge initializer lists, so we continue to build IR directly from the Expr nodes for array and record types outside of C++11. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@148178 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b08cfb3c5909752c0e501a4e5c31a507a4cc1f72 |
|
08-Jan-2012 |
Fariborz Jahanian <fjahanian@apple.com> |
objc++: more atomic property api code for c++ object properties. wip. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147750 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
cd93b96bc51c255d104095bc6a6d8eac74a84b1e |
|
06-Jan-2012 |
Fariborz Jahanian <fjahanian@apple.com> |
objc++: more code gen stuff for atomic property api, currently turned off. // rdar://6137845 Also, fixes a test case which should be nonatomic under new API. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@147691 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bcf6b98247bd3ac76c5edf706b1087a8d32c0320 |
|
19-Dec-2011 |
Rafael Espindola <rafael.espindola@gmail.com> |
Extend the fix for PR9614 to handle inline asm in the outer decl and the inner decl being a builtin. This is needed to support the glibc headers in fedora 16 (2.14). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@146867 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7401cf524cdb7aad4951d8727d280f8b271af5a2 |
|
22-Nov-2011 |
Richard Smith <richard-llvm@metafoo.co.uk> |
Use static storage duration for file-scope compound literals, even when they appear in non-constant initializers in C++. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@145087 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a8ecd7c82a13be635f3f550691752a268fc69ec6 |
|
09-Nov-2011 |
Devang Patel <dpatel@apple.com> |
Remove unnecessary include. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@144210 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
64f45a24b19eb89ff88f7c3ff0df9be8e861ac97 |
|
01-Nov-2011 |
Eli Friedman <eli.friedman@gmail.com> |
Fix the representation of wide strings in the AST and IR so that it uses the native representation of integers for the elements. This fixes a bunch of nastiness involving treating wide strings as a series of bytes. Patch by Seth Cantrell. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143417 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
eea64802558cc398571938b1f28cda1d4fa79ec3 |
|
31-Oct-2011 |
Anders Carlsson <andersca@mac.com> |
In x86_64, when calling an Objective-C method that returns a _Complex long double, make sure to use the objc_msgSend_fp2ret function which ensures that the return value will be {0, 0} if the receiver is nil. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143350 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a411d2f1ed4598a7a96a7befe07a9d9ee1a6efde |
|
26-Oct-2011 |
Rafael Espindola <rafael.espindola@gmail.com> |
Fix pr9614 by not emitting an available_externally function when it calls itself via an asm label. available_externally functions are supposed to correspond to an external function, and that is not the case in the examples in pr9614. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@143049 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2ed7cb649aa709b875c519f4a980a1e2b5712370 |
|
14-Oct-2011 |
Eli Friedman <eli.friedman@gmail.com> |
PR11124: Don't overwrite memory outside of a base class when performing zero-initialization before running its constructor. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141933 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6c0aa5ff6e6253db0f993053599e2a52b5b93b2d |
|
06-Oct-2011 |
Peter Collingbourne <peter@pcc.me.uk> |
CUDA: IR generation support for kernel call expressions git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@141300 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1d2b31710539d705a3850c9fc3aa1804c2a5efee |
|
26-Sep-2011 |
Peter Collingbourne <peter@pcc.me.uk> |
Create a VTableContext class and start moving CodeGenVTables methods to it git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140502 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d6471f7c1921c7802804ce3ff6fe9768310f72b9 |
|
26-Sep-2011 |
David Blaikie <dblaikie@gmail.com> |
Rename Diagnostic to DiagnosticsEngine as per issue 5397 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140478 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8c25fc584ce27d59df9923f153e8a132dde58d04 |
|
19-Sep-2011 |
Peter Collingbourne <peter@pcc.me.uk> |
OpenCL: introduce support for function scope __local variables git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140068 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
71c758d3f4ecc8b511e6ae4a7210486aa994c182 |
|
10-Sep-2011 |
John McCall <rjmccall@apple.com> |
Simplify the generation of Objective-C setters, at least a little. Use a more portable heuristic for deciding when to emit a single atomic store; it's possible that I've lost information here, but I'm not sure how much of the logic before was intentionally arch-specific and how much was just not quite consistent. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139468 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
77f68bb90af93b95045fb994e7cd68137adcc132 |
|
10-Sep-2011 |
Julien Lerouge <jlerouge@apple.com> |
Bring llvm.annotation* intrinsics support back to where it was in llvm-gcc: can annotate global, local variables, struct fields, or arbitrary statements (using the __builtin_annotation), rdar://8037476. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139423 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ead363bdd2756efa945108941ab46bbde3bd8bdf |
|
09-Sep-2011 |
Argyrios Kyrtzidis <akyrtzi@gmail.com> |
Do a lookup for the blocks runtime globals to see if they were declared, instead of codegen waiting to consume such a declaration, which won't happen if that decls are coming from a PCH. Fixes rdar://10028656. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139359 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bcfd1f55bfbb3e5944cd5e03d07b343e280838c4 |
|
02-Sep-2011 |
Douglas Gregor <dgregor@apple.com> |
Extend the ASTContext constructor to delay the initialization of builtin types (When requested). This is another step toward making ASTUnit build the ASTContext as needed when loading an AST file, rather than doing so after the fact. No actual functionality change (yet). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@138985 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0815b579b31cb3129f732bb7ea36fd6ba6949e98 |
|
09-Aug-2011 |
Douglas Gregor <dgregor@apple.com> |
Move the creation of the record type for the state of Objective-C fast enumerations from the ASTContext into CodeGen, so that we don't need to serialize it to AST files. This appears to be the last of the low-hanging fruit for SpecialTypes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137124 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
45c4ea75b235de94f44bf96843624e6a559e4c00 |
|
09-Aug-2011 |
Douglas Gregor <dgregor@apple.com> |
Move the construction of the RecordDecl representing the runtime layout of a constant NSString from the ASTContext over to CodeGen, since this is solely CodeGen's responsibility. Eliminates one of the unnecessary "special" types that we serialize. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@137121 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a5e19c6b2554f6d9c4b9850d4dbbbfa3643282e5 |
|
04-Aug-2011 |
John McCall <rjmccall@apple.com> |
Emit wide string literals with the appropriate alignment. Patch by Craig Topper and Sundeep! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136856 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e926523105dd2604ccd5c101605dea43c5269965 |
|
27-Jul-2011 |
Peter Collingbourne <peter@pcc.me.uk> |
CodeGen: rename CodeGenModule::Runtime to ObjCRuntime git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136254 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2d3ba4f5a923a90c3fc290ddfba5e36c2d0a9b46 |
|
23-Jul-2011 |
Chris Lattner <sabre@nondot.org> |
Move ArrayRef to LLVM.h and eliminate now-redundant qualifiers, patch by Jon Mulder! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135855 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
686775deca8b8685eb90801495880e3abdd844c2 |
|
20-Jul-2011 |
Chris Lattner <sabre@nondot.org> |
now that we have a centralized place to do so, add some using declarations for some common llvm types: stringref and smallvector. This cleans up the codebase quite a bit. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135576 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2acc6e3feda5e4f7d9009bdcf8b1cd777fecfe2d |
|
18-Jul-2011 |
Chris Lattner <sabre@nondot.org> |
de-constify llvm::Type, patch by David Blaikie! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135370 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8dd55a3c3b28d195717c87bbc60e765951d408fe |
|
14-Jul-2011 |
Benjamin Kramer <benny.kra@googlemail.com> |
Change intrinsic getter to take an ArrayRef, now that the underlying function in LLVM does. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135155 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9cbe4f0ba01ec304e1e3d071c071f7bca33631c0 |
|
09-Jul-2011 |
Chris Lattner <sabre@nondot.org> |
clang side to match the LLVM IR type system rewrite patch. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134831 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bc8d40d85f3fa1e34569834916f18fecaa635152 |
|
24-Jun-2011 |
John McCall <rjmccall@apple.com> |
Change the IR-generation of VLAs so that we capture bounds, not sizes; so that we use well-typed allocas; and so that we properly recurse through the full set of variably-modified types. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133827 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f85e193739c953358c865005855253af4f68a497 |
|
16-Jun-2011 |
John McCall <rjmccall@apple.com> |
Automatic Reference Counting. Language-design credit goes to a lot of people, but I particularly want to single out Blaine Garst and Patrick Beard for their contributions. Compiler implementation credit goes to Argyrios, Doug, Fariborz, and myself, in no particular order. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133103 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
fd05ca03abdfb38f78b9535d996ecc9c39d3b0db |
|
14-Jun-2011 |
Peter Collingbourne <peter@pcc.me.uk> |
Move GlobalDecl to AST git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@132973 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0774cb84719f2aea3016493a2bbd9a02aa3e0541 |
|
15-May-2011 |
John McCall <rjmccall@apple.com> |
Use arrays and SmallVectors instead of std::vectors when building function types. Also, cache a translation of 'void' in CGM and provide a ptrdiff_t alias. No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@131373 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3dc05418538c719fea48b906bfa4febe5296e126 |
|
05-May-2011 |
Nick Lewycky <nicholas@mxc.ca> |
Preserve the full name of the file, so that '-c -o foo.pic.o' produces foo.pic.gcno instead of foo.gcno. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130899 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5ea4f44e34449a78d6b38aa47c14b527839d7aac |
|
04-May-2011 |
Nick Lewycky <nicholas@mxc.ca> |
Record where the GCOV data files should be placed. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@130866 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
755d8497e39071aa24acc173ff07083e3256b8f8 |
|
12-Apr-2011 |
John McCall <rjmccall@apple.com> |
After some discussion with Doug, we decided that it made a lot more sense for __unknown_anytype resolution to destructively modify the AST. So that's what it does now, which significantly simplifies some of the implementation. Normal member calls work pretty cleanly now, and I added support for propagating unknown-ness through &. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129331 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1de4d4e8cb2e9c88809fea8092bc6e835a5473d2 |
|
07-Apr-2011 |
John McCall <rjmccall@apple.com> |
Basic, untested implementation for an "unknown any" type requested by LLDB. The idea is that you can create a VarDecl with an unknown type, or a FunctionDecl with an unknown return type, and it will still be valid to access that object as long as you explicitly cast it at every use. I'm still going back and forth about how I want to test this effectively, but I wanted to go ahead and provide a skeletal implementation for the LLDB folks' benefit and because it also improves some diagnostic goodness for placeholder expressions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@129065 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f0c11f7e6848f023ced6a5b51399ba787c7d4d0b |
|
31-Mar-2011 |
John McCall <rjmccall@apple.com> |
After much contemplation, I've decided that we probably shouldn't "unique" __block object copy/dispose helpers for C++ objects with those for different variables with completely different semantics simply because they happen to both be no more aligned than a pointer. Found by inspection. Also, internalize most of the helper generation logic within CGBlocks.cpp, and refactor it to fit my peculiar aesthetic sense. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128618 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bda0d6bda0f1a08a9fdf3ee4cf550b6b10d454ec |
|
27-Mar-2011 |
John McCall <rjmccall@apple.com> |
We were emitting construction v-tables with internal linkage all the time. Emit them instead with the linkage of the VTT. I'm actually really ambivalent about this; it's what GCC does, but outside of improving code size (if the linkage is coalescing), I'm not sure it's at all relevant. Construction vtables are naturally referenced only by the VTT, which is itself only referenced by complete-object constructors and destructors; giving the construction vtables possibly-external linkage is important if you have an optimization that drills through the VTT to a reference to a particular construction vtable which it cannot just emit itself. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128374 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e80d56771736c85fd8365c394a6731923b17e91d |
|
23-Mar-2011 |
Devang Patel <dpatel@apple.com> |
Update type cache when a type is completed. Radar 9168773 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@128150 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
32096695c76033a6b0b1747c439f7378a11e8312 |
|
18-Mar-2011 |
John McCall <rjmccall@apple.com> |
The Darwin kernel does not provide useful guard variable support. Issue this as an IR-gen error; it's not really worthwhile doing this "right", i.e. in Sema, because IR gen knows a lot of tricks beyond what the constant evaluator knows. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127854 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1f6f961293da9c2b1c23da2411c1b439a9502ed0 |
|
09-Mar-2011 |
John McCall <rjmccall@apple.com> |
Fix three of the four places where I left breadcrumbs to avoid unnecessary recomputation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127322 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d26bc76c98006609002d9930f8840490e88ac5b5 |
|
09-Mar-2011 |
John McCall <rjmccall@apple.com> |
Use the "undergoes default argument promotion" bit on parameters to simplify the logic of initializing function parameters so that we don't need both a variable declaration and a type in FunctionArgList. This also means that we need to propagate the CGFunctionInfo down in a lot of places rather than recalculating it from the FAL. There's more we can do to eliminate redundancy here, and I've left FIXMEs behind to do it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127314 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
aa11289f754d220c9c155b68a4f84cdcfcefef6a |
|
07-Mar-2011 |
Devang Patel <dpatel@apple.com> |
DebugInfo can be enabled or disabled at function level (e.g. using an attribute). However, at module level it is determined by command line option and the state of command line option does not change during compilation. Make this layering explicit and fix accidental cases where the code generator was checking whether module has debug info enabled instead of checking whether debug info is enabled for this function or not. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127165 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5de7a0e8800b89780e565c1013e566414f11546a |
|
07-Mar-2011 |
Devang Patel <dpatel@apple.com> |
Do not emit stop point for CXXDefaultArgExpr. It results in suboptimial user experience. 21 int main() { 22 A a; For example, here user would expect to stop at line 22, even if A's constructor leads to a call through CXXDefaultArgExpr. This fixes ostream-defined.exp regression from gdb testsuite. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127164 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9de4342ef79a18c706e46bc23f8f579f5add2375 |
|
05-Mar-2011 |
Benjamin Kramer <benny.kra@googlemail.com> |
StringRefify. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@127082 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bc7fbf0d37b286b37d96b033dfaaabf9c729bca8 |
|
26-Feb-2011 |
John McCall <rjmccall@apple.com> |
Pretty up the emission of field l-values and use volatile and TBAA when loading references as part of that. Use 'char' TBAA when accessing (immediate!) fields of a may_alias struct; fixes PR9307. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126540 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8178df3b39ab923ff5d24538812628abee33df79 |
|
22-Feb-2011 |
John McCall <rjmccall@apple.com> |
Emit the structure layout of the block literal parameter to a block invocation function into the debug info. Rather than faking up a class, which is tricky because of the custom layout we do, we just emit a struct directly from the layout information we've already got. Also, don't emit an unnecessarily parameter alloca for this "variable". git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126255 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
34695856c0e67b3765b46304cc71b5d2cd5b71c7 |
|
22-Feb-2011 |
John McCall <rjmccall@apple.com> |
Reorganize the emission of local variables. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@126189 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5936e33bf74dd6bf126ceee0f6169a2593d03a69 |
|
15-Feb-2011 |
John McCall <rjmccall@apple.com> |
Assorted cleanup: - Have CGM precompute a number of commonly-used types - Have CGF copy that during initialization instead of recomputing them - Use TBAA info when initializing a parameter variable - Refactor the scalar ++/-- code git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125562 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d16c2cf1cafa413709aa487cbbd5dc392f1ba1ff |
|
08-Feb-2011 |
John McCall <rjmccall@apple.com> |
Reorganize CodeGen{Function,Module} to eliminate the unfortunate Block{Function,Module} base class. Minor other refactorings. Fixed a few address-space bugs while I was there. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125085 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
84c49e4e4baeb4c30251fd72220efb344b033cf0 |
|
06-Feb-2011 |
Anders Carlsson <andersca@mac.com> |
Simplify thunks code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124983 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bbfd5babab059af14eed20b63b2aabedaa6a6ac7 |
|
05-Feb-2011 |
Anders Carlsson <andersca@mac.com> |
Pass a 'ForVTable' flag to GetAddrOfThunk and pass it along to GetOrCreateLLVMFunction so that we won't assert when building a thunk for an implicit virtual member function that is not marked used. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124967 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1faa89f9c619e4b2411fab4af7e22ee7a2bd9009 |
|
05-Feb-2011 |
Anders Carlsson <andersca@mac.com> |
Re-land r124768, with a fix for PR9130. We now emit everything except unused implicit virtual member functions when building the vtable. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124935 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5808ce43f8d7e71f5acacc9ca320268c4f37565a |
|
03-Feb-2011 |
John McCall <rjmccall@apple.com> |
More capturing of 'this': implicit member expressions. Getting that right for anonymous struct/union members led to me discovering some seemingly broken code in that area of Sema, which I fixed, partly by changing the representation of member pointer constants so that IndirectFieldDecls aren't expanded. This led to assorted cleanups with member pointers in CodeGen, and while I was doing that I saw some random other things to clean up. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124785 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
01de7a44cea9f77cbcda65faad8edc8b48a3b617 |
|
03-Feb-2011 |
Rafael Espindola <rafael.espindola@gmail.com> |
Revert 124768. This reopens PR99114, but that one at least can be avoided with an #include. PR9130 cannot. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124780 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
aedd9d5ad3cc776fd61457050bcd54cac4c5ea66 |
|
03-Feb-2011 |
Anders Carlsson <andersca@mac.com> |
Don't try to mark virtual members referenced for classes where the key function is not defined in the current translation unit. Doing so lead to compile errors such as PR9114. Instead, when CodeGen is building the vtable, don't try to emit a definition for functions that aren't marked used in the current translation unit. Fixes PR9114. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124768 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c7e98fabd852e9dfa7409b7fc664b87322522c43 |
|
29-Jan-2011 |
Anders Carlsson <andersca@mac.com> |
Move GetLLVMVisibility to CodeGenModule. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124550 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
fa2e99f72f9bfe2270ea8caf76d0eef11c45259f |
|
29-Jan-2011 |
Anders Carlsson <andersca@mac.com> |
Change CodeGenModule::setTypeVisibility to take a TypeVisibilityKind enum instead of an "IsForRTTI" flag. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124546 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0ffeaad72cb335b926b064379be4c9886bbff004 |
|
29-Jan-2011 |
Anders Carlsson <andersca@mac.com> |
Get rid of an unneeded parameter from setGlobalVisibility. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124541 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3bd6202ea2d5b5f7c8229cd280a846ae3dcf2355 |
|
29-Jan-2011 |
Anders Carlsson <andersca@mac.com> |
Add a new function, to be used by CGRTTI, CGVTables and CGVTT (which each has their own copy of this code). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124537 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c93a776c89bd0820813e5c7c87af2c820d9bbd27 |
|
29-Jan-2011 |
Anders Carlsson <andersca@mac.com> |
Remove IsDefinition from CodeGenModule::setTypeVisibility; it is always true. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124529 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3a717f7fbb94ec31b826b48c15fdc965b5910df3 |
|
24-Jan-2011 |
Anders Carlsson <andersca@mac.com> |
Change CodeGenModule::getVTableLinkage to be a non-static member function. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124095 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c532b502858032f377056dc8cba2fe43cba8702b |
|
18-Jan-2011 |
Rafael Espindola <rafael.espindola@gmail.com> |
Add unnamed_addr in CreateRuntimeVariable. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123773 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
14110477887e3dc168ffc6c191e72d705051f99e |
|
13-Jan-2011 |
Peter Collingbourne <peter@pcc.me.uk> |
Move name mangling support from CodeGen to AST. In the process, perform a number of refactorings: - Move MiscNameMangler member functions to MangleContext - Remove GlobalDecl dependency from MangleContext - Make MangleContext abstract and move Itanium/Microsoft functionality to their own classes/files - Implement ASTContext::createMangleContext and have CodeGen use it No (intended) functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123386 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9f0c7cc36d29cf591c33962931f5862847145f3e |
|
30-Dec-2010 |
Benjamin Kramer <benny.kra@googlemail.com> |
Simplify mem{cpy, move, set} creation with IRBuilder. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@122634 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3030eb82593097502469a8b3fc26112c79c75605 |
|
06-Nov-2010 |
John McCall <rjmccall@apple.com> |
Simplify the logic for emitting guard variables for template static data members by delaying the emission of the initializer until after linkage and visibility have been set on the global. Also, don't emit a guard unless the variable actually ends up with vague linkage, and don't use thread-safe statics in any case. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@118336 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
af14603ca61757cf4361b583b45639a04c57e651 |
|
30-Oct-2010 |
John McCall <rjmccall@apple.com> |
Better solution: calculate the visibility of functions and variables independently of whether they're definitions, then teach IR generation to ignore non-explicit visibility when emitting declarations. Use this to make sure that RTTI, vtables, and VTTs get the right visibility. More of rdar://problem/8613093 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117781 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
354e712c81fbb07c0ce5f06180788b25fffa1b56 |
|
27-Oct-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
Do the guarding of instantiated static data members on if its linkage is weak. Currently this is the case but may change in the future. (part of radar 8562966). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117452 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1fb0caaa7bef765b85972274e3b434af2572c141 |
|
22-Oct-2010 |
John McCall <rjmccall@apple.com> |
Substantially revise how clang computes the visibility of a declaration to more closely parallel the computation of linkage. This gets us to a state much closer to what gcc emits, modulo bugs, which will undoubtedly arise in abundance. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@117147 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4c73307c74764ba99e1379677fe92af72f676531 |
|
19-Oct-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
This patch implements Next's IRGen for -fconstant-string-class=class-name. PR6056, //rdar: //8564463 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116819 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3d5aff5d3036b0ff09d114857cd2276134b3d8c9 |
|
15-Oct-2010 |
Dan Gohman <gohman@apple.com> |
Experimental TBAA support. This enables metadata generation by default, however the TBAA pass in the optimizer is still disabled for now. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116536 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b25938303de0976b9f189363d43033e5788e3d36 |
|
16-Sep-2010 |
John McCall <rjmccall@apple.com> |
Opportunistically use the C++ personality function in ObjC++ translation units that don't catch ObjC types. rdar://problem/8434851 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@114070 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4c40d98ab7acf5f27fa89b17bd8fc0ef7683df37 |
|
31-Aug-2010 |
John McCall <rjmccall@apple.com> |
Teach IR generation to return 'this' from constructors and destructors under the ARM ABI. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112588 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0bab0cdab751248ca389a5592bcb70eac5d39260 |
|
23-Aug-2010 |
John McCall <rjmccall@apple.com> |
Abstract out everything having to do with member pointers into the ABI class; they should just be completely opaque throughout IR gen now, although I haven't really audited that. Fix a bug apparently inherited from gcc-4.2 where we failed to null-check member data pointers when performing derived-to-base or base-to-derived conversions on them. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111789 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f16aa103d3afd42fbca2ab346f191bf745cec092 |
|
22-Aug-2010 |
John McCall <rjmccall@apple.com> |
Go back to asking CodeGenTypes whether a type is zero-initializable. Make CGT defer to the ABI on all member pointer types. This requires giving CGT a handle to the ABI. It's way easier to make that work if we avoid lazily creating the ABI. Make it so. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111786 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
875ab10245d3bf37252dd822aa1616bb0a391095 |
|
22-Aug-2010 |
John McCall <rjmccall@apple.com> |
Abstract out member-pointer creation. I'm really unhappy about the current duplication between the constant and non-constant paths in all of this. Implement ARM ABI semantics for member pointer constants and conversion. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111772 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
071cc7deffad608165b1ddd5263e8bf181861520 |
|
16-Aug-2010 |
Charles Davis <cdavis@mines.edu> |
Implement support for member pointers under the Microsoft C++ ABI in the AST library. This also adds infrastructure for supporting multiple C++ ABIs in the AST. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@111117 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f871d0cc377a1367b519a6cce26be74607566eba |
|
07-Aug-2010 |
John McCall <rjmccall@apple.com> |
Store inheritance paths after CastExprs instead of inside them. This takes some trickery since CastExpr has subclasses (and indeed, is abstract). Also, smoosh the CastKind into the bitfield from Expr. Drops two words of storage from Expr in the common case of expressions which don't need inheritance paths. Avoids a separate allocation and another word of overhead in cases needing inheritance paths. Also has the advantage of not leaking memory, since destructors for AST nodes are never run. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110507 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
cbfe50224b19119e759802bd0c1463269dffd09e |
|
04-Aug-2010 |
John McCall <rjmccall@apple.com> |
Emit standard-library RTTI with external linkage, not weak_odr. Apply hidden visibility to most RTTI; libstdc++ does not rely on exact pointer equality for the type info (just the type info names). Apply the same optimization to RTTI that we do to vtables. Fixes PR5962. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@110192 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
90e99a84ddd020e8fda79643748243725a2ed071 |
|
29-Jul-2010 |
Argyrios Kyrtzidis <akyrtzi@gmail.com> |
Merge PCHWriterDecl.cpp's isRequiredDecl and CodeGenModule::MayDeferGeneration into a new function, DeclIsRequiredFunctionOrFileScopedVar. This is essentially a CodeGen predicate that is also needed by the PCH mechanism to determine whether a decl needs to be deserialized during PCH loading for codegen purposes. Since this logic is shared by CodeGen and the PCH mechanism, move it to the ASTContext, thus CodeGenModule's GetLinkageForFunction/GetLinkageForVariable and the GVALinkage enum is moved out of CodeGen. This fixes current (and avoids future) codegen-from-PCH bugs. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109784 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ea0443212e7ec6ff82e2f174e8e948a6eb0e0876 |
|
29-Jul-2010 |
Chris Lattner <sabre@nondot.org> |
cave in to reality and make ABIInfo depend on CodeGenTypes. This will simplify a bunch of code, coming up next. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@109722 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
754b9fbaa13749c61393cc613eec7c79efe60ddf |
|
16-Jul-2010 |
Daniel Dunbar <daniel@zuster.org> |
IRgen: Support user defined attributes on block runtime functions. - This issue here is that /usr/include/Blocks.h wants to define some of the block runtime globals as weak, depending on the target. This doesn't work in Clang because we aren't using the AST decl for these globals. - The fix is a pretty gross hack which just watches all the decls for the specific blocks globals we need to know about; if we see one we use it, otherwise we use the hand coded type. In time, I would like to clean this up by changing IRgen to ask Sema/AST for the decl, which would then be lazily loaded from the builtin table if necessary. This could be used in a whole host of places in IRgen and would get rid of a lot of grotty hand coding of LLVM IR; however, we need some extra Sema support for this as well as support for builtin global variables. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108482 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
673431a2986f750b4d8fadb57abf3f00db27bbbd |
|
16-Jul-2010 |
Daniel Dunbar <daniel@zuster.org> |
IRgen: Move blocks runtime interfaces to CodeGenModule. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108481 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bf40cb518312dde1c07e44fcae59bc4eec65589c |
|
16-Jul-2010 |
John McCall <rjmccall@apple.com> |
When deferring the emission of declarations with initializers in C++, remember the order they appeared in the translation unit. If they get emitted, put them in their proper order. Fixes rdar://problem/7458115 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108477 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
dacf9dda17346c628fdd8c5df53c681738db0dc5 |
|
15-Jul-2010 |
Daniel Dunbar <daniel@zuster.org> |
CodeGen/ObjC/NeXT: Fix Obj-C message send to match llvm-gcc when choosing whether to use objc_msgSend_fpret; the choice is target dependent, not Obj-C ABI dependent. - <rdar://problem/8139758> arm objc _objc_msgSend_fpret bug git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@108379 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
744016dde06fcffd50931e94a98c850f8b12cd87 |
|
07-Jul-2010 |
John McCall <rjmccall@apple.com> |
Provide a hook for the benefit of clients using clang IR gen as a subroutine: emit metadata associating allocas and global values with a Decl*. This feature is controlled by an option that (intentionally) cannot be enabled on the command line. To use this feature, simply set CodeGenOptions.EmitDeclMetadata = true; and then interpret the completely underspecified metadata. :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@107739 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ec2830d930e306124c2ba6bf1060a3c71dced6ea |
|
27-Jun-2010 |
Chris Lattner <sabre@nondot.org> |
tidy up OrderGlobalInits git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106976 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
564360be450b319aeafc26698be9811837bfb826 |
|
24-Jun-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
Patch to correctly mangle block helper functions when block literal is declared inside a ctor/dtor. Fixes radr 8096995. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106700 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9a20d55807cc2f6534a9c51a46cc8143ed16786d |
|
22-Jun-2010 |
Anders Carlsson <andersca@mac.com> |
Switch over to the new caching version of getMangledName. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106549 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
793a990774826a0c20b0da66cec0991badfb8b63 |
|
22-Jun-2010 |
Anders Carlsson <andersca@mac.com> |
Add a new variant of getMangledName that caches the mangling for decls. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106547 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f489688114275c821b1e647e26f71eeb94d8ab24 |
|
22-Jun-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
Per Chris's comment, remove another static (this one is a static comparator operator). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106511 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e0b691a25f801d8be552c9387863637b9526e639 |
|
21-Jun-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
In supporting init-priority, globals with the same init_priority must be emitted in the order in which they are seen (still radar 8076356). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106485 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9f967c5e4bbeb48caf6d0e62056b3d3fee20bf7c |
|
21-Jun-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
IRGen for implementation of init-priority attribute. Test case will be checked in llvm test suite. (finishes off radar 8076356). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106441 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
810112e28dc839715d17b0a786f23aaa19600ac0 |
|
19-Jun-2010 |
Chris Lattner <sabre@nondot.org> |
Fix PR7097, a bad interaction between -fno-use-cxa-atexit and -mconstructor-aliases by using a WeakVH instead of a raw pointer. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@106384 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9a8822bb154b792cdb18fe4cfb34480ca0ec7661 |
|
09-Jun-2010 |
Anders Carlsson <andersca@mac.com> |
Get rid of getMangledCXXCtorName and getMangledCXXDtorName. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105673 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
afd04290de594111fe0f5917317e3a68e28639cf |
|
09-Jun-2010 |
Anders Carlsson <andersca@mac.com> |
Get rid of an unnecessary getMangledName overload. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105671 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c00129a08c829bb34f22dc13727043c994c85644 |
|
30-May-2010 |
Eli Friedman <eli.friedman@gmail.com> |
Fix for PR7040: Don't try to compute the LLVM type for a function where it isn't possible to compute. This patch is mostly refactoring; the key change is the addition of the code starting with the comment, "Check whether the function has a computable LLVM signature." The solution here is essentially the same as the way the vtable code handles such functions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@105151 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3a811f1f4286ee3fd0c563c1cfe623956f3caa24 |
|
25-May-2010 |
Charles Davis <cdavis@mines.edu> |
IRgen: Add a stub class for generating ABI-specific C++ code. This class only supports name mangling (which is apparently used during C/ObjC codegen). For now only the Itanium C++ ABI is supported. Patches to add a second C++ ABI are forthcoming. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104630 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
35415f5132f70ad5097a3514ab84251e10db3664 |
|
25-May-2010 |
Douglas Gregor <dgregor@apple.com> |
Improve name mangling for blocks and support mangling of static local variables within blocks. We loosely follow GCC's mangling, but since these are always internal symbols the names don't really matter. I intend to revisit block mangling later, because GCC's mangling is rather verbose. <rdar://problem/8015719>. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104610 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8b2423361648c39a7d8a3c5e8129e12006deac32 |
|
25-May-2010 |
John McCall <rjmccall@apple.com> |
If a function definition has any sort of weak linkage, its static local variables should have that linkage. Otherwise, its static local variables should have internal linkage. To avoid computing this excessively, set a function's linkage before we emit code for it. Previously we were assigning weak linkage to the static variables of static inline functions in C++, with predictably terrible results. This fixes that and also gives better linkage than 'weak' when merging is required. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@104581 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6fb745bdf1ff1e32caf07e42093a7920726892c1 |
|
13-May-2010 |
Douglas Gregor <dgregor@apple.com> |
Rework when and how vtables are emitted, by tracking where vtables are "used" (e.g., we will refer to the vtable in the generated code) and when they are defined (i.e., because we've seen the key function definition). Previously, we were effectively tracking "potential definitions" rather than uses, so we were a bit too eager about emitting vtables for classes without key functions. The new scheme: - For every use of a vtable, Sema calls MarkVTableUsed() to indicate the use. For example, this occurs when calling a virtual member function of the class, defining a constructor of that class type, dynamic_cast'ing from that type to a derived class, casting to/through a virtual base class, etc. - For every definition of a vtable, Sema calls MarkVTableUsed() to indicate the definition. This happens at the end of the translation unit for classes whose key function has been defined (so we can delay computation of the key function; see PR6564), and will also occur with explicit template instantiation definitions. - For every vtable defined/used, we mark all of the virtual member functions of that vtable as defined/used, unless we know that the key function is in another translation unit. This instantiates virtual member functions when needed. - At the end of the translation unit, Sema tells CodeGen (via the ASTConsumer) which vtables must be defined (CodeGen will define them) and which may be used (for which CodeGen will define the vtables lazily). From a language perspective, both the old and the new schemes are permissible: we're allowed to instantiate virtual member functions whenever we want per the standard. However, all other C++ compilers were more lazy than we were, and our eagerness was both a performance issue (we instantiated too much) and a portability problem (we broke Boost test cases, which now pass). Notes: (1) There's a ton of churn in the tests, because the order in which vtables get emitted to IR has changed. I've tried to isolate some of the larger tests from these issues. (2) Some diagnostics related to implicitly-instantiated/implicitly-defined virtual member functions have moved to the point of first use/definition. It's better this way. (3) I could use a review of the places where we MarkVTableUsed, to see if I missed any place where the language effectively requires a vtable. Fixes PR7114 and PR6564. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103718 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9dffe6f51c676c1e423c382c62d1648746e36cd4 |
|
30-Apr-2010 |
John McCall <rjmccall@apple.com> |
Fix -fno-rtti -fexceptions by forcing the emission of (non-"builtin") RTTI when used by the exceptions routines. Fixes PR 6974. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102684 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
109dfc6ca6652f60c55ed0f2631aebf323d0200d |
|
28-Apr-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
IRGen for initialization/destruction of ivar class objects (NeXt runtime). (radar 7900343). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102533 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e04d45e05277ee04997fe59b1d194503f484c846 |
|
24-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Get rid of the old GetNonVirtualBaseClassOffset and change all call sites to use the new version. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102274 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a04efdf635d35d88e65041fad007225d8c8d64a5 |
|
24-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Change CodeGenFunction::GetAddressOfDerivedClass to take a BasePath. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102273 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2bb5ddaff86ee73d2cea7ec1835978afc88a83f0 |
|
23-Apr-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
More work toward implementing NeXt's -fno-constant-cfstrings - wip. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102189 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
33e982bf782d851bfe5767acb1336fcf3419ac6b |
|
22-Apr-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
Support for -fno-constant-cfstrings option - wip. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@102112 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
63326a53418b4853a83b360ce1dbdb10c5739fc7 |
|
19-Apr-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
Some renaming of methods, fixes typo (related to PR6769). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101794 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
65ad5a42cca954e070428dcc499b62393aa7a6d3 |
|
18-Apr-2010 |
Fariborz Jahanian <fjahanian@apple.com> |
Local static variables must be available module-wise as they are accessible in static methods in a class local to the same function. Fixes PR6769. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101756 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
046c294a43024874ff35656c6e785b64e72f1f36 |
|
17-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Vtable -> VTable renames across the board. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101666 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
461e326e74fa840945330a04df33b1180b08ddc0 |
|
08-Apr-2010 |
Anders Carlsson <andersca@mac.com> |
Rename CGVtable files to CGVTables. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100778 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e17ad2fd5c4b66c712bdffd2789eaafc54a9b001 |
|
08-Apr-2010 |
Douglas Gregor <dgregor@apple.com> |
Unbreak the build git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100775 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3ecd785aff34381f3704d9cb28fe3ef85af759de |
|
04-Apr-2010 |
Mon P Wang <wangmp@apple.com> |
Reapply patch for adding support for address spaces and added a isVolatile field to memcpy, memmove, and memset. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100305 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c90f56d9f144b2dce88d1c141ddf0e0940e62e63 |
|
02-Apr-2010 |
Mon P Wang <wangmp@apple.com> |
Revert r100193 since it causes failures in objc in clang git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100200 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8facca6cafa8d471768fe14074b1301e24e08fec |
|
02-Apr-2010 |
Mon P Wang <wangmp@apple.com> |
Reapply patch for adding support for address spaces and added a isVolatile field to memcpy, memmove, and memset. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100193 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6876fe615e16b0e76c7711e129e470305b7e9d41 |
|
31-Mar-2010 |
Benjamin Kramer <benny.kra@googlemail.com> |
Minor include pruning. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@100007 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b5896c37922e09529e61db4b3dd946cf2ecb211e |
|
31-Mar-2010 |
Bob Wilson <bob.wilson@apple.com> |
Revert Mon Ping's 99930 due to broken llvm-gcc buildbots. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99949 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3b5caa20652c43d00229bac972b78bee44a0ee9f |
|
30-Mar-2010 |
Mon P Wang <wangmp@apple.com> |
Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99930 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bfb7a1d6eba6714bd71db921092332da65b774c0 |
|
30-Mar-2010 |
Anders Carlsson <andersca@mac.com> |
Remove the old vtable layout code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99869 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d1a5c31b78997befe75d10a4731cee4ab211cc31 |
|
27-Mar-2010 |
Rafael Espindola <rafael.espindola@gmail.com> |
When given the magic class __cxxabiv1::__fundamental_type_info, produce the typeinfo for the fundamental types. Fixes PR6685. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99701 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f532f3b4a642ad5d9704c4a1d17b61cc52ab2f65 |
|
24-Mar-2010 |
Anders Carlsson <andersca@mac.com> |
Remove old thunks code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99374 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
19879c98d964bc67442618510af04e3457219780 |
|
23-Mar-2010 |
Anders Carlsson <andersca@mac.com> |
More thunks scaffolding. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99294 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
af4403545a50a60d208e6fcae057308d576a92e0 |
|
23-Mar-2010 |
Anders Carlsson <andersca@mac.com> |
Rename CGVtableInfo to CodeGenVTables in preparation of adding another VTableInfo class. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99250 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
efb0fa9e11f75af51744a6159530ef7cc8efa24a |
|
20-Mar-2010 |
Daniel Dunbar <daniel@zuster.org> |
C++: Add support for -fno-use-cxa-atexit. - So much typing, so little gain... Also, rename the __cxx_global_initialization function just to match llvm-gcc. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99039 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f746aa6a8f538be914173a4aef2d9a2fd9f99d17 |
|
20-Mar-2010 |
John McCall <rjmccall@apple.com> |
Change CodeGenModule to rely on the Module's symbol table instead of shadowing it in the GlobalDeclMap. Eliminates the string-uniquing requirement for mangled names, which should help C++ codegen times a little. Forces us to do string lookups instead of pointer lookups, which might hurt codegen times a little across the board. We'll see how it plays out. Removing the string-uniquing requirement implicitly fixes any bugs like PR6635 which arose from the fact that we had multiple uniquing tables for different kinds of identifiers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@99012 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8f51a4f2d00b0abda3cde7f3828fb2e2b9beafb5 |
|
13-Mar-2010 |
Douglas Gregor <dgregor@apple.com> |
Give explicit template instantiations weak ODR linkage. Former iterations of this patch gave explicit template instantiation link-once ODR linkage, which permitted the back end to eliminate unused symbols. Weak ODR linkage still requires the symbols to be generated. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98441 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
34fd284e0a6ea88b98d6e1183548264bab5b3702 |
|
13-Mar-2010 |
Douglas Gregor <dgregor@apple.com> |
Re-revert the explicit template instantiation linkage patch. I am beginning to look incompetent git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98425 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8721360da5cf3d5dfdc2fc2bf8d53a5f79307995 |
|
13-Mar-2010 |
Douglas Gregor <dgregor@apple.com> |
Reinstate patch to turn explicit template instantiations into weak symbols git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98424 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4ea9006629acb6bf9b2984554517c968a10a6b77 |
|
12-Mar-2010 |
Douglas Gregor <dgregor@apple.com> |
Revert the linkage change for explicit template instantiations; something is amiss git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98332 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e5e0c9deb1b4cfa081152cda548d31368facbc57 |
|
12-Mar-2010 |
Douglas Gregor <dgregor@apple.com> |
Give explicit template instantiations weak linkage (but don't defer them). Fixes PR6578. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98328 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bbf58bb1b8dd8c5e0f07547a6c20ffd55385fcf6 |
|
10-Mar-2010 |
Rafael Espindola <rafael.espindola@gmail.com> |
Delay codegen of vtables when handling implicit instantiations. This fixes PR6474. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@98123 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6374c3307e2d73348f7b8cc73eeeb0998ad0ac94 |
|
06-Mar-2010 |
John McCall <rjmccall@apple.com> |
Implement __builtin_dwarf_sp_column for i386 (Darwin and not), x86-64 (all), and ARM. Implement __builtin_init_dwarf_reg_size_table for i386 (both) and x86-64 (all). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97859 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6a836706c40a31c716952b74785102c90fd6afa7 |
|
04-Mar-2010 |
Rafael Espindola <rafael.espindola@gmail.com> |
Fix PR6473. Clang's support for weakref is now better than llvm-gcc's :-) We don't introduce a new symbol and we correctly mark undefined references weak only if there is no definition or regular undefined references in the same file. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97733 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
468ec6c0266e48fccb26ce50d5b915c645bb3c7b |
|
04-Mar-2010 |
John McCall <rjmccall@apple.com> |
Revert changes r97693, r97700, and r97718. Our testing framework can't deal with disabled targets yet. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97719 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c9fe644675503894e9e76e8ecd8e6519426548de |
|
04-Mar-2010 |
John McCall <rjmccall@apple.com> |
Create a TargetMachine whenever we create a CodeGenAction. The codegen of some builtins will rely on target knowledge. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@97693 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c0bf462cf35fe050bddbd8bff967298e4a67e79d |
|
23-Feb-2010 |
John McCall <rjmccall@apple.com> |
Perform two more constructor/destructor code-size optimizations: 1) emit base destructors as aliases to their unique base class destructors under some careful conditions. This is enabled for the same targets that can support complete-to-base aliases, i.e. not darwin. 2) Emit non-variadic complete constructors for classes with no virtual bases as calls to the base constructor. This is enabled on all targets and in theory can trigger in situations that the alias optimization can't (mostly involving virtual bases, mostly not yet supported). These are bundled together because I didn't think it worthwhile to split them, not because they really need to be. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96842 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d46f98573ba104eda102dd3224b2dca69f1c6336 |
|
19-Feb-2010 |
John McCall <rjmccall@apple.com> |
Re-introduce the ctor/dtor alias optimization, this time hidden behind a command-line option which defaults off. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96649 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8e51a1f5da6ef4a1a168d14116c6eed3a578a263 |
|
18-Feb-2010 |
John McCall <rjmccall@apple.com> |
Revert the ctor/dtor alias optimization for now; the buildbots can detect some failure here that I can't. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96612 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
92ac9ffecd236a6be0d6ab30cef56100e56b171c |
|
17-Feb-2010 |
John McCall <rjmccall@apple.com> |
Emit complete constructors and destructors as aliases to base constructors and destructors when the two entities are semantically identical, i.e. when the class has no virtual base classes. We only do this for linkage types for which aliases are supported, i.e. internal and external, i.e. not linkonce. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@96451 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b2bcf1c176b200b36f371e189ce22f93c86cdf45 |
|
06-Feb-2010 |
Anders Carlsson <andersca@mac.com> |
Use the correct function info for constructors when applying function attributes. Fixes PR6245. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95474 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
45147d0098a34c3705f74ca121b27d7736ac113a |
|
02-Feb-2010 |
Anders Carlsson <andersca@mac.com> |
Move pointer to data member emission to CodeGenModule and use it in CGExprConstant. Fixes PR5674. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@95063 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bb7e17b52ffaa4097b4c4d7935746d23539ffe2a |
|
31-Jan-2010 |
Anders Carlsson <andersca@mac.com> |
Some class related cleanup. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@94938 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
687cc4a850b59116efee061018f0d8df50728b82 |
|
26-Jan-2010 |
Ken Dyck <ken.dyck@onsemi.com> |
Introduce CodeGenModule::GetTargetTypeStoreSize() to calculate the store size of LLVM types in character units. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@94542 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0d13f6fdbdd6f06e2449b8834dda53334abd399a |
|
23-Jan-2010 |
David Chisnall <csdavec@swan.ac.uk> |
Created __builtin___NSStringMakeConstantString() builtin, which generates constant Objective-C strings. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@94274 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
82d0a418c8699fc6f4a9417457ffe93d43bba1c1 |
|
10-Jan-2010 |
Anton Korobeynikov <asl@math.spbu.ru> |
Generalize target weirdness handling having proper layering in mind: 1. Add helper class for sema checks for target attributes 2. Add helper class for codegen of target attributes As a proof-of-concept - implement msp430's 'interrupt' attribute. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@93118 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6c6bda3b0b1d8adaac2ba3f4da7056e9f1eef52e |
|
08-Jan-2010 |
Eli Friedman <eli.friedman@gmail.com> |
Fix for PR5967: Make const-marking for LLVM globals correct for cases requiring run-time initialization, and emit run-time initializers aggresively to avoid ordering issues with deferred globals. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92976 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
dffb8010a130733f1b55acf0af01deb0a2e083d3 |
|
06-Jan-2010 |
Douglas Gregor <dgregor@apple.com> |
Fix linkage for RTTI names by re-using the logic for computing the linkage of vtables. Before this, we were emitting RTTI names for template instantiations with strong external linkage rather than with weak ODR linkage. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92857 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4b0f21c0f8bed0e2a7dc62d73be64e7e277d6c9a |
|
06-Jan-2010 |
Douglas Gregor <dgregor@apple.com> |
Fix marking of virtual members for nested classes whose first non-pure virtual function has a body inlined in the class git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92855 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
21431c551d867962c66c92f0f96f652678f64c1c |
|
02-Jan-2010 |
Anders Carlsson <andersca@mac.com> |
Move address points to CGVtableInfo, no functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@92420 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e12e77bed10f87bdc7305d0dbd1de89e48f280c1 |
|
19-Dec-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Work in progress for setting the vtable pointers for all bases correctly in the constructor. This doesn't handle cases requiring the VTT at the moment, and generates unnecessary stores, but I think it's essentially correct. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91731 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1d7088d1d9dc99e5478c0184a3e21cafef2a0b53 |
|
17-Dec-2009 |
Anders Carlsson <andersca@mac.com> |
Rename GetAddrOfRTTI to GetAddrOfRTTIDescriptor. Remove the overload that takes a CXXRecordDecl since we were just creating a QualType from it anyway. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91590 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e8e4a1c0bf2e3dd26dd0721a102307bbb589e96a |
|
16-Dec-2009 |
Anders Carlsson <andersca@mac.com> |
Use GetAddrOfRTTI everywhere and remove GenerateRTTI and GenerateRTTIRef. With this change, we can now compile and link TableGen. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91520 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
31b7f52d8c8d459e80d2a72176cc7fcc4b7d8d38 |
|
11-Dec-2009 |
Anders Carlsson <andersca@mac.com> |
Improve linkage of RTTI data structures. Introduce CodeGenModule::GetAddrOfRTTI which figures out the right linkage of the RTTI information for the given type and whether it should be defined or not. I will migrate clients over to GetAddrOfRTTI in subsequent commits (with tests). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91098 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
72649ed78a25365d003b5218cae7b332c418800e |
|
06-Dec-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Work-in-progess rewrite of thunks: move thunk generation outside of vtable generation, and make sure we generate thunks when the function is defined rather than when the vtable is defined. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90722 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c3a46ef9f86aa0b38d3baf75d59cacc55cd7ba24 |
|
06-Dec-2009 |
Anders Carlsson <andersca@mac.com> |
Set the correct linkage for VTTs as well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90689 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8c2d36ffc82c6c616c02f4a231a39f0fe5ab4e54 |
|
06-Dec-2009 |
Anders Carlsson <andersca@mac.com> |
Make GenerateVtable a private member function of CGVtableInfo. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90684 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
35c98cc4c00efcfe47ad0b716e7c50afb9c5ff75 |
|
03-Dec-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Minor cleanup. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90411 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
919d5e51fd0a1b6e52028c8aa42edf44ee036954 |
|
03-Dec-2009 |
Mike Stump <mrs@apple.com> |
Add support for thunking dtors. Oh why does this make my head hurt? git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90409 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9fcfc421d3bf124beed5b185b8d6d795edcbf83a |
|
03-Dec-2009 |
Anders Carlsson <andersca@mac.com> |
Add CodeGenModule::ComputeThunkAdjustment, which Eli wrote. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90401 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
de05057932cebc3f43911f87d75869cb7b705a19 |
|
02-Dec-2009 |
Mike Stump <mrs@apple.com> |
Change rtti/Rtti to RTTI, as it is an acronym. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@90334 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
15233e5a4d98b66b3c6cfcc4e6413ad776a79481 |
|
26-Nov-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Simplify and fix up the handling of implicit constructors, copy assignment operators, and destructors. Avoids generating declarations/definitions of trivial constructors/destructors, and makes sure the trivial copy assignment operator is generated when necessary. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89943 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7622cd3410846d28862ecfe862117894a259a7fa |
|
26-Nov-2009 |
Anders Carlsson <andersca@mac.com> |
Add a CovariantThunkAdjustment struct that represents the adjustments needed for a covariant thunk. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89933 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a94822e8937eeb340a653b88024f805a07a2d2ee |
|
26-Nov-2009 |
Anders Carlsson <andersca@mac.com> |
Add a ThunkAdjustment struct which holds a non-virtual and a virtual adjustment offset. Start using it. General cleanup in Mangle.cpp. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89925 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7e1365a163cde50b1972f05db7884fb124e6b2d7 |
|
20-Nov-2009 |
Mike Stump <mrs@apple.com> |
Simplify rtti building code a little. Prep for reuse for throw rtti generation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89416 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ea2c0b5dec07c28222856e66177f0922c9f508b1 |
|
17-Nov-2009 |
Mike Stump <mrs@apple.com> |
Add typeid for the builtin types. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@89028 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
cbcd4e5d9d4c6148d47c6c05038b295c1eb037b2 |
|
15-Nov-2009 |
Mike Stump <mrs@apple.com> |
Finisgh off rest of class_type_info rtti generation. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@88823 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
764d0c23724b3671dcbe20af152fa1ad45f45e15 |
|
13-Nov-2009 |
Anders Carlsson <andersca@mac.com> |
Move GlobalDecl to its own file. Also add DenseMapInfo traits. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87081 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
acfd1e5ea124ee1f6af74293ba5235771d237456 |
|
13-Nov-2009 |
Mike Stump <mrs@apple.com> |
Allow the tracking of address points for construction vtables as well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87063 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9840c70c34fbe3c8c7ca8b3950447bade915139a |
|
12-Nov-2009 |
Mike Stump <mrs@apple.com> |
Fix the offset calculations for non-virtual bases with overrides. Refine the VTT entries for virtual bases to refer to the complete object's vtable instead of constructor vtables. Refine the AddressPoint calculations for VTT entries for virtual bases. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87021 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
23908b8a43adefd42b3635364cfab44de1064942 |
|
12-Nov-2009 |
Devang Patel <dpatel@apple.com> |
"Attach debug info with llvm instructions" mode was enabled a month ago. Now make it permanent and remove old way of inserting intrinsics to encode debug info for locations and types. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@87007 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2811ccf48d6d898c42cc4cfad37abedb36236d20 |
|
12-Nov-2009 |
Chandler Carruth <chandlerc@gmail.com> |
Move CompileOptions -> CodeGenOptions, and sink it into the CodeGen library. This resolves the layering violation where CodeGen depended on Frontend. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86998 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8cfcb52059d5ff8596cc7a92d856800b9f0da1dc |
|
11-Nov-2009 |
Mike Stump <mrs@apple.com> |
Push ctor vtable construction down further. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86878 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
380dd759b33fd059b1aa7dbd85f8e66ca32f7bdc |
|
10-Nov-2009 |
Mike Stump <mrs@apple.com> |
Add vtable caching to prevent multiple vtables for the same class from being generated. Add the most derived vtable pointer to the VTT. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86671 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
393c247fe025ccb5f914e37e948192ea86faef8c |
|
05-Nov-2009 |
Fariborz Jahanian <fjahanian@apple.com> |
Added support for static variables which require initialization before main. Fixes pr5396. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86145 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
55df71abf0c48a73ae7b7c3abaf611337a2cf12d |
|
13-Oct-2009 |
Devang Patel <dpatel@apple.com> |
Enable "debug info attached to an instruction" mode. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83928 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
dbd920c7758e6dfb678a8f503fb14ba97c26f23a |
|
12-Oct-2009 |
Anders Carlsson <andersca@mac.com> |
Move the vtable builder to CGVtable.cpp, general cleanup. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83798 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b540491851910c2efa68196a8bdc2eed1071c17d |
|
07-Oct-2009 |
Anders Carlsson <andersca@mac.com> |
Add a MangleContext and pass it to all mangle functions. It will be used for keeping state, such as identifiers assigned to anonymous structs as well as scope encoding. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83442 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2b3583573ba6b26b605aacaad9a50492fb3d6fe6 |
|
03-Oct-2009 |
Anders Carlsson <andersca@mac.com> |
Move some functions from CodeGenFunctions to CodeGenModule so they can be used by CGExprConstant. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83263 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
34771b594ca8cdf8cd2e40b27170efa4ed2833c5 |
|
14-Sep-2009 |
Daniel Dunbar <daniel@zuster.org> |
Fix subtle bug in generating LLVM function declarations for builtin functions. The decl wasn't being passed down, which meant that function attributes were not being set correctly. This is particularly important for ARM, since it wants to override the calling convention. Instead we would emit the builtin with the wrong calling convention, and instcombine would come along and merrily shred all the calls to it. :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81756 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ca0017a394e0a93a2412c3fe5c47a63b4b2b2ab0 |
|
13-Sep-2009 |
Chris Lattner <sabre@nondot.org> |
whitespace fix git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81644 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ca6408c3176783f0b29da4679a08512aa05f0c73 |
|
12-Sep-2009 |
Daniel Dunbar <daniel@zuster.org> |
Change CodeGenModule::ConstructTypeAttributes to return the calling convention to use, and allow the ABI implementation to override the calling convention. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81593 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6e319f6adc2a06c31cf99265854eef1321bcecf2 |
|
12-Sep-2009 |
Mike Stump <mrs@apple.com> |
Add basic covariant thunk generation support. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81585 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0ff8bafde95f6fa51ccea70738c1b99db870bddc |
|
11-Sep-2009 |
Anders Carlsson <andersca@mac.com> |
Pass GlobalDecls to GenerateCode and StartFunction. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81485 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4a6835e650ff24e19ce08a3bd347c0ad186777fd |
|
11-Sep-2009 |
Anders Carlsson <andersca@mac.com> |
Add stricter GlobalDecl constructors. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81480 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1eb4433ac451dc16f4133a88af2d002ac26c58ef |
|
09-Sep-2009 |
Mike Stump <mrs@apple.com> |
Remove tabs, and whitespace cleanups. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81346 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
77ca8f6c5e666ef873066b580bf1b7fabd41d4f5 |
|
05-Sep-2009 |
Mike Stump <mrs@apple.com> |
Install thunks later to fixup overrides. Track space taken by vbase offsets better for thunk refinements. Cleanups. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81067 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ed032eb5c18b99528cbd76415337b6056a72b911 |
|
04-Sep-2009 |
Mike Stump <mrs@apple.com> |
Add overidding for methods for vtable building for the secondary vtables. Add thunk generation. WIP. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@81014 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
32f3701853a8237704065c77abc17369dd02c39b |
|
18-Aug-2009 |
Mike Stump <mrs@apple.com> |
Cleanups. Move GenerateRtti to CodeGenModule. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@79372 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b193a414f13d7cfa2524a8149eff8d4871f8cbf6 |
|
16-Aug-2009 |
Fariborz Jahanian <fjahanian@apple.com> |
Patch toward synthesizing non-trivial destructors. WIP git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@79199 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ad25883a644dd6b52c7923dd128a7d05fb26213c |
|
13-Aug-2009 |
Fariborz Jahanian <fjahanian@apple.com> |
Patch to force synthesis of copy assignment operator function in the order according to c++03. ir-gen for copy assignment in the trivial case and the first test case. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78938 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f21efe9088a0b3eda1209d1706529f6cb2073092 |
|
11-Aug-2009 |
Benjamin Kramer <benny.kra@googlemail.com> |
LLVMContext is a class now. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78691 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
89ed31d3f9eeb8ec77c284a5cf404a74bf5e7acf |
|
09-Aug-2009 |
Anders Carlsson <andersca@mac.com> |
Add support for global initializers. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78515 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
97a937532c24a8ea44317d4fdee26d9701a1e83c |
|
07-Aug-2009 |
Fariborz Jahanian <fjahanian@apple.com> |
More synthesis of copy constructors. Work in progress. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78402 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
47a434ff3d49e7906eda88e8e8242e4297725b32 |
|
06-Aug-2009 |
Owen Anderson <resistor@mac.com> |
Update for LLVM API change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@78259 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f121677b6bbbf4e4a51ee7a1120b77adf187bad4 |
|
31-Jul-2009 |
Mike Stump <mrs@apple.com> |
Add code to setup the vtable pointer in the constructor. Work in progress. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@77699 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
a1cf15f4680e5cf39e72e28c5ea854fcba792e84 |
|
15-Jul-2009 |
Owen Anderson <resistor@mac.com> |
Update for LLVM API change, and contextify a bunch of related stuff. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75705 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
69243825cb5c91ec7207256aa57ae327cfaf8cb2 |
|
13-Jul-2009 |
Owen Anderson <resistor@mac.com> |
Update for LLVM API change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@75446 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1fd2dd145d9bcdf0b8d60a88e1795b6ae83656f5 |
|
30-Jun-2009 |
Douglas Gregor <dgregor@apple.com> |
Improve code generation for function template specializations: - Track implicit instantiations vs. the not-yet-supported explicit specializations - Give implicit instantiations of function templates (and member functions of class templates) linkonce_odr linkage. - Improve name mangling for function template specializations, including the template arguments of the instantiation and the return type of the function. Note that our name-mangling is improved, but not correct: we still don't mangle substitutions, although the manglings we produce can be demangled. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@74466 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c6c14d1cd68afcd90d097715296377f15be45210 |
|
26-May-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Handle the edge case of a weak function with incomplete type correctly. Found by code inspection; I haven't seen this in real-world code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@72408 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b4880bab7fc1b61267cfd9a0ad52188e7a828cb3 |
|
12-May-2009 |
Chris Lattner <sabre@nondot.org> |
push GlobalDecl through enough of the CodeGenModule interfaces to allow us to support generation of deferred ctors/dtors. It looks like codegen isn't emitting a call to the dtor in member-functions.cpp:test2, but when it does, its body should get emitted. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@71594 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2a131fbca2a51085dc083b8c56a2d4ced3cf1413 |
|
05-May-2009 |
Anders Carlsson <andersca@mac.com> |
Refactor global decls to hold either a regular Decl or a CXXConstructorDecl + ctor type or a CXXDestructorDecl + dtor type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@70962 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b6c8c8bd8d362c8a6cdb767415b0d21e62b77eb2 |
|
21-Apr-2009 |
Douglas Gregor <dgregor@apple.com> |
Explictly track tentative definitions within Sema, then hand those tentative definitions off to the ASTConsumer at the end of the translation unit. Eliminate CodeGen's internal tracking of tentative definitions, and instead hook into ASTConsumer::CompleteTentativeDefinition. Also, tweak the definition-deferal logic for C++, where there are no tentative definitions. Fixes <rdar://problem/6808352>, and will make it much easier for precompiled headers to cope with tentative definitions in the future. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69681 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
27ae53665f8b00fe4ba21da0fa79a4ce6e0b6cd5 |
|
17-Apr-2009 |
Anders Carlsson <andersca@mac.com> |
Add support for generating (very basic) C++ destructors. These aren't called by anything yet. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69343 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0e4f40e1bbc4dce16bbb9870300a435419f1b3d5 |
|
17-Apr-2009 |
Daniel Dunbar <daniel@zuster.org> |
Attributes on block functions were not being set. - <rdar://problem/6800351> clang not producing correct large struct return code for Blocks git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69337 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
363c184139e26ea38223b477ad64ee67b22bb9a7 |
|
17-Apr-2009 |
Anders Carlsson <andersca@mac.com> |
Add GetAddrOfCXXConstructor and use it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69328 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
03f5ad9a7707e098f601921fcec17ed65eb355a7 |
|
16-Apr-2009 |
Daniel Dunbar <daniel@zuster.org> |
Defer generation of tentative definitions. - PR3980. - <rdar://problem/6762287> [irgen] crash when generating tentative definition of incomplete structure - This also avoids creating common definitions for things which are later overwritten. - XFAIL'ed external-defs.c, it isn't completing types properly yet. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69231 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
95d4e5d2f87a0f07fb143ccb824dfc4c5c595c78 |
|
15-Apr-2009 |
Anders Carlsson <andersca@mac.com> |
Start attempting to generate code for C++ ctors. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69168 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
44e79b1b60ada12119bd9b39fef28f7f69cddd7c |
|
14-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
remove dead enum git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69070 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
cbb8fc18d86a886856f5b852a6a3ead71fec17f9 |
|
14-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
Fix PR3988: extern inline functions get strong symbol definitions in C99 mode. This is a regression from an earlier patch of mine. This also simplifies the linkage enums a bit. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69069 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
86daeee2d4aa6523679f07f27a826bf4c42ca95d |
|
14-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
implement codegen support for __attribute((__gnuc_inline__)), pulling some attribute munging stuff into GetLinkageForFunction. This should fix PR3986 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69045 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7c65e990e9f0dafaf9adbc59b766dcc23eaee845 |
|
14-Apr-2009 |
Daniel Dunbar <daniel@zuster.org> |
Refactor how attributes are set on values. - Pull out SetCommonAttributes, which handles the things common to aliases, methods, functions, and variables. - Pull out SetLLVMFunctionAttributesForDefinition, which handles the LLVM attributes which we only want to apply to a definition (like noinline and alwaysinline). - Kill SetGVDeclarationAttributes (inlined into SetFunctionAttributes and specialized). - Kill SetFunctionAttributesForDefinition (inlined into sole caller). - Inline SetGVDefinitionAttributes into SetMethodAttributes and specialize. - Rename SetGVDefinitionAttributes to SetFunctionDefinitionAttributes. This is supposed to be a no functionality change commit, but I may have made a mistake. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69036 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
55d6f50b23a1fd0a04b568787a25beb7537e6c9b |
|
14-Apr-2009 |
Daniel Dunbar <daniel@zuster.org> |
Split SetGlobalValueAttributes into definition/declaration halves. - No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69035 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7dbd8197040313d796282d4af06eccdf8a17319c |
|
14-Apr-2009 |
Daniel Dunbar <daniel@zuster.org> |
Rename (one) SetFunctionAttributes to SetLLVMFunctionAttributes to disambiguate it. - No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69034 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
44b0bc008ee11cdee69ad12210ca7550e4fa426a |
|
14-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
add a new enum type for linkage, no functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69028 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
04d4078425614bf9fd58d606335c1f5f74ee7fa4 |
|
14-Apr-2009 |
Daniel Dunbar <daniel@zuster.org> |
Clean up handling of visibility. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69027 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0f59312e7b625fa5821a63db65377d4b3b667e99 |
|
13-Apr-2009 |
Eli Friedman <eli.friedman@gmail.com> |
Minor work related to removing the assumption that value initialization implies an all-zero bit pattern. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68994 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e9352cc9818ba59e7cf88500ef048991c90f3821 |
|
08-Apr-2009 |
Anders Carlsson <andersca@mac.com> |
Add a destination type argument to EmitConstantExpr. This will be used for when the destination has a reference type. (No functionality change yet) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68593 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
91e20dd8bf1bc8980ee93839383d2bd170bce050 |
|
02-Apr-2009 |
Anders Carlsson <andersca@mac.com> |
Emit code for linkage specifications. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68300 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8d4141f83d9de379547cf05bd75d4c6cf894b189 |
|
01-Apr-2009 |
Steve Naroff <snaroff@apple.com> |
More "prep" work for handling UTF16 CFString. Patch by Jean-Daniel Dupas. Thanks! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68203 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5ad0f6778556535dca448e9d82e674d2d255ad06 |
|
01-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
move trivial forwarding function inline. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68176 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
984e06874685396ca2cb51f0008cfff7c9b3d9c6 |
|
01-Apr-2009 |
Anders Carlsson <andersca@mac.com> |
Implement code generation of namespaces and add mangling tests. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68170 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
35f38a2c22d68c22e2dbe8e9ee84c120c8f327bb |
|
01-Apr-2009 |
Chris Lattner <sabre@nondot.org> |
Change UsedArray to be a vector of WeakVH to fix a dangling pointer problem that occurs when attribute(used) and asm renaming are used together. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68155 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0773903975631a4baa41e495e8654e2f88a6f3dd |
|
28-Mar-2009 |
Devang Patel <dpatel@apple.com> |
Do not emit debug information for variables while generating optimized code. The llvm optimizer and code generator are not yet ready to support optimized code debugging. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67876 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bd3606426d389370616126af969904ec493cb105 |
|
26-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
most of this is plumbing to get CompileOptions down into CodeGenModule. Once there, add a new NoCommon option to it and implement -fno-common. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67735 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b808c952bbff821dce727dd801a1098d64394f98 |
|
22-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
switch getBuiltinLibFunction to use the new GetOrCreateLLVMFunction functionality, fixing a crash on the attached testcase. Eliminate the BuiltinFunctions cache, as it can contain dangling pointers. This fixes a bunch of valgrind errors on test/CodeGen/builtins.c git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67484 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bd53271dc7570b54f7b7cab7b09bcf04c6e927f6 |
|
22-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
emit aliases as the definitions fly by, don't bother deferring until the end of the module. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67482 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
74391b48b4791cded373683a3baf67314f358d50 |
|
22-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
pull "runtime globals" into the same framework as other functions/global variables. No intended functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67478 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
67b00520c8f5b48fad722b790d87fea6be764efe |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
now that all the decl reference and creation stuff is going through two very simple places, reimplement the deferred decl emission logic to not be O(N^2), fixing PR3810. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67447 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0558e79840bfdbbd38c6e2b4f6765bf0158e85f4 |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
fix a crash that could occur when a variable declaration became a function definition. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67446 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
570585c91dee98d7ba8ccf1198c03208ba17966b |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
simplify and cleanup global variable creation stuff to all go through one code path. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67445 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
34809507232bc4c3c4840c7d092c7440219fddaf |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
simplify management of llvm::Function creation to all go through GetAddrOfFunction. This is simpler and more efficient. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67444 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
62b33ea51adbd0e7f2f05983e9e4a3a2b2ed26de |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
code cleanups, rename EmitForwardFunctionDefinition -> CreateFunctionPrototypeIR, though my next patch will eliminate it entirely. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67443 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
99b53613ebe2c59d41030e987962c1ed101b2efe |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
simplify some more code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67439 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e21c4b829c9e69c20f4baab4916e05cdb786d9ae |
|
21-Mar-2009 |
Chris Lattner <sabre@nondot.org> |
simplify and comment some code better. Make BindRuntimeGlobals more optimistic that it will work (optimizing for the common case). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67438 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5e1e1f95c98b1add70c238093bbd5dc8d4f9c4e9 |
|
19-Mar-2009 |
Daniel Dunbar <daniel@zuster.org> |
IRgen support for alias of global variable. - PR3818. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@67297 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
42745815fa4e90bfb07e581d2e5152b2c2db08ff |
|
10-Mar-2009 |
Daniel Dunbar <daniel@zuster.org> |
Backout r66408, we don't want handling of globals to rely on the module symbol table. The root problem inspiring this was fixed in r66316 (and again in r66506). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66512 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
53d89225560fb9434a68e25019a31a75c0006537 |
|
09-Mar-2009 |
Mike Stump <mrs@apple.com> |
Be sure to never create two functions with the same name, instead arrange to reuse the prior one. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66408 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
43af76e845c95be160c088ec11ba3c43e2527fa8 |
|
07-Mar-2009 |
Sebastian Redl <sebastian.redl@getdesigned.at> |
Some struct/class mismatch fixes, to silence MSVC warnings. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66335 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b681b8ffab2aa016b3897916d5110927c34a584b |
|
06-Mar-2009 |
Daniel Dunbar <daniel@zuster.org> |
(LLVM svn up) Generalize RuntimeFunctions to RuntimeGlobals and add CodeGenModule::CreateRuntimeVariable. - No real functionality change; although we now assert on silly things like: -- int objc_exception_throw; void f0() { @throw(@"A"); } -- instead of accepting it. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66292 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
90a904309c79977fcba2ff0542e2e4cd8e3c3faf |
|
04-Mar-2009 |
Mike Stump <mrs@apple.com> |
Move more of the blocks code up and out. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66046 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
2a998148a6823c44d67da347c95eb2ea21f6b986 |
|
04-Mar-2009 |
Mike Stump <mrs@apple.com> |
Move more of blocks codegen out of CodeGenModule and into the BlockModule. No functionality change. This should help people that don't want to know anything about blocks not be confused by the overloaded use of the term block or nor want to see all the blocks goop. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66042 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
96bd13ae1ab89f5a04b3ad3ec8ec1864cbba3482 |
|
04-Mar-2009 |
Mike Stump <mrs@apple.com> |
Start the migration of more of the blocks code out of sight for most people. De-duplicates BLOCK_NEEDS_FREE and friends. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66034 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
dab514fc30242c7afd6c03956e46136c400fb0d3 |
|
04-Mar-2009 |
Mike Stump <mrs@apple.com> |
Improved ABI compliance for __block variables. No testcases yet as we still give an unsupported error for them due to the fact this is a work in progress. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@66007 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c136e6cf237711f9f1324637a0b2cdf6ae8e79e4 |
|
27-Feb-2009 |
Mike Stump <mrs@apple.com> |
Fix PR3612. We ensure that we add builtins to the GlobalDeclMap and we ensure that things added to the module can be found even when they are not in GlobalDeclMap. The later is for increased flexibility, should someone want to do something tricky like extern "Ada" in the same module. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65657 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
eaf2bb89eb2aad3b80673de30febe52df43c10ec |
|
24-Feb-2009 |
Chris Lattner <sabre@nondot.org> |
first wave of fixes for @encode sema support. This is part of PR3648. The big difference here is that (like string literal) @encode has array type, not pointer type. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65391 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8a219ceda2b5afd447e7199b9c53079bead31b89 |
|
24-Feb-2009 |
Anders Carlsson <andersca@mac.com> |
Prevent accidental copying of CodeGenFunction and CodeGenModule. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65372 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d5d31801fc87239436fa349c89dce7797cf13537 |
|
19-Feb-2009 |
Daniel Dunbar <daniel@zuster.org> |
Don't emit K&R unprototyped function definitions as varargs. - <rdar://problem/6584606> clang/x86-64 - too many reg saves git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@65032 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bd65cac8de63d108a681035782a71d42954b03ab |
|
19-Feb-2009 |
Mike Stump <mrs@apple.com> |
More codegen for blocks. The type of block literals should be better. The size calculation is improved. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64994 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6ec3668a2608b63473207319f5ceff9bbd22ea51 |
|
19-Feb-2009 |
Douglas Gregor <dgregor@apple.com> |
Address Chris's comments regarding C++ name mangling. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64984 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d60f2fbf69df08e952377b498c036f269395024d |
|
17-Feb-2009 |
Daniel Dunbar <daniel@zuster.org> |
Change EmitConstantExpr to allow failure. IRgen no longer relies on isConstantInitializer, instead we just try to emit the constant. If that fails then in C we emit an error unsupported (this occurs when Sema accepted something that it doesn't know how to fold, and IRgen doesn't know how to emit) and in C++ we emit a guarded initializer. This ends up handling a few more cases, because IRgen was actually able to emit some of the constants Sema accepts but can't Evaluate(). For example, PR3398. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64780 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
30395dd7b77ec1abfae9ebfcacf86f5d72b91fef |
|
14-Feb-2009 |
Mike Stump <mrs@apple.com> |
Use getNameAsCString instead of getNameAsString and reflow the type. Thanks Anders. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64571 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
67a6448a8d52ae46d1cba4e474f9f6b3968d2ff9 |
|
14-Feb-2009 |
Mike Stump <mrs@apple.com> |
Generate the helper function for blocks. Now basic codegen is starting to work for blocks. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64570 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5c61d97ad442b2c0bbecb617c8f21857ce1fff6d |
|
13-Feb-2009 |
Daniel Dunbar <daniel@zuster.org> |
IRgen support for attribute used. - PR3566 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64492 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
73241dfeb5c498255b662984cca369fd28ec3147 |
|
13-Feb-2009 |
Daniel Dunbar <daniel@zuster.org> |
Pull MayDeferGeneration out of EmitGlobal. - Fix emission of static functions with constructor attribute while I was here. <rdar://problem/6140899> [codegen] "static" and attribute-constructor interact poorly git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64488 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0269871c9cba493f76237175ab60313406f3bafa |
|
13-Feb-2009 |
Daniel Dunbar <daniel@zuster.org> |
Rename EmitStatics (etc) to EmitDeferred; provide basic infrastructure for attribute used support. - No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64487 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
7d6dc4ff45917c480d8b3350385337f34511ebaf |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Let the backend unique these. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64486 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
324699105567f2948db316c3a3dc4c1d38a3657e |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Move DescriptorUniqueCount into CGM. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64481 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
59c5b118dfbcbc22c65ae42b8f5ef5979ec802ee |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Move NSConcreteStackBlock into CGM. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64479 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ecc90e9512b2ddaced6cb02a08f933fc7afa8e3f |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Reflow to 80col. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64475 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
26efc3388adb010984da2f70e1f24e8286e6476d |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Move GlobalUniqueCount up into CGM. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64473 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f99f1d022614200f04a94f0fc5586aa2f5e6226d |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Condense NSConcreteGlobalBlock handling. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64461 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9b8a7977109604d573b49d517e98badbbb9d5ac7 |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Move GenericBlockLiteralType into CGM. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64452 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ab695143861b520f5c9f8f982534a71d355396f1 |
|
13-Feb-2009 |
Mike Stump <mrs@apple.com> |
Move BlockDescriptorType into CGM. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64451 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5f2bfd4811996abb783aa6c7254c56baa6930e8c |
|
13-Feb-2009 |
Douglas Gregor <dgregor@apple.com> |
Add basic support for C++ name mangling according to the Itanium C++ ABI to the CodeGen library. Since C++ code-generation is so incomplete, we can't exercise much of this mangling code. However, a few smoke tests show that it's doing the same thing as GCC. When C++ codegen matures, we'll extend the ABI tester to verify name-mangling as well, and complete the implementation here. At this point, the major client of name mangling is in the uses of the new "overloadable" attribute in C, which allows overloading. Any "overloadable" function in C (or in an extern "C" block in C++) will be mangled the same way that the corresponding C++ function would be mangled. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64413 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d5cab5435371b8cc74a9e05ebd40b5995ebad149 |
|
12-Feb-2009 |
Anders Carlsson <andersca@mac.com> |
Add a very basic implemenation of global blocks. This needs to be cleaned up. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@64387 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
88b5396b0897f28d22ae3debf4a0d97b33b6c362 |
|
02-Feb-2009 |
Daniel Dunbar <daniel@zuster.org> |
More ABI API cleanup. - Lift CGFunctionInfo creation above ReturnTypeUsesSret and EmitFunction{Epi,Pro}log. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63553 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
725ad31086e3d6c41afa10c43db44f2e7060a961 |
|
31-Jan-2009 |
Daniel Dunbar <daniel@zuster.org> |
Kill off CGCallInfo, always use CGFunctionInfo for encapsulating function/call info. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@63466 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b723f7520bcce5f13ccaae557c16a1e7133b6908 |
|
04-Jan-2009 |
Anders Carlsson <andersca@mac.com> |
Fix the bug that would cause Python to crash at startup. When emitting the static variables we need to make sure that the order is preserved. Fix this by making StaticDecls a std::list which has O(1) random removal. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@61621 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
5fabf9dbee29464bcd06cd09f8e569d1b850f948 |
|
17-Oct-2008 |
Daniel Dunbar <daniel@zuster.org> |
Add option argument to GetAddrOfConstantString to use for name of (first) global holding the string. - No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@57736 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f1968f28869f4e0675450ae39c478a37c5b9abd6 |
|
01-Oct-2008 |
Daniel Dunbar <daniel@zuster.org> |
Add simple interface for protecting runtime functions from name collisions. - Provide CodeGenModule::CreateRuntimeFunction which guarantees that the function it creates will have the provided name in the final module. This allows the runtime to have its functions protected from declarations of the same name in the source code. - One could argue that this is a reason to abuse the llvm::Module namespace for dealing with function redeclarations. However, that approach seems conceptually flawed to me. This one also happens to be somewhat more efficient. No functionality change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56899 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
761d7f78e2dac7ea5f35828c2271e60d91e106ce |
|
25-Sep-2008 |
Devang Patel <dpatel@apple.com> |
Large mechanical patch. s/ParamAttr/Attribute/g s/PAList/AttrList/g s/FnAttributeWithIndex/AttributeWithIndex/g s/FnAttr/Attribute/g This sets the stage - to implement function notes as function attributes and - to distinguish between function attributes and return value attributes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56623 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
45c25ba11cbf8c9a461def5b03f6ee9481e06769 |
|
10-Sep-2008 |
Daniel Dunbar <daniel@zuster.org> |
Move FunctionType conversion into CGCall.cpp: - Added CodeGenTypes::GetFunctionType, taking a CGFunctionInfo. - Updated Obj-C runtimes to use this instead of rolling the llvm::FunctionType by hand. - Killed CodeGenTypes::{ConvertReturnType, DecodeArgumentTypes}. Add ABIArgInfo class to encapsulate ABI decision of how to lower types to LLVM. - Will move to target sometime soon. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56047 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
b768807c49a1c7085def099b848631856af766fa |
|
10-Sep-2008 |
Daniel Dunbar <daniel@zuster.org> |
Tweak CGCall functions again: - Realized these functions will eventually need access to more data, moved to CodeGenModule. Eventually they should probably live together in some other helper class. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56039 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
219df6644e2338ff067471ab0d85f27b88544ac2 |
|
09-Sep-2008 |
Daniel Dunbar <daniel@zuster.org> |
Fix a number of issues w.r.t. emission of global for functions and aliases. - Attributes specific to a definition are only set when the definition is seen. - Alias generation is delayed until the end of the module; necessary since the alias may reference forward. - Fixes: PR2743, <rdr://6140807&6094512> - Improves: <rdr://6095112> (added XFAIL) Also, print module on verification failures. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55966 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0dbe227feccf6a8dbadfff8ca3f80416b7bf2f28 |
|
08-Sep-2008 |
Daniel Dunbar <daniel@zuster.org> |
Refactor parameter attribute handling: - Add CGCall.h for dealing with ABI issues related to calls. - Add CGFunctionInfo and CGCallInfo for capturing ABI relevant information about functions and calls. - Isolate LLVM parameter attribute handling inside CGCall.cpp git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55963 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f80519b919a348db004fba18530706314d1ebfb5 |
|
05-Sep-2008 |
Daniel Dunbar <daniel@zuster.org> |
Set function attributes (sext, zext, etc.) on Objective-C methods. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55812 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
90df4b6661968a84bf64baee489bb2f6d948fcc1 |
|
04-Sep-2008 |
Daniel Dunbar <daniel@zuster.org> |
Avoid superfluous errors regarding variable-length arrays (casts). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55759 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
af05bb9073319d8381b71c4325188853fd4b8ed6 |
|
26-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Objective-C @synthesize support. - Only supports simple assignment and atomic semantics are ignored. - Not quite usable yet because the methods do not actually get added to the class metadata. - Added ObjCPropertyDecl::getSetterKind (one of Assign, Copy, Retain). - Rearrange CodeGenFunction so synthesis can reuse function prolog / epilog code. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55365 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
90db88249ac92e6ed515065048a4ead4467e6639 |
|
25-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Use DenseMap on IdentifierInfo instead of StringMap. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55303 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3e9df9920db8de8ec93a424b0c1784f9bff301ea |
|
23-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
NeXT: Clean up constant CFString handling. - Use CodeGenModule::GetAddrOfConstantCFString Some tweaks of CodeGenModule::GetAddrOfConstantCFString git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@55243 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
488e993a135ce700b982bf099c3d6b856301d642 |
|
16-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Change WarnUnsupported to ErrorUnsupported (in name and in practice). - We are beyond the point where this shows up often and when it does generating miscompiled files is bad. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54836 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
41071debe9b8887449c3f2ee0dd7124ed47bdda8 |
|
16-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Clean up CodeGenModule interface. - Add CodeGenModule::EmitTopLevelDecl which uses switch on kind instead of ugly & slow dyn_cast chains. - Drop some simple forwarding methods into the ObjC runtime. - Privatize appropriate methods. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54827 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6143293fa4366ee95d7e47e61bd030a34bf68b55 |
|
14-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Add GetAddrOfConstantCString method - Returns addr of constant for argument + '\0'. - I couldn't think of a better name. - Move appropriate users of GetAddrOfConstantString to this. Rename getStringForStringLiteral to GetStringForStringLiteral. Add GetAddrOfConstantStringFromLiteral - This combines GetAddrOfConstantString and GetStringForStringLiteral. This method can be, but is not yet, more efficient. Change GetAddrOfConstantString to not add terminating '\0' - <rdar://problem/6140956> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54768 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
af2f62ce32e462f256855cd24b06dec4755d2827 |
|
13-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Change ObjCRuntime GenerateProtocol[Ref] methods to take ObjCProtocolDecl directly. Implement CodeGen support for forward protocol decls (no-ops are so nice to implement). Also moved CGObjCRuntime.h out of CodeGenModule.h git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54709 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
f77ac86f4eca528a04b817d7ad7f045a47d52712 |
|
11-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Add LangOptions::NeXTRuntime. - Wired to -fnext-runtime and -fgnu-runtime options. - Defaults to GNU, no autoselection for NeXT. Emit NeXT OBJC_IMAGE_INFO marker. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54651 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
208ff5e8a073de2a5d15cbe03cab8a4c0d935e28 |
|
11-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Change CodeGenModule to only create ObjC runtime for ObjC files - Changed CodeGenModule::getObjCRuntime to return reference. - Added CodeGenModule::hasObjCRuntime predicate. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54645 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
c17a4d3b16a2624a76de5d7508805534545bd3bf |
|
11-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Add dummy Mac Objective-C runtime interface. - Not currently accessible and completely non-functional. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54624 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1e04976fc2611d8cc06986a81deed4c42183b870 |
|
10-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Back out r54608 (inline string literals were getting an extra '\0') temporarily, I assumed GetAddrForConstantString literal was being used consistently but it doesn't look like it is. Factored out a CodeGenModule::getStringForStringLiteral which handles extracting a std::string for the bytes of a StringLiteral, padded to match the type. Update EmitLValue to use getStringForStringLiteral, this was previously not padding strings correctly. Good thing we only emit strings in 4 different places! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54621 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
3c827a79cb7d04c255db8080e682ee2c6912373d |
|
06-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Change CodeGen of global decls to key off of the name (instead of having multiple bindings from all the possible decls which conceptually map to the same global). - This eliminates CodeGen depending on the LLVM module for name lookup. - This also eliminates the need for ReplaceMapValuesWith (hurrah). - This handles lookups for FunctionDecls correctly in the presence of aliases, this was previously broken. - WIP: Can still clean up & unify variable and function emission. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54382 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
588b1f0a754da053b77cb16bcfb76007ebd60830 |
|
05-Aug-2008 |
Ted Kremenek <kremenek@apple.com> |
Remove excess #include. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54366 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
815c78fd9ab8bd5dfe8e8a91b8c6a413e2b8c889 |
|
05-Aug-2008 |
Ted Kremenek <kremenek@apple.com> |
Refactored driver logic for CodeGen into LLVMCodeGenWriter. This ASTConsumer layers on top of LLVMCodeGen (another existing ASTConsumer) to emit bitcode files to disk. This layering takes this logic out of clang.cpp and puts it directly into the ASTConsumer interface. The benefit is that now --emit-llvm works with both serialized ASTs and regular source files. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54364 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
6bfed7e411adc46eaf616371f85f68305c6e6257 |
|
01-Aug-2008 |
Daniel Dunbar <daniel@zuster.org> |
Support constructor and destructor attributes in CodeGen - There is an miscompilation issue remaining due to a poor interaction between the delayed emission of static functions and the emission of constructors, but that already existed prior to this change. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54258 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
9986eabd4423d867262c358ca62f94a60ac58412 |
|
30-Jul-2008 |
Daniel Dunbar <daniel@zuster.org> |
Change CodeGenModule GlobalDeclMap to directly reference globals instead of mapping the decl to a bitcast of the global to the correct type. - GetAddrOf{Function,GlobalVar} introduce the bitcast on every use now. - This solves a problem where a dangling pointer could be introduced by the RAUW done when replacing a forward or tentative definition. See testcase for more details. - Fixes <rdar://problem/6108358> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54211 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bd012ff1fa088181646a784f385b28867372d434 |
|
30-Jul-2008 |
Daniel Dunbar <daniel@zuster.org> |
Rework codegen emission of globals - No (intended) functionality change. - Primary purpose is to clearly separate (lazy) construction of globals that are a forward declaration or tentative definition from those that are the final definition. - Lazy construction is now encapsulated in GetAddrOf{Function,GlobalVar} while final definitions are constructed in EmitGlobal{Function,Var}Definition. - External interface for dealing with globals is now limited to EmitGlobal and GetAddrOf{Function,GlobalVar}. - Also updated helper functions dealing with statics, annotations, and ctors to be private. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54179 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
58a7a265cf9203795e718d12c074f103e6b27e73 |
|
29-Jul-2008 |
Daniel Dunbar <daniel@zuster.org> |
Fix codegen of chained declarations - Killed useless CodeGenModule::EmitGlobalVarDeclarator, instead just recurse on any ScopedDecl. - Fix for <rdar://problem/6093838> git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@54162 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
d4cbda6292b321c2e7dce7f039d92918fee99b3a |
|
08-Jun-2008 |
Nuno Lopes <nunoplopes@sapo.pt> |
implement the alias attirbute (in both Sema and Codegen) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@52092 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
ff4a2d9e2c1ddbf87e00e2a36ae341faf03eafb3 |
|
01-Jun-2008 |
Eli Friedman <eli.friedman@gmail.com> |
First cut at setting attributes for functions and calls; this puts us much closer to passing the gcc struct layout tests. It might be possible to refactor this a bit, but I'm not sure there's actually enough common code for that to be useful. To get the calling convention completely correct, a bit of platform-specific code is necessary even for x86-Linux. On x86-Linux, the alignment of function parameters is extremely strange; as far as I can tell, it's always 4 except for SSE vectors or structs containing SSE vectors. I'm continuing to investigate this. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51839 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
20ff3108fcd2c3bd734dc79efc22ebaa090abd41 |
|
01-Jun-2008 |
Anton Korobeynikov <asl@math.spbu.ru> |
Support for code generation of Objective-C top-level language constructs. Implemented by David Chisnall! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51835 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
0c99509927a0c7a48490486b9fec287b63e5c09c |
|
26-May-2008 |
Eli Friedman <eli.friedman@gmail.com> |
Emit memmove, not memcpy, for structure copies; this is unfortunately required for correctness in cases of copying a struct to itself or to an overlapping struct (itself for cases like *a = *a, and overlapping is possible with unions). Hopefully, this won't end up being a perf issue; LLVM *should* be able to optimize memmove to memcpy in a lot of cases, and for small copies the generated code *should* be mostly comparable. (In reality, LLVM is currently horrible at optimizing memmove, but that's a bug, not a fundamental issue.) gcc currently generates wrong code; that's http://gcc.gnu.org/bugzilla/show_bug.cgi?id=32667. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51566 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4f8d123e3e2c260de3377208106ddba87cee28b4 |
|
22-May-2008 |
Dan Gohman <gohman@apple.com> |
Move getAccessedFieldNo out of lib/AST/Expr.cpp into lib/CodeGen/CGExpr.cpp and to change include/clang/AST/Attr.h to use its own enum for visibility types instead of using llvm::GlobalValue::VisibilityTypes. These changes eliminate dependencies in the AST library on LLVM's VMCore library. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@51398 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
e8b9f5b8ea60983c4a74cb8b63879616b914b65a |
|
08-May-2008 |
Sanjiv Gupta <sanjiv.gupta@microchip.com> |
Added -g command line options to clang for generating source level debug information. This patch currently enables generation of line number debug information (stoppoints) and region begin/end debug information. The new files CGDebugInfo.h and CGDebugInfo.cpp implements the debug info manager class CGDebugInfo. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@50848 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
1a1d92ac5e1354634af08c62a1d72e263d13be0c |
|
20-Apr-2008 |
Nate Begeman <natebegeman@mac.com> |
Fix PR2236 Add test Implement feedback from Chris re: PR1998 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@50001 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
4c13b7a3973d2d263d9682d7b68fbfeb76334af5 |
|
20-Apr-2008 |
Nate Begeman <natebegeman@mac.com> |
Only generate code for static functions and global variables that are actually used. Warn about unused static functions and variables. This fixes PR1998. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49987 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
8bd4afeb876fd0015bb808eb2f3de1fe709658a7 |
|
19-Apr-2008 |
Nate Begeman <natebegeman@mac.com> |
Generate code for annotation attributes. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49951 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
532485cc6c078d9e51b517c6bbd8984deb17f0fe |
|
19-Apr-2008 |
Nate Begeman <natebegeman@mac.com> |
Add support to module codegen for adding and emitting annotations git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49944 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
248a753f6b670692523c99afaeb8fe98f7ae3ca7 |
|
16-Apr-2008 |
Steve Naroff <snaroff@apple.com> |
Remove FileVarDecl and BlockVarDecl. They are replaced by VarDecl::isBlockVarDecl() and VarDecl::isFileVarDecl(). This is a fairly mechanical/large change. As a result, I avoided making any changes/simplifications that weren't directly related. I did break two Analysis tests. I also have a couple FIXME's in UninitializedValues.cpp. Ted, can you take a look? If the bug isn't obvious, I am happy to dig in and fix it (since I broke it). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@49748 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
391d77a26382dddf25da73e29fc1fa5aaaea4c6f |
|
31-Mar-2008 |
Chris Lattner <sabre@nondot.org> |
Add initial support for objc codegen for methods, ivars, and the etoile runtime, patch by David Chisnall! git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@48969 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|
bda0b626e74513950405c27525af87e214e605e2 |
|
16-Mar-2008 |
Chris Lattner <sabre@nondot.org> |
Make a major restructuring of the clang tree: introduce a top-level lib dir and move all the libraries into it. This follows the main llvm tree, and allows the libraries to be built in parallel. The top level now enforces that all the libs are built before Driver, but we don't care what order the libs are built in. This speeds up parallel builds, particularly incremental ones. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@48402 91177308-0d34-0410-b5e6-96231b3b80d8
/external/clang/lib/CodeGen/CodeGenModule.h
|