On 23/07/2019 3:58 AM, a11e99z wrote:
On Monday, 22 July 2019 at 14:03:15 UTC, Mike Parker wrote:
Francesco Mecca ha written an experience report for the D Blog about his SAOC 2018 project, porting Leandro Lucarella's old GC from D1 to D2.

The blog:
https://dlang.org/blog/wp-admin/post.php?post=2148&action=edit

Reddit:
https://www.reddit.com/r/programming/comments/cgdk1r/symmetry_autumn_of_code_experience_report_porting/

interesting idea do Mark phase through fork process.

I want more technical details:
- about Windows: will such idea work on Windows? does Windows support similar technique? (VirtualQueryEx/ReadProcessMemory/mmap/or_something)

The problem with Windows is not so much reading another process memory, is the fact that you cannot create another process which is copied from your own memory space AND be able to have live threads running in it.

What we can do (which will be good for things like audio and game engines) is make the GC only suspend the current thread and read from a snapshot of the heap space of the process. This we can do.

Unfortunately I remembered that marking is a bit more complex than just locating memory a bit too late tonight. No wonder I never tried before now to implement this (I have evaluated it).

I may have another try at it, if somebody can give me pointers on where the actual reading occurs in the GC. Because it has left me a bit stumped.

Reply via email to