[concurrency-interest] DirectByteBuffers and reachabilityFence

thurstonn thurston at nomagicsoftware.com
Tue Dec 15 15:31:28 EST 2015

Ahh, yes.  You're right.
The outer ES becomes unreachable while the delegate's #submit is executing.
And the outer ES finalize (indirectly) ->

hence the race and the rejected submission

Martin Buchholz-3 wrote
> I just added this comment to
> https://bugs.openjdk.java.net/browse/JDK-8145304
> Part of the problem is that there are two finalize methods in play here.
> The implementation does
>     public static ExecutorService newSingleThreadExecutor() {
>         return new FinalizableDelegatedExecutorService
>             (new ThreadPoolExecutor(1, 1,
> so the outer executor may get finalized while methods on the inner are
> still executing.
> Not sure of the motivation for the finalization strategy here.
> _______________________________________________
> Concurrency-interest mailing list

> Concurrency-interest at .oswego

> http://cs.oswego.edu/mailman/listinfo/concurrency-interest

View this message in context: http://jsr166-concurrency.10961.n7.nabble.com/DirectByteBuffers-and-reachabilityFence-tp12935p13087.html
Sent from the JSR166 Concurrency mailing list archive at Nabble.com.

More information about the Concurrency-interest mailing list