Skip to content

Add quickPass option to skip heavy tests in tornado-test script #509

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Jul 25, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions tornado-assembly/src/bin/tornado-test
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,13 @@ __TORNADO_TESTS_WHITE_LIST__ = [

]

## List of tests to be excluded when running with te quick pass argument as they cause delays
__TORNADO_HEAVY_TESTS__ = [
"uk.ac.manchester.tornado.unittests.memory.TestStressDeviceMemory",
"uk.ac.manchester.tornado.unittests.profiler.TestProfiler",
"uk.ac.manchester.tornado.unittests.tensors.TestTensorAPIWithOnnx",
]

# ################################################################################################################
## Default options and flags
# ################################################################################################################
Expand Down Expand Up @@ -248,7 +255,6 @@ ENABLE_ASSERTIONS = "-ea "

__VERSION__ = "0.16_10032024"

JDK_8_VERSION = "1.8"
try:
javaHome = os.environ["JAVA_HOME"]
except:
Expand Down Expand Up @@ -413,10 +419,8 @@ def appendTestRunnerClassToCmd(cmd, args):
testRunner = __MAIN_TORNADO_JUNIT__
module = __MAIN_TORNADO_JUNIT_MODULE__

if (javaVersion != JDK_8_VERSION):
cmd += " -m " + module + testRunner
else:
cmd += " " + testRunner
cmd += " -m " + module + testRunner

return cmd


Expand Down Expand Up @@ -465,6 +469,8 @@ def runTestTheWorld(options, args):
stats = {"[PASS]": 0, "[FAILED]": 0, "[UNSUPPORTED]": 0}

for t in __TEST_THE_WORLD__:
if args.quickPass and t.testName in __TORNADO_HEAVY_TESTS__:
continue
command = options
if t.testParameters:
for testParam in t.testParameters:
Expand Down Expand Up @@ -548,6 +554,8 @@ def parseArguments():
parser.add_argument('--fullDebug', action="store_true", dest="fullDebug", default=False,
help="Enable the Full Debug mode. This mode is more verbose compared to --debug only")
parser.add_argument('--fast', "-f", action="store_true", dest="fast", default=False, help="Visualize Fast")
parser.add_argument('--quickPass', "-qp", action="store_true", dest="quickPass", default=False,
help="Quick pass without stress memory and output for logs in a file.")
parser.add_argument('--device', dest="device", default=None, help="Set an specific device. E.g `s0.t0.device=0:1`")
parser.add_argument('--printExec', dest="printExecution", action="store_true", default=False,
help="Print OpenCL Kernel Execution Time")
Expand Down