** Enter generational mode. Must go until the end of an atomic cycle ** to ensure that all threads and weak tables are in the gray lists. ** Then, turn all objects into old and finishes the collection. */
| 1191 | ** Then, turn all objects into old and finishes the collection. |
| 1192 | */ |
| 1193 | static lu_mem entergen (lua_State *L, global_State *g) { |
| 1194 | lu_mem numobjs; |
| 1195 | luaC_runtilstate(L, bitmask(GCSpause)); /* prepare to start a new cycle */ |
| 1196 | luaC_runtilstate(L, bitmask(GCSpropagate)); /* start new cycle */ |
| 1197 | numobjs = atomic(L); /* propagates all and then do the atomic stuff */ |
| 1198 | atomic2gen(L, g); |
| 1199 | return numobjs; |
| 1200 | } |
| 1201 | |
| 1202 | |
| 1203 | /* |
no test coverage detected