Debugging NPE during CanonicalizerPhase
java at stefan-marr.de
Wed Jul 24 09:16:44 PDT 2013
I am trying to debug an NPE I get while running TruffleSOM on top of Graal.
Would be great if someone could give me a hint, how to debug it.
For a bit of context, I got the latest Graal code checked out and compiled for debugging.
The invocation looks like this:
/mx.sh -d --debug --vm server vm -G:+DumpOnError -Xbootclasspath/a:../som/build/classes som.vm.Universe -cp ../TruffleSOM/Smalltalk ../TruffleSOM/Examples/Benchmarks/Loop.som
With a connected Eclipse, I was able to figure out that a FrameGetNode has a value for `slot` that is a ConstantNode with the value null (i.e. slot.asConstant().isNull() == true).
Now I am a bit stuck, because it looks like the FrameGetNode is never actually instantiated with such a ConstantNode object for the slot field, so I assume, it is changed somewhere later. However, I have no clue where that might happen.
What also confuses me is that there is no setter for the slot field, and ConstantNode as well as Constant look rather immutable to me.
I have the feeling I am missing something rather basic here.
Any hints would be highly appreciated.
Software Languages Lab
Vrije Universiteit Brussel
Pleinlaan 2 / B-1050 Brussels / Belgium
Phone: +32 2 629 2974
Fax: +32 2 629 3525
More information about the graal-dev