summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGenCXX/virt.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Get rid of virt.cpp.Anders Carlsson2010-05-031-696/+0
| | | | llvm-svn: 102918
* remove alignment specifier on this. CAn't this test be removed yet? :)Chris Lattner2010-04-261-1/+1
| | | | llvm-svn: 102369
* We seem to get an inconsistent alignment value in the generatedDouglas Gregor2010-04-021-1/+2
| | | | | | | | | assembly for the global "d7". We were previously testing for alignment 3, which seems to happen for some builders and not for others. I've eliminated the alignment check and added a FIXME to unbreak the buildbots. llvm-svn: 100205
* Rework our handling of copy construction of temporaries, which was aDouglas Gregor2010-04-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | poor (and wrong) approximation of the actual rules governing when to build a copy and when it can be elided. The correct implementation is actually simpler than the approximation. When we only enumerate constructors as part of initialization (e.g., for direct initialization or when we're copying from a class type or one of its derived classes), we don't create a copy. When we enumerate all conversion functions, we do create a copy. Before, we created some extra copies and missed some others. The new test copy-initialization.cpp shows a case where we missed creating a (required, non-elidable) copy as part of a user-defined conversion, which resulted in a miscompile. This commit also fixes PR6757, where the missing copy made us reject well-formed code in the ternary operator. This commit also cleans up our handling of copy elision in the case where we create an extra copy of a temporary object, which became necessary now that we produce the right copies. The code that seeks to find the temporary object being copied has moved into Expr::getTemporaryObject(); it used to have two different not-quite-the-same implementations, one in Sema and one in CodeGen. Note that we still do not attempt to perform the named return value optimization, so we miss copy elisions for return values and throw expressions. llvm-svn: 100196
* Remove parts of virt.cppAnders Carlsson2010-03-241-52/+0
| | | | llvm-svn: 99363
* Update tests in -Asserts mode. These tests really need to be rewritten...Daniel Dunbar2010-02-091-4/+4
| | | | llvm-svn: 95658
* Refine the non-virtual this adjustments for thunks by using the offsetMike Stump2010-01-261-2/+2
| | | | | | | | to the declaring class from the nearest virtual base class. WIP. This fixes 40% of all the problems remaining in one of my testcases. llvm-svn: 94592
* Be sure to track the non-virtual part of the vcall offset in complexMike Stump2010-01-261-2/+2
| | | | | | | | | multiple inheritance cases. WIP. This fixes 20% of the outstanding problems found by the randomized tester. llvm-svn: 94499
* Fixup a missing vcall entry. WIP.Mike Stump2010-01-261-25/+25
| | | | llvm-svn: 94478
* Adjust testcase for recent AsmPrinter changes, sigh.Benjamin Kramer2010-01-231-34/+34
| | | | llvm-svn: 94307
* Fixup the rest of the testcases to grep the .ll file instead of the .sMike Stump2010-01-221-263/+22
| | | | | | file, and add FIXMEs to the remaining broken tests. llvm-svn: 94238
* Convert more testcases to checking the .ll file instead of the .s file.Mike Stump2010-01-221-269/+105
| | | | llvm-svn: 94229
* Be sure to select primary bases among the nearly empties in preorder,Mike Stump2010-01-221-0/+39
| | | | | | | not just among the direct bases. Before we where missing nearly empties that were bases of virtual base classes. llvm-svn: 94208
* Ensure we output all non-virtual base vtables. Fixes PR5890.Mike Stump2010-01-221-0/+14
| | | | llvm-svn: 94163
* allow this test to pass, even with the recent .s printer changes.Chris Lattner2010-01-201-126/+126
| | | | | | Have I ever mentioned that clang regtests should not be grepping .s files?? llvm-svn: 93998
* Fix a bunch of VTT layout bugs, add simple tests for VTT layout.Anders Carlsson2010-01-181-7/+7
| | | | llvm-svn: 93709
* Update virt.cpp for changes to the LLVM asm printer (?) This test should ↵Anders Carlsson2010-01-181-2/+2
| | | | | | really be all LLVM IR... llvm-svn: 93707
* Fix Release-Asserts.Mike Stump2010-01-131-44/+42
| | | | llvm-svn: 93346
* Baby steps towards fixing PR5589. If a class needs a vtable pointer, add one.Anders Carlsson2009-12-161-6/+6
| | | | llvm-svn: 91545
* Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar2009-12-151-2/+2
| | | | | | | | | - This is designed to make it obvious that %clang_cc1 is a "test variable" which is substituted. It is '%clang_cc1' instead of '%clang -cc1' because it can be useful to redefine what gets run as 'clang -cc1' (for example, to set a default target). llvm-svn: 91446
* Work-in-progess rewrite of thunks: move thunk generation outside of vtableEli Friedman2009-12-061-2/+2
| | | | | | | generation, and make sure we generate thunks when the function is defined rather than when the vtable is defined. llvm-svn: 90722
* Fixup key function calculations.Mike Stump2009-11-201-46/+47
| | | | llvm-svn: 89412
* More VTT and constructor vtable testcases from recent work.Mike Stump2009-11-131-0/+43
| | | | llvm-svn: 88710
* Add more testcase for construction vtables and VTTs.Mike Stump2009-11-131-0/+28
| | | | llvm-svn: 88702
* Add some more VTT testcases.Mike Stump2009-11-131-0/+21
| | | | llvm-svn: 88699
* Add a testcase for the recent VTT work.Mike Stump2009-11-131-0/+10
| | | | llvm-svn: 88681
* This falls into the category of stupid pet tricks. I hate to do this,Mike Stump2009-11-131-5/+3
| | | | | | | | but this is necessary to continue work on virtual vtables. We don't want to penalize virtual table building testcases, just because complex virtual conversions don't yet work. llvm-svn: 88676
* Unify the codepaths used to verify base and member initializers for explicitlyEli Friedman2009-11-091-0/+1
| | | | | | | | | | | | | | | | and implicitly defined constructors. This has a number of benefits: 1. Less code. 2. Explicit and implicit constructors get the same diagnostics. 3. The AST explicitly contains constructor calls from implicit default constructors. This allows handing some cases that previously weren't handled correctly in IRGen without any additional code. Specifically, implicit default constructors containing calls to constructors with default arguments are now handled correctly. llvm-svn: 86500
* Remove RUN: true lines.Daniel Dunbar2009-11-081-1/+0
| | | | llvm-svn: 86432
* Eliminate &&s in tests.Daniel Dunbar2009-11-081-4/+4
| | | | | | - 'for i in $(find . -type f); do sed -e 's#\(RUN:.*[^ ]\) *&& *$#\1#g' $i | FileUpdate $i; done', for the curious. llvm-svn: 86430
* Refine the non-virtual this adjustment. Optimize out virtual thisMike Stump2009-11-061-12/+12
| | | | | | adjustments of zero. llvm-svn: 86300
* Refine the vcall for a function that is defined in a virtual baseMike Stump2009-11-061-1/+31
| | | | | | class that is overridden in a base that isn't morally virtual. llvm-svn: 86217
* Convert file over to checking the .ll file for codegen. Also, weMike Stump2009-11-061-450/+63
| | | | | | speed up this file by not doing twice the checking. llvm-svn: 86205
* Refine covariant return value adjustments for thunks when nullMike Stump2009-11-051-1/+5
| | | | | | pointers are returned. llvm-svn: 86120
* Testcase for a recent checkin.Mike Stump2009-11-051-0/+27
| | | | llvm-svn: 86118
* Update.Mike Stump2009-11-051-46/+36
| | | | llvm-svn: 86117
* this test has started failing due to an optimizer change. Clang testsChris Lattner2009-11-041-0/+1
| | | | | | | should only look at -O0 IR output not -O3 assembly output. XFAIL it for now. llvm-svn: 86029
* Split out return adjustments in thunks from this adjustment in thunksMike Stump2009-11-041-3/+17
| | | | | | | so the optimizer can tailcall into the return value adjustment thunk. This improves codesize for complex hierarchies. llvm-svn: 85988
* vtable testcase for recent work on vcall/vbase offsets.Mike Stump2009-11-031-2/+83
| | | | llvm-svn: 85925
* Refine codegen for covariant thunks that return references.Mike Stump2009-11-031-0/+32
| | | | llvm-svn: 85916
* Refine return value adjustments for thunks.Mike Stump2009-11-031-0/+30
| | | | llvm-svn: 85905
* Refine vcall/vbase ordering with vtable construction.Mike Stump2009-10-311-8/+8
| | | | llvm-svn: 85677
* Finish off pure virtual function handling.Mike Stump2009-10-281-0/+35
| | | | llvm-svn: 85354
* Testcase for recent checkin. WIP.Mike Stump2009-10-141-0/+119
| | | | llvm-svn: 84123
* Refine handling for return value conversions with respect to virtualMike Stump2009-10-131-15/+92
| | | | | | offsets for covariant thunks. llvm-svn: 83965
* Fix http://llvm.org/PR5090.Mike Stump2009-09-291-0/+13
| | | | llvm-svn: 83035
* Remove tabs, and whitespace cleanups.Mike Stump2009-09-091-1/+1
| | | | llvm-svn: 81346
* Refine vcall offsets. Cleanups. WIP.Mike Stump2009-09-071-0/+119
| | | | llvm-svn: 81143
* Testcase for recent checkin.Mike Stump2009-09-011-3/+3
| | | | llvm-svn: 80725
* iGenerate vcalls as we build up the methods. WIP.Mike Stump2009-08-281-9/+9
| | | | llvm-svn: 80405
OpenPOWER on IntegriCloud