RFR(M): 8156915: introduce MethodHandle factory for array length

Uwe Schindler uschindler at apache.org
Wed May 18 10:39:37 UTC 2016


Hi,

looks good to me!

I am also fine with the method name arrayLength() - my original proposal was arrayLengthGetter(); to be consistent with the element accessors: arrayElementGetter, arrayElementSetter.

Uwe

P.S.: I am not so familiar with the intrinsic stuff, so here is my question: The intrinsic for the array accesses is always created before caching the MH; so why do we need the static implementation methods at all? I had the same question also about the old element getters and setters. Or is the intrinsic only used after the MH is called multiple times as "optimization"? If the latter is the case, the test should ensure that the intrinsics are tested, too.

-----
Uwe Schindler
uschindler at apache.org 
ASF Member, Apache Lucene PMC / Committer
Bremen, Germany
http://lucene.apache.org/

> -----Original Message-----
> From: core-libs-dev [mailto:core-libs-dev-bounces at openjdk.java.net] On
> Behalf Of Michael Haupt
> Sent: Wednesday, May 18, 2016 9:53 AM
> To: Core-Libs-Dev <core-libs-dev at openjdk.java.net>
> Subject: RFR(M): 8156915: introduce MethodHandle factory for array length
> 
> Dear all,
> 
> please review this change.
> RFE: https://bugs.openjdk.java.net/browse/JDK-8156915
> Webrev: http://cr.openjdk.java.net/~mhaupt/8156915/webrev.00/
> 
> Thanks,
> 
> Michael
> 
> --
> 
>  <http://www.oracle.com/>
> Dr. Michael Haupt | Principal Member of Technical Staff
> Phone: +49 331 200 7277 | Fax: +49 331 200 7561
> Oracle Java Platform Group | LangTools Team | Nashorn
> Oracle Deutschland B.V. & Co. KG | Schiffbauergasse 14 | 14467 Potsdam,
> Germany
> 
> ORACLE Deutschland B.V. & Co. KG | Hauptverwaltung: Riesstraße 25, D-
> 80992 München
> Registergericht: Amtsgericht München, HRA 95603
> 
> Komplementärin: ORACLE Deutschland Verwaltung B.V. | Hertogswetering
> 163/167, 3543 AS Utrecht, Niederlande
> Handelsregister der Handelskammer Midden-Nederland, Nr. 30143697
> Geschäftsführer: Alexander van der Ven, Jan Schultheiss, Val Maher
>  <http://www.oracle.com/commitment>	Oracle is committed to
> developing practices and products that help protect the environment




More information about the core-libs-dev mailing list