Skip to content

8353730: TestSubNodeFloatDoubleNegation.java fails with native Float16 support #24565

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 3 commits into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -53,11 +53,14 @@ public static void assertResults() {
}

@Test
// Match a generic SubNode, because scalar Float16 operations are often
// performed as float operations.
@IR(counts = { IRNode.SUB, "2" }, applyIfPlatform = {"riscv64", "false"})
@IR(counts = { IRNode.SUB, "2" }, applyIfCPUFeature = {"zfh", "false"})
@IR(counts = { IRNode.SUB_HF, "2" }, applyIfCPUFeature = {"zfh", "true"})
@IR(counts = { IRNode.SUB, "2" }, applyIfPlatform = {"x64", "true"}, applyIfCPUFeature = {"avx512_fp16", "false"})
@IR(counts = { IRNode.SUB_HF, "2" }, applyIfPlatform = {"x64", "true"}, applyIfCPUFeature = {"avx512_fp16", "true"})
// TODO: uncomment once Float16 support lands in aarch64 with JDK-8345125
//@IR(counts = { IRNode.SUB, "2" }, applyIfPlatform = {"aarch64", "true"}, applyIfCPUFeatureAnd = {"fphp", "false", "asimdhp", "false"})
//@IR(counts = { IRNode.SUB_HF, "2" }, applyIfPlatform = {"aarch64", "true"}, applyIfCPUFeatureAnd = {"fphp", "true", "asimdhp", "true"})
@IR(counts = { IRNode.SUB, "2" }, applyIfPlatform = {"riscv64", "true"}, applyIfCPUFeature = {"zfh", "false"})
@IR(counts = { IRNode.SUB_HF, "2" }, applyIfPlatform = {"riscv64", "true"}, applyIfCPUFeature = {"zfh", "true"})
@IR(counts = { IRNode.SUB, "2" }, applyIfPlatformAnd = {"x64", "false", "aarch64", "false", "riscv64", "false"})
// Checks that the subtractions in 0 - (0 - hf) do not get eliminiated
public static Float16 testHalfFloat(Float16 hf) {
return Float16.subtract(