RFR(XS): 8193518: C2: Vector registers sometimes corrupted at safepoint

Nils Eliasson nils.eliasson at oracle.com
Thu Dec 14 16:15:47 UTC 2017


Sorry, I was fast and wrong. 

Looks good,

Thanks for fixing Roland,

//Nils

----- Original Message -----
From: nils.eliasson at oracle.com
To: hotspot-compiler-dev at openjdk.java.net
Sent: Thursday, December 14, 2017 5:12:39 PM GMT +01:00 Amsterdam / Berlin / Bern / Rome / Stockholm / Vienna
Subject: Re: RFR(XS): 8193518: C2: Vector registers sometimes corrupted at safepoint

Hi Roland,

Thanks for finding this bug!

You need to initalize _max_vector_size in Compile::init.

// Nils


On 2017-12-14 17:00, Roland Westrelin wrote:
> http://cr.openjdk.java.net/~roland/8193518/webrev.00/
>
> If a method has several vectorized loops, the logic that keep tracks of
> Compile::_max_vector_size sets it to the max vector size of the last
> loop (and not to the max vector size of all
> loops). Compile::_max_vector_size is then used to mark nmethods that
> need vector registers to be saved on a safepoint. If the last loop uses
> small vectors but other loops in the method use large vectors, registers
> are not saved correctly at a safepoint in one of the other loops and can
> be corrupted.
>
> The test case only fails with Serial GC AFAICT but I saw that failure
> with G1 running some other applications.
>
> Roland.



More information about the hotspot-compiler-dev mailing list