Scoped variables

Douglas Surber douglas.surber at
Tue Dec 4 15:02:22 UTC 2018

For what it is worth all the uses I have made of ThreadLocals are simpler than what I understand of this discussion. Yes, I have seen others use them in more sophisticated ways, but I haven't. I have only used ThreadLocals to avoid lock contention on Objects that could otherwise be static. In my uses I don't need or even want an Object per Java Thread. What would be better is an Object per core. Context switch while in a critical section of the Object would be problematic so Object per core might not be practical, but if it could be made to work it would be the ideal for my use cases.


> On 12/3/18 2:55 PM, John Rose wrote:
>> In part we are drawing on the very old idea of a Lisp "SPECIAL" variable.

More information about the loom-dev mailing list