From 4ccc004219090e571ad7d0fcddb2c9c8099b7d8f Mon Sep 17 00:00:00 2001 From: Florin-Gabriel Blanaru Date: Mon, 18 Jul 2022 12:59:14 -0700 Subject: [PATCH] Pass GlobalVarSupply when lowering shape funcs --- src/relay/backend/te_compiler.cc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/relay/backend/te_compiler.cc b/src/relay/backend/te_compiler.cc index 64ca4411d083e..2086b90f03375 100644 --- a/src/relay/backend/te_compiler.cc +++ b/src/relay/backend/te_compiler.cc @@ -499,8 +499,7 @@ class TECompilerImpl : public TECompilerNode { using tvm::transform::PassContext; With fresh_pass_ctx_scope(PassContext::Create()); - value->cached_func = - ShapeFuncFor(key->source_func, key->target, GlobalVarSupply::EmptySupply()); + value->cached_func = ShapeFuncFor(key->source_func, key->target, global_var_supply); ICHECK( value->cached_func->funcs->Lookup(value->cached_func->prim_fn_var).as());