Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
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
8 changes: 7 additions & 1 deletion projects/hipblaslt/tensilelite/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ While full test suites can be run with a single `tox` command, developers may wi
build the hipBLASLt tensilelite client executable (`tensilelite-client`) and run individual tests separately.
This is useful for debugging specific problems or isolating issues in a specific test.

### Run Full Test Suite with Tox
### Run Test Suite with Tox

The standard workflow for running the entire test suite is to use `tox`. This command will build
`tensilelite-client` and execute all tests.
Expand All @@ -16,6 +16,12 @@ cd rocm-libraries/projects/hipblaslt/tensilelite
tox -e py3 -- Tensile/Tests -m common
```

Subsequently, you can run just the Tensile unit tests via:

```
tox -e unit -- Tensile/Tests/unit
```

### Build client with invoke and Run a Test (Default Path)

This workflow uses `invoke` to build the client into the default `build_tmp` directory.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ def test_filterLogicFilesByPredicates_no_match(mock_logic_file):
result = filterLogicFilesByPredicates(logicFiles, predicateMap)
assert len(result) == 0

@pytest.mark.xfail
def test_filterLogicFilesByPredicates_match_emulation_ids(mock_logic_file):
logicFiles = ["file1.yaml"]
predicateMap = {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,6 @@ def test_convert_9_item_custom_kernel_config():
assert outputConf["MIInputPerThreadB"] == 5
assert outputConf["MIInputPerThreadMetadata"] == 5
assert outputConf["ThreadTile"] == [1, 1]
assert outputConf["Sparse"] == 0
Comment thread
talumbau marked this conversation as resolved.
assert outputConf["WorkGroup"] == [128, 3, 1]
assert outputConf["WavefrontSize"] == 48
assert outputConf["ISA"] == isa
Expand Down Expand Up @@ -201,7 +200,6 @@ def testConvert9ItemCustomKernelConfig():
assert outputConf["MIInputPerThreadB"] == 5
assert outputConf["MIInputPerThreadMetadata"] == 5
assert outputConf["ThreadTile"] == [1, 1]
assert outputConf["Sparse"] == 0
Comment thread
talumbau marked this conversation as resolved.
assert outputConf["WorkGroup"] == [1280, 2, 6] # Why do we change the workgroup here?
assert outputConf["WavefrontSize"] == 48
assert outputConf["ISA"] == isa
Expand Down
16 changes: 13 additions & 3 deletions projects/hipblaslt/tensilelite/tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -20,17 +20,27 @@ deps =
invoke
setenv =
TENSILE_CLIENT_STATIC = {env:TENSILE_CLIENT_STATIC:}
PYTHONPATH = {envdir}/build_tmp/tensilelite/rocisa/lib
PYTHONPATH = {toxinidir}/build_tmp/tensilelite/rocisa/lib
TENSILELITE_CLIENT_ARGS = {env:TENSILELITE_CLIENT_ARGS:}
commands =
pip install --upgrade pip
pip install --no-build-isolation {toxinidir}/rocisa/
pip install pytest-cov
invoke build-client --build-dir {envdir}/build_tmp {env:TENSILELITE_CLIENT_ARGS}
pytest -v --basetemp={envtmpdir} --junit-xml={toxinidir}/python_tests.xml --junit-prefix={envname} --color=yes -n 4 --prebuilt-client={envdir}/build_tmp/tensilelite/client/tensilelite-client {posargs}
invoke build-client --build-dir {toxinidir}/build_tmp {env:TENSILELITE_CLIENT_ARGS}
pytest -v --basetemp={envtmpdir} --junit-xml={toxinidir}/python_tests.xml --junit-prefix={envname} --color=yes -n 4 --prebuilt-client={toxinidir}/build_tmp/tensilelite/client/tensilelite-client {posargs}
allowlist_externals =
mkdir
sh
cmake

[testenv:unit]
description = "Runs Python unit tests quickly, skipping the client build. Assumes a build has run before."
basepython = python3
# This environment inherits 'deps' and 'setenv' from [testenv]
commands =
pytest -v --basetemp={envtmpdir} {posargs}


[testenv:lint]
basepython = python3
deps =
Expand Down