nak: Use nak_builder::fsetp() in op_fquantize2f16
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30448>
This commit is contained in:
committed by
Marge Bot
parent
138910d898
commit
d7e06c6e08
@@ -1163,15 +1163,11 @@ impl<'a> ShaderFromNir<'a> {
|
||||
if b.sm() < 70 {
|
||||
// Pre-Volta, F2F.ftz doesn't flush denorms so we need to do
|
||||
// that manually
|
||||
let denorm = b.alloc_ssa(RegFile::Pred, 1);
|
||||
b.push_op(OpFSetP {
|
||||
dst: denorm.into(),
|
||||
set_op: PredSetOp::And,
|
||||
cmp_op: FloatCmpOp::OrdLt,
|
||||
srcs: [srcs[0].fabs(), 0x38800000.into()],
|
||||
accum: true.into(),
|
||||
ftz: false,
|
||||
});
|
||||
let denorm = b.fsetp(
|
||||
FloatCmpOp::OrdLt,
|
||||
srcs[0].fabs(),
|
||||
0x38800000.into(),
|
||||
);
|
||||
// Get the correctly signed zero
|
||||
let zero =
|
||||
b.lop2(LogicOp2::And, srcs[0], 0x80000000.into());
|
||||
|
||||
Reference in New Issue
Block a user