review (S) for 6777083: assert(target != __null, "must not be null")
Tom Rodriguez
tom.rodriguez at oracle.com
Mon Apr 4 17:25:08 PDT 2011
On Apr 4, 2011, at 5:17 PM, Vladimir Kozlov wrote:
> The fix looks good. Do you know why we use ExternalAddress for byte_map_base on x86? On sparc it is just constant value (address).
I think it's an attempt to take advantage of rip relative addressing to produce the constant in 64 bit. I played a bit with unifying all the copies of the card table assembly but I kind of rat holed on it. It's just a bit of a mess and I felt myself getting sucked under so I got out of the water and went with the most straightforward fixed that made it go away. ;)
tom
>
> Vladimir
>
> Tom Rodriguez wrote:
>> http://cr.openjdk.java.net/~never/6777083
>> 6777083: assert(target != __null,"must not be null")
>> Reviewed-by:
>> ExternalAddress is often used to generate code for references to the
>> byte_map_base of the card table. Depending on the address layout we
>> get byte_map_base may be a real address looking value or sometimes it
>> maybe a small number or even zero. This causes
>> external_word_relocation to assert because the encoding it uses
>> assumes that the adress isn't within the first page. This has been
>> patched up at each use site in the past but keeps recurring as new
>> code gets written. To fix this I've modified ExternalAddress to drop
>> the reloc in the case where it's not encodable. It's almost
>> impossible to force a layout where byte_map_base is a small number but
>> injecting a small number into it indicates that the assembly code
>> generation works correcty after the change.
More information about the hotspot-compiler-dev
mailing list