8212043: Add floating-point Math.min/max intrinsics

Floating-point Math.min() and Math.max() intrinsics are enabled on AArch64 platform

Reviewed-by: adinn, aph
This commit is contained in:
Pengfei Li 2018-12-18 16:50:35 +00:00
parent 8b6b63b38b
commit 556d79b518
14 changed files with 214 additions and 1 deletions

View file

@ -1154,6 +1154,7 @@ public final class StrictMath {
* @param b another argument.
* @return the larger of {@code a} and {@code b}.
*/
@HotSpotIntrinsicCandidate
public static float max(float a, float b) {
return Math.max(a, b);
}
@ -1172,6 +1173,7 @@ public final class StrictMath {
* @param b another argument.
* @return the larger of {@code a} and {@code b}.
*/
@HotSpotIntrinsicCandidate
public static double max(double a, double b) {
return Math.max(a, b);
}
@ -1219,6 +1221,7 @@ public final class StrictMath {
* @param b another argument.
* @return the smaller of {@code a} and {@code b.}
*/
@HotSpotIntrinsicCandidate
public static float min(float a, float b) {
return Math.min(a, b);
}
@ -1237,6 +1240,7 @@ public final class StrictMath {
* @param b another argument.
* @return the smaller of {@code a} and {@code b}.
*/
@HotSpotIntrinsicCandidate
public static double min(double a, double b) {
return Math.min(a, b);
}