mirror of
https://github.com/RPCS3/llvm-mirror.git
synced 2024-11-25 20:23:11 +01:00
[SelectionDAG] Add MVT::bf16 to getConstantFP()
Summary: This was probably overlooked in recent bfloat patches. Needed to handle bf16 constants in SelectionDAG. ConstantFP:bf16<APFloat(0)> Reviewers: stuij Reviewed By: stuij Subscribers: hiraditya, llvm-commits Tags: #llvm Differential Revision: https://reviews.llvm.org/D81779
This commit is contained in:
parent
3ac41a5d21
commit
f22e6d55bc
@ -1394,7 +1394,7 @@ SDValue SelectionDAG::getConstantFP(double Val, const SDLoc &DL, EVT VT,
|
||||
else if (EltVT == MVT::f64)
|
||||
return getConstantFP(APFloat(Val), DL, VT, isTarget);
|
||||
else if (EltVT == MVT::f80 || EltVT == MVT::f128 || EltVT == MVT::ppcf128 ||
|
||||
EltVT == MVT::f16) {
|
||||
EltVT == MVT::f16 || EltVT == MVT::bf16) {
|
||||
bool Ignored;
|
||||
APFloat APF = APFloat(Val);
|
||||
APF.convert(EVTToAPFloatSemantics(EltVT), APFloat::rmNearestTiesToEven,
|
||||
|
Loading…
Reference in New Issue
Block a user