RFR: 8209459: TestSHA512MultiBlockIntrinsics failed on AArch64

Joshua Zhu Joshua.Zhu at arm.com
Tue Aug 14 07:35:21 UTC 2018


Hi,

Please help review the following change.
Bug: https://bugs.openjdk.java.net/browse/JDK-8209459
Webrev: http://cr.openjdk.java.net/~zyao/8209459/webrev.00
It has passed "compiler/intrinsics/sha" jtreg testing for Graal and C2.

The jtreg TestSHA512MultiBlockIntrinsics failed on aarch64 since commit http://hg.openjdk.java.net/jdk/jdk/rev/2a12ff1fff68
The failed case expected "<intrinsic id='_digestBase_implCompressMB'" not to appear in compilation logs with "+XX:+LogCompilation"
because "-XX:+UseSHA512Intrinsics" is not supported on aarch64.
http://hg.openjdk.java.net/jdk/jdk/file/e810abb27deb/src/hotspot/cpu/aarch64/vm_version_aarch64.cpp#l354

But _digestBase_implCompressMB intrinsic has three stub routines.
http://hg.openjdk.java.net/jdk/jdk/file/e810abb27deb/src/hotspot/share/opto/library_call.cpp#l6190
Generation of any one among three stub routines will cause "<intrinsic id='_digestBase_implCompressMB'" printed in log.
http://hg.openjdk.java.net/jdk/jdk/file/e810abb27deb/src/hotspot/share/opto/library_call.cpp#l406

Which ones are generated for intrinsic _digestBase_implCompressMB is related with:
    jvm option (e.g. UseSHA512Intrinsics)
    cpu feature
    loaded class (e.g. if SHA5.class is not loaded, no need to generate the corresponding stub routine: sha512_implCompressMB)
    http://hg.openjdk.java.net/jdk/jdk/file/e810abb27deb/src/hotspot/share/opto/library_call.cpp#l6326
    speculative type (if object has speculative type, only stub routine for the speculative type will be generated as fast path)
    http://hg.openjdk.java.net/jdk/jdk/file/e810abb27deb/src/hotspot/share/opto/library_call.cpp#l6334

The pseudo code is:
if (digestBaseObj instanceof SHA/SHA2/SHA5)
    do_intrinsic
else
    do_javapath

The commit http://hg.openjdk.java.net/jdk/jdk/rev/2a12ff1fff68 caused load of all three SHA, SHA2 and SHA5 classes.

Best Regards,
Joshua


More information about the hotspot-compiler-dev mailing list