RFR(M): 8166140: C1: Possible integer overflow in LIRGenerator::generate_address on several platforms
Doerr, Martin
martin.doerr at sap.com
Mon Sep 19 13:47:50 UTC 2016
Hi Vladimir,
you're right. I have fixed that too in the new webrev:
http://cr.openjdk.java.net/~mdoerr/8166140_C1_int_overflow/webrev.01/
The 2 LIR_Address constructors you have mentioned don't have many users. The other ones look ok.
Thanks and best regards,
Martin
-----Original Message-----
From: Vladimir Kozlov [mailto:vladimir.kozlov at oracle.com]
Sent: Donnerstag, 15. September 2016 20:06
To: hotspot-compiler-dev at openjdk.java.net
Cc: Doerr, Martin <martin.doerr at sap.com>
Subject: Re: RFR(M): 8166140: C1: Possible integer overflow in LIRGenerator::generate_address on several platforms
Good but is is not enough.
emit_array_address() in c1_LIRGenerator_x86.cpp has the same problem.
I would suggest to look on all places where next methods are called and make sure they are correct:
LIR_Address(LIR_Opr base, intx disp, BasicType type)
LIR_Address(LIR_Opr base, LIR_Opr index, Scale scale, intx disp, BasicType type)
Thanks,
Vladimir
On 9/15/16 8:25 AM, Doerr, Martin wrote:
> Hi,
>
>
>
> as discussed with Vladimir, C1 contains code to simplify constant index/displacement addressing which uses int. However,
> int may overflow on 64 bit platforms.
>
>
>
> Please review the following webrev:
>
> http://cr.openjdk.java.net/~mdoerr/8166140_C1_int_overflow/webrev.00/
>
>
>
> I'll also need a sponsor, please.
>
>
>
> Thanks and best regards,
>
> Martin
>
>
>
More information about the hotspot-compiler-dev
mailing list