[erlang-questions] Deterministic destruction of NIF resources
Lukas Larsson
garazdawi@REDACTED
Fri Jul 15 16:53:40 CEST 2016
How do you know when the process dies?
If you aren't already you should use the trace flag 'exiting' (
http://erlang.org/doc/man/erlang.html#trace-3) to figure out when a process
actually has died. ERTS will delay process death after you send it a
termination signal for various reasons.
On Fri, Jul 15, 2016 at 4:39 PM, Roger Lipscombe <roger@REDACTED>
wrote:
> Sorry, let me rephrase: they're not garbage collected *when* that
> process dies. The destructor is sometimes called immediately, and
> sometimes at some point in the future. Can I make this deterministic?
>
> And, no, the resource has not been sent to another process or stored in
> ETS.
>
> On 15 July 2016 at 15:10, Sergej Jurečko <sergej.jurecko@REDACTED> wrote:
> >
> > On 15 Jul 2016, at 15:57, Roger Lipscombe <roger@REDACTED>
> wrote:
> >
> > because they're not garbage collected when that
> > process dies.
> >
> >
> > Then there is an outstanding reference to the resource. Has it been sent
> to
> > another process or stored in an ETS?
> >
> >
> > Sergej
> _______________________________________________
> erlang-questions mailing list
> erlang-questions@REDACTED
> http://erlang.org/mailman/listinfo/erlang-questions
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20160715/57c018c4/attachment.htm>
More information about the erlang-questions
mailing list