comparison src/hotspot/cpu/s390/vm_version_s390.cpp @ 54970:b776653628c5

8218991: s390: Add intrinsic for GHASH algorithm Reviewed-by: lucy, simonis
author mdoerr
date Mon, 18 Feb 2019 12:16:02 +0100
parents 9937ef7499dc
children ddc19ea5059c
comparison
equal deleted inserted replaced
6:86eb1790389f 7:bb4f2c5e337b
1 /* 1 /*
2 * Copyright (c) 2016, 2018, Oracle and/or its affiliates. All rights reserved. 2 * Copyright (c) 2016, 2019, Oracle and/or its affiliates. All rights reserved.
3 * Copyright (c) 2016, 2018 SAP SE. All rights reserved. 3 * Copyright (c) 2016, 2019 SAP SE. All rights reserved.
4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 * 5 *
6 * This code is free software; you can redistribute it and/or modify it 6 * This code is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License version 2 only, as 7 * under the terms of the GNU General Public License version 2 only, as
8 * published by the Free Software Foundation. 8 * published by the Free Software Foundation.
163 if (UseAESCTRIntrinsics) { 163 if (UseAESCTRIntrinsics) {
164 warning("AES/CTR intrinsics are not available on this CPU"); 164 warning("AES/CTR intrinsics are not available on this CPU");
165 FLAG_SET_DEFAULT(UseAESCTRIntrinsics, false); 165 FLAG_SET_DEFAULT(UseAESCTRIntrinsics, false);
166 } 166 }
167 167
168 // TODO: implement GHASH intrinsics 168 if (FLAG_IS_DEFAULT(UseGHASHIntrinsics) && has_Crypto_GHASH()) {
169 if (UseGHASHIntrinsics) { 169 FLAG_SET_DEFAULT(UseGHASHIntrinsics, true);
170 }
171 if (UseGHASHIntrinsics && !has_Crypto_GHASH()) {
170 warning("GHASH intrinsics are not available on this CPU"); 172 warning("GHASH intrinsics are not available on this CPU");
171 FLAG_SET_DEFAULT(UseGHASHIntrinsics, false); 173 FLAG_SET_DEFAULT(UseGHASHIntrinsics, false);
172 } 174 }
173 175
174 if (FLAG_IS_DEFAULT(UseFMA)) { 176 if (FLAG_IS_DEFAULT(UseFMA)) {