As of bug 659782 the allocator is treated as infallible for small, fix-sized structures. The ballast isn't actually implemented though, so at some point we'll have to modify IonAllocPolicy::ensureBallast to reserve space in the arena.
A tip from TM: be careful where you put the ballast. TM has some ballast (for nanojit) in every compartment, and you can have a lot of compartments, so that's just wasted space. It's much better if you can put it in the JSRuntime, say. Though I guess you then have locking considerations. Hmm. Ballast kinda sucks.
Would the threaddata be okay in terms of memory use? The compiler won't re-enter and the ballast could live and die with the compiler, if need be.
(In reply to comment #2)
> Would the threaddata be okay in terms of memory use? The compiler won't
> re-enter and the ballast could live and die with the compiler, if need be.
Sounds ideal. Do you mean ThreadData in jscntxt.h? I wonder if the tracer ballast could be moved in there as well.
This got fixed a while ago.