================ @@ -1415,7 +1415,10 @@ ACLEIntrinsic::ACLEIntrinsic(EmitterBase &ME, const Record *R, } else if (Bounds->getName() == "IB_LaneIndex") { IA.boundsType = ImmediateArg::BoundsType::ExplicitRange; IA.i1 = 0; - IA.i2 = 128 / Param->sizeInBits() - 1; + unsigned sizeInBits = Param->sizeInBits(); + if (sizeInBits == 0) + PrintFatalError("Division by zero: Param->sizeInBits() is zero."); + IA.i2 = 128 / sizeInBits() - 1; ---------------- Fznamznon wrote:
This code doesn't build. To fix ```suggestion IA.i2 = 128 / sizeInBits - 1; ``` Also, I'm not sure if the check is not obsolete at all. Adding a couple of more reviewers. https://github.com/llvm/llvm-project/pull/115883 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits