nak: Disallow isetp.x pre-Volta
Fixes: a33507d621
("nak/sm50: Set the .x bit for isetp")
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/30402>
This commit is contained in:

committed by
Marge Bot

parent
c695fd7cd2
commit
315e8d6faa
@@ -711,6 +711,10 @@ fn test_op_isetp() {
|
|||||||
|
|
||||||
let ex = i != 0;
|
let ex = i != 0;
|
||||||
|
|
||||||
|
if ex && RunSingleton::get().sm.sm() < 70 {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
let op = OpISetP {
|
let op = OpISetP {
|
||||||
dst: Dst::None,
|
dst: Dst::None,
|
||||||
set_op,
|
set_op,
|
||||||
|
@@ -3699,32 +3699,18 @@ impl Foldable for OpISetP {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
let dst = if sm.sm() >= 70 {
|
let cmp = if self.ex && x == y {
|
||||||
let cmp = if self.ex && x == y { low_cmp } else { cmp };
|
// Pre-Volta, isetp.x takes the accumulator into account. If we
|
||||||
self.set_op.eval(cmp, accum)
|
// want to support this, we need to take an an accumulator into
|
||||||
|
// account. Disallow it for now.
|
||||||
|
assert!(sm.sm() >= 70);
|
||||||
|
low_cmp
|
||||||
} else {
|
} else {
|
||||||
if self.ex && x == y {
|
cmp
|
||||||
match self.cmp_op {
|
|
||||||
IntCmpOp::Eq | IntCmpOp::Gt | IntCmpOp::Ge => {
|
|
||||||
match &self.set_op {
|
|
||||||
PredSetOp::And => false,
|
|
||||||
PredSetOp::Or => accum,
|
|
||||||
PredSetOp::Xor => accum,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
IntCmpOp::Ne | IntCmpOp::Lt | IntCmpOp::Le => {
|
|
||||||
match &self.set_op {
|
|
||||||
PredSetOp::And => accum,
|
|
||||||
PredSetOp::Or => true,
|
|
||||||
PredSetOp::Xor => !accum,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
self.set_op.eval(cmp, accum)
|
|
||||||
}
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
let dst = self.set_op.eval(cmp, accum);
|
||||||
|
|
||||||
f.set_pred_dst(self, &self.dst, dst);
|
f.set_pred_dst(self, &self.dst, dst);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -1437,6 +1437,9 @@ impl SM50Op for OpISetP {
|
|||||||
e.set_reg_src(8..16, self.srcs[0]);
|
e.set_reg_src(8..16, self.srcs[0]);
|
||||||
e.set_pred_src(39..42, 42, self.accum);
|
e.set_pred_src(39..42, 42, self.accum);
|
||||||
|
|
||||||
|
// isetp.x seems to take the accumulator into account and we don't fully
|
||||||
|
// understand how. Until we do, disallow it.
|
||||||
|
assert!(!self.ex);
|
||||||
e.set_bit(43, self.ex);
|
e.set_bit(43, self.ex);
|
||||||
e.set_pred_set_op(45..47, self.set_op);
|
e.set_pred_set_op(45..47, self.set_op);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user