From b16f605bd19101d762074e6cc1c3db6c7637675f Mon Sep 17 00:00:00 2001 From: Andrew Reusch Date: Wed, 5 Jan 2022 12:05:49 -0800 Subject: [PATCH] fixup! Stack-allocate DLTensor instances when necessary. --- src/relay/backend/aot_executor_codegen.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/relay/backend/aot_executor_codegen.cc b/src/relay/backend/aot_executor_codegen.cc index 805aad359630..93d742ee238a 100644 --- a/src/relay/backend/aot_executor_codegen.cc +++ b/src/relay/backend/aot_executor_codegen.cc @@ -445,7 +445,7 @@ class AOTExecutorCodegen : public MixedModeVisitor { func_call, GenerateDeviceHook(context, "Close"), })); - } else if (use_call_cpacked_) { + } else if (use_call_cpacked_ && !use_unpacked_api_) { // call_cpacked calling convention needs a blank context args.push_back(tir::make_zero(DataType::Handle())); tir::Evaluate func_call(tvm::tir::Call(DataType::Int(32), calling_pattern, args));