Skip to content
4 changes: 2 additions & 2 deletions third_party/intel/triton_xpu.cc
Original file line number Diff line number Diff line change
Expand Up @@ -300,8 +300,8 @@ void init_triton_intel(py::module &&m) {
for (Instruction &inst : instructions(func)) {
if (auto *op = dyn_cast<FPMathOperator>(&inst)) {
FastMathFlags FMF;
// Allow contract when default fp fusion is enabled.
if ((enableFpFusion.has_value() && enableFpFusion.value()) &&
// Default to allow contract when default fp fusion is not disabled.
if ((!enableFpFusion.has_value() || enableFpFusion.value()) &&
!fastMath.has_value()) {
if (op->getOpcode() == Instruction::FAdd ||
op->getOpcode() == Instruction::FMul)
Expand Down