From c3573c5219cb907c3e84a215177a2a69a09c3d21 Mon Sep 17 00:00:00 2001 From: Lei Wen Date: Tue, 12 Sep 2023 14:03:23 +0800 Subject: [PATCH] Fix tvm_module_wrapper build error [100%] Building CXX object CMakeFiles/pt_tvmdsoop_new.dir/src/contrib/torch/tvm_module_wrapper/RuntimeModuleWrapperTVM.cc.o mlc-llm/3rdparty/tvm/src/contrib/torch/tvm_module_wrapper/RuntimeModuleWrapperTVM.cc:32:10: fatal error: ../../support/base64.h: No such file or directory 32 | #include "../../support/base64.h" | ^~~~~~~~~~~~~~~~~~~~~~~~ Signed-off-by: Lei Wen --- .../tvm_module_wrapper/RuntimeModuleWrapperTVM.cc | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/contrib/torch/tvm_module_wrapper/RuntimeModuleWrapperTVM.cc b/src/contrib/torch/tvm_module_wrapper/RuntimeModuleWrapperTVM.cc index c77996cf67..3e1c7e7c0e 100644 --- a/src/contrib/torch/tvm_module_wrapper/RuntimeModuleWrapperTVM.cc +++ b/src/contrib/torch/tvm_module_wrapper/RuntimeModuleWrapperTVM.cc @@ -29,7 +29,7 @@ #include #include "../../../runtime/graph_executor/graph_executor_factory.h" -#include "../../support/base64.h" +#include "../../../support/base64.h" #include "runtime_bridge.h" namespace tvm { @@ -209,10 +209,10 @@ inline void b64decode(const std::string b64str, uint8_t* ret) { size_t index = 0; const auto length = b64str.size(); for (size_t i = 0; i < length; i += 4) { - int8_t ch0 = base64::DecodeTable[(int32_t)b64str[i]]; - int8_t ch1 = base64::DecodeTable[(int32_t)b64str[i + 1]]; - int8_t ch2 = base64::DecodeTable[(int32_t)b64str[i + 2]]; - int8_t ch3 = base64::DecodeTable[(int32_t)b64str[i + 3]]; + int8_t ch0 = tvm::support::base64::DecodeTable[(int32_t)b64str[i]]; + int8_t ch1 = tvm::support::base64::DecodeTable[(int32_t)b64str[i + 1]]; + int8_t ch2 = tvm::support::base64::DecodeTable[(int32_t)b64str[i + 2]]; + int8_t ch3 = tvm::support::base64::DecodeTable[(int32_t)b64str[i + 3]]; uint8_t st1 = (ch0 << 2) + (ch1 >> 4); ret[index++] = st1; if (b64str[i + 2] != '=') {