summaryrefslogtreecommitdiffstats
path: root/clang/lib/CodeGen/CGObjCMac.cpp
Commit message (Collapse)AuthorAgeFilesLines
...
* Remove getIntegerConstantExprValue in favor of using EvaluateAsInt.Eli Friedman2009-04-261-2/+2
| | | | llvm-svn: 70145
* split ObjC and C++ Statements out into their own headers.Chris Lattner2009-04-261-0/+1
| | | | llvm-svn: 70105
* Minor refactoring. No intended change in behavior.Fariborz Jahanian2009-04-241-3/+3
| | | | llvm-svn: 69988
* Minor refactoring. No change in functionality.Fariborz Jahanian2009-04-241-2/+1
| | | | llvm-svn: 69979
* Some code clean up of objc2's bitmap layout.Fariborz Jahanian2009-04-241-30/+28
| | | | llvm-svn: 69970
* Removed bunch of FIXMEs no longer needed.Fariborz Jahanian2009-04-231-8/+0
| | | | llvm-svn: 69896
* Mark IMAGE_INFO as constant on x86_64-darwin.Daniel Dunbar2009-04-231-0/+1
| | | | | | | - This shouldn't change anything, we never actually access it, but this is consistent with llvm-gcc (and 32-bit) llvm-svn: 69880
* Use std::sort instead of qsort.Daniel Dunbar2009-04-231-15/+7
| | | | | | | | | - Notably, there was a memory error here, SkipIvars does not have to be the same size as IvarsInfo. - Fariborz, please check. llvm-svn: 69850
* Eliminate the three SmallVectors in ObjCImplDecl (for instanceDouglas Gregor2009-04-231-20/+30
| | | | | | | | | | | methods, class methods, and property implementations) and instead place all of these entities into the DeclContext. This eliminates more linear walks when looking for class or instance methods and should make PCH (de-)serialization of ObjCDecls trivial (and lazy). llvm-svn: 69849
* ivar layout bitmap is alive!Fariborz Jahanian2009-04-221-10/+20
| | | | llvm-svn: 69838
* Reapply r69771, with updates & fixes:Daniel Dunbar2009-04-221-8/+21
| | | | | | | | | | | | | | | | | | | | | | Rework the shadow struct that is layed out for Objective-C classes. - Superclasses are now always laid out in their shadow structure at the first field. - Prior to this, the entire class heirarchy was flattened into a single structure which meant that alignment, padding, and bitfields were incorrect (the ASTRecordLayout was correct however, which meant our debug info didn't coincide with ivar offsets, for example). - This is still very suboptimal (for example, ivar are looked up recursively, but I believe the ivar layout itself is now at least close to correct. - <rdar://problem/6773388> error: objc[29823]: layout bitmap sliding backwards llvm-svn: 69811
* Remove lookupFieldDeclFromIvar from ObjCIvarDecl interface.Daniel Dunbar2009-04-221-2/+18
| | | | | | - This is only used by CGObjCRuntime now. llvm-svn: 69800
* Don't convert interface types (to structs) as part of CodeGenTypes.Daniel Dunbar2009-04-221-2/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | - This has pros and cons, but for now the pros seem to significantly outway the con. The con is that we will always need to cast in the runtime implementation to a struct type, if we wish to access an interface directly. The pros are: - Avoid the cost of generating types which are used. Most manipulation of Objective-C objects is done through messages, and only the implementation of a class will directly access memory. Previously, we would convert the type even if it only appear as a function parameter, for example. - We don't need to worry about incomplete types, and UpdateCompletedType for interfaces is gone. - It becomes easier to narrow the interface to the shadow struct for Objective-C interfaces (so it can be eliminated). Currently the runtimes still use the CodeGenTypes machinery to generate the LLVM structure they need via ConvertTagDecl, but this can eventually be replaced. llvm-svn: 69797
* Add CGObjCRuntime::GetConcreteClassStruct to encapsulate access to theDaniel Dunbar2009-04-221-26/+13
| | | | | | underlying llvm::StructType for an interface. llvm-svn: 69796
* Emit meta data using the Ivar, not a looked up FieldDecl.Daniel Dunbar2009-04-221-8/+6
| | | | llvm-svn: 69790
* Merge ivar access amongst the three runtimes.Daniel Dunbar2009-04-221-124/+99
| | | | | | | | | - For now, this means we are always doing the address computations by hand instead of constructing a proper GEP. Right now, however, this is less important than having fewer entry points to dealing with Objective-C interface layout. llvm-svn: 69787
* Make ObjCInterfaceDecl's const in some more places.Daniel Dunbar2009-04-221-6/+5
| | | | llvm-svn: 69775
* Revert r69771, I missed some (obvious) details. :/Daniel Dunbar2009-04-221-16/+49
| | | | llvm-svn: 69773
* Rework the shadow struct that is layed out for Objective-C classes.Daniel Dunbar2009-04-221-49/+16
| | | | | | | | | | | | | | | | | | | - Superclasses are now always laid out their shadow structure at the first field. - Prior to this, the entire class heirarchy was flattened into a single structure which meant that alignment, padding, and bitfields weren't packed correctly (the ASTRecordLayout was correct however, which meant our debug info didn't coincide with ivar offsets, for example). - This is still very suboptimal, but I believe the ivar layout itself is now at least close to correct. - <rdar://problem/6773388> error: objc[29823]: layout bitmap sliding backwards llvm-svn: 69771
* move 64-bit abi functions to lazy model, everything is lazy now, yay.Chris Lattner2009-04-221-75/+81
| | | | llvm-svn: 69767
* remove the last of the non-lazy objc runtime functions for the 32-bit ABI,Chris Lattner2009-04-221-54/+56
| | | | | | 7 left for 64-bit ABI. llvm-svn: 69766
* number of non-lazy runtime functions from 9 -> 4.Chris Lattner2009-04-221-44/+47
| | | | llvm-svn: 69765
* make message send functions lazy, we're down from 14 non-lazy functions to 9.Chris Lattner2009-04-221-64/+65
| | | | llvm-svn: 69764
* move more EH stuff to being lazily created. An empty .m file now Chris Lattner2009-04-221-52/+54
| | | | | | produces just 14 dead "declares" in llvm ir instead of 19. llvm-svn: 69763
* make try/catch objc runtime functions be lazily generated.Chris Lattner2009-04-221-22/+26
| | | | | | rdar://6809612 llvm-svn: 69762
* Make sure to mark the interface as completed when we see anDaniel Dunbar2009-04-211-5/+2
| | | | | | | | | @implementation that closes a @class delcaration. - I don't know how to make a test case for this, but this strengthens the invariants that hold internally. The functionality change here is the edit to SemaDeclObjC.cpp. llvm-svn: 69728
* More objc2's ivar layout bitmap. No change in functionality.Fariborz Jahanian2009-04-211-5/+26
| | | | llvm-svn: 69695
* Kill ASTContext::[gs]etFieldForDecl, instead we just lookup thingsDaniel Dunbar2009-04-211-9/+4
| | | | | | | | when we need them -- which is exactly what some code was already doing! - No intended functionality change. llvm-svn: 69648
* Assert on a few conditions that (I believe) should holdDaniel Dunbar2009-04-211-0/+2
| | | | | | | w.r.t. ASTContext::[gs]etFieldDecl, and the Field argument to EmitObjCValueForIvar). llvm-svn: 69639
* ObjC2's Ivar bitmap layout work. No change in functionality.Fariborz Jahanian2009-04-201-17/+29
| | | | llvm-svn: 69629
* Move countInheritedIvars to within striking distance ofDaniel Dunbar2009-04-201-39/+34
| | | | | | | | | | | | GetClassSizeInfo Reduce nesting in GetInterfaceDeclStructLayout. Tweak some comments. No functionality change. llvm-svn: 69621
* Inline GetFirstIvarInRecord into sole caller.Daniel Dunbar2009-04-201-28/+9
| | | | | | - No functionality change. llvm-svn: 69582
* Set a bit in IMAGE_INFO to indicate that we don't contain anyDaniel Dunbar2009-04-201-3/+12
| | | | | | | | @synthesized ivars for superclasses. - <rdar://problem/6806371> [clang] Mark code without miscompiled @synthesized properties llvm-svn: 69581
* Lift out GetNamedIvarList.Daniel Dunbar2009-04-201-30/+40
| | | | | | | | | Drop uses of GetFirstInvarInRecord, instead we lookup the ivars we know are in the record. - This is somewhat less efficient, but I need to detangle this code first... llvm-svn: 69579
* Don't emit ivar offsets for unnamed bit fields.Daniel Dunbar2009-04-201-5/+8
| | | | | | Also, added assertion that the field matches what would be looked up. llvm-svn: 69572
* Remove non-const form of lookupFieldDeclForIvar.Daniel Dunbar2009-04-201-1/+2
| | | | llvm-svn: 69563
* Comment fixes.Daniel Dunbar2009-04-201-6/+6
| | | | llvm-svn: 69562
* Lift GetClassSizeInfo out of GenerateClass, add a FIXME.Daniel Dunbar2009-04-191-29/+37
| | | | | | - No functionality change. llvm-svn: 69561
* Fix rdar://6804402 - crash on objc implementations declared withChris Lattner2009-04-191-8/+17
| | | | | | | @class but no implementation. This was broken in all 3 runtime impls. llvm-svn: 69512
* Fix bug in computation of ivar offsets for (adjacent) bitfields.Daniel Dunbar2009-04-191-10/+13
| | | | | | | | - The confusing IRgen bitfield interface is partly to blame here; fixing the functional error for now, cleanups to the interface to follow. llvm-svn: 69503
* Reuse ObjcIvarOffsetVariable instead of duplicating code.Daniel Dunbar2009-04-191-22/+9
| | | | | | - No functionality change (but added a FIXME). llvm-svn: 69496
* Remove some unnecessary complexity.Daniel Dunbar2009-04-191-11/+5
| | | | | | - No functionality change. llvm-svn: 69495
* Fix a bug found by inspection, class/meta references could be emittedDaniel Dunbar2009-04-181-17/+39
| | | | | | into the wrong section (they shared the same lookup table). llvm-svn: 69433
* fix a crash compiling code with its own definition of objc_assign_weak.Chris Lattner2009-04-171-5/+11
| | | | | | rdar://6800430 llvm-svn: 69392
* Don't put msgrefs in used globals (in particular, we don't wantDaniel Dunbar2009-04-171-1/+0
| | | | | | no-dead-strip set on them). llvm-svn: 69388
* Fix rdar://6800926 - crash compiling non-fragile _Bool bitfield ivar,Chris Lattner2009-04-171-5/+5
| | | | | | | the functional change here is changing ConvertType -> ConvertTypeForMem so that we handle i1 fields properly as memory. llvm-svn: 69361
* Removed a no longer needed FIXME comment.Fariborz Jahanian2009-04-161-2/+0
| | | | llvm-svn: 69315
* Category method synbols must be qualified by gategory name toFariborz Jahanian2009-04-161-0/+6
| | | | | | match gcc's. llvm-svn: 69305
* Don't use \01 in symbol name if unnecessary.Daniel Dunbar2009-04-151-1/+1
| | | | | | | | - This was particularly bad since I fixed one instance of this name and not another, meaning we got an LLVM module with the same effective name in two different globals! llvm-svn: 69205
* Fix alignment on obj_msgrefs to match llvm-gcc.Daniel Dunbar2009-04-151-2/+1
| | | | llvm-svn: 69199
OpenPOWER on IntegriCloud