summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CodeGenFunction.h
Commit message (Collapse)AuthorAgeFilesLines
...
* Support compound complex operations as l-values in C++. Add a testJohn McCall2010-11-161-0/+3
| | | | | | | case based on CodeGen/volatile-1.c which tests the current C++ semantics, and note the many, many places we fall short of them. llvm-svn: 119402
* Implements __block API for c++ objects. There is stillFariborz Jahanian2010-11-161-5/+5
| | | | | | | issue with runtime which I am discussing it with Blaine. This is wip (so no test yet). llvm-svn: 119368
* Simplify some complex emission and implement correct semantics forJohn McCall2010-11-161-4/+3
| | | | | | | | | assignment to volatiles in C. This in effect reverts some of mjs's work in and around r72572. Basically, the C++ standard is quite clear, except that it lies about volatile behavior approximating C's, whereas the C standard is almost actively misleading. llvm-svn: 119344
* Block API patch to do copy ctor of copied-in cxx objects inFariborz Jahanian2010-11-131-3/+15
| | | | | | | | copy helper function and dtor of copied cxx objects in dispose helper functions. __block variables TBD next. llvm-svn: 119011
* Simplify the logic for emitting guard variables for template staticJohn McCall2010-11-061-2/+8
| | | | | | | | | 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. llvm-svn: 118336
* Restore r117403 (fixing IR gen for bool atomics), this time being less John McCall2010-10-271-0/+8
| | | | | | | aggressive about the form we expect bools to be in. I don't really have time to fix all the sources right now. llvm-svn: 117486
* Revert r117403 as it caused PR8480.Rafael Espindola2010-10-271-8/+0
| | | | llvm-svn: 117456
* Extract procedures to do scalar-to-memory and memory-to-scalar conversionsJohn McCall2010-10-261-0/+8
| | | | | | | in IR gen, and use those to fix a correctness issue with bool atomic intrinsics. rdar://problem/8461234 llvm-svn: 117403
* Factor out the code for emitting code to load vtable pointer membersDan Gohman2010-10-261-0/+3
| | | | | | so that it's done in one place. llvm-svn: 117386
* Fix Whitespace.Michael J. Spencer2010-10-191-40/+40
| | | | llvm-svn: 116798
* Death to blocks, or at least the word "block" in one particular obnoxiouslyJohn McCall2010-10-151-13/+13
| | | | | | ambiguous context. llvm-svn: 116567
* Experimental TBAA support.Dan Gohman2010-10-141-3/+6
| | | | | | | This enables metadata generation by default, however the TBAA pass in the optimizer is still disabled for now. llvm-svn: 116536
* Eliminate usage of ObjCSuperExpr used forFariborz Jahanian2010-10-141-1/+0
| | | | | | | 'super' as receiver of property or a setter/getter methods. //rdar: //8525788 llvm-svn: 116483
* Add target implementations for the X86 builtins:Bill Wendling2010-10-091-0/+1
| | | | | | | | | | | __builtin_ia32_vec_init_v8qi __builtin_ia32_vec_init_v4hi __builtin_ia32_vec_init_v2si They are lowered to bitcasts. (These are all ready tested by the gcc testsuite.) <rdar://problem/8529957> llvm-svn: 116147
* Permit constant evaluation of const floating-point variables withJohn McCall2010-10-091-1/+1
| | | | | | constant initializers. llvm-svn: 116138
* Accidentally committed some temporary changes on my branch when reverting ↵Bill Wendling2010-09-281-3/+0
| | | | | | patches. llvm-svn: 114936
* Temporarily revert 114929 114925 114924 114921. It looked like they (or at leastBill Wendling2010-09-281-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | one of them) was causing a series of failures: http://google1.osuosl.org:8011/builders/clang-x86_64-darwin10-selfhost/builds/4518 svn merge -c -114929 https://llvm.org/svn/llvm-project/cfe/trunk --- Reverse-merging r114929 into '.': U include/clang/Sema/Sema.h U include/clang/AST/DeclCXX.h U lib/Sema/SemaDeclCXX.cpp U lib/Sema/SemaTemplateInstantiateDecl.cpp U lib/Sema/SemaDecl.cpp U lib/Sema/SemaTemplateInstantiate.cpp U lib/AST/DeclCXX.cpp svn merge -c -114925 https://llvm.org/svn/llvm-project/cfe/trunk --- Reverse-merging r114925 into '.': G include/clang/AST/DeclCXX.h G lib/Sema/SemaDeclCXX.cpp G lib/AST/DeclCXX.cpp svn merge -c -114924 https://llvm.org/svn/llvm-project/cfe/trunk --- Reverse-merging r114924 into '.': G include/clang/AST/DeclCXX.h G lib/Sema/SemaDeclCXX.cpp G lib/Sema/SemaDecl.cpp G lib/AST/DeclCXX.cpp U lib/AST/ASTContext.cpp svn merge -c -114921 https://llvm.org/svn/llvm-project/cfe/trunk --- Reverse-merging r114921 into '.': G include/clang/AST/DeclCXX.h G lib/Sema/SemaDeclCXX.cpp G lib/Sema/SemaDecl.cpp G lib/AST/DeclCXX.cpp llvm-svn: 114933
* Patch implements passing arrays to functions expectingFariborz Jahanian2010-09-241-3/+17
| | | | | | vla. Implements pr7827. llvm-svn: 114737
* IRgen for gnu extension's conditional lvalue expressionFariborz Jahanian2010-09-211-0/+1
| | | | | | | with missing LHS. radar 8453812. Executable test is checked into llvm test suite. llvm-svn: 114457
* Implements in IRgen gnu extensions missing LHS forFariborz Jahanian2010-09-201-0/+1
| | | | | | complex conditionals. Radar 8453812. llvm-svn: 114376
* Adjust a fixup's starting branch if it's being resolved becauseJohn McCall2010-09-181-2/+1
| | | | | | | it reached the outermost scope and it hasn't yet been forwarded to a cleanup. Fixed PR8175. llvm-svn: 114259
* Patch to add IRgen support for Gnu's conditional operatorFariborz Jahanian2010-09-171-0/+5
| | | | | | | | extension when missing LHS. This patch covers scalar conditionals only. Others are wip. (pr7726, radar 8353567). llvm-svn: 114182
* When emitting a new-expression inside a conditional expression,John McCall2010-09-171-0/+4
| | | | | | | | | | | | | | | | the cleanup might not be dominated by the allocation code. In this case, we have to store aside all the delete arguments in case we need them later. There's room for optimization here in cases where we end up not actually needing the cleanup in different branches (or being able to pop it after the initialization code). Also make sure we only call this operator delete along the path where we actually allocated something. Fixes rdar://problem/8439196. llvm-svn: 114145
* Patch to move RequiresGCollection bit toFariborz Jahanian2010-09-161-2/+1
| | | | | | AggValueSlot slot. llvm-svn: 114045
* one piece of code is responsible for the lifetime of every aggregateJohn McCall2010-09-151-17/+20
| | | | | | | | | | | | | slot. The easiest way to do that was to bundle up the information we care about for aggregate slots into a new structure which demands that its creators at least consider the question. I could probably be convinced that the ObjC 'needs GC' bit should be rolled into this structure. Implement generalized copy elision. The main obstacle here is that IR-generation must be much more careful about making sure that exactly llvm-svn: 113962
* Implement the EH cleanup to call 'operator delete' if a new-expression throwsJohn McCall2010-09-141-1/+27
| | | | | | (but not if destructors associated with the full-expression throw). llvm-svn: 113836
* Fix VLA miscompilation.Argyrios Kyrtzidis2010-09-141-0/+1
| | | | | | | llvm.stacksave/llvm.stackrestore wasn't emitted for VLAs in inner scopes. Fixes r8403108. llvm-svn: 113822
* Implement ARM static local initialization guards, which are more compact thanJohn McCall2010-09-081-5/+2
| | | | | | Itanium guards and use a slightly different compiled-in API. llvm-svn: 113330
* Abstract IR generation of array cookies into the C++ ABI class andJohn McCall2010-09-021-0/+1
| | | | | | | | | | | | | | 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 :) llvm-svn: 112814
* Teach IR generation to return 'this' from constructors and destructorsJohn McCall2010-08-311-2/+11
| | | | | | under the ARM ABI. llvm-svn: 112588
* IRgen: Set the alignment correctly when creating LValue for a decls.Daniel Dunbar2010-08-211-2/+2
| | | | | | | - Fixes PR5598. - Review appreciated. llvm-svn: 111726
* CodeGenFunction: Eliminate unused MakeQualifiers() function.Daniel Dunbar2010-08-211-6/+0
| | | | llvm-svn: 111725
* IRgen/CGValue: Give MakeAddrLValue() an alignment argument, and eliminate ↵Daniel Dunbar2010-08-211-1/+1
| | | | | | old form of MakeAddr(). llvm-svn: 111723
* IRgen: Eliminate EmitPredefinedFunctionName(), it doesn't need to be ↵Daniel Dunbar2010-08-211-1/+0
| | | | | | factored out. llvm-svn: 111715
* IRgen: Add an LValue::MakeAddr variant which takes a type and uses that to buildDaniel Dunbar2010-08-211-0/+4
| | | | | | | | | the qualifiers. Also, add CodeGenFunction::MakeAddrLValue() helper function which passes in the ASTContext. llvm-svn: 111714
* IRgen: Change Emit{Load,Store}OfScalar to take a required Alignment argument andDaniel Dunbar2010-08-211-2/+2
| | | | | | | | update callers as best I can. - This is a work in progress, our alignment handling is very horrible / sketchy -- I am just aiming for monotonic improvement. - Serious review appreciated. llvm-svn: 111707
* More cleanup enabling.John McCall2010-08-141-0/+10
| | | | llvm-svn: 111070
* Sketch out a framework for delaying the activation of a cleanup.John McCall2010-08-131-1/+12
| | | | | | Not yet complete or used. llvm-svn: 111044
* Simplify code and add comments, in code that generate debug info for ↵Devang Patel2010-08-101-1/+1
| | | | | | constant integer globals, based on Chris's feedback. llvm-svn: 110694
* Even if a constant's evaluated value is used, emit debug info for the ↵Devang Patel2010-08-101-1/+2
| | | | | | constant variable. llvm-svn: 110660
* Store inheritance paths after CastExprs instead of inside them.John McCall2010-08-071-2/+4
| | | | | | | | | | | | | | | 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. llvm-svn: 110507
* vdup_lane was missingNate Begeman2010-08-061-1/+2
| | | | | | <rdar://problem/8278732> llvm-svn: 110420
* More objc block variable layout info. work.Fariborz Jahanian2010-08-041-0/+2
| | | | llvm-svn: 110239
* Some early work for providing block layout info. Fariborz Jahanian2010-08-041-3/+31
| | | | | | for objective-c/c++ blocks (NeXt runtime). llvm-svn: 110213
* When creating a jump destination, its scope should be the scope of theJohn McCall2010-07-281-1/+3
| | | | | | | | | enclosing normal cleanup, not the top of the EH stack. I'm *really* surprised this hasn't been causing more problems. Fixes rdar://problem/8231514. llvm-svn: 109569
* Revise cleanup IR generation to fix a major bug with cleanups (PR7686)John McCall2010-07-231-33/+87
| | | | | | | as well as some significant asymptotic inefficiencies with threading multiple jumps through deep cleanups. llvm-svn: 109274
* Rename LazyCleanup -> Cleanup. No functionality change for these last threeJohn McCall2010-07-211-25/+26
| | | | | | commits. llvm-svn: 109000
* Rip out EHCleanupScope.John McCall2010-07-211-6/+0
| | | | llvm-svn: 108999
* Kill the CleanupBlock API.John McCall2010-07-211-21/+0
| | | | llvm-svn: 108998
* Switch the destructor for a temporary arising from a reference binding over toJohn McCall2010-07-211-0/+6
| | | | | | using a lazy cleanup. llvm-svn: 108994
OpenPOWER on IntegriCloud