Intern globals per-context, not per tree, which allows transitioning between trees that use globals. The type of all global slots compiled code uses is expected to remain stable, otherwise the entire code cache has to be flushed. Changes to the shape of the global object also flush the code cache. Working for trace-tests.js, but fails math-partial-sum.js

This commit is contained in:
Andreas Gal
2008-08-19 11:32:36 -07:00
parent 577aae6c7f
commit f423ed448c
3 changed files with 76 additions and 92 deletions

View File

@@ -417,8 +417,6 @@ js_FastCallIteratorNext(JSContext* cx, JSObject* iterobj)
GuardRecord* FASTCALL
js_CallTree(InterpState* state, Fragment* f)
{
/* current we can't deal with inner trees that have globals so report an error */
JS_ASSERT(!((TreeInfo*)f->vmprivate)->globalSlots.length());
union { NIns *code; GuardRecord* (FASTCALL *func)(InterpState*, Fragment*); } u;
u.code = f->code();
return u.func(state, NULL);