MasterJH5574 opened a new pull request, #20096:
URL: https://github.com/apache/tvm/pull/20096
The Windows wheel build for `v0.26.0.rc0` fails to compile:
```
src\tirx\ir\data_type_rewriter.cc(696,47): error C2352:
'tvm::tirx::ExprMutator::VisitPrimExpr': a call of a non-static member
function requires an object
```
`StmtExprMutator` derives from both `ExprMutator` and `StmtMutator`, and
re-exports the name via `using ExprMutator::VisitPrimExpr;`. MSVC resolves the
class-qualified `IndexDataTypeNormalizer::VisitPrimExpr` down to
`ExprMutator::VisitPrimExpr` and then fails to form the implicit object
conversion. GCC and Clang accept the same expression, so only the Windows leg
broke — the macOS and both Linux wheels built fine.
The fix calls it through `this` instead, matching every other
`VisitPrimExpr` call site in this file. `VisitPrimExpr` is a non-virtual inline
helper, so the qualification was suppressing nothing and behavior is unchanged.
The other class-qualified call sites in the tree name `StmtExprMutator`
directly — that is where the using-declaration lives, so they resolve fine and
are left alone.
The call was introduced in #19931, which changed
`IndexDataTypeNormalizer::VisitExpr` to
`IndexDataTypeNormalizer::VisitPrimExpr`; the former resolved unambiguously.
Targeting the release branch first to unblock the `v0.26.0.rc0` Windows
wheel; it will be ported to `main` separately.
Failing job:
https://github.com/apache/tvm/actions/runs/31033249253/job/92400739674
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]