<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Issue</th>
<td>
<a href=https://github.com/llvm/llvm-project/issues/60628>60628</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>
Remove RUN line duplication in mlir/test/Integration/Dialect/SparseTensor/CPU/
</td>
</tr>
<tr>
<th>Labels</th>
<td>
mlir:sparse
</td>
</tr>
<tr>
<th>Assignees</th>
<td>
banach-space
</td>
</tr>
<tr>
<th>Reporter</th>
<td>
banach-space
</td>
</tr>
</table>
<pre>
When extending SparseCompiler integrations tests to run via SVE codegen (see https://reviews.llvm.org/D143514 and https://reviews.llvm.org/D121304), we effectively duplicated many of the RUN lines.
More specifically, if the `MLIR_RUN_ARM_SVE_TESTS` CMake flag is disabled, the following RUN lines are effectively identical (they verify similar code-path):
1. https://github.com/llvm/llvm-project/blob/6a4e9ccb2c6f3340eb01bd374988a55daed2a68d/mlir/test/Integration/Dialect/SparseTensor/CPU/sparse_unary.mlir#L15-L16
2. https://github.com/llvm/llvm-project/blob/4c72266830ffa332ebb7cf1d3bbd6c56d001fa0f/mlir/test/Integration/Dialect/SparseTensor/CPU/sparse_unary.mlir#L20-L27
We should avoid this. My suggestion would be to replace both `RUN` lines with RUN line 2. above. Additionally, we should make sure that there are public buildbots that
* set MLIR_RUN_ARM_SVE_TESTS to `On` (e.g. [clang-aarch64-sve-vla](https://github.com/llvm/llvm-zorg/blob/91b1e24a8df6bd10be68f8df3865803dbe2d9ae5/buildbot/osuosl/master/config/builders.py#L479-L499)
* set MLIR_RUN_ARM_SVE_TESTS to `Off` (that's the default, so any buildbot running MLIR integration tests should be fine, e.g. [mlir-rocm-mi200](https://github.com/llvm/llvm-zorg/blob/91b1e24a8df6bd10be68f8df3865803dbe2d9ae5/buildbot/osuosl/master/config/builders.py#L2600-L2622)
This way we will be making sure that all configurations are tested, but there is not code duplication in tests. WDYT?
CC @aartbik
-Andrzej
</pre>
<img width="1px" height="1px" alt="" src="http://email.email.llvm.org/o/eJzMVUuP2zYQ_jX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