Fwd: NSSpellChecker crashes after 64k words
Fwd: NSSpellChecker crashes after 64k words
- Subject: Fwd: NSSpellChecker crashes after 64k words
- From: Denis Stanton <email@hidden>
- Date: Thu, 14 Apr 2005 08:36:08 +1200
Hi Evan
With advice from this list I added NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init]; and [pool release]; to each level of my nested loops, and at the same time increased the nesting to four levels.
I ran the app last night for 12 hours on a 2 x 2 GB XServe. I had to switch it off after 76,468,325 iterations through NSSpellChecker. I think I can safely say that with proper auto releasing NSSpellChecker does not impose any artificial limits on use.
Thanks for contributing time to my little project.
Denis
Begin forwarded message:
From: Denis Stanton <email@hidden>
Date: April 14, 2005 7:03:03 AM
To: Denis Stanton <email@hidden>
Subject: Fwd: NSSpellChecker crashes after 64k words
Begin forwarded message:
From: Evan DiBiase <email@hidden>
Date: 13 April 2005 3:41:20 AM
To: email@hidden
Subject: Re: NSSpellChecker crashes after 64k words
On Apr 12, 2005, at 11:07 AM, The Karl Adam wrote:
Have you tried this with code that just creates auto-released objects?
I whipped up a sample program to test this:
#import <Foundation/Foundation.h>
int main (int argc, const char * argv[]) {
NSAutoreleasePool * pool = [[NSAutoreleasePool alloc] init];
NSString *s;
int i;
for (i = 0; true; i++) {
s = [NSString stringWithString:@"email@hidden"];
NSLog(@"%d", i);
}
[pool release];
return 0;
}
It's still going strong at 200,000 strings created. I'll keep it running for a while, though, and if it crashes I'll let the list know.
Evan _______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
Denis Stanton
email@hidden
Home: (09) 533 0391
mobile: 021 1433622
<x-tad-smaller>Denis Stanton
Orcon Internet Limited
(09) 480 9299
</x-tad-smaller><x-tad-smaller>http://www.orcon.net.nz
</x-tad-smaller><x-tad-smaller>
</x-tad-smaller>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden