19 Commits (67741f3f6841d423e59b3f6bd6c94971a9e150fa)

Author SHA1 Message Date
theraven 1a60fabf96 More 64-bit fixes. 16 years ago
theraven b04cccf46b Fixed some issues in runtime.c when looking up methods. This fixes some issues with DO.
Removed GNU dtable and sparse array implementations, replaced entirely now with versions based on the Étoilé runtime.  Performance is roughly equivalent in microbenchmarks, memory usage is significantly lower (Gorm goes from 95MB to 50MB on my machine - this will be even more pronounced on 64-bit systems), which should improve cache usage considerably.  Still room for some performance tuning, however.
16 years ago
theraven 0d78186238 Some bug fixes and tidies.
I now have an out-of-tree replacement for the dtable stuff, so sarray.{h,c} will be going away soon.  The replacement offers similar (slightly worse currently) performance in microbenchmarks, but uses half as much memory (Gorm goes from 95MB to 48MB on my machine).  This will be committed once it's been tweaked a little bit.
16 years ago
theraven 0957cbe425 Factored out dtable stuff into dtable_legacy.c so that it can be replaced and so that we can do some profiling of the replacement to make sure it doesn't introduce performance regressions. 16 years ago
theraven 2d84b96a72 Tidied up some bits by creating private headers for private data structures.
Imported selector table code frm the Étoilé runtime.  We can now make dispatch type dependent with a -D switch.  Not enabled yet, but it will be enabled in a warning mode soon - I consider preferable to the existing GNU and Apple solution of corrupting the stack.
16 years ago
qmathe 7656e1f9aa Commented out 'firstslot' unused variable, otherwise Clang reports it as an error. 16 years ago
theraven 96f51da81e Commented out some premature termination code. This is a bit of a hack; we're now repeatedly adding the same methods to dtables, which is ugly. We ought instead to be able to test if something is a lazy copy. 16 years ago
theraven 0abdc2a574 Small cleanups from last commit. 16 years ago
theraven d58dad7e32 Fixed a bug with category loading. Previously, a method in a category that overrode a method in the superclass would only be picked up by subclasses that were not yet initialized.
Quentin: This was the category loading problem that you saw.  It was dependent upon load order, so was difficult to reproduce, however a Smalltalk category on NSString overriding a method from NSObject demonstrated it (because GSString was always initialized by the time Smalltalk code is loaded because LKCompiler use it, but not by the time ObjC code is loaded).
16 years ago
theraven 202006f6b8 Removed some dead variables. 16 years ago
theraven 7af08f5a82 Tweaked the +initialize order to work around some of the insanity in NSObject and NSAutoreleasePool's interaction in GNUstep. This code is incredibly fragile, and on the old runtime sometimes completely fails and crashes during startup, depending on the order in which the files were linked in -base and how the platform linker works. Hopefully now it should work in all cases. 16 years ago
theraven cbf41a1fec Fixed build with clang. 16 years ago
theraven baed61c3e6 Added property support functions, NSBlock base classes and uncaught exception handler. 16 years ago
theraven 29790da51c Fixed bug in loading categories. 16 years ago
theraven 5bb7c43244 Fixed accidental insertion of methods into the uninitialized dtable. 16 years ago
theraven 546f31df69 Fixed a load of ->dtable references up to dtable_for_class() calls. Now no longer does the Wrong Thing™ if you do silly things like modifying a class's dtable in +initialize (which, sadly, GNUstep does for NSConstantString). 16 years ago
theraven d010cc60ea Fix for threading bug with +initialize. Some limitations:
- Now only one thread may be in any +initialize method at once.
- Not yet implemented for the new ABI lookup function.

The first I don't see as a limitation; if anything having +initialize methods
be guaranteed not to run concurrently may be convenient.  The second I will fix
soon.
17 years ago
theraven bba507bf70 Removed incorrect comment from blocks runtime. Tweaked runtime.h to make it show the new functions even in GNU-compat mode and made sure the object-substitution hook is called even when object substitution can't be used, so GNUstep can use it for the 10.5 NSObject runtime functions. 17 years ago
theraven 323e3dfaeb Added new runtime library, based on GCC 4.4 libobjc, libobjc_tr and Objective2.framework. 17 years ago