[MLIR] [AMDGPU] Use correct flags when building SerializeToHsaco
authorKrzysztof Drewniak <Krzysztof.Drewniak@amd.com>
Mon, 28 Feb 2022 15:56:17 +0000 (15:56 +0000)
committerKrzysztof Drewniak <Krzysztof.Drewniak@amd.com>
Thu, 3 Mar 2022 21:44:26 +0000 (21:44 +0000)
commitd7f9220bb63405f2f874e29eaa3a98a45b2ac452
treea6812c8df13f5feccb590d0018abcbf2e218801e
parent7e570308f225139d353f8133882b4946e2aa9a43
[MLIR] [AMDGPU] Use correct flags when building SerializeToHsaco

The SerializeToHsaco pass does not depend on ROCm being available on
the build system - it only requires ROCm to be present at runtime.
However, the CMake file that built it tested for
MLIR_ENABLE_ROCM_RUNNER , which implies that ROCm is currently
available and is used to control building ROCm integration tests.

Referencing MLIR_ENABLE_ROCM_RUNNER instead of
MLIR_ENABLE_ROCM_CONVERSIONS in the SerializeToHsaco build therefore
causes problems for clients who wish to build projects that depend on
this pass on a system without an AMD GPU present.

Reviewed By: whchung

Differential Revision: https://reviews.llvm.org/D120663
mlir/lib/Dialect/GPU/CMakeLists.txt