Summary: | Add zombies to JSC | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Oliver Hunt <oliver> | ||||
Component: | JavaScriptCore | Assignee: | Nobody <webkit-unassigned> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | ggaren, webkit.review.bot, zombie | ||||
Priority: | P2 | ||||||
Version: | 528+ (Nightly build) | ||||||
Hardware: | PC | ||||||
OS: | OS X 10.5 | ||||||
Attachments: |
|
Description
Oliver Hunt
2009-12-02 21:47:31 PST
Created attachment 44209 [details]
Patch
style-queue ran check-webkit-style on attachment 44209 [details] without any errors.
Comment on attachment 44209 [details] Patch > -#define COLLECT_ON_EVERY_ALLOCATION 0 > +#define COLLECT_ON_EVERY_ALLOCATION 1 Yeah, I don't think you mean that. I'm only guessing. > - imp->~JSCell(); > +#if ENABLE(JSC_ZOMBIES) > + if (!imp->isZombie()) { > + const ClassInfo* info = imp->classInfo(); > +#endif > + imp->~JSCell(); > +#if ENABLE(JSC_ZOMBIES) > + new (imp) JSZombie(info, JSZombie::leakedZombieStructure()); > + heap.numZombies++; > + } > +#endif Personally I think this might be a little nicer as: #if ENABLE(JSC_ZOMBIES) if (!imp->isZombie()) { const ClassInfo* info = imp->classInfo(); imp->~JSCell(); new (imp) JSZombie(info, JSZombie::leakedZombieStructure()); heap.numZombies++; } #else imp->~JSCell(); #endif BRRrrrraaaiiiiiinnnnzzzzzzzzzzzzzzzzzzzzz+ MMmoorrre BRRrrrraaaiiiiiinnnnzzzzzzzzzzzzzzzzzzzzz. LOL |