<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=UTF-8" http-equiv="Content-Type">
  <title></title>
</head>
<body bgcolor="#ffffff" text="#000000">
<br>
<br>
Leandro Lucarella wrote:
<blockquote cite="mid:20100819154844.GT5751@llucax.com.ar" type="cite">
  <pre wrap="">Leandro Lucarella, el 15 de agosto a las 21:57 me escribiste:
  </pre>
  <blockquote type="cite">
    <pre wrap="">I've created a bug report:
"Static data that must be scanned by the GC should be grouped"
<a class="moz-txt-link-freetext" href="http://d.puremagic.com/issues/show_bug.cgi?id=4650">http://d.puremagic.com/issues/show_bug.cgi?id=4650</a>

For the lazy, here is a fragment of the bug report:
---
It would be nice if the compiler could group all the static that must
really be scanned (programs static variables) together and make its
limits available to the GC. It would be even nicer to leave static
variables that have no pointers out of that group, and even much more
nicer to create a pointer map like the one in the patch from bug 3463 to
allow precise heap scanning. That way the only memory in the program
that would have to be scanned conservatively will be the stack.
---

I wonder if this is even possible, and how much work would require in
that case. I did almost no DMD hacking but if this is not too hard
and/or if someone can give me some pointers on how to do it I'd like to
give it a try. I suspect it could have a very significant positive
impact in the GC performance.
    </pre>
  </blockquote>
  <pre wrap=""><!---->
I know this is probably really low priority for DMD, but any answer
would be appreciated, even if it is something like "no idea how doable
it is, it would take time to think about it and is low priority" :)

  </pre>
</blockquote>
<br>
I don't think spending a lot of effort on the static data is
worthwhile, as very little of modern programs should consist of static
mutable data.<br>
<br>
What's held me back from adding in precise scanning data for everything
is the large expansion of the memory footprint of a program to hold all
this data.<br>
</body>
</html>