You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tvm.apache.org by "Lunderberg (via GitHub)" <gi...@apache.org> on 2024/04/02 19:08:28 UTC
[PR] [TIR] Use constructor for new PrimFunc in TransformLayout [tvm]
Lunderberg opened a new pull request, #16832:
URL: https://github.com/apache/tvm/pull/16832
Using the constructor applies all initialization steps and error-checking, where using `CopyOnWrite()` does not. This function is used as part of the legalization of `relax.op.layout_tranform`, which relies on the annotations produced in the `PrimFunc` constructor.
--
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: commits-unsubscribe@tvm.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [TIR] Use constructor for new PrimFunc in TransformLayout [tvm]
Posted by "Lunderberg (via GitHub)" <gi...@apache.org>.
Lunderberg commented on PR #16832:
URL: https://github.com/apache/tvm/pull/16832#issuecomment-2039664039
Rebased this PR onto main as https://github.com/apache/tvm/pull/16837 has now landed.
--
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: commits-unsubscribe@tvm.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [TIR] Use constructor for new PrimFunc in TransformLayout [tvm]
Posted by "Lunderberg (via GitHub)" <gi...@apache.org>.
Lunderberg commented on PR #16832:
URL: https://github.com/apache/tvm/pull/16832#issuecomment-2045487082
In the future, I'm wondering if the `CopyOnWrite` functionality should be extended to perform this type of initialization. Currently, regardless of what invariants are established by an object's constructor, they can be violated when overwritten with `CopyOnWrite`.
We could have `CopyOnWrite` return a proxy object, rather than `T::ContainerType*`. The proxy object would provide `operator->`, so the same `obj.CopyOnWrite()->foo = new_foo` would still function as intended. However, on destruction, the proxy object would call some `T::Validate` method. That way, we get the usability of direct access and CoW to mutating a single field, but we can still establish invariants for classes.
--
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: commits-unsubscribe@tvm.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [TIR] Use constructor for new PrimFunc in TransformLayout [tvm]
Posted by "Lunderberg (via GitHub)" <gi...@apache.org>.
Lunderberg commented on PR #16832:
URL: https://github.com/apache/tvm/pull/16832#issuecomment-2034950915
CI failure is for `tests/python/relay/test_auto_scheduler_tuning.py::test_tuning_cuda`. It looks like a flaky test, which occurs whenever the randomized tuning fails to find any valid schedules. I can reproduce the failures on main, and have submitted https://github.com/apache/tvm/pull/16837 to disable the test. After that PR lands, I'll re-run CI for this PR.
--
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: commits-unsubscribe@tvm.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [TIR] Use constructor for new PrimFunc in TransformLayout [tvm]
Posted by "quic-sanirudh (via GitHub)" <gi...@apache.org>.
quic-sanirudh merged PR #16832:
URL: https://github.com/apache/tvm/pull/16832
--
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: commits-unsubscribe@tvm.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] [TIR] Use constructor for new PrimFunc in TransformLayout [tvm]
Posted by "quic-sanirudh (via GitHub)" <gi...@apache.org>.
quic-sanirudh commented on PR #16832:
URL: https://github.com/apache/tvm/pull/16832#issuecomment-2039245214
@tvm-bot rerun
--
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: commits-unsubscribe@tvm.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org