I just heard of the instruction set extension AES-NI. Does Java's JIT compiler compile the application to use AES-NI if it is available to enhance performance?
And if yes, does it also do so if it is not sure that AES will be used (like when using TLS)?
Java 8 and 7u40 and later include support for x86 AES intrinsics for the built-in SunJCE provider, but the feature is not enabled by default (it is).
Search globals.hpp for "AES":
product(bool, UseAES, false, \
"Control whether AES instructions can be used on x86/x64") \
...
product(bool, UseAESIntrinsics, false, \
"Use intrinsics for AES versions of crypto") \
You can enable the feature by passing the -XX:+UseAES -XX:+UseAESIntrinsics options to the virtual machine.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With