summaryrefslogtreecommitdiffstats
path: root/test/CodeGenCXX/delete.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Update Clang tests to handle explicitly typed load changes in LLVM.David Blaikie2015-02-271-5/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@230795 91177308-0d34-0410-b5e6-96231b3b80d8
* Update Clang tests to handle explicitly typed gep changes in LLVM.David Blaikie2015-02-271-7/+7
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@230783 91177308-0d34-0410-b5e6-96231b3b80d8
* CHECK-LABEL-ify some code gen tests to improve diagnostic experience when ↵Stephen Lin2013-08-151-8/+8
| | | | | | tests fail. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@188447 91177308-0d34-0410-b5e6-96231b3b80d8
* Test updates missed from r186799.Richard Smith2013-07-211-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@186800 91177308-0d34-0410-b5e6-96231b3b80d8
* Update to use references to attribute groups instead of listing the ↵Bill Wendling2013-02-221-1/+3
| | | | | | attributes on the call/invoke instructions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@175878 91177308-0d34-0410-b5e6-96231b3b80d8
* When performing a ::delete of an object with a virtual destructor,John McCall2012-09-251-6/+17
| | | | | | | | | | | | | | be sure to delete the complete object pointer, not the original pointer. This is necessary if the base being deleted is at a non-zero offset in the complete object. This is only required for objects with virtual destructors because deleting an object via a base-class subobject when the base does not have a virtual destructor is undefined behavior. Noticed while reviewing the last four years of cxx-abi-dev activity. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@164597 91177308-0d34-0410-b5e6-96231b3b80d8
* Enforce access control for conversion operators used in contextualJohn McCall2011-09-211-1/+1
| | | | | | | | conversions (rather than just call-arguments). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@140244 91177308-0d34-0410-b5e6-96231b3b80d8
* PR10566: Make sure codegen for deleting an pointer to an incomplete type ↵Eli Friedman2011-08-021-3/+5
| | | | | | actually works. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136703 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix typo in test.Eli Friedman2011-07-271-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136251 91177308-0d34-0410-b5e6-96231b3b80d8
* Make CodeGen for array delete involving incomplete class work without ↵Eli Friedman2011-07-271-0/+9
| | | | | | crashing. Should fix regression on g++.dg/init/delete1.C. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@136241 91177308-0d34-0410-b5e6-96231b3b80d8
* Okay, that rule about zero-length arrays applies to destroyingJohn McCall2011-07-131-3/+2
| | | | | | | | them, too. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135038 91177308-0d34-0410-b5e6-96231b3b80d8
* Switch delete[] IR-generation over to the destroy framework,John McCall2011-07-131-22/+14
| | | | | | | | which implicitly makes it EH-safe as well. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135025 91177308-0d34-0410-b5e6-96231b3b80d8
* When compiling ::delete for a class with a virtual destructor, callDouglas Gregor2011-07-131-0/+19
| | | | | | | | | the complete destructor and then invoke the global delete operator. Previously, we would invoke the deleting destructor, which calls the wrong delete operator. Fixes PR10341. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@135021 91177308-0d34-0410-b5e6-96231b3b80d8
* clang side to match the LLVM IR type system rewrite patch.Chris Lattner2011-07-091-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@134831 91177308-0d34-0410-b5e6-96231b3b80d8
* Move unnamed_addr after the function arguments on Sabre's request.Rafael Espindola2011-01-251-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@124210 91177308-0d34-0410-b5e6-96231b3b80d8
* Add unnamed_addr to constructors and destructors.Rafael Espindola2011-01-111-1/+1
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@123197 91177308-0d34-0410-b5e6-96231b3b80d8
* When applying 'delete' on a pointer-to-array type match GCC and EDG behavior ↵Argyrios Kyrtzidis2010-09-131-0/+7
| | | | | | | | and treat it as 'delete[]'. Also offer a fix-it hint adding '[]'. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113778 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix more i1/i8 pointer madness. Here, an overactive assertionDouglas Gregor2010-09-021-0/+10
| | | | | | | | | | | | | | complains when the element type of a C++ "delete" expression is different from what we would expect from the pointer type. When deleting a bool*, we end up with an i1 on one side (where we compute the LLVM type from the Clang bool type) and i8 on the other (where we grab the LLVM type from the LLVM pointer type). I've weakened the assertion appropriately, and the Boost Parallel Graph Library now passes its regression tests. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112821 91177308-0d34-0410-b5e6-96231b3b80d8
* Abstract IR generation of array cookies into the C++ ABI class andJohn McCall2010-09-021-1/+39
| | | | | | | | | | | | | | | | implement ARM array cookies. Also fix a few unfortunate bugs: - throwing dtors in deletes prevented the allocation from being deleted - adding the cookie to the new[] size was not being considered for overflow (and, more seriously, was screwing up the earlier checks) - deleting an array via a pointer to array of class type was not causing any destructors to be run and was passing the unadjusted pointer to the deallocator - lots of address-space problems, in case anyone wants to support free store in a variant address space :) git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@112814 91177308-0d34-0410-b5e6-96231b3b80d8
* Restore r101841 without modification. Also mark 'operator delete' as used forJohn McCall2010-04-201-2/+24
| | | | | | | | actual delete expressions, not just new expressions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@101861 91177308-0d34-0410-b5e6-96231b3b80d8
* Update tests to use %clang_cc1 instead of 'clang-cc' or 'clang -cc1'.Daniel Dunbar2009-12-151-1/+1
| | | | | | | | | - 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). git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@91446 91177308-0d34-0410-b5e6-96231b3b80d8
* Eliminate &&s in tests.Daniel Dunbar2009-11-081-1/+1
| | | | | | - 'for i in $(find . -type f); do sed -e 's#\(RUN:.*[^ ]\) *&& *$#\1#g' $i | FileUpdate $i; done', for the curious. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@86430 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a lame regression in IR gen for C++ delete expressions. PR5102Douglas Gregor2009-10-011-0/+12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@83195 91177308-0d34-0410-b5e6-96231b3b80d8
* Improve handling of delete expressions.Anders Carlsson2009-08-161-0/+25
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@79205 91177308-0d34-0410-b5e6-96231b3b80d8