summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenFunction.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Patch for synthesizing copy assignment operator.Fariborz Jahanian2009-08-121-0/+3
| | | | | | WIP. llvm-svn: 78841
* minor refactoring. No change otherwise.Fariborz Jahanian2009-08-101-3/+1
| | | | llvm-svn: 78582
* Improve handling of member pointers.Anders Carlsson2009-08-091-2/+2
| | | | llvm-svn: 78536
* Add support for global initializers.Anders Carlsson2009-08-081-1/+1
| | | | llvm-svn: 78515
* Refactoring of copy ctor ir-gen. No change in functionality.Fariborz Jahanian2009-08-081-3/+1
| | | | llvm-svn: 78489
* Synthesized copy constructor now generates code forFariborz Jahanian2009-08-071-1/+1
| | | | | | | copying non-virtual base classes which have non-trivial constructor. Work in progress. llvm-svn: 78436
* More synthesis of copy constructors. Work in progress.Fariborz Jahanian2009-08-071-0/+1
| | | | llvm-svn: 78402
* Patch toward synthesizing copy constructors.Fariborz Jahanian2009-08-061-7/+16
| | | | | | Work in progress. llvm-svn: 78355
* Update for LLVM API change.Owen Anderson2009-07-311-2/+2
| | | | llvm-svn: 77722
* Synthesize the default constructor which has notFariborz Jahanian2009-07-301-1/+11
| | | | | | been declared as needed. llvm-svn: 77641
* Update for LLVM API changes.Owen Anderson2009-07-301-1/+1
| | | | llvm-svn: 77638
* Patch for future ir-gen for destructor calls.Fariborz Jahanian2009-07-301-0/+2
| | | | llvm-svn: 77608
* Update for LLVM API change.Owen Anderson2009-07-291-2/+2
| | | | llvm-svn: 77514
* Change uses of:Ted Kremenek2009-07-291-2/+2
| | | | | | | | | | | | | | | | | | | | Type::getAsReferenceType() -> Type::getAs<ReferenceType>() Type::getAsRecordType() -> Type::getAs<RecordType>() Type::getAsPointerType() -> Type::getAs<PointerType>() Type::getAsBlockPointerType() -> Type::getAs<BlockPointerType>() Type::getAsLValueReferenceType() -> Type::getAs<LValueReferenceType>() Type::getAsRValueReferenceType() -> Type::getAs<RValueReferenceType>() Type::getAsMemberPointerType() -> Type::getAs<MemberPointerType>() Type::getAsReferenceType() -> Type::getAs<ReferenceType>() Type::getAsTagType() -> Type::getAs<TagType>() And remove Type::getAsReferenceType(), etc. This change is similar to one I made a couple weeks ago, but that was partly reverted pending some additional design discussion. With Doug's pending smart pointer changes for Types, it seemed natural to take this approach. llvm-svn: 77510
* Update for LLVM API change.Owen Anderson2009-07-241-7/+7
| | | | llvm-svn: 77012
* Shield clang from LLVM API changes, until the dust settles.Daniel Dunbar2009-07-231-1/+3
| | | | llvm-svn: 76862
* Move EmitCtorPrologue to CGCXX. Add an assert and FIXMEs.Fariborz Jahanian2009-07-201-33/+0
| | | | llvm-svn: 76498
* Early ir-gen for constructor prologue. This is on going.Fariborz Jahanian2009-07-201-0/+35
| | | | llvm-svn: 76493
* Remove an apparently unused header.Mike Stump2009-07-201-1/+0
| | | | llvm-svn: 76473
* Catch another trivial case where we can avoid emitting a separate return blcok.Daniel Dunbar2009-07-191-4/+5
| | | | llvm-svn: 76365
* Avoid generation of dead code in a few more situations.Daniel Dunbar2009-07-191-4/+4
| | | | | | | | | | | | | - Emit variable declarations as "simple", we want to avoid forcing the creation of a dummy basic block, but still need to make the variable available for later use. - With that, we can now skip IRgen for other unreachable statements (which don't define a label). - Anders, I added two fixmes on calls to EmitVLASize, can you check them? llvm-svn: 76361
* Per offline discussion with Steve Naroff, add back Type::getAsXXXType() methodsTed Kremenek2009-07-171-2/+2
| | | | | | | | | until Doug Gregor's Type smart pointer code lands (or more discussion occurs). These methods just call the new Type::getAs<XXX> methods, so we still have reduced implementation redundancy. Having explicit getAsXXXType() methods makes it easier to set breakpoints in the debugger. llvm-svn: 76193
* Replaced Type::getAsLValueReferenceType(), Type::getAsRValueReferenceType(), ↵Ted Kremenek2009-07-171-1/+1
| | | | | | Type::getAsMemberPointerType(), Type::getAsTagType(), and Type::getAsRecordType() with their Type::getAs<XXX> equivalents. llvm-svn: 76139
* Add member template 'Type::getAs<T>', which converts a Type* to a respective T*.Ted Kremenek2009-07-161-1/+1
| | | | | | | | | | | | | | | | | | | | | This method is intended to eventually replace the individual Type::getAsXXXType<> methods. The motivation behind this change is twofold: 1) Reduce redundant implementations of Type::getAsXXXType() methods. Most of them are basically copy-and-paste. 2) By centralizing the implementation of the getAs<Type> logic we can more smoothly move over to Doug Gregor's proposed canonical type smart pointer scheme. Along with this patch: a) Removed 'Type::getAsPointerType()'; now clients use getAs<PointerType>. b) Removed 'Type::getAsBlockPointerTypE()'; now clients use getAs<BlockPointerType>. llvm-svn: 76098
* Update for LLVM API change, and contextify a bunch of related stuff.Owen Anderson2009-07-141-10/+10
| | | | llvm-svn: 75705
* Update for LLVM API change.Owen Anderson2009-07-131-2/+2
| | | | llvm-svn: 75446
* Update for IRBuilder API change.Owen Anderson2009-07-081-0/+1
| | | | llvm-svn: 75041
* Remove the ASTContext parameter from the getBody() methods of Decl and ↵Argyrios Kyrtzidis2009-06-301-1/+1
| | | | | | | | subclasses. Timings showed no significant difference before and after the commit. llvm-svn: 74504
* Remove the ASTContext parameter from the attribute-related methods of Decl.Argyrios Kyrtzidis2009-06-301-1/+1
| | | | | | | | | The implementations of these methods can Use Decl::getASTContext() to get the ASTContext. This commit touches a lot of files since call sites for these methods are everywhere. I used pre-tokenized "carbon.h" and "cocoa.h" headers to do some timings, and there was no real time difference between before the commit and after it. llvm-svn: 74501
* Move the static DeclAttrs map into ASTContext. Fixes <rdar://problem/6983177>.Douglas Gregor2009-06-181-1/+1
| | | | llvm-svn: 73702
* When possible, don't emit the cleanup block. Instead, just move the ↵Anders Carlsson2009-05-311-1/+7
| | | | | | instructions to the current block. llvm-svn: 72654
* Re-add a slightly more general version of the check from r72578; it is Eli Friedman2009-05-291-0/+2
| | | | | | actually necessary in some obscure cases. llvm-svn: 72585
* Oops, the testcase I was thinking of is supposed to error out. IMike Stump2009-05-291-2/+0
| | | | | | tried other things that might trip, but they all worked. llvm-svn: 72584
* Fixup codegen for composition of vla types using a normal array type.Mike Stump2009-05-291-0/+2
| | | | llvm-svn: 72578
* Reflow some comments.Mike Stump2009-05-161-7/+7
| | | | llvm-svn: 71937
* Implement function-try-blocks. However, there's a very subtle bug that I ↵Sebastian Redl2009-04-261-5/+6
| | | | | | can't track down. llvm-svn: 70155
* the logic for computing __func__ and friends is really broken:Chris Lattner2009-04-231-1/+1
| | | | | | | | | the type assigned by sema (and is visible with sizeof(__func__) for example) has nothing to do with what codegen ends up producing. We should eventually add a method on PredefinedExpr to handle this. In the meantime, just set up some framework and add some fixme's. llvm-svn: 69872
* don't bother emitting a zero byte memset at all. We used to get themChris Lattner2009-04-211-2/+5
| | | | | | | | | | | | | | | | | in cases like this: typedef struct { short instance; char name[0]; } ATTR_LIST_ENTRY2; void test() { ATTR_LIST_ENTRY2 X = (ATTR_LIST_ENTRY2) { .instance = 7, }; } While it is safe to emit them, it is pretty silly. llvm-svn: 69687
* FunctionDecl::getBody() is getting an ASTContext argument for use inDouglas Gregor2009-04-181-1/+1
| | | | | | | | lazy PCH deserialization. Propagate that argument wherever it needs to be. No functionality change, except that I've tightened up a few PCH tests in preparation. llvm-svn: 69406
* Simplify CodeGenFunction::GenerateCode.Anders Carlsson2009-04-151-9/+4
| | | | llvm-svn: 69134
* Update to use hasAttr() instead of getAttr().Daniel Dunbar2009-04-131-1/+1
| | | | | | - No functionality change. llvm-svn: 68987
* reject codegen of __thread variables as unimplemented, rdar://6775265Chris Lattner2009-04-101-3/+2
| | | | llvm-svn: 68755
* Add some basic support for generating C++ member functions.Anders Carlsson2009-04-041-1/+20
| | | | llvm-svn: 68425
* remove some obsolete comments, use an AssertingVH.Chris Lattner2009-03-311-1/+2
| | | | llvm-svn: 68151
* Move where block-related variables are initialized so that block Eli Friedman2009-03-281-10/+0
| | | | | | types don't get generated when blocks aren't used. llvm-svn: 67898
* fix CreateTempAlloca to not set a name on the alloca for temporariesChris Lattner2009-03-221-2/+4
| | | | | | | | | in release-assert builds. For automatic variables, explicitly set a name with setName that does not make a temporary std::string. This speeds up -emit-llvm-only -disable-free on PR3810 by 4.6% llvm-svn: 67459
* Initialize the cleanup.dst variable if necessary. Fixes PR3789.Anders Carlsson2009-03-171-3/+8
| | | | llvm-svn: 67075
* Codegen support for copy helpers for block literals.Mike Stump2009-03-071-1/+0
| | | | llvm-svn: 66319
* Framework for codegen for copy/dispose helpers.Mike Stump2009-03-061-1/+2
| | | | llvm-svn: 66231
* Add codegen support for __block variables to call _Block_object_dispose as ↵Mike Stump2009-03-051-1/+1
| | | | | | necessary. llvm-svn: 66117
OpenPOWER on IntegriCloud