RFR 8038418 New tests development for type profiling and speculation
Pavel Punegov
pavel.punegov at oracle.com
Wed Apr 9 17:32:39 UTC 2014
New webrev:
http://cr.openjdk.java.net/~iignatyev/ppunegov/8038418/webrev.02/
Changed -XX:CompileCommand= commands to compile only test and execution
scenarios.
Changed Scenario::run() in scenarios to implement the next pattern:
if (isReturnType) {
T t = collectReturnType(obj);
// test code with t
} else {
// test code with obj
}
On Wed, 09 of Apr 2014 13:33:41 Roland Westrelin wrote:
>> But what if the collectReturnType(obj) will change the obj inside the
>> method? E.g. before it was a TypeHierarchy.B, but became a TypeHierarchy.
>> I thought
>> that it should use return type profiling for this case:
>
> The first profiling data that it finds for an object is the one that it
> keeps. Later profiling data is ignored.
Changed code that it stores returned object in the local that is used next in
the test. See above
>> but why does compiler not eliminate if() when isReturnType == true and is
>> a
>> final field?
>
> Maybe it does indeed. Have you verified whether it is eliminated?
I've checked this and it seems that compiler doesn't eliminate such ifs.
--
Thanks,
Pavel Punegov
More information about the hotspot-compiler-dev
mailing list