================ @@ -3287,6 +3287,76 @@ struct MemorySanitizerVisitor : public InstVisitor<MemorySanitizerVisitor> { setOriginForNaryOp(I); } + // Convert `Mask` into `<n x i1>`. + Constant *createDppMask(unsigned Width, unsigned Mask) { + SmallVector<Constant *, 4> R; + R.assign(Width, ConstantInt::getFalse(F.getContext())); + for (auto &M : R) { + if (Mask & 1) + M = ConstantInt::getTrue(F.getContext()); + Mask >>= 1; + } + return ConstantVector::get(R); + } + + // Calculate output shadow as array of booleans `<n x i1>`, assuming if any ---------------- fmayer wrote:
"assuming" is a bit weird. Isn't that how the poison should propagate, not an assumption? https://github.com/llvm/llvm-project/pull/94875 _______________________________________________ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits