Recent Truffle DSL changes.

Doug Simon doug.simon at oracle.com
Thu Sep 18 10:10:41 UTC 2014


On Sep 18, 2014, at 11:12 AM, Stefan Marr <java at stefan-marr.de> wrote:

> Hi Christian:
> 
> On 18 Sep 2014, at 00:05, Christian Humer <christian.humer at gmail.com> wrote:
> 
>> Regarding the thread-safety issues. Yes polymorphic rewrites are not yet thread-safe. But they were also not thread-safe in the old version. So you might have been just lucky.
>> However it is straight forward to make them thread-safe. You just have to wrap every replace in DSLShare into a closure and call atomic on the node that is currently in the AST.
>> I've attached a patch. Let me know if that works for you. So I can push it tomorrow. (Had no time to verify it yet) 
> 
> Have only tested it briefly, but there is still an issue with a node that doesn’t have a parent yet.
> The Eclipse and the JVM are unfortunately rather uncooperative. Debugging this isn’t exactly easy, because for half of the objects Eclipse refuses to give me any information.
> Is this a known issue? I set the debugger to suspend the VM once an illegal state exception is hit. That doesn’t seem to be a good idea.

Try setting the exception breakpoint to “suspend thread” instead of “suspend VM”. This resolved most of my issues where Eclipse does not respond.

-Doug


More information about the graal-dev mailing list