code: def test_two_models_with_a_single_external_pool(
      model_urls, usmp_algo
  ):
      """This checks for inference using a single large enough common pool"""
      pytest.importorskip("tflite")
  
      import tvm.relay.testing.tf as tf_testing  # pylint: disable=import-outside-toplevel
  
      use_unpacked_api = True
      interface_api = "c"
  
      target = tvm.target.Target("c")
      workspace_memory_pools = WorkspaceMemoryPools(
          [WorkspacePoolInfo("my_memory_pool", [target])]
      )
      test_runner = AOTTestRunner(
          pass_config={
              "tir.usmp.enable": True,
              "tir.usmp.algorithm": usmp_algo,
          },
          prologue=f"""
          #define MAX(A, B) ((A > B) ? A : B)
          __attribute__((section(".data.tvm"), aligned(16)))
          static uint8_t my_memory_pool[MAX({_get_workspace_size_define_macro("my_memory_pool", "mod1")},{_get_workspace_size_define_macro("my_memory_pool", "mod2")})];
          """,
      )
  
      tflite_model_file1 = tf_testing.get_workload_official(
          model_urls[0][0],
          model_urls[0][1],
      )
      (
          mod1,
          inputs1,
          params1,
      ) = create_relay_module_and_inputs_from_tflite_file(
          tflite_model_file1
      )
      output_list1 = generate_ref_data(mod1, inputs1, params1)
  
      tflite_model_file2 = tf_testing.get_workload_official(
          model_urls[1][0],
          model_urls[1][1],
      )
      (
          mod2,
          inputs2,
          params2,
      ) = create_relay_module_and_inputs_from_tflite_file(
          tflite_model_file2
      )
      output_list2 = generate_ref_data(mod2, inputs2, params2)
  
      compiled_test_mods = compile_models(
          [
              AOTTestModel(
                  name="mod1",
                  module=mod1,
                  inputs=inputs1,
                  outputs=output_list1,
                  params=params1,
              ),
              AOTTestModel(
                  name="mod2",
                  module=mod2,
                  inputs=inputs2,
                  outputs=output_list2,
                  params=params2,
              ),
          ],
          interface_api=interface_api,
          use_unpacked_api=use_unpacked_api,
          pass_config=test_runner.pass_config,
          workspace_memory_pools=workspace_memory_pools,
          target=target,
      )
  
      for compiled_model in compiled_test_mods:
          _check_for_no_tvm_backendallocworkspace_calls(
              compiled_model.executor_factory.lib
          )
  
      run_and_check(
          models=compiled_test_mods,
          runner=test_runner,
          interface_api=interface_api,
      )
  
imports: from collections import OrderedDict
  import re
  import random
  import numpy
  import pytest
  import tvm
  from tvm import relay
  from tvm.relay import testing
  from tvm.relay import transform
  from tvm.relay.op.annotation import compiler_begin, compiler_end
  from tvm.relay.backend import Executor, Runtime
  from tvm import WorkspaceMemoryPools, ConstantMemoryPools, WorkspacePoolInfo, ConstantPoolInfo, PoolInfoProperties
  from tvm.micro import model_library_format
  from tvm.micro.testing.aot_test_utils import parametrize_aot_options
  from tvm.testing.aot import AOTTestModel, AOTTestRunner, generate_ref_data, compile_and_run, compile_models, run_and_check, create_relay_module_and_inputs_from_tflite_file
  from tvm.testing.usmp import is_tvm_backendallocworkspace_calls
label_desc: Use image node_id 15 for calling a global function with example usage: test_two_models_with_a_single_external_pool(model_urls, usmp_algo) without return types