less conservative write barrier for tables

This commit is contained in:
Roberto Ierusalimschy
2004-08-10 16:17:23 -03:00
parent f87057690b
commit 26ae992129
5 changed files with 38 additions and 18 deletions

View File

@@ -1,5 +1,5 @@
/*
** $Id: ltable.c,v 2.2 2004/03/26 14:02:41 roberto Exp roberto $
** $Id: ltable.c,v 2.3 2004/04/30 20:13:38 roberto Exp roberto $
** Lua tables (hash)
** See Copyright Notice in lua.h
*/
@@ -375,7 +375,7 @@ static TValue *newkey (lua_State *L, Table *t, const TValue *key) {
}
}
setobj2t(L, gkey(mp), key);
luaC_barrier(L, t, key);
luaC_barriert(L, t, key);
lua_assert(ttisnil(gval(mp)));
for (;;) { /* correct `firstfree' */
if (ttisnil(gkey(t->firstfree)))