diff --git a/apps/howto_deploy/prepare_test_libs.py b/apps/howto_deploy/prepare_test_libs.py index a6c7688d20846..8e9f8b5f7335c 100644 --- a/apps/howto_deploy/prepare_test_libs.py +++ b/apps/howto_deploy/prepare_test_libs.py @@ -33,7 +33,7 @@ def prepare_test_libs(base_path): fadd_dylib.export_library(dylib_path) # Compile library in system library mode - fadd_syslib = tvm.build(s, [A, B], "llvm --system-lib", name="addonesys") + fadd_syslib = tvm.build(s, [A, B], "llvm", name="addonesys") syslib_path = os.path.join(base_path, "test_addone_sys.o") fadd_syslib.save(syslib_path) diff --git a/apps/sgx/src/build_model.py b/apps/sgx/src/build_model.py index 1fc297d8a0942..5e4e37db69b8a 100755 --- a/apps/sgx/src/build_model.py +++ b/apps/sgx/src/build_model.py @@ -39,7 +39,7 @@ def main(): ) with tvm.transform.PassContext(opt_level=3): - graph, lib, params = relay.build(net, "llvm --system-lib", params=params) + graph, lib, params = relay.build(net, "llvm", params=params) build_dir = osp.abspath(sys.argv[1]) if not osp.isdir(build_dir): diff --git a/apps/wasm-standalone/wasm-graph/tools/build_graph_lib.py b/apps/wasm-standalone/wasm-graph/tools/build_graph_lib.py index 9b262c398e00d..d647545afec54 100755 --- a/apps/wasm-standalone/wasm-graph/tools/build_graph_lib.py +++ b/apps/wasm-standalone/wasm-graph/tools/build_graph_lib.py @@ -72,7 +72,7 @@ def build_graph_lib(opt_level): shape_dict = {input_name: img_data.shape} mod, params = relay.frontend.from_onnx(onnx_model, shape_dict) - target = "llvm -mtriple=wasm32-unknown-unknown -mattr=+simd128 --system-lib" + target = "llvm -mtriple=wasm32-unknown-unknown -mattr=+simd128" with tvm.transform.PassContext(opt_level=opt_level): factory = relay.build(mod, target=target, params=params) diff --git a/tests/python/driver/tvmc/test_target.py b/tests/python/driver/tvmc/test_target.py index 4438ec437cb44..39e90e6d6ac48 100644 --- a/tests/python/driver/tvmc/test_target.py +++ b/tests/python/driver/tvmc/test_target.py @@ -114,9 +114,7 @@ def test_parse_multiple_target(): def test_parse_hybrid_target(): """Hybrid Target and external codegen""" - targets = parse_target( - "cmsis-nn -accelerator_config=ethos-u55-256, llvm -device=arm_cpu --system-lib" - ) + targets = parse_target("cmsis-nn -accelerator_config=ethos-u55-256, llvm -device=arm_cpu") assert len(targets) == 2 assert "cmsis-nn" == targets[0]["name"] @@ -154,7 +152,7 @@ def test_parse_quotes_and_separators_on_options(): def test_parse_multiple_target_with_opts_ethos_n78(): - targets = parse_target("ethos-n -myopt=value, llvm -device=arm_cpu --system-lib") + targets = parse_target("ethos-n -myopt=value, llvm -device=arm_cpu") assert len(targets) == 2 assert "ethos-n" == targets[0]["name"] diff --git a/tests/python/driver/tvmc/test_target_options.py b/tests/python/driver/tvmc/test_target_options.py index c73dc288cdd8f..891df86f0c1f1 100644 --- a/tests/python/driver/tvmc/test_target_options.py +++ b/tests/python/driver/tvmc/test_target_options.py @@ -86,7 +86,7 @@ def test_skip_target_from_codegen(): def test_target_recombobulation_single(): tvm_target, _ = target_from_cli("llvm", {"llvm": {"mcpu": "cortex-m3"}}) - assert str(tvm_target) == "llvm -keys=arm_cpu,cpu -link-params=0 -mcpu=cortex-m3" + assert str(tvm_target) == "llvm -keys=arm_cpu,cpu -mcpu=cortex-m3" def test_target_recombobulation_many(): diff --git a/tests/python/relay/aot/test_cpp_aot.py b/tests/python/relay/aot/test_cpp_aot.py index 3f641c9956521..4ffe302763f8a 100644 --- a/tests/python/relay/aot/test_cpp_aot.py +++ b/tests/python/relay/aot/test_cpp_aot.py @@ -169,7 +169,7 @@ def test_create_executor(): x = tvm.relay.var("x", tvm.relay.TensorType([1], dtype="float32")) expr = tvm.relay.add(x, tvm.relay.Constant(tvm.nd.array(np.array([1], dtype="float32")))) actual = relay.create_executor( - "aot", mod=tvm.IRModule.from_expr(tvm.relay.Function([x], expr)), target="c -executor=aot" + "aot", mod=tvm.IRModule.from_expr(tvm.relay.Function([x], expr)), target="c" ).evaluate()(np.array([2], dtype="float32")) np.isfinite(np.array([3], dtype="float32")) diff --git a/tests/python/relay/aot/test_crt_aot.py b/tests/python/relay/aot/test_crt_aot.py index edf23ff227813..c3426f147e0d1 100644 --- a/tests/python/relay/aot/test_crt_aot.py +++ b/tests/python/relay/aot/test_crt_aot.py @@ -710,42 +710,6 @@ def test_name_sanitiser_name_clash(): ) -# This tests for deprecated AOT executor arguments -# TODO(Mousius) Remove deprecated arguments later -def test_deprecated_target_arguments(): - """Tests we can still use relay.build with -executor, -runtime and -link-params""" - - interface_api = "c" - use_unpacked_api = True - test_runner = AOT_DEFAULT_RUNNER - - input_x = relay.var("x", shape=(1, 10)) - input_y = relay.var("y", shape=(1, 10)) - func_add = relay.add(input_x, input_y) - func = relay.Function([input_x, input_y], func_add) - - x_in = np.ones((1, 10)).astype("float32") - y_in = np.random.uniform(size=(1, 10)).astype("float32") - - params = {"x": x_in} - inputs = {"y": y_in} - output_list = generate_ref_data(func, inputs, params) - - compile_and_run( - AOTTestModel( - module=IRModule.from_expr(func), - inputs=inputs, - outputs=output_list, - params=params, - ), - test_runner, - interface_api, - use_unpacked_api, - use_runtime_executor=False, - target="c -executor=aot --link-params -runtime=c -interface-api=c --unpacked-api", - ) - - def test_aot_codegen_backend_alloc_workspace_calls(): """This test checks whether AoT lowering creates TVMBackendAllocWorkspace calls"""