From 6b3dd520d6cc8d37355fc99d3a4d1793a9c36af7 Mon Sep 17 00:00:00 2001 From: ANSHUMAN TRIPATHY Date: Wed, 3 Jun 2020 12:24:07 +0530 Subject: [PATCH] Template ambiguity resolved --- src/relay/backend/compile_engine.cc | 4 ++-- src/relay/transforms/fold_constant.cc | 2 +- src/relay/transforms/partial_eval.cc | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/relay/backend/compile_engine.cc b/src/relay/backend/compile_engine.cc index 55c83f8133a9e..3da49390d4d27 100644 --- a/src/relay/backend/compile_engine.cc +++ b/src/relay/backend/compile_engine.cc @@ -689,7 +689,7 @@ class CompileEngineImpl : public CompileEngineNode { cache_node->funcs = (*f)(cfunc->schedule, all_args, cache_node->func_name, key->source_func); } else { using tvm::transform::PassContext; - With fresh_pass_ctx_scope(PassContext()); + With fresh_pass_ctx_scope(static_cast(PassContext())); std::unordered_map binds; cache_node->funcs = tvm::lower(cfunc->schedule, all_args, cache_node->func_name, binds); @@ -726,7 +726,7 @@ class CompileEngineImpl : public CompileEngineNode { } using tvm::transform::PassContext; - With fresh_pass_ctx_scope(PassContext()); + With fresh_pass_ctx_scope(static_cast(PassContext())); std::unordered_map binds; cache_node->funcs = tvm::lower(spair.first, all_args, cache_node->func_name, binds); diff --git a/src/relay/transforms/fold_constant.cc b/src/relay/transforms/fold_constant.cc index e6b5a08432994..0300482fa3431 100644 --- a/src/relay/transforms/fold_constant.cc +++ b/src/relay/transforms/fold_constant.cc @@ -275,7 +275,7 @@ Expr FoldConstant(const Expr& expr, const IRModule& mod) { Target target = Target::Create("llvm"); // use a fresh build context // in case we are already in a build context. - With fresh_build_ctx(PassContext()); + With fresh_build_ctx(static_cast(PassContext())); return ConstantFolder(CreateInterpreter(mod, ctx, target), mod).Mutate(expr); } diff --git a/src/relay/transforms/partial_eval.cc b/src/relay/transforms/partial_eval.cc index 8a25ac0493ff5..acd161a917bdd 100644 --- a/src/relay/transforms/partial_eval.cc +++ b/src/relay/transforms/partial_eval.cc @@ -538,7 +538,7 @@ FInterpreter CPUInterpreter() { Target target = Target::Create("llvm"); // use a fresh build context // in case we are already in a build context. - With fresh_build_ctx(PassContext()); + With fresh_build_ctx(static_cast(PassContext())); return CreateInterpreter(IRModule(nullptr), CPUContext(), target); }