[Gc] win32 special treatment in GC_add_roots and GC_remove_roots
lucas at lucasmeijer.com
Mon Sep 12 12:45:30 PDT 2011
in GC_add_roots_inner there are is a win32 codepath and a nonwin32 codepath
for detecting if there is an overlap/adjescent rootset already present. if so it
extends the existing rootset to fully include the newly added rootset.
GC-remove_roots is not implemented on win32.
I'm hoping someone can explain why the nonwin32 codepath is required. On a quick
experiment, making win32 use the nonwin32 codepath, things "seem" to work fine,
and allow me to unregister roots.
A message on this mailinglist, Ivan writes:
"In theory, it's possible to implement GC_remove_roots() for Win32.
But, it is complicated due to overlapping/adjacent regions processing."
This statement puzzles me, as the non Win32 codepath also does
overlapped-roots-collapsing, so it would seem to be it would suffer from the
same problem of unregistering being unsuccesful in the case where the rootset
has been expanded.
What is so special about win32?
More information about the Gc