[llvm] [PowerPC] Use the same lowering rule for vector rounding instructions (PR #166307)
via llvm-commits
llvm-commits at lists.llvm.org
Sun Nov 9 02:58:31 PST 2025
https://github.com/paperchalice updated https://github.com/llvm/llvm-project/pull/166307
>From 3e07f419b67745c05ebe937ab3a9c83599ceca46 Mon Sep 17 00:00:00 2001
From: PaperChalice <liujunchang97 at outlook.com>
Date: Tue, 4 Nov 2025 13:35:34 +0800
Subject: [PATCH] [PowerPC] Use the same lowering rule for vector rounding
instructions They should have the same lowering rule.
---
llvm/lib/Target/PowerPC/PPCISelLowering.cpp | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
index dd233e236e17f..02b4e9894d964 100644
--- a/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
+++ b/llvm/lib/Target/PowerPC/PPCISelLowering.cpp
@@ -1049,17 +1049,17 @@ PPCTargetLowering::PPCTargetLowering(const PPCTargetMachine &TM,
// so we can only code-gen them with fpexcept.ignore.
setOperationAction(ISD::STRICT_FNEARBYINT, MVT::f64, Custom);
setOperationAction(ISD::STRICT_FNEARBYINT, MVT::f32, Custom);
+ setOperationAction(ISD::STRICT_FNEARBYINT, MVT::v2f64, Custom);
+ setOperationAction(ISD::STRICT_FNEARBYINT, MVT::v4f32, Custom);
setOperationAction(ISD::FFLOOR, MVT::v2f64, Legal);
setOperationAction(ISD::FCEIL, MVT::v2f64, Legal);
setOperationAction(ISD::FTRUNC, MVT::v2f64, Legal);
- setOperationAction(ISD::FNEARBYINT, MVT::v2f64, Legal);
setOperationAction(ISD::FRINT, MVT::v2f64, Legal);
setOperationAction(ISD::FROUND, MVT::v2f64, Legal);
setOperationAction(ISD::FROUND, MVT::f64, Legal);
setOperationAction(ISD::FRINT, MVT::f64, Legal);
- setOperationAction(ISD::FNEARBYINT, MVT::v4f32, Legal);
setOperationAction(ISD::FRINT, MVT::v4f32, Legal);
setOperationAction(ISD::FROUND, MVT::v4f32, Legal);
setOperationAction(ISD::FROUND, MVT::f32, Legal);
More information about the llvm-commits
mailing list