I tried to compile a file with '-mllvm -debug', which caused a crash. This time this was during isel, where the common code did not properly handle a call to printIRSlotNumber without a Function pointer set. This occurred because SystemZAddressingMode::dump() was calling SDNode::dump() without passing the DAG pointer.
This patch:
- It seems reasonable that the common code does not crash, and this patch at least prints a question mark instead of calling printIRSlotNumber() when the Function pointer is not set.
- Since the DAG is available, SystemZAddressingMode::dump() should pass it.
My problem would disappear even without (1) since (2) avoids it. This also means there is no test case for (1). Adding reviewer for (1) also.
Can we make this:
?
That way, printIRSlotNumber will print <badref> instead of ?.