8191339: [JVMCI] BigInteger compiler intrinsics on Graal
authorphedlin
Wed, 06 Dec 2017 13:07:21 +0100
changeset 52609 83b1d9797b20
parent 52608 61241fc2217a
child 52610 7ac273f045e3
8191339: [JVMCI] BigInteger compiler intrinsics on Graal Reviewed-by: kvn
src/hotspot/cpu/x86/vm_version_x86.cpp
src/hotspot/share/jvmci/jvmci_globals.hpp
--- a/src/hotspot/cpu/x86/vm_version_x86.cpp	Thu Nov 08 10:20:04 2018 +0100
+++ b/src/hotspot/cpu/x86/vm_version_x86.cpp	Wed Dec 06 13:07:21 2017 +0100
@@ -1042,9 +1042,7 @@
     }
   }
 #endif // COMPILER2 && ASSERT
-#endif // COMPILER2_OR_JVMCI
 
-#ifdef COMPILER2
 #ifdef _LP64
   if (FLAG_IS_DEFAULT(UseMultiplyToLenIntrinsic)) {
     UseMultiplyToLenIntrinsic = true;
@@ -1092,8 +1090,8 @@
     }
     FLAG_SET_DEFAULT(UseMulAddIntrinsic, false);
   }
-#endif
-#endif // COMPILER2
+#endif // _LP64
+#endif // COMPILER2_OR_JVMCI
 
   // On new cpus instructions which update whole XMM register should be used
   // to prevent partial register stall due to dependencies on high half.
--- a/src/hotspot/share/jvmci/jvmci_globals.hpp	Thu Nov 08 10:20:04 2018 +0100
+++ b/src/hotspot/share/jvmci/jvmci_globals.hpp	Wed Dec 06 13:07:21 2017 +0100
@@ -98,7 +98,22 @@
           "Number of methods to record in call profile")                    \
                                                                             \
   develop(bool, TraceUncollectedSpeculations, false,                        \
-          "Print message when a failed speculation was not collected")
+          "Print message when a failed speculation was not collected")      \
+                                                                            \
+  NOT_COMPILER2(diagnostic(bool, UseMultiplyToLenIntrinsic, false,          \
+          "Enables intrinsification of BigInteger.multiplyToLen()"))        \
+                                                                            \
+  NOT_COMPILER2(diagnostic(bool, UseSquareToLenIntrinsic, false,            \
+          "Enables intrinsification of BigInteger.squareToLen()"))          \
+                                                                            \
+  NOT_COMPILER2(diagnostic(bool, UseMulAddIntrinsic, false,                 \
+          "Enables intrinsification of BigInteger.mulAdd()"))               \
+                                                                            \
+  NOT_COMPILER2(diagnostic(bool, UseMontgomeryMultiplyIntrinsic, false,     \
+          "Enables intrinsification of BigInteger.montgomeryMultiply()"))   \
+                                                                            \
+  NOT_COMPILER2(diagnostic(bool, UseMontgomerySquareIntrinsic, false,       \
+          "Enables intrinsification of BigInteger.montgomerySquare()"))
 
 
 // Read default values for JVMCI globals