Request for reviews (M): 6709742: find_base_for_derived's use of Ideal NULL is unsafe causing crashes during register allocation
Vladimir Kozlov
Vladimir.Kozlov at Sun.COM
Mon Apr 20 14:50:12 PDT 2009
http://cr.openjdk.java.net/~kvn/6709742/webrev.00
Fixed 6709742: find_base_for_derived's use of Ideal NULL is unsafe causing crashes during register allocation
Problem:
PhaseChaitin::stretch_base_pointer_live_ranges() stretches
the base pointers for live ranges and in some cases may
have to construct a NULL base in find_base_for_derived.
It constructs an Ideal NULL instead of a mach one and
if the Ideal NULL is ever used in Phi with real machine
values we will die during register allocation.
Solution:
Create a mach node corresponding to ideal node ConP #NULL
specifically for derived pointers.
Use an existing mach node (matched for ConP #NULL) only
if it is shared to avoid false sharing if the mach node
for derived pointers is not used.
Add the assert to catch the bug case.
Add asserts to verify that narrow pointers can't be derived.
Reviewed by:
Fix verified (y/n): y
Other testing:
JPRT, CTW (32- and 64-bit), JPRT and CTW with compressed oops
More information about the hotspot-compiler-dev
mailing list