Jan Vroonhof writes:
Colin Rafferty <craffert(a)ms.com> writes:
> More specifically, does it remove purespace altogher? Cool hack.
I
> never was sure what we needed it for, since it is for sharing static
> data between processes, and most OSs are smart about COW.
I used to think that too, but Kyle enlightened me.
Kyle has a way of doing that to people. Kyle's done it for me a
couple of times -- usually accompanying a rejected patch.
Read up on the archive. The GC needs to mark all objects that can
refer to other objects and thus it modifies the pages and you loose on
COW. Even strings can point to other objects because they can have
properties. (Not sure whether there is actually code that does that).
How about static strings?
For example, imagine I had a string at file scope defined like this:
const char * const DocString = ".....";
If it is only used in the C part, would it get marked?
--
Colin