comaniac commented on a change in pull request #8464:
URL: https://github.com/apache/tvm/pull/8464#discussion_r669156343
##########
File path: src/relay/analysis/annotated_region_set.cc
##########
@@ -76,17 +76,21 @@ void AnnotatedRegionSetNode::AddToRegion(AnnotatedRegion
dest, const Expr& expr)
}
}
-AnnotatedRegion AnnotatedRegionSetNode::MakeRegion(const std::string& target) {
+AnnotatedRegion AnnotatedRegionSetNode::MakeRegion(const std::string&
func_name,
+ const std::string& target) {
auto ret = regions_.emplace(AnnotatedRegion());
(*ret.first)->id_ = region_id_++;
(*ret.first)->target_ = target;
+ (*ret.first)->func_name_ = func_name;
return *ret.first;
}
class AnnotatedRegionSet::Creator : protected MixedModeVisitor {
public:
Creator(const Op& region_begin_op, const Op& region_end_op)
: begin_op_(region_begin_op), end_op_(region_end_op) {}
+ Creator(const Op& region_begin_op, const Op& region_end_op, const
std::string& func_name)
+ : begin_op_(region_begin_op), end_op_(region_end_op),
func_name(func_name) {}
Review comment:
Hmm I see. So in the case of merge compiler region we don't really care
its name. How about keeping one constructor and assign a default value to
func_name?
--
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]