-nogc
Frank Benoit
keinfarbton at googlemail.com
Thu Apr 23 04:43:49 PDT 2009
I am using D for a real time test system. There i have to make sure that
real time code does never use direct or indirect allocations.
I can use the GC in the non real time thread and at start up. I can
preallocate as much as I want. Just, it is not allowed in IRQ handler,
certainly.
What i did is, i patched the GC to have a callback in the allocation
function. My application can register for that callback and checks the
current thread. If it is a real time thread, an error is generated.
The disadvantage is, it is a runtime check. The advantage is, i can mix
code that can use the GC and code that can't.
More information about the Digitalmars-d
mailing list