This is an automated email from the ASF dual-hosted git repository.
tqchen pushed a commit to branch manylinux-ci-836
in repository https://gitbox.apache.org/repos/asf/tvm-tirx.git
The following commit(s) were added to refs/heads/manylinux-ci-836 by this push:
new 1c3894ef7 [FIX] Scope negation pattern variables to their rewrite paths
1c3894ef7 is described below
commit 1c3894ef7306a27233b07d6a87fd683bebb62f10
Author: Tianqi Chen <[email protected]>
AuthorDate: Sun Oct 25 03:15:56 2026 +0000
[FIX] Scope negation pattern variables to their rewrite paths
---
src/sym/rewrite_simplify.cc | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/src/sym/rewrite_simplify.cc b/src/sym/rewrite_simplify.cc
index 2c39c233b..e44a2ae04 100644
--- a/src/sym/rewrite_simplify.cc
+++ b/src/sym/rewrite_simplify.cc
@@ -1969,13 +1969,13 @@ UnchangedOr<PrimExpr>
RewriteSimplifier::Impl::Mutate_(const prim::NotObj* op,
}
PrimExpr RewriteSimplifier::Impl::ApplyRewriteRules(prim::Not ret, InplaceMode
inplace_mode) {
- // Pattern var to match any expression
- PVar<PrimExpr> x{}, y{};
- PVar<PrimExpr> lanes;
if (IsVectorExpr(ret.get())) {
+ PVar<PrimExpr> x, lanes;
TVM_TRY_REWRITE(!broadcast(x, lanes), broadcast(!x, lanes));
}
+ // Pattern var to match any expression
+ PVar<PrimExpr> x, y;
TVM_TRY_REWRITE(!(!x), x);
TVM_TRY_REWRITE(!(x <= y), y < x);
TVM_TRY_REWRITE(!(x >= y), x < y);