code: def test_multigpu_routine(self):
      with mock.patch(
          "time.perf_counter",
          mock.Mock(side_effect=[2.4, 3.8, 3.8] * 10),
      ):
          with mock.patch(
              "cupy.cuda.get_elapsed_time", mock.Mock(return_value=2500)
          ):
              mock_func = mock.Mock()
              mock_func.__name__ = "test_name_xxx"
              x = cupy.testing.shaped_random((2, 3), cupy, "int32")
              y = cupy.testing.shaped_random((2, 3), cupy, "int32")
              assert mock_func.call_count == 0
  
              perf = profiler.benchmark(
                  mock_func,
                  (x, y),
                  n_repeat=10,
                  n_warmup=3,
                  devices=(0, 1),
              )
  
              assert perf.name == "test_name_xxx"
              assert mock_func.call_count == 13
              assert perf.cpu_times.shape == (10,)
              assert perf.gpu_times.shape == (
                  2,
                  10,
              )
              assert (perf.cpu_times == 1.4).all()
              assert (perf.gpu_times == 2.5).all()
  
file_path: cupy/tests/cupyx_tests/profiler_tests/test_benchmark.py
imports: import unittest
  from unittest import mock
  import numpy
  import cupy
  from cupy import testing
  from cupyx import profiler
  from cupyx.profiler import _time
label_desc: Use image node_id 2 for calling the TestBenchmark obj's underlying member method code with example usage: obj.test_multigpu_routine() without return types