Message6122

Author zyasoft
Recipients MrMeanie, adam.spiers, amak, colinhevans, fwierzbicki, matt_brinkley, pjenvey, zyasoft
Date 2010-10-03.06:18:52
SpamBayes Score 5.0809685e-08
Marked as misclassified No
Message-id <1286086735.06.0.0510682016053.issue1327@psf.upfronthosting.co.za>
In-reply-to
Content
I have added a patch to demonstrate how we can remove the linked list maintained by initializingProxies and instead just use a simpler mechanism of managing it in the stack (but linkage via a ThreadLocal). This could be part of a more general refactoring of ThreadState, to separate reentrancy management from state mgmt.

Bob Lee's blog post on ThreadLocal is pretty useful for understanding this simplification:
http://blog.crazybob.org/2006/07/hard-core-java-threadlocal.html

We can apply something similar to other reentrancy state, such as enterRepr/exitRepr, compareStateDict, and recursion_depth.

Any actual change should just integrate this into ThreadState, instead of yet another auxiliary class (ThreadContext here). (Although in this case, it has no impact because proxy init always must use a ThreadLocal because it's going from Python -> Java -> Python.)
History
Date User Action Args
2010-10-03 06:18:55zyasoftsetmessageid: <1286086735.06.0.0510682016053.issue1327@psf.upfronthosting.co.za>
2010-10-03 06:18:55zyasoftsetrecipients: + zyasoft, fwierzbicki, amak, pjenvey, colinhevans, MrMeanie, matt_brinkley, adam.spiers
2010-10-03 06:18:54zyasoftlinkissue1327 messages
2010-10-03 06:18:54zyasoftcreate