Skip to content

Commit

Permalink
Rename GraphRuntime to GraphExecutor (apache#7653)
Browse files Browse the repository at this point in the history
  • Loading branch information
areusch authored Mar 30, 2021
1 parent 53d44ef commit 9b43a64
Show file tree
Hide file tree
Showing 208 changed files with 1,727 additions and 1,641 deletions.
44 changes: 29 additions & 15 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ tvm_option(USE_RPC "Build with RPC" ON)
tvm_option(USE_THREADS "Build with thread support" ON)
tvm_option(USE_LLVM "Build with LLVM, can be set to specific llvm-config path" OFF)
tvm_option(USE_STACKVM_RUNTIME "Include stackvm into the runtime" OFF)
tvm_option(USE_GRAPH_RUNTIME "Build with tiny graph runtime" ON)
tvm_option(USE_GRAPH_RUNTIME_CUDA_GRAPH "Build with tiny graph runtime with CUDA Graph for GPUs" OFF)
tvm_option(USE_PROFILER "Build profiler for the VM and graph runtime" ON)
tvm_option(USE_GRAPH_EXECUTOR "Build with tiny graph executor" ON)
tvm_option(USE_GRAPH_EXECUTOR_CUDA_GRAPH "Build with tiny graph executor with CUDA Graph for GPUs" OFF)
tvm_option(USE_PROFILER "Build profiler for the VM and graph executor" ON)
tvm_option(USE_OPENMP "Build with OpenMP thread pool implementation" OFF)
tvm_option(USE_RELAY_DEBUG "Building Relay in debug mode..." OFF)
tvm_option(USE_RTTI "Build with RTTI" ON)
Expand Down Expand Up @@ -79,7 +79,7 @@ tvm_option(USE_COREML "Build with coreml support" OFF)
tvm_option(USE_BNNS "Build with BNNS support" OFF)
tvm_option(USE_TARGET_ONNX "Build with ONNX Codegen support" OFF)
tvm_option(USE_ARM_COMPUTE_LIB "Build with Arm Compute Library" OFF)
tvm_option(USE_ARM_COMPUTE_LIB_GRAPH_RUNTIME "Build with Arm Compute Library graph runtime" OFF)
tvm_option(USE_ARM_COMPUTE_LIB_GRAPH_EXECUTOR "Build with Arm Compute Library graph executor" OFF)
tvm_option(USE_TENSORRT_CODEGEN "Build with TensorRT Codegen support" OFF)
tvm_option(USE_TENSORRT_RUNTIME "Build with TensorRT runtime" OFF)
tvm_option(USE_RUST_EXT "Build with Rust based compiler extensions, STATIC, DYNAMIC, or OFF" OFF)
Expand Down Expand Up @@ -307,16 +307,30 @@ else()
list(APPEND COMPILER_SRCS ${STACKVM_RUNTIME_SRCS})
endif(USE_STACKVM_RUNTIME)

if(USE_GRAPH_RUNTIME)
message(STATUS "Build with Graph runtime support...")
file(GLOB RUNTIME_GRAPH_SRCS src/runtime/graph/*.cc)
list(APPEND RUNTIME_SRCS ${RUNTIME_GRAPH_SRCS})
# NOTE(areusch): USE_GRAPH_RUNTIME will be deleted in a future release
if(USE_GRAPH_RUNTIME AND NOT DEFINED USE_GRAPH_EXECUTOR)
message(WARNING "USE_GRAPH_RUNTIME renamed to USE_GRAPH_EXECUTOR. Please update your config.cmake")
set(USE_GRAPH_EXECUTOR ${USE_GRAPH_RUNTIME})
unset(USE_GRAPH_RUNTIME CACHE)
endif(USE_GRAPH_RUNTIME AND NOT DEFINED USE_GRAPH_EXECUTOR)

# NOTE(areusch): USE_GRAPH_RUNTIME_DEBUG will be deleted in a future release
if(USE_GRAPH_RUNTIME_DEBUG AND NOT DEFINED USE_GRAPH_EXECUTOR_DEBUG)
message(WARNING "USE_GRAPH_RUNTIME_DEBUG renamed to USE_GRAPH_EXECUTOR_DEBUG. Please update your config.cmake")
set(USE_GRAPH_EXECUTOR_DEBUG ${USE_GRAPH_RUNTIME_DEBUG})
unset(USE_GRAPH_RUNTIME_DEBUG CACHE)
endif(USE_GRAPH_RUNTIME_DEBUG AND NOT DEFINED USE_GRAPH_EXECUTOR_DEBUG)

if(USE_GRAPH_EXECUTOR)
message(STATUS "Build with Graph Executor support...")
file(GLOB RUNTIME_GRAPH_EXECUTOR_SRCS src/runtime/graph_executor/*.cc)
list(APPEND RUNTIME_SRCS ${RUNTIME_GRAPH_EXECUTOR_SRCS})

endif(USE_GRAPH_RUNTIME)
endif(USE_GRAPH_EXECUTOR)

# convert old options for profiler
if(USE_GRAPH_RUNTIME_DEBUG)
unset(USE_GRAPH_RUNTIME_DEBUG CACHE)
if(USE_GRAPH_EXECUTOR_DEBUG)
unset(USE_GRAPH_EXECUTOR_DEBUG CACHE)
set(USE_PROFILER ON)
endif()
if(USE_VM_PROFILER)
Expand All @@ -327,10 +341,10 @@ endif()
if(USE_PROFILER)
message(STATUS "Build with profiler...")

file(GLOB RUNTIME_GRAPH_DEBUG_SRCS src/runtime/graph/debug/*.cc)
list(APPEND RUNTIME_SRCS ${RUNTIME_GRAPH_DEBUG_SRCS})
set_source_files_properties(${RUNTIME_GRAPH_SRCS}
PROPERTIES COMPILE_DEFINITIONS "TVM_GRAPH_RUNTIME_DEBUG")
file(GLOB RUNTIME_GRAPH_EXECUTOR_DEBUG_SRCS src/runtime/graph_executor/debug/*.cc)
list(APPEND RUNTIME_SRCS ${RUNTIME_GRAPH_EXECUTOR_DEBUG_SRCS})
set_source_files_properties(${RUNTIME_GRAPH_EXECUTOR_SRCS}
PROPERTIES COMPILE_DEFINITIONS "TVM_GRAPH_EXECUTOR_DEBUG")

file(GLOB RUNTIME_VM_PROFILER_SRCS src/runtime/vm/profiler/*.cc)
list(APPEND RUNTIME_SRCS ${RUNTIME_VM_PROFILER_SRCS})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public class Camera2BasicFragment extends Fragment {
private AppCompatTextView mInfoView;
private ListView mModelView;
private AssetManager assetManager;
private Module graphRuntimeModule;
private Module graphExecutorModule;
private JSONObject labels;
private ListenableFuture<ProcessCameraProvider> cameraProviderFuture;
private PreviewView previewView;
Expand Down Expand Up @@ -187,21 +187,21 @@ private String[] getModels() {
private String[] inference(float[] chw) {
NDArray inputNdArray = NDArray.empty(new long[]{1, IMG_CHANNEL, MODEL_INPUT_SIZE, MODEL_INPUT_SIZE}, new TVMType("float32"));
inputNdArray.copyFrom(chw);
Function setInputFunc = graphRuntimeModule.getFunction("set_input");
Function setInputFunc = graphExecutorModule.getFunction("set_input");
setInputFunc.pushArg(INPUT_NAME).pushArg(inputNdArray).invoke();
// release tvm local variables
inputNdArray.release();
setInputFunc.release();

// get the function from the module(run it)
Function runFunc = graphRuntimeModule.getFunction("run");
Function runFunc = graphExecutorModule.getFunction("run");
runFunc.invoke();
// release tvm local variables
runFunc.release();

// get the function from the module(get output data)
NDArray outputNdArray = NDArray.empty(new long[]{1, 1000}, new TVMType("float32"));
Function getOutputFunc = graphRuntimeModule.getFunction("get_output");
Function getOutputFunc = graphExecutorModule.getFunction("get_output");
getOutputFunc.pushArg(OUTPUT_INDEX).pushArg(outputNdArray).invoke();
float[] output = outputNdArray.asFloatArray();
// release tvm local variables
Expand Down Expand Up @@ -272,8 +272,8 @@ public void onActivityCreated(Bundle savedInstanceState) {
@Override
public void onDestroy() {
// release tvm local variables
if (null != graphRuntimeModule)
graphRuntimeModule.release();
if (null != graphExecutorModule)
graphExecutorModule.release();
super.onDestroy();
}

Expand Down Expand Up @@ -516,7 +516,7 @@ private void setInputName(String modelName) {
}

/*
Load precompiled model on TVM graph runtime and init the system.
Load precompiled model on TVM graph executor and init the system.
*/
private class LoadModelAsyncTask extends AsyncTask<Void, Void, Integer> {

Expand Down Expand Up @@ -581,11 +581,11 @@ protected Integer doInBackground(Void... args) {
Module modelLib = Module.load(libCacheFilePath);


// get global function module for graph runtime
Log.i(TAG, "getting graph runtime create handle...");
// get global function module for graph executor
Log.i(TAG, "getting graph executor create handle...");

Function runtimeCreFun = Function.getFunction("tvm.graph_runtime.create");
Log.i(TAG, "creating graph runtime...");
Function runtimeCreFun = Function.getFunction("tvm.graph_executor.create");
Log.i(TAG, "creating graph executor...");

Log.i(TAG, "device type: " + tvmDev.deviceType);
Log.i(TAG, "device id: " + tvmDev.deviceId);
Expand All @@ -597,10 +597,10 @@ protected Integer doInBackground(Void... args) {
.invoke();

Log.i(TAG, "as module...");
graphRuntimeModule = runtimeCreFunRes.asModule();
Log.i(TAG, "getting graph runtime load params handle...");
graphExecutorModule = runtimeCreFunRes.asModule();
Log.i(TAG, "getting graph executor load params handle...");
// get the function from the module(load parameters)
Function loadParamFunc = graphRuntimeModule.getFunction("load_params");
Function loadParamFunc = graphExecutorModule.getFunction("load_params");
Log.i(TAG, "loading params...");
loadParamFunc.pushArg(modelParams).invoke();
// release tvm local variables
Expand Down
2 changes: 1 addition & 1 deletion apps/android_camera/app/src/main/jni/tvm_runtime.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@
#include "../src/runtime/cpu_device_api.cc"
#include "../src/runtime/dso_library.cc"
#include "../src/runtime/file_utils.cc"
#include "../src/runtime/graph/graph_runtime.cc"
#include "../src/runtime/graph_executor/graph_executor.cc"
#include "../src/runtime/library_module.cc"
#include "../src/runtime/logging.cc"
#include "../src/runtime/module.cc"
Expand Down
2 changes: 1 addition & 1 deletion apps/android_camera/models/prepare_model.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

import tvm
import tvm.relay as relay
from tvm.contrib import utils, ndk, graph_runtime as runtime
from tvm.contrib import utils, ndk, graph_executor as runtime
from tvm.contrib.download import download_testdata, download

target = "llvm -mtriple=arm64-linux-android"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public class MainActivity extends AppCompatActivity {
private ImageView mImageView;
private TextView mResultView;
private AssetManager assetManager;
private Module graphRuntimeModule;
private Module graphExecutorModule;
private Vector<String> labels = new Vector<String>();

@Override
Expand Down Expand Up @@ -119,7 +119,7 @@ public void onClick(View v) {
}

/*
Load precompiled model on TVM graph runtime and init the system.
Load precompiled model on TVM graph executor and init the system.
*/
private class LoadModleAsyncTask extends AsyncTask<Void, Void, Integer> {
ProgressDialog dialog = new ProgressDialog(MainActivity.this);
Expand Down Expand Up @@ -183,17 +183,17 @@ protected Integer doInBackground(Void... args) {
// tvm module for compiled functions
Module modelLib = Module.load(libCacheFilePath);

// get global function module for graph runtime
Function runtimeCreFun = Function.getFunction("tvm.graph_runtime.create");
// get global function module for graph executor
Function runtimeCreFun = Function.getFunction("tvm.graph_executor.create");
TVMValue runtimeCreFunRes = runtimeCreFun.pushArg(modelGraph)
.pushArg(modelLib)
.pushArg(tvmDev.deviceType)
.pushArg(tvmDev.deviceId)
.invoke();
graphRuntimeModule = runtimeCreFunRes.asModule();
graphExecutorModule = runtimeCreFunRes.asModule();

// get the function from the module(load parameters)
Function loadParamFunc = graphRuntimeModule.getFunction("load_params");
Function loadParamFunc = graphExecutorModule.getFunction("load_params");
loadParamFunc.pushArg(modelParams).invoke();

// release tvm local variables
Expand Down Expand Up @@ -224,14 +224,14 @@ protected void onPostExecute(Integer status) {
}

/*
Execute prediction for processed decode input bitmap image content on TVM graph runtime.
Execute prediction for processed decode input bitmap image content on TVM graph executor.
*/
private class ModelRunAsyncTask extends AsyncTask<Bitmap, Void, Integer> {
ProgressDialog dialog = new ProgressDialog(MainActivity.this);

@Override
protected Integer doInBackground(Bitmap... bitmaps) {
if (null != graphRuntimeModule) {
if (null != graphExecutorModule) {
int count = bitmaps.length;
for (int i = 0 ; i < count ; i++) {
long processingTimeMs = SystemClock.uptimeMillis();
Expand Down Expand Up @@ -283,23 +283,23 @@ protected Integer doInBackground(Bitmap... bitmaps) {
Log.i(TAG, "set input data");
NDArray inputNdArray = NDArray.empty(new long[]{1, IMG_CHANNEL, MODEL_INPUT_SIZE, MODEL_INPUT_SIZE}, new TVMType("float32"));;
inputNdArray.copyFrom(imgRgbTranValues);
Function setInputFunc = graphRuntimeModule.getFunction("set_input");
Function setInputFunc = graphExecutorModule.getFunction("set_input");
setInputFunc.pushArg(INPUT_NAME).pushArg(inputNdArray).invoke();
// release tvm local variables
inputNdArray.release();
setInputFunc.release();

// get the function from the module(run it)
Log.i(TAG, "run function on target");
Function runFunc = graphRuntimeModule.getFunction("run");
Function runFunc = graphExecutorModule.getFunction("run");
runFunc.invoke();
// release tvm local variables
runFunc.release();

// get the function from the module(get output data)
Log.i(TAG, "get output data");
NDArray outputNdArray = NDArray.empty(new long[]{1, 1000}, new TVMType("float32"));
Function getOutputFunc = graphRuntimeModule.getFunction("get_output");
Function getOutputFunc = graphExecutorModule.getFunction("get_output");
getOutputFunc.pushArg(OUTPUT_INDEX).pushArg(outputNdArray).invoke();
float[] output = outputNdArray.asFloatArray();
// release tvm local variables
Expand Down Expand Up @@ -343,16 +343,16 @@ protected void onPostExecute(Integer status) {
dialog.dismiss();
}
if (status != 0) {
showDialog("Error", "Fail to predict image, GraphRuntime exception");
showDialog("Error", "Fail to predict image, GraphExecutor exception");
}
}
}

@Override
protected void onDestroy() {
// release tvm local variables
if (null != graphRuntimeModule)
graphRuntimeModule.release();
if (null != graphExecutorModule)
graphExecutorModule.release();
super.onDestroy();
}

Expand Down
2 changes: 1 addition & 1 deletion apps/android_deploy/app/src/main/jni/tvm_runtime.h
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
#include "../src/runtime/cpu_device_api.cc"
#include "../src/runtime/dso_library.cc"
#include "../src/runtime/file_utils.cc"
#include "../src/runtime/graph/graph_runtime.cc"
#include "../src/runtime/graph_executor/graph_executor.cc"
#include "../src/runtime/library_module.cc"
#include "../src/runtime/logging.cc"
#include "../src/runtime/module.cc"
Expand Down
4 changes: 2 additions & 2 deletions apps/android_rpc/app/src/main/jni/tvm_runtime.h
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@
#include "../src/runtime/cpu_device_api.cc"
#include "../src/runtime/dso_library.cc"
#include "../src/runtime/file_utils.cc"
#include "../src/runtime/graph/graph_runtime.cc"
#include "../src/runtime/graph/graph_runtime_factory.cc"
#include "../src/runtime/graph_executor/graph_executor.cc"
#include "../src/runtime/graph_executor/graph_executor_factory.cc"
#include "../src/runtime/library_module.cc"
#include "../src/runtime/logging.cc"
#include "../src/runtime/module.cc"
Expand Down
2 changes: 1 addition & 1 deletion apps/benchmark/arm_cpu_imagenet_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import tvm
from tvm import te
from tvm.contrib.utils import tempdir
import tvm.contrib.graph_runtime as runtime
import tvm.contrib.graph_executor as runtime
from tvm import relay

from util import get_network, print_progress
Expand Down
2 changes: 1 addition & 1 deletion apps/benchmark/gpu_imagenet_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@

import tvm
from tvm import te
import tvm.contrib.graph_runtime as runtime
import tvm.contrib.graph_executor as runtime
from tvm import relay

from util import get_network
Expand Down
2 changes: 1 addition & 1 deletion apps/benchmark/mobile_gpu_imagenet_bench.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
import tvm
from tvm import te
from tvm.contrib.utils import tempdir
import tvm.contrib.graph_runtime as runtime
import tvm.contrib.graph_executor as runtime
from tvm import relay

from util import get_network, print_progress
Expand Down
12 changes: 6 additions & 6 deletions apps/bundle_deploy/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ test_static: $(build_dir)/test_static $(build_dir)/test_data_c.bin $(build_dir)/
$(build_dir)/crt/libcommon.a: $(CRT_SRCS)
$(QUIET)cd $(CRT_ROOT) && make QUIET= BUILD_DIR=$(abspath $(build_dir))/crt CRT_CONFIG=$(abspath crt_config/crt_config.h) "EXTRA_CFLAGS=$(PKG_COMPILE_OPTS)" common

$(build_dir)/crt/libgraph_runtime.a: $(CRT_SRCS)
$(QUIET)cd $(CRT_ROOT) && make QUIET= BUILD_DIR=$(abspath $(build_dir))/crt CRT_CONFIG=$(abspath crt_config/crt_config.h) "EXTRA_CFLAGS=$(PKG_COMPILE_OPTS)" graph_runtime
$(build_dir)/crt/libgraph_executor.a: $(CRT_SRCS)
$(QUIET)cd $(CRT_ROOT) && make QUIET= BUILD_DIR=$(abspath $(build_dir))/crt CRT_CONFIG=$(abspath crt_config/crt_config.h) "EXTRA_CFLAGS=$(PKG_COMPILE_OPTS)" graph_executor

$(build_dir)/crt/libmemory.a: $(CRT_SRCS)
$(QUIET)cd $(CRT_ROOT) && make QUIET= BUILD_DIR=$(abspath $(build_dir))/crt CRT_CONFIG=$(abspath crt_config/crt_config.h) "EXTRA_CFLAGS=$(PKG_COMPILE_OPTS)" memory
Expand All @@ -98,11 +98,11 @@ $(build_dir)/test_dynamic: test.cc ${build_dir}/test_graph_c.json ${build_dir}/t
$(QUIET)mkdir -p $(@D)
$(QUIET)g++ $(PKG_CXXFLAGS) -o $@ test.cc $(BACKTRACE_OBJS) $(BACKTRACE_LDFLAGS)

$(build_dir)/demo_static: demo_static.c ${build_dir}/bundle_static.o $(MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_runtime.a ${build_dir}/crt/libcommon.a ${build_dir}/graph_c.json.c ${build_dir}/params_c.bin.c $(BACKTRACE_OBJS)
$(build_dir)/demo_static: demo_static.c ${build_dir}/bundle_static.o $(MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_executor.a ${build_dir}/crt/libcommon.a ${build_dir}/graph_c.json.c ${build_dir}/params_c.bin.c $(BACKTRACE_OBJS)
$(QUIET)mkdir -p $(@D)
$(QUIET)gcc $(PKG_CFLAGS) -o $@ $^ $(PKG_LDFLAGS) $(BACKTRACE_LDFLAGS) $(BACKTRACE_CFLAGS)

$(build_dir)/test_static: test_static.c ${build_dir}/bundle_static.o $(TEST_MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_runtime.a ${build_dir}/crt/libcommon.a $(BACKTRACE_OBJS)
$(build_dir)/test_static: test_static.c ${build_dir}/bundle_static.o $(TEST_MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_executor.a ${build_dir}/crt/libcommon.a $(BACKTRACE_OBJS)
$(QUIET)mkdir -p $(@D)
$(QUIET)gcc $(PKG_CFLAGS) -o $@ $^ $(BACKTRACE_LDFLAGS)

Expand Down Expand Up @@ -140,15 +140,15 @@ $(build_dir)/bundle.so: bundle.cc runtime.cc $(build_dir)/model_cpp.o
$(QUIET)mkdir -p $(@D)
$(QUIET)g++ -shared $(PKG_CXXFLAGS) -fvisibility=hidden -o $@ $^ $(PKG_LDFLAGS)

$(build_dir)/bundle_c.so: bundle.c $(MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_runtime.a ${build_dir}/crt/libcommon.a $(BACKTRACE_OBJS)
$(build_dir)/bundle_c.so: bundle.c $(MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_executor.a ${build_dir}/crt/libcommon.a $(BACKTRACE_OBJS)
$(QUIET)mkdir -p $(@D)
$(QUIET)gcc -shared $(PKG_CFLAGS) -fvisibility=hidden -o $@ $^ $(PKG_LDFLAGS) $(BACKTRACE_LDFLAGS) $(BACKTRACE_CFLAGS)

$(build_dir)/test_bundle.so: bundle.cc runtime.cc $(build_dir)/test_model_cpp.o
$(QUIET)mkdir -p $(@D)
$(QUIET)g++ -shared $(PKG_CXXFLAGS) -fvisibility=hidden -o $@ $^ $(PKG_LDFLAGS)

$(build_dir)/test_bundle_c.so: bundle.c $(TEST_MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_runtime.a ${build_dir}/crt/libcommon.a $(BACKTRACE_OBJS)
$(build_dir)/test_bundle_c.so: bundle.c $(TEST_MODEL_OBJ) ${build_dir}/crt/libmemory.a ${build_dir}/crt/libgraph_executor.a ${build_dir}/crt/libcommon.a $(BACKTRACE_OBJS)
$(QUIET)mkdir -p $(@D)
$(QUIET)gcc -shared $(PKG_CFLAGS) -fvisibility=hidden -o $@ $^ $(PKG_LDFLAGS) $(BACKTRACE_LDFLAGS) $(BACKTRACE_CFLAGS)

Expand Down
8 changes: 4 additions & 4 deletions apps/bundle_deploy/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ How to Bundle TVM Modules
=========================

This folder contains an example on how to bundle a TVM module (with the required
interpreter runtime modules such as `runtime::GraphRuntime`, the graph JSON, and
interpreter runtime modules such as `runtime::GraphExecutor`, the graph JSON, and
the params) into a single, self-contained shared object (`bundle.so`) which
exposes a C API wrapping the appropriate `runtime::GraphRuntime` instance.
exposes a C API wrapping the appropriate `runtime::GraphExecutor` instance.

This is useful for cases where we'd like to avoid deploying the TVM runtime
components to the target host in advance - instead, we simply deploy the bundled
Expand All @@ -49,8 +49,8 @@ This will:
- Build a `bundle.so` shared object containing the model specification and
parameters
- Build a `demo_dynamic` executable that `dlopen`'s `bundle.so` (or `bundle_c.so` in
terms of the MISRA-C runtime), instantiates the contained graph runtime,
and invokes the `GraphRuntime::Run` function on a cat image, then prints
terms of the MISRA-C runtime), instantiates the contained graph executor,
and invokes the `GraphExecutor::Run` function on a cat image, then prints
the output results.

Type the following command to run the sample code with static linking.
Expand Down
Loading

0 comments on commit 9b43a64

Please sign in to comment.