Subj : Re: GC question: JS_GetStringBytes To : Brendan Eich From : Eric Anholt Date : Sun Aug 28 2005 05:03 am Brendan Eich wrote: > Eric Anholt wrote: > >> I'm one of the developers of swfdec, and we've been using the >> spidermonkey code for interpreting actionscript with pretty good >> success (primary complaint would be the lack of a build system outside >> of mozilla that properly builds and installs shared libraries). > > > > We're taking patches ;-). There's a bug > (https://bugzilla.mozilla.org/show_bug.cgi?id=97954) asking for a > unified, standalone, mozilla-style autoconf build setup. Not sure this > will help, but it might. What OSes are you targeting? I'm a FreeBSD guy, Linux is where most of our handful of users are (we've got a *long* way to go to be a general useful flash player), but I think open-source unix is the main target. So autotooled build is just great, because it means that the libraries come out right and the build is automatic for users on anything that it's been ported to before. Right now FreeBSD has a spidermonkey package, but I noticed a lack of soversion on the lib, and it's quite patched from upstream. I'm assuming you're intending the "standalone" to be in the same tree, just side-by-side build systems so that you could make distcheck the autotooled bits and get a tarball to release. Is this your expection? If so, would reviewing the patch help to get it in? >> - What would you do if you have to maintain a stack of jsvals? I'm >> using a manually rooted JS array and setting jsvals into indexes of >> it, but I'm not terribly pleased with this method. > > > > You might use the interpreter's stack in the current JSContext. Anent > that idea, what are these jsvals for? When do you push and pop? Can > you bound the size of the stack, or of segments of it that are "chunky" > enough to amortize the costs of managing the allocation and deallocation? The idea of using the interpreter's stack is interesting, but I'll have to think more than I can at the moment (approaching four am, coming back from a housewarming party) before I could say if sharing a stack would work for us for sure. .