summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
* Fix some unused variable, control reaches end of non-void function,Daniel Dunbar2009-01-151-3/+2
| | | | | | and uninitialized use options. llvm-svn: 62270
* Add dummy X86_64 ABIInfo implementation.Daniel Dunbar2009-01-151-5/+26
| | | | llvm-svn: 62268
* Bug fix, __private_extern__ globals were always introducing a definition.Daniel Dunbar2009-01-131-10/+31
| | | | llvm-svn: 62139
* Patch to implement code gen for aggrgate-valued property usedFariborz Jahanian2009-01-121-0/+8
| | | | | | to access a field of its type. llvm-svn: 62123
* Cleanup DeclContext::addDecl and DeclContext::insert interface, from Piotr RakDouglas Gregor2009-01-121-8/+4
| | | | llvm-svn: 62122
* (LLVM up) Match TargetData API change in LLVM TOT.Daniel Dunbar2009-01-124-12/+12
| | | | llvm-svn: 62101
* Handle multi-value inputsAnders Carlsson2009-01-121-5/+18
| | | | llvm-svn: 62069
* make ScalarExprEmitter::EmitCompare() emit the expression with the correct ↵Nuno Lopes2009-01-111-3/+2
| | | | | | | | type instead of always zext it to an int this fixes codegen of simple exprs in C++ like 'if (x != 0)' llvm-svn: 62060
* More inline asm fixesAnders Carlsson2009-01-111-1/+4
| | | | llvm-svn: 62049
* Handle readwrite constraints correctlyAnders Carlsson2009-01-111-1/+2
| | | | llvm-svn: 62043
* Forgot to commit thisAnders Carlsson2009-01-111-0/+5
| | | | llvm-svn: 62042
* Use a common function for emitting asm inputs and remove a FIXMEAnders Carlsson2009-01-111-31/+26
| | | | llvm-svn: 62041
* Convert property implementation to DeclContext::addDecl().Steve Naroff2009-01-111-16/+9
| | | | | | This completes the ObjCContainerDecl AST cleanup (for now). llvm-svn: 62037
* Fix a misleading comment.Steve Naroff2009-01-101-4/+4
| | | | llvm-svn: 62031
* This patch fixes the code gen failures which was a fallout fromFariborz Jahanian2009-01-105-17/+25
| | | | | | | | not merging protocol properties into the classes which use those protocols. With this patch, all my exceutable test pass again. llvm-svn: 62030
* assert if attempting to code gen. a property setter/getterFariborz Jahanian2009-01-101-0/+4
| | | | | | coming from a protocol. llvm-svn: 62017
* Prevent a segfault for vaarg expressions on unsupported architectures.Sebastian Redl2009-01-091-2/+4
| | | | llvm-svn: 62008
* Implement EmitUnsupportedRValue to generate an appropriately typed RValue.Daniel Dunbar2009-01-091-3/+13
| | | | llvm-svn: 62004
* Provide a new kind of iterator, the specific_decl_iterator, thatDouglas Gregor2009-01-095-11/+11
| | | | | | | | | filters the decls seen by decl_iterator with two criteria: the dynamic type of the declaration and a run-time predicate described by a member function. This simplifies EnumDecl, RecordDecl, and ObjCContainerDecl considerably. It has no measurable performance impact. llvm-svn: 61994
* Emit more refined "unsupported" error for block expressions.Daniel Dunbar2009-01-091-0/+5
| | | | llvm-svn: 61993
* Give "unsupported" error on calls through block pointers instead ofDaniel Dunbar2009-01-092-6/+28
| | | | | | crashes. llvm-svn: 61992
* Move property API's up to ObjCContainerDecl (removing a lot of duplicate code).Steve Naroff2009-01-091-6/+6
| | | | | | | | | Add isa/cast/dyncast support for ObjCContainerDecl. Renamed classprop_iterator/begin/end to prop_iterator/begin/end (the class prefix was confusing). More simplifications to Sema::ActOnAtEnd()... Added/changed some FIXME's as a result of the above work. llvm-svn: 61988
* Convert block types in IRgen. This is not the correct type, butDaniel Dunbar2009-01-091-1/+3
| | | | | | matches llvm-gcc (?). llvm-svn: 61974
* Block pointer types are not aggregate types.Daniel Dunbar2009-01-091-1/+4
| | | | llvm-svn: 61973
* Remove redundant method context (now that ObjCMethodDecl isa ScopedDecl).Steve Naroff2009-01-081-1/+1
| | | | | | | | Convert clients to use the standard getDeclContext() API. Doug, thanks for the review! llvm-svn: 61935
* This is a large/messy diff that unifies the ObjC AST's with DeclContext.Steve Naroff2009-01-081-2/+2
| | | | | | | | | | | | | | | - ObjCContainerDecl's (ObjCInterfaceDecl/ObjCCategoryDecl/ObjCProtocolDecl), ObjCCategoryImpl, & ObjCImplementation are all DeclContexts. - ObjCMethodDecl is now a ScopedDecl (so it can play nicely with DeclContext). - ObjCContainerDecl now does iteration/lookup using DeclContext infrastructure (no more linear search:-) - Removed ASTContext argument to DeclContext::lookup(). It wasn't being used and complicated it's use from an ObjC AST perspective. - Added Sema::ProcessPropertyDecl() and removed Sema::diagnosePropertySetterGetterMismatch(). - Simplified Sema::ActOnAtEnd() considerably. Still more work to do. - Fixed an incorrect casting assumption in Sema::getCurFunctionOrMethodDecl(), now that ObjCMethodDecl is a ScopedDecl. - Removed addPropertyMethods from ObjCInterfaceDecl/ObjCCategoryDecl/ObjCProtocolDecl. This passes all the tests on my machine. Since many of the changes are central to the way ObjC finds it's methods, I expect some fallout (and there are still a handful of FIXME's). Nevertheless, this should be a step in the right direction. llvm-svn: 61929
* Objc's compatibility-alias semantics and codeFariborz Jahanian2009-01-081-1/+1
| | | | | | gen issue fix. llvm-svn: 61901
* Another nasty code gen. bug with trivial fix. Calling classFariborz Jahanian2009-01-071-1/+3
| | | | | | | method on 'super' receiver in a category implementation. Other simpler cases were working by accident. llvm-svn: 61880
* Couple of code gen. fixes in ObjC's colection-statement. HardFariborz Jahanian2009-01-061-1/+3
| | | | | | to track down, easy to fix. This is on going. llvm-svn: 61817
* Add QualifiedDeclRefExpr, which retains additional source-locationDouglas Gregor2009-01-062-2/+5
| | | | | | | | | | | | | | | | | | | information for declarations that were referenced via a qualified-id, e.g., N::C::value. We keep track of the location of the start of the nested-name-specifier. Note that the difference between QualifiedDeclRefExpr and DeclRefExpr does have an effect on the semantics of function calls in two ways: 1) The use of a qualified-id instead of an unqualified-id suppresses argument-dependent lookup 2) If the name refers to a virtual function, the qualified-id version will call the function determined statically while the unqualified-id version will call the function determined dynamically (by looking up the appropriate function in the vtable). Neither of these features is implemented yet, but we do print out qualified names for QualifiedDeclRefExprs as part of the AST printing. llvm-svn: 61789
* Silence a GCC warningSebastian Redl2009-01-051-1/+2
| | | | llvm-svn: 61747
* Generate debug info for VLA typesAnders Carlsson2009-01-051-3/+14
| | | | llvm-svn: 61661
* Fix the bug that would cause Python to crash at startup.Anders Carlsson2009-01-042-11/+14
| | | | | | | When emitting the static variables we need to make sure that the order is preserved. Fix this by making StaticDecls a std::list which has O(1) random removal. llvm-svn: 61621
* Add full dllimport / dllexport support: both sema checks and codegen.Anton Korobeynikov2008-12-261-7/+20
| | | | | | Patch by Ilya Okonsky llvm-svn: 61437
* Generate code for __builtin_ia32_pshufwAnders Carlsson2008-12-221-0/+7
| | | | llvm-svn: 61324
* Add codegen support for __nullAnders Carlsson2008-12-211-0/+3
| | | | llvm-svn: 61314
* Implement alignof for vla types.Anders Carlsson2008-12-211-2/+7
| | | | llvm-svn: 61305
* Add ASTContext::getBaseElementType and use it in ↵Anders Carlsson2008-12-211-6/+1
| | | | | | CodeGenFunction::EmitArraySubscriptExpr. llvm-svn: 61303
* Make sure to emit the size expression for sizeof(type)Anders Carlsson2008-12-211-1/+6
| | | | llvm-svn: 61301
* Fix for PR3246: an empty clobber list is the empty string, not a null Eli Friedman2008-12-211-2/+3
| | | | | | | | | | string. That said, we should probably try and track down the correct clobber lists for the targets that don't have them (PPC, ARM, and Sparc), so that we can generate correct code. llvm-svn: 61298
* Handle VLA indexingAnders Carlsson2008-12-211-2/+19
| | | | llvm-svn: 61295
* Add support for member references (E1.E2, E1->E2) with C++ semantics,Douglas Gregor2008-12-202-2/+7
| | | | | | | | | | which can refer to static data members, enumerators, and member functions as well as to non-static data members. Implement correct lvalue computation for member references in C++. Compute the result type of non-static data members of reference type properly. llvm-svn: 61294
* Extend the unsupported error to include break and continue, and fix a Eli Friedman2008-12-201-8/+12
| | | | | | warning by using an unsigned index. llvm-svn: 61292
* Make VLAs usable, and make basic usage work correctly. Also, add a Eli Friedman2008-12-202-19/+9
| | | | | | | | | | simple test that actually does VLA codegen. Note that despite the fact that the alloca isn't in the entry block, it should dominate all uses; this is guaranteed by the restrictions on goto into VLA scope in C99. llvm-svn: 61291
* Handle typedefs to VLAs (Emit the size expr when we encounter the typedefAnders Carlsson2008-12-202-16/+23
| | | | llvm-svn: 61290
* Check the entire StackSaveValues stack for VLAs when dealing with goto and ↵Anders Carlsson2008-12-201-6/+10
| | | | | | return statements. Noticed by Eli Friedman. llvm-svn: 61289
* Make sure to generate code for arguments that have a variably modified type.Anders Carlsson2008-12-201-0/+10
| | | | llvm-svn: 61288
* Change EmitVLASize to take a QualType that must be a variably modified type.Anders Carlsson2008-12-203-27/+40
| | | | | | | | | | | | Emit the size even if the declared type is a variably modified type. This lets us handle void f(int n) { int (*a)[n]; printf("size: %d\n", sizeof(*a)); } llvm-svn: 61285
* Split up emitting of VLA sizes and getting the size of a VLA.Anders Carlsson2008-12-203-19/+31
| | | | llvm-svn: 61284
* Add some ErrorUnsupported calls and turn on VLA codegen again.Anders Carlsson2008-12-202-10/+21
| | | | llvm-svn: 61283
OpenPOWER on IntegriCloud