Skip to content

Commit

Permalink
fix python segfault 2
Browse files Browse the repository at this point in the history
  • Loading branch information
goliaro committed Jul 18, 2023
1 parent 716a5b1 commit 1367f8a
Showing 1 changed file with 9 additions and 2 deletions.
11 changes: 9 additions & 2 deletions src/runtime/model.cc
Original file line number Diff line number Diff line change
Expand Up @@ -6002,8 +6002,15 @@ void register_flexflow_internal_tasks(Runtime *runtime,
"AllReduce Inference");
registrar.add_constraint(ProcessorConstraint(Processor::TOC_PROC));
registrar.set_leaf();
Runtime::preregister_task_variant<AllReduce::inference_task>(
registrar, "AllReduce Inference Task");
if (pre_register) {
Runtime::preregister_task_variant<AllReduce::inference_task>(
registrar, "AllReduce Inference Task");
} else {
if (enable_control_replication) {
registrar.global_registration = false;
}
runtime->register_task_variant<AllReduce::inference_task>(registrar);
}
}
{
TaskVariantRegistrar registrar(ALLREDUCE_FWD_TASK_ID, "AllReduce Forward");
Expand Down

0 comments on commit 1367f8a

Please sign in to comment.