-nogc
Andrei Alexandrescu
SeeWebsiteForEmail at erdani.org
Thu Apr 23 04:49:34 PDT 2009
Frank Benoit wrote:
> 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.
Great. We need to mind this scenario (the right place is I think Ref).
Andrei
More information about the Digitalmars-d
mailing list