jcf94 commented on a change in pull request #6073:
URL: https://github.com/apache/incubator-tvm/pull/6073#discussion_r457831406
##########
File path: src/auto_scheduler/compute_dag.cc
##########
@@ -270,19 +270,9 @@ std::pair<te::Schedule, Array<te::Tensor>>
ComputeDAG::ApplySteps(
}
// Apply the history steps to TVM schedule
+ // Call each step's ApplyToSchedule method
for (const auto& step : transform_steps) {
- // Call each step's ApplyToSchedule method
- // Note: some steps have extra parameters that must be passed and they may
need different
- // return value, so the ApplyToSchedule is not able to be merged to single
interface
- if (auto ps = step.as<ReorderStepNode>()) {
- ps->ApplyToSchedule(stages, stage_to_axes);
- } else if (auto ps = step.as<SplitStepNode>()) {
- ps->ApplyToSchedule(stages, stage_to_axes);
- } else if (auto ps = step.as<FuseStepNode>()) {
- ps->ApplyToSchedule(stages, stage_to_axes);
- } else {
- LOG(FATAL) << "Invalid Step";
- }
+ StepApplyToSchedule(step, stages, stage_to_axes);
Review comment:
This corresponds to each step's ApplyToSchedule, so I just name it like
this ...
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]