Skip to content

Commit

Permalink
[BUILD SYSTEM] Remove zstd (#1291)
Browse files Browse the repository at this point in the history
**Context:** We do not want to ship zstd.

**Description of the Change:** Removes zstd from LLVM build process.

**Benefits:** No zstd.

**Possible Drawbacks:** Possibly our bytecode takes more space.

**Related GitHub Issues:**

We will need to remove all caches for this change to take into effect.
  • Loading branch information
erick-xanadu authored Nov 8, 2024
1 parent 9b76c64 commit b12e047
Show file tree
Hide file tree
Showing 7 changed files with 26 additions and 26 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/build-wheel-linux-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -179,8 +179,8 @@ jobs:
-DLLVM_ENABLE_PROJECTS="mlir" \
-DLLVM_ENABLE_ASSERTIONS=ON \
-DLLVM_INSTALL_UTILS=ON \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DMLIR_ENABLE_BINDINGS_PYTHON=ON \
-DPython3_EXECUTABLE=$(which python${{ matrix.python_version }}) \
-DPython3_NumPy_INCLUDE_DIRS=$(python${{ matrix.python_version }} -c "import numpy as np; print(np.get_include())") \
Expand Down Expand Up @@ -215,8 +215,8 @@ jobs:
-DLLVM_ENABLE_ASSERTIONS=ON \
-DMLIR_DIR=$GITHUB_WORKSPACE/llvm-build/lib/cmake/mlir \
-DPython3_EXECUTABLE=$(which python${{ matrix.python_version }}) \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DCMAKE_CXX_VISIBILITY_PRESET=protected \
-DLLVM_ENABLE_LLD=ON
Expand Down Expand Up @@ -375,8 +375,8 @@ jobs:
-DMHLO_BINARY_DIR=$GITHUB_WORKSPACE/mhlo-build/bin \
-DEnzyme_DIR=$GITHUB_WORKSPACE/enzyme-build \
-DENZYME_SRC_DIR=$GITHUB_WORKSPACE/mlir/Enzyme \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=ON
cmake --build quantum-build --target check-dialects compiler_driver catalyst-cli
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/build-wheel-macos-arm64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -144,8 +144,8 @@ jobs:
-DLLVM_ENABLE_PROJECTS="mlir" \
-DLLVM_ENABLE_ASSERTIONS=ON \
-DLLVM_INSTALL_UTILS=ON \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=OFF \
-DMLIR_ENABLE_BINDINGS_PYTHON=ON \
-DPython3_EXECUTABLE=$(which python${{ matrix.python_version }}) \
Expand Down Expand Up @@ -180,8 +180,8 @@ jobs:
-DMLIR_DIR=$GITHUB_WORKSPACE/llvm-build/lib/cmake/mlir \
-DPython3_EXECUTABLE=$(which python${{ matrix.python_version }}) \
-DLLVM_ENABLE_LLD=OFF \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DCMAKE_CXX_VISIBILITY_PRESET=hidden
cmake --build mhlo-build --target check-mlir-hlo
Expand Down Expand Up @@ -339,8 +339,8 @@ jobs:
-DMHLO_BINARY_DIR=$GITHUB_WORKSPACE/mhlo-build/bin \
-DEnzyme_DIR=$GITHUB_WORKSPACE/enzyme-build \
-DENZYME_SRC_DIR=$GITHUB_WORKSPACE/mlir/Enzyme \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=OFF \
-DLLVM_DIR=$GITHUB_WORKSPACE/llvm-build/lib/cmake/llvm
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/build-wheel-macos-x86_64.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -140,8 +140,8 @@ jobs:
-DLLVM_ENABLE_PROJECTS="mlir" \
-DLLVM_ENABLE_ASSERTIONS=ON \
-DLLVM_INSTALL_UTILS=ON \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=OFF \
-DMLIR_ENABLE_BINDINGS_PYTHON=ON \
-DPython3_EXECUTABLE=$(which python${{ matrix.python_version }}) \
Expand Down Expand Up @@ -176,8 +176,8 @@ jobs:
-DMLIR_DIR=$GITHUB_WORKSPACE/llvm-build/lib/cmake/mlir \
-DPython3_EXECUTABLE=$(which python${{ matrix.python_version }}) \
-DLLVM_ENABLE_LLD=OFF \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DCMAKE_CXX_VISIBILITY_PRESET=hidden
cmake --build mhlo-build --target check-mlir-hlo
Expand Down Expand Up @@ -330,8 +330,8 @@ jobs:
-DMHLO_BINARY_DIR=$GITHUB_WORKSPACE/mhlo-build/bin \
-DEnzyme_DIR=$GITHUB_WORKSPACE/enzyme-build \
-DENZYME_SRC_DIR=$GITHUB_WORKSPACE/mlir/Enzyme \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=OFF
cmake --build quantum-build --target check-dialects compiler_driver catalyst-cli
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/scripts/linux_arm64/rh8/build_catalyst.sh
Original file line number Diff line number Diff line change
Expand Up @@ -70,8 +70,8 @@ cmake -S mlir -B quantum-build -G Ninja \
-DMHLO_BINARY_DIR=/catalyst/mhlo-build/bin \
-DEnzyme_DIR=/catalyst/enzyme-build \
-DENZYME_SRC_DIR=/catalyst/mlir/Enzyme \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=ON \
-DLLVM_DIR=/catalyst/llvm-build/lib/cmake/llvm
cmake --build quantum-build --target check-dialects compiler_driver catalyst-cli
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/scripts/linux_arm64/rh8/build_llvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,8 @@ cmake -S /catalyst/mlir/llvm-project/llvm -B /catalyst/llvm-build -G Ninja \
-DLLVM_ENABLE_PROJECTS="mlir" \
-DLLVM_ENABLE_ASSERTIONS=ON \
-DLLVM_INSTALL_UTILS=ON \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DLLVM_ENABLE_LLD=ON \
-DMLIR_ENABLE_BINDINGS_PYTHON=ON \
-DPython3_EXECUTABLE=/usr/bin/python3 \
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/scripts/linux_arm64/rh8/build_mhlo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ cmake -S /catalyst/mlir/mlir-hlo -B /catalyst/mhlo-build -G Ninja \
-DMLIR_DIR=/catalyst/llvm-build/lib/cmake/mlir \
-DPython3_EXECUTABLE=/usr/bin/python3 \
-DLLVM_ENABLE_LLD=ON \
-DLLVM_ENABLE_ZLIB=OFF \
-DLLVM_ENABLE_ZSTD=FORCE_ON \
-DLLVM_ENABLE_ZLIB=FORCE_ON \
-DLLVM_ENABLE_ZSTD=OFF \
-DCMAKE_CXX_VISIBILITY_PRESET=protected

LIT_FILTER_OUT="chlo_legalize_to_mhlo" cmake --build /catalyst/mhlo-build --target check-mlir-hlo
4 changes: 2 additions & 2 deletions mlir/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ SYMBOL_VISIBILITY := protected
endif

ENABLE_LLD?=$(DEFAULT_ENABLE_LLD)
ENABLE_ZLIB?=OFF
ENABLE_ZSTD?=ON
ENABLE_ZLIB?=ON
ENABLE_ZSTD?=OFF

ifeq ($(ENABLE_ASAN), ON)
USE_SANITIZER_NAMES="Address"
Expand Down

0 comments on commit b12e047

Please sign in to comment.