RFR(S/M): 8150646: Add support for blocking compiles through whitebox API

Volker Simonis volker.simonis at gmail.com
Fri Feb 26 08:10:22 UTC 2016


Hi Nils,

I have a similar fix like yours in my patch queue since a while but
never managed to send it out for review.

I took a little different approach and made -XX:BackgroundCompilation
applicable on a per-method base trough the compiler directive
framework. Can you please give me a few hours to prepare a clean
webrev of my solution so we can discuss it as well. Maybe we can even
merge both solutions?

And I think there's two things you can improve even if we completely
stay with your solution. You will have to change
AdvancedThresholdPolicy::is_stale() to prevent methods from beeing
removed from the compile queue because they are considered stale. This
happens quite often if you register a method for compilation but don't
call it anymore.

And you can change AdvancedThresholdPolicy::compare_methods() to
prefer blocking compiles over non-blocking ones. This will decrease
the time you'll have to wait for a blocking compilation and decreases
the chance that a method registered for a blocking compile gets stale
(see previous section).

Regards,
Volker


On Thu, Feb 25, 2016 at 4:01 PM, Nils Eliasson <nils.eliasson at oracle.com> wrote:
> Hi,
>
> Please review this change that adds support for blocking compiles in the
> whitebox API. This enables simpler less time consuming tests.
>
> Motivation:
> * -XX:-BackgroundCompilation is a global flag and can be time consuming
> * Blocking compiles removes the need for waiting on the compile queue to
> complete
> * Compiles put in the queue may be evicted if the queue grows to big -
> causing indeterminism in the test
> * Less VM-flags allows for more tests in the same VM
>
> Testing:
> Posting a separate RFR for test fix that uses this change. They will be
> pushed at the same time.
>
> RFE: https://bugs.openjdk.java.net/browse/JDK-8150646
> JDK rev: http://cr.openjdk.java.net/~neliasso/8150646/webrev_jdk.01/
> Hotspot rev: http://cr.openjdk.java.net/~neliasso/8150646/webrev.02/
>
> Best regards,
> Nils Eliasson


More information about the hotspot-compiler-dev mailing list