MCPcopy Create free account
hub / github.com/ZDoom/Raze / MarkRoot

Function MarkRoot

source/common/objects/dobjgc.cpp:383–408  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

381}
382
383static void MarkRoot()
384{
385 PrevStepStats = StepStats;
386 StepStats.Reset();
387
388 Gray = nullptr;
389
390 for (auto func : markers) func();
391
392 // Mark soft roots.
393 if (SoftRoots != nullptr)
394 {
395 DObject **probe = &SoftRoots->ObjNext;
396 while (*probe != nullptr)
397 {
398 DObject *soft = *probe;
399 probe = &soft->ObjNext;
400 if ((soft->ObjectFlags & (OF_Rooted | OF_EuthanizeMe)) == OF_Rooted)
401 {
402 Mark(soft);
403 }
404 }
405 }
406 // Time to propagate the marks.
407 State = GCS_Propagate;
408}
409
410//==========================================================================
411//

Callers 2

SingleStepFunction · 0.85
FullGCFunction · 0.85

Calls 2

MarkFunction · 0.70
ResetMethod · 0.45

Tested by

no test coverage detected