MCPcopy Create free account
hub / github.com/CppCXY/EmmyLuaCodeStyle / entergen

Function entergen

3rd/lua-5.4.3/src/lgc.c:1293–1300  ·  view source on GitHub ↗

** Enter generational mode. Must go until the end of an atomic cycle ** to ensure that all objects are correctly marked and weak tables ** are cleared. Then, turn all objects into old and finishes the ** collection. */

Source from the content-addressed store, hash-verified

1291** collection.
1292*/
1293static lu_mem entergen (lua_State *L, global_State *g) {
1294 lu_mem numobjs;
1295 luaC_runtilstate(L, bitmask(GCSpause)); /* prepare to start a new cycle */
1296 luaC_runtilstate(L, bitmask(GCSpropagate)); /* start new cycle */
1297 numobjs = atomic(L); /* propagates all and then do the atomic stuff */
1298 atomic2gen(L, g);
1299 return numobjs;
1300}
1301
1302
1303/*

Callers 2

luaC_changemodeFunction · 0.85
fullgenFunction · 0.85

Calls 3

luaC_runtilstateFunction · 0.85
atomicFunction · 0.85
atomic2genFunction · 0.85

Tested by

no test coverage detected