summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGClass.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove an unnecessary parameter from EmitClassCopyAssignment.Anders Carlsson2010-04-301-11/+6
| | | | llvm-svn: 102747
* Account for the VTT argument when making an implicit copy constructor forJohn McCall2010-04-301-1/+13
| | | | | | | | | a class with virtual bases. Just a patch until Sema starts (correctly) doing most of this analysis. Fixes PR 6622. llvm-svn: 102692
* Get the base class addresses before calling EmitClassCopyAssignment.Anders Carlsson2010-04-301-5/+8
| | | | llvm-svn: 102676
* Remove an unnecessary argument to EmitClassCopyAssignment.Anders Carlsson2010-04-291-9/+7
| | | | llvm-svn: 102674
* Land another cleanup patch.Anders Carlsson2010-04-251-14/+8
| | | | llvm-svn: 102293
* Revert enough of my patches to fix self-host again :(Anders Carlsson2010-04-251-37/+76
| | | | llvm-svn: 102289
* Cleanup SynthesizeCXXCopyConstructor.Anders Carlsson2010-04-241-16/+9
| | | | llvm-svn: 102286
* Clean up SynthesizeCXXCopyAssignment a little.Anders Carlsson2010-04-241-15/+11
| | | | llvm-svn: 102285
* RenameGetAddressOfBaseOfCompleteClass to ↵Anders Carlsson2010-04-241-20/+20
| | | | | | GetAddressOfDirectBaseInCompleteClass to reflect that it only handles direct bases. llvm-svn: 102284
* More cleanup.Anders Carlsson2010-04-241-23/+15
| | | | llvm-svn: 102282
* Simplify EmitClassMemberwiseCopy now that it's only used for fields.Anders Carlsson2010-04-241-25/+13
| | | | llvm-svn: 102281
* DefineImplicitCopyConstructor now uses SetBaseOrMemberInitializers to create ↵Anders Carlsson2010-04-241-12/+0
| | | | | | implicit base initializers. (Member initializers are still handled by CodeGenFunction::SynthesizeCXXCopyConstructor for now). llvm-svn: 102279
* Rename GetAddressOfBaseClass to OldGetAddressOfBaseClass.Anders Carlsson2010-04-241-48/+10
| | | | llvm-svn: 102275
* Get rid of the old GetNonVirtualBaseClassOffset and change all call sites to ↵Anders Carlsson2010-04-241-25/+0
| | | | | | use the new version. llvm-svn: 102274
* Change CodeGenFunction::GetAddressOfDerivedClass to take a BasePath.Anders Carlsson2010-04-241-7/+21
| | | | llvm-svn: 102273
* Convert more call sites over to the new GetAddressOfBaseClass.Anders Carlsson2010-04-241-1/+1
| | | | llvm-svn: 102272
* Add a new GetAddressOfBaseClass overload that takes a base path and. Use it ↵Anders Carlsson2010-04-241-0/+104
| | | | | | for derived-to-base casts. llvm-svn: 102270
* Comment out an assert for now.Anders Carlsson2010-04-211-0/+3
| | | | llvm-svn: 102007
* Back out r101911 and see if it makes the bots happy.Anders Carlsson2010-04-201-28/+13
| | | | llvm-svn: 101921
* Fix a bug which triggered the assertion I added yesterday. Basically, when ↵Anders Carlsson2010-04-201-13/+28
| | | | | | we initialize the vtable pointer for a virtual base, and there was another path from the most derived class to another base with the same class type, we would use the wrong base. llvm-svn: 101911
* Move code to apply a non-virtual and virtual offset out into a separate ↵Anders Carlsson2010-04-201-19/+31
| | | | | | function. llvm-svn: 101909
* Pass the nearest virtual base decl to InitializeVTablePointers. No ↵Anders Carlsson2010-04-201-10/+7
| | | | | | functionality change right now. llvm-svn: 101872
* Assert that the path from the derived to the base class in ↵Anders Carlsson2010-04-201-0/+7
| | | | | | CodeGenFunction::GetAddressOfBaseClass is not ambiguous. llvm-svn: 101869
* Keep track of the actual storage specifier written on a variable orDouglas Gregor2010-04-191-0/+1
| | | | | | | | function declaration, since it may end up being changed (e.g., "extern" can become "static" if a prior declaration was static). Patch by Enea Zaffanella and Paolo Bolzoni. llvm-svn: 101826
* Have the CXXBaseOrMemberInitializer keep track of whether an initializer ↵Anders Carlsson2010-04-121-11/+1
| | | | | | initializes a virtual base or not. llvm-svn: 101004
* the big refactoring bits of PR3782.Rafael Espindola2010-03-301-1/+1
| | | | | | | | This introduces FunctionType::ExtInfo to hold the calling convention and the noreturn attribute. The next patch will extend it to include the regparm attribute and fix the bug. llvm-svn: 99920
* Remove the old vtable layout code.Anders Carlsson2010-03-301-36/+0
| | | | llvm-svn: 99869
* Use the new function in EmitClassAggrMemberwiseCopy, fixing the same assert ↵Anders Carlsson2010-03-301-15/+2
| | | | | | as seen in PR6628 but for arrays this time. llvm-svn: 99867
* Factor emitting a call to a copy constructor out into a separate function.Anders Carlsson2010-03-301-40/+53
| | | | llvm-svn: 99866
* Introduce a CXXTemporariesCleanupScope RAII object and use it to cleanup the ↵Anders Carlsson2010-03-301-25/+21
| | | | | | temporaries code. llvm-svn: 99865
* Handle default arguments when calling copy constructors for bases or members ↵Anders Carlsson2010-03-301-0/+20
| | | | | | when synthesizing a copy constructor. Fixes PR6628. llvm-svn: 99864
* Flip the switch to always get vtables from the VTT when necessary, I've ↵Anders Carlsson2010-03-291-7/+3
| | | | | | verified that clang bootstraps with this. llvm-svn: 99800
* Cleanup, no functionality change.Anders Carlsson2010-03-291-6/+1
| | | | llvm-svn: 99798
* Fix another thinko, so that flags don't depend on previous bases.Anders Carlsson2010-03-291-5/+7
| | | | llvm-svn: 99791
* When generating base ctors/dtors, we need to lookup virtual bases using the ↵Anders Carlsson2010-03-291-4/+15
| | | | | | vtable. llvm-svn: 99790
* Use construction vtables when needed. This is currently guarded by ↵Anders Carlsson2010-03-291-5/+29
| | | | | | -fdump-vtable-layouts since it doesn't work 100% yet :) llvm-svn: 99787
* Reapply r99775 with a fix for a silly bug - we were setting the vtable ↵Anders Carlsson2010-03-281-47/+58
| | | | | | pointer for all bases, even those without a vtable pointer :) llvm-svn: 99777
* Looks like I broke self-host again :(.Anders Carlsson2010-03-281-53/+46
| | | | llvm-svn: 99776
* More improvements to setting the vtable pointer. We now no longer set the ↵Anders Carlsson2010-03-281-46/+53
| | | | | | vtable pointer for non-virtual primary bases. We also do a pre-order traversal of the class hierarchy; this is necessary in order to get the right vbase offset offsets in base ctors/dtors. llvm-svn: 99775
* Factor vtable pointer setting code out into a separate function.Anders Carlsson2010-03-281-21/+32
| | | | llvm-svn: 99773
* Revert r99612 and see if it fixes self-host.Anders Carlsson2010-03-261-7/+0
| | | | llvm-svn: 99614
* Don't initialize virtual pointers for primary bases, they've already been ↵Anders Carlsson2010-03-261-0/+7
| | | | | | initialized. llvm-svn: 99612
* Simplify InitializeVtablePtrs in preparation of making it work with ↵Anders Carlsson2010-03-261-52/+57
| | | | | | construction vtables. llvm-svn: 99609
* Use getNamedGlobal instead of getGlobalVariable. (Fixes self-host).Anders Carlsson2010-03-241-1/+1
| | | | llvm-svn: 99385
* More vtable work; preparations for moving over to the new vtable layout code ↵Anders Carlsson2010-03-241-5/+7
| | | | | | (finally). llvm-svn: 99381
* Rename CGVtableInfo to CodeGenVTables in preparation of adding another ↵Anders Carlsson2010-03-231-14/+14
| | | | | | VTableInfo class. llvm-svn: 99250
* Rename getVirtualBaseOffsetIndex to getVirtualBaseOffsetOffset to reflect ↵Anders Carlsson2010-03-111-4/+4
| | | | | | what it actually does. llvm-svn: 98248
* Perform two more constructor/destructor code-size optimizations:John McCall2010-02-231-11/+125
| | | | | | | | | | | | | | | | 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. llvm-svn: 96842
* More refactoring around constructor/destructor code generation.John McCall2010-02-191-48/+129
| | | | | | | | | | | | Fix some bugs with function-try-blocks and simplify normal try-block code generation. This implementation excludes a deleting destructor's call to operator delete() from the function-try-block, which I believe is correct but which I can't find straightforward support for at a moment's glance. llvm-svn: 96670
* Make deleting and complete dtor variants defer to other dtor variants byJohn McCall2010-02-181-36/+51
| | | | | | | | calling them as subroutines. This triggers whenever the alias optimization doesn't, i.e. when the dtor has linkonce linkage or there are virtual bases or it's the deleting dtor. llvm-svn: 96605
OpenPOWER on IntegriCloud