[lworld] RFR: 8244796: [lworld] Javac does not compile test/hotspot/jtreg/runtime/valhalla/valuetypes/UnsafeTest.java anymore

Srikanth srikanth.adayapalam at oracle.com
Thu May 14 08:52:56 UTC 2020



On 14/05/20 2:09 pm, Remi Forax wrote:
> ----- Mail original -----
>> De: "Srikanth Adayapalam" <sadayapalam at openjdk.java.net>
>> À: "valhalla-dev" <valhalla-dev at openjdk.java.net>
>> Envoyé: Jeudi 14 Mai 2020 03:40:04
>> Objet: [lworld] RFR: 8244796: [lworld] Javac does not compile
>> test/hotspot/jtreg/runtime/valhalla/valuetypes/UnsafeTest.java anymore
>> Summary: Implement temporary typing rules for value class literals, these being:
>>
>>     o Given a value class V that implements an interface I
>>         - Class<V>, Class<? extends V>, Class<? super V> are all malformed for the time
>>         being.
>>         - V.class and v.getClass() are to be typed temporarily as Class<? extends Object
>>         & I>
>>
> Hi Srikanth,
> why V.class is not typed as Class<? extends V.ref> ?

I would say the operative word is "temporary" - this fix is basically so 
we can make things malleable enough to compile code that we used to 
compile with the type system as it existed in LW2 - to buy us time so to 
speak - to evolve all the rules around bounds checking in the LW3 world 
where an inline type V is not a subtype of jlO.

As for that specific typing, in the language model V is not a subtype of 
V.ref and we haven't figured out all the nuances of how inline 
widening/narrowing conversions interact with bounds checking.

Srikanth
>
> Rémi
>
>> -------------
>>
>> Commit messages:
>> - Additional fixes for typing of value class literals.
>> - Merge branch 'JDK-8244796' of https://github.com/sadayapalam/valhalla into
>> JDK-8244796
>> - 8244796: Javac does not compile
>> test/hotspot/jtreg/runtime/valhalla/valuetypes/UnsafeTest.java anymore
>> - 8244796: Javac does not compile
>> test/hotspot/jtreg/runtime/valhalla/valuetypes/UnsafeTest.java anymore
>>
>> Changes: https://git.openjdk.java.net/valhalla/pull/46/files
>> Webrev: https://webrevs.openjdk.java.net/valhalla/46/webrev.00
>>   Issue: https://bugs.openjdk.java.net/browse/JDK-8244796
>>   Stats: 91 lines in 6 files changed: 85 ins; 2 del; 4 mod
>>   Patch: https://git.openjdk.java.net/valhalla/pull/46.diff
>>   Fetch: git fetch https://git.openjdk.java.net/valhalla pull/46/head:pull/46
>>
>> PR: https://git.openjdk.java.net/valhalla/pull/46



More information about the valhalla-dev mailing list