Compare commits

...

14 Commits

Author SHA1 Message Date
83ea323dd6 Bump to include user-defined autotuner fix and load-with-other codegen workaround 2024-11-21 19:57:54 -08:00
fb98ff267a Bump pin to include ProgramPoint fix (triton-lang/triton#5181) 2024-11-21 19:57:54 -08:00
fe97150a81 Only use clang/lld for CUDA 2024-11-21 19:57:54 -08:00
d771851d87 Only call dnf on the cuda runners 2024-11-21 19:57:54 -08:00
62de0f18d3 Add pybind11 to conda build 2024-11-21 19:57:54 -08:00
950fabb0eb Add TRITON_BUILD_WITH_CLANG_LLD 2024-11-21 19:57:54 -08:00
8822d7eaaa Update build-triton-wheel.yml 2024-11-21 19:57:54 -08:00
46393b37f3 Remove gcc 11 install fro xpu builds 2024-11-21 19:57:54 -08:00
d15f63007d Use manylinux2_28-builder 2024-11-21 19:57:54 -08:00
e0ff34eaca Update build-triton-wheel.yml - use manylinux_2_28-builder 2024-11-21 19:57:54 -08:00
fb6f32df9e Remove git version suffix from Triton wheel version
It is now always added by Triton's own setup.py (see
https://github.com/triton-lang/triton/pull/4812/)
2024-11-21 19:57:54 -08:00
001b682784 Revert "Fix triton build failure due to tritonlang.blob.core.windows.net not available (#133694)"
This reverts commit 2cffe82deae5a0a075f817c4c706906f227e3244.
2024-11-21 19:57:54 -08:00
7df46c122a Install pybind11 to build Triton 2024-11-21 19:57:54 -08:00
abb28ee50e [triton] Update pin for PyTorch 2.6/Triton 3.2 2024-11-21 19:57:54 -08:00
4 changed files with 12 additions and 42 deletions

View File

@ -1 +1 @@
cf34004b8a67d290a962da166f5aa2fc66751326
35c6c7c6284582b3f41c71c150e11b517acf074a

View File

@ -1 +1 @@
3.1.0
3.2.0

View File

@ -48,25 +48,6 @@ def patch_init_py(
f.write(orig)
# TODO: remove patch_setup_py() once we have a proper fix for https://github.com/triton-lang/triton/issues/4527
def patch_setup_py(path: Path) -> None:
with open(path) as f:
orig = f.read()
try:
orig = check_and_replace(
orig,
"https://tritonlang.blob.core.windows.net/llvm-builds/",
"https://oaitriton.blob.core.windows.net/public/llvm-builds/",
)
with open(path, "w") as f:
f.write(orig)
except RuntimeError as e:
print(
f"Applying patch_setup_py() for llvm-build package failed: {e}.",
"If you are trying to build a newer version of Triton, you can ignore this.",
)
def build_triton(
*,
version: str,
@ -81,13 +62,6 @@ def build_triton(
max_jobs = os.cpu_count() or 1
env["MAX_JOBS"] = str(max_jobs)
version_suffix = ""
if not release:
# Nightly binaries include the triton commit hash, i.e. 2.1.0+e6216047b8
# while release build should only include the version, i.e. 2.1.0
version_suffix = f"+{commit_hash[:10]}"
version += version_suffix
with TemporaryDirectory() as tmpdir:
triton_basedir = Path(tmpdir) / "triton"
triton_pythondir = triton_basedir / "python"
@ -108,9 +82,6 @@ def build_triton(
else:
check_call(["git", "checkout", commit_hash], cwd=triton_basedir)
# TODO: remove this and patch_setup_py() once we have a proper fix for https://github.com/triton-lang/triton/issues/4527
patch_setup_py(triton_pythondir / "setup.py")
if build_conda:
with open(triton_basedir / "meta.yaml", "w") as meta:
print(
@ -125,8 +96,8 @@ def build_triton(
file=meta,
)
print(
"requirements:\n host:\n - python\n - setuptools\n run:\n - python\n"
" - filelock\n - pytorch\n",
"requirements:\n host:\n - python\n - setuptools\n - pybind11\n"
" run:\n - python\n - filelock\n - pytorch\n",
file=meta,
)
print(
@ -162,7 +133,8 @@ def build_triton(
# change built wheel name and version
env["TRITON_WHEEL_NAME"] = triton_pkg_name
env["TRITON_WHEEL_VERSION_SUFFIX"] = version_suffix
if device == "cuda":
env["TRITON_BUILD_WITH_CLANG_LLD"] = "1"
patch_init_py(
triton_pythondir / "triton" / "__init__.py",
version=f"{version}",

View File

@ -53,7 +53,7 @@ jobs:
rocm_version: ""
timeout-minutes: 40
env:
DOCKER_IMAGE: ${{ matrix.device == 'rocm' && format('pytorch/manylinux-builder:rocm{0}', matrix.rocm_version) || 'pytorch/manylinux-builder:cpu' }}
DOCKER_IMAGE: ${{ matrix.device == 'rocm' && format('pytorch/manylinux-builder:rocm{0}', matrix.rocm_version) || 'pytorch/manylinux2_28-builder:cpu' }}
PY_VERS: ${{ matrix.py_vers }}
BUILD_DEVICE: ${{ matrix.device }}
steps:
@ -119,14 +119,12 @@ jobs:
fi
docker exec -t "${container_name}" yum install -y zlib-devel zip
docker exec -t "${container_name}" "${PYTHON_EXECUTABLE}" -m pip install -U setuptools==67.4.0
# Triton xpu build use GCC11
if [[ "${BUILD_DEVICE}" == xpu ]]; then
docker exec -t "${container_name}" yum install -y devtoolset-11-gcc-c++
docker exec -t "${container_name}" bash -c "source /opt/rh/devtoolset-11/enable && ${PYTHON_EXECUTABLE} /pytorch/.github/scripts/build_triton_wheel.py --device=$BUILD_DEVICE $RELEASE"
else
docker exec -t "${container_name}" bash -c "${PYTHON_EXECUTABLE} /pytorch/.github/scripts/build_triton_wheel.py --device=$BUILD_DEVICE $RELEASE"
docker exec -t "${container_name}" "${PYTHON_EXECUTABLE}" -m pip install -U setuptools==67.4.0 pybind11==2.13.1
if [[ "${{ matrix.device }}" == "cuda" ]]; then
# With this install, it gets clang 16.0.6.
docker exec -t "${container_name}" dnf install clang lld -y
fi
docker exec -t "${container_name}" bash -c "${PYTHON_EXECUTABLE} /pytorch/.github/scripts/build_triton_wheel.py --device=$BUILD_DEVICE $RELEASE"
docker exec -t "${container_name}" chown -R 1000.1000 /artifacts
- uses: actions/upload-artifact@v4.4.0