-
Notifications
You must be signed in to change notification settings - Fork 3.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[PASS] Refactor a couple of TIR passes - BindTarget, AnnotateEntryFunc, Filter, LowerInitBlock #11628
Conversation
include/tvm/tir/transform.h
Outdated
@@ -24,6 +24,7 @@ | |||
#ifndef TVM_TIR_TRANSFORM_H_ | |||
#define TVM_TIR_TRANSFORM_H_ | |||
|
|||
#include <tvm/driver/driver_api.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is it possible that we don't depend on driver_api.h
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for pointing out! Changed to #include <tvm/target/target.h>
which is more accurate.
src/tir/transforms/helpers.cc
Outdated
*/ | ||
|
||
/*! | ||
* \file helpers.cc |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we might want to find better names other than helpers.cc
. For example, driver_api_pass.cc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed. How about the primfunc_utils.cc
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
that sounds a reasonable choice!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall the PR looks in a good state! Please address my nitpicks and let's get it merged sooooon!
…c, Filter, LowerInitBlock (apache#11628) This PR fixes a few inconsistent pass registration and add testcases for them. - `LowerInitBlock` had mismatch between its pass name and ffi key. - `BindTarget`, `AnnotateEntryFunc`, `Filter` were not following the name convention of tir passes and they were not registered in FFI registry.
This PR fixes a few inconsistent pass registration and add testcases for them.
LowerInitBlock
had mismatch between its pass name and ffi key.BindTarget
,AnnotateEntryFunc
,Filter
were not following the name convention of tir passes and they were not registered in FFI registry.cc. @junrushao1994