hotspot/src/cpu/s390/vm/vm_version_s390.cpp
changeset 46315 a796c32af782
parent 42897 57e7b1c75d17
child 46560 388aa8d67c80
--- a/hotspot/src/cpu/s390/vm/vm_version_s390.cpp	Tue Mar 07 22:58:16 2017 +0000
+++ b/hotspot/src/cpu/s390/vm/vm_version_s390.cpp	Wed Mar 08 14:55:32 2017 +0100
@@ -111,13 +111,23 @@
     ContendedPaddingWidth = cache_line_size;
   }
 
-  // On z/Architecture, the CRC32 intrinsics had to be implemented "by hand".
-  // They cannot be based on the CHECKSUM instruction which has been there
-  // since the very beginning (of z/Architecture). It computes "some kind of" a checksum
-  // which has nothing to do with the CRC32 algorithm.
+  // On z/Architecture, the CRC32/CRC32C intrinsics are implemented "by hand".
+  // TODO: Provide implementation based on the vector instructions available from z13.
+  // Note: The CHECKSUM instruction, which has been there since the very beginning
+  //       (of z/Architecture), computes "some kind of" a checksum.
+  //       It has nothing to do with the CRC32 algorithm.
   if (FLAG_IS_DEFAULT(UseCRC32Intrinsics)) {
     FLAG_SET_DEFAULT(UseCRC32Intrinsics, true);
   }
+  if (FLAG_IS_DEFAULT(UseCRC32CIntrinsics)) {
+    FLAG_SET_DEFAULT(UseCRC32CIntrinsics, true);
+  }
+
+  // TODO: Provide implementation.
+  if (UseAdler32Intrinsics) {
+    warning("Adler32Intrinsics not available on this CPU.");
+    FLAG_SET_DEFAULT(UseAdler32Intrinsics, false);
+  }
 
   // On z/Architecture, we take UseAES as the general switch to enable/disable the AES intrinsics.
   // The specific, and yet to be defined, switches UseAESxxxIntrinsics will then be set
@@ -195,11 +205,6 @@
     FLAG_SET_DEFAULT(UseSHA512Intrinsics, false);
   }
 
-  if (UseAdler32Intrinsics) {
-    warning("Adler32Intrinsics not available on this CPU.");
-    FLAG_SET_DEFAULT(UseAdler32Intrinsics, false);
-  }
-
   if (FLAG_IS_DEFAULT(UseMultiplyToLenIntrinsic)) {
     FLAG_SET_DEFAULT(UseMultiplyToLenIntrinsic, true);
   }