Skip to content

Commit

Permalink
Add nvidia to list of backends (#1032)
Browse files Browse the repository at this point in the history
Add `nvidia` to list of backends to build to avoid regression from
building `intel` backend with `nvidia` backend.

Signed-off-by: Whitney Tsang <[email protected]>
  • Loading branch information
whitneywhtsang authored May 3, 2024
1 parent efe6886 commit d92c565
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 11 deletions.
6 changes: 0 additions & 6 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -173,12 +173,6 @@ if(TRITON_BUILD_PYTHON_MODULE)
add_subdirectory(third_party/${CODEGEN_BACKEND})
endforeach()

# Always build NVidia dialects for MLIR tools.
if (NOT "nvidia" IN_LIST TRITON_CODEGEN_BACKENDS)
set(NVIDIA_DIALECTS_ONLY "")
add_subdirectory(third_party/nvidia)
endif()

if (TRITON_BUILD_PROTON)
add_subdirectory(third_party/proton)
endif()
Expand Down
6 changes: 1 addition & 5 deletions python/setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -333,10 +333,6 @@ def get_proton_cmake_args(self):
def build_extension(self, ext):
lit_dir = shutil.which('lit')
ninja_dir = shutil.which('ninja')
user_home = os.getenv("HOME") or os.getenv("USERPROFILE") or \
os.getenv("HOMEPATH") or None
if not user_home:
raise RuntimeError("Could not find user home directory")
# lit is used by the test suite
thirdparty_cmake_args = get_thirdparty_packages([get_pybind11_package_info(), get_llvm_package_info()])
extdir = os.path.abspath(os.path.dirname(self.get_ext_fullpath(ext.path)))
Expand Down Expand Up @@ -464,7 +460,7 @@ def build_extension(self, ext):
f"https://anaconda.org/nvidia/cuda-cupti/{version}/download/linux-{arch}/cuda-cupti-{version}-0.tar.bz2",
)

backends = [*BackendInstaller.copy(["intel", "amd"]), *BackendInstaller.copy_externals()]
backends = [*BackendInstaller.copy(["intel", "nvidia", "amd"]), *BackendInstaller.copy_externals()]


def add_link_to_backends():
Expand Down

0 comments on commit d92c565

Please sign in to comment.