summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen
Commit message (Collapse)AuthorAgeFilesLines
...
* 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
* More encoding support. This time forFariborz Jahanian2008-12-191-1/+1
| | | | | | @encode of classes and bitfields. llvm-svn: 61268
* Removed a slot in ObjCMemRegExpr used inFariborz Jahanian2008-12-182-4/+4
| | | | | | code gen which did not belong there. llvm-svn: 61203
* Allow ABI to use StructRet even for scalar values.Daniel Dunbar2008-12-181-9/+17
| | | | | | | | | | - Update comment to reflect fact that StructRet is now supported for any type (modulo LLVM support). - No functionality change, no scalar types currently use this feature. llvm-svn: 61192
* This patch will build the Records lazily per Steve's comments.Fariborz Jahanian2008-12-171-7/+1
| | | | | | | Note that one test duplicate-ivar-check.m will fail because I need to re-implement duplicate ivar checking. llvm-svn: 61154
* Warning fixes to operator precedence warnings.Eli Friedman2008-12-161-1/+1
| | | | | | | Someone should double-check that I didn't somehow break ObjC serialization; I think the change there actually changes the semantics. llvm-svn: 61098
* Remove tabs.Nate Begeman2008-12-162-4/+4
| | | | llvm-svn: 61097
* Name of addLayoutToClass is confusing as no layout calculationFariborz Jahanian2008-12-151-1/+1
| | | | | | | is done. Layout is calculated lazily at code gen type. This patch changes the name. llvm-svn: 61054
* Code gen. for ivar references; including bitfieldFariborz Jahanian2008-12-157-70/+61
| | | | | | ivars. llvm-svn: 61043
* Store the size of the EH stack inside each BreakContinue struct so we know ↵Anders Carlsson2008-12-133-10/+16
| | | | | | when a break/continue won't cross a try block. llvm-svn: 60998
* Patch for ObjCIvarRefExpr containing the fieldFariborz Jahanian2008-12-131-1/+3
| | | | | | matching the storage layout for this ivar llvm-svn: 60996
OpenPOWER on IntegriCloud