Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,15 +55,15 @@ jobs:
echo "mlir-air timestamp: $MLIR_AIR_TIMESTAMP"
python3 -m pip install "mlir_air[aie]==$MLIR_AIR_VERSION.$MLIR_AIR_TIMESTAMP+$SHORT_MLIR_AIR_COMMIT_HASH.no.rtti" \
-f https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti \
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
-f https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly
# The [aie] extra requires llvm-aie without a version pin. Force an
# upgrade so we always test against the latest nightly wheel.
python3 -m pip install --upgrade --force-reinstall llvm-aie -f https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly
python3 -m pip show llvm-aie
python3 -m pip show mlir_aie
python3 -m pip show mlir_aie_no_rtti
# Set environmental variable "MLIR_AIE_INSTALL_DIR"
MLIR_AIE_INSTALL_DIR_STR="$(python3 -m pip show mlir_aie | grep ^Location: | awk '{print $2}')/mlir_aie"
MLIR_AIE_INSTALL_DIR_STR="$(python3 -m pip show mlir_aie_no_rtti | grep ^Location: | awk '{print $2}')/mlir_aie"
echo "MLIR_AIE_INSTALL_DIR=$MLIR_AIE_INSTALL_DIR_STR" >> $GITHUB_ENV
# Update paths in environmental variables
echo "${MLIR_AIE_INSTALL_DIR}/bin" >> $GITHUB_PATH
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/nightly-wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -345,7 +345,7 @@ jobs:
```bash
pip install triton-xdna \
--find-links https://github.com/${{ github.repository }}/releases/expanded_assets/latest-wheels \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
--find-links https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly \
--find-links https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti
```
Expand All @@ -355,7 +355,7 @@ jobs:
```powershell
pip install triton-xdna `
--find-links https://github.com/${{ github.repository }}/releases/expanded_assets/latest-wheels `
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti `
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 `
--find-links https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly `
--find-links https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti
```
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,15 +54,15 @@ python3 -m pip install --upgrade pip
# Install triton-xdna from GitHub Releases
pip install triton-xdna \
--find-links https://github.com/amd/Triton-XDNA/releases/expanded_assets/latest-wheels \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
--find-links https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly \
--find-links https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti
```

**Note:** To install from a local wheel file:
```bash
pip install /path/to/triton_xdna-*.whl \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
--find-links https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly \
--find-links https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti
```
Expand All @@ -79,7 +79,7 @@ pip install cmake pybind11 nanobind wheel ninja pytest setuptools Cython

# Install triton-xdna from source and all dependencies automatically
pip install . --no-build-isolation \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
--find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
--find-links https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly \
--find-links https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti
```
Expand Down Expand Up @@ -179,7 +179,7 @@ pip install torch --index-url https://download.pytorch.org/whl/cpu
pip install triton-windows
pip install "mlir_air[aie]" `
-f https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti `
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti `
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 `
-f https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly
```

Expand Down
16 changes: 8 additions & 8 deletions amd_triton_npu/backend/driver.py
Original file line number Diff line number Diff line change
Expand Up @@ -707,22 +707,22 @@ def _get_transform_ir_string():
transform.named_sequence @__transform_main(%arg1: !transform.any_op {{transform.readonly}}) {{
%mul = transform.structured.match ops{{["linalg.mul"]}} in %arg1 : (!transform.any_op) -> !transform.any_op
%mul_1, %loop = transform.air.linalg_tile %mul [{elemwise_tiling_size_l1_m}, {elemwise_tiling_size_l1_n}]
transform.air.linalg_promote %mul_1 {{"operands_to_promote"=[2], "memory_space"="L1"}}
transform.air.linalg_promote %mul_1 {{"operands_to_promote"=[0,1], "memory_space"="L1"}}
transform.air.linalg_promote %mul_1 {{"operands_to_promote"=[2], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
transform.air.linalg_promote %mul_1 {{"operands_to_promote"=[0,1], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
Comment thread
erwei-xilinx marked this conversation as resolved.

%add = transform.structured.match ops{{["linalg.add"]}} in %arg1 : (!transform.any_op) -> !transform.any_op
%add_1, %add_loop = transform.air.linalg_tile %add [{elemwise_tiling_size_l1_m}, {elemwise_tiling_size_l1_n}]
transform.air.linalg_promote %add_1 {{"operands_to_promote"=[2], "memory_space"="L1"}}
transform.air.linalg_promote %add_1 {{"operands_to_promote"=[0,1], "memory_space"="L1"}}
transform.air.linalg_promote %add_1 {{"operands_to_promote"=[2], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
transform.air.linalg_promote %add_1 {{"operands_to_promote"=[0,1], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
Comment thread
erwei-xilinx marked this conversation as resolved.

%matmul = transform.structured.match ops{{["linalg.matmul"]}} in %arg1 : (!transform.any_op) -> !transform.any_op
%fill = transform.structured.match ops{{["linalg.fill"]}} in %arg1 : (!transform.any_op) -> !transform.any_op
%matmul_1, %matmul_loop = transform.air.linalg_tile %matmul [{matmul_tiling_size_l1_m}, {matmul_tiling_size_l1_n}]
%fill_1 = transform.air.fuse_into_containing_op %fill into %matmul_loop
transform.air.linalg_promote %fill_1 {{"operands_to_promote"=[1], "memory_space"="L1"}}
transform.air.linalg_promote %matmul_1 {{"operands_to_promote"=[2], "memory_space"="L1"}}
%fill_1 = transform.air.fuse_into_containing_op %fill into %matmul_loop : (!transform.any_op, !transform.any_op) -> !transform.any_op
transform.air.linalg_promote %fill_1 {{"operands_to_promote"=[1], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
transform.air.linalg_promote %matmul_1 {{"operands_to_promote"=[2], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
%matmul_2, %reduction_loop = transform.air.linalg_tile %matmul_1 [0, 0, {matmul_tiling_size_l1_k}]
transform.air.linalg_promote %matmul_2 {{"operands_to_promote"=[0,1], "memory_space"="L1"}}
transform.air.linalg_promote %matmul_2 {{"operands_to_promote"=[0,1], "memory_space"="L1"}} : (!transform.any_op) -> !transform.any_op
Comment thread
erwei-xilinx marked this conversation as resolved.
transform.yield
}}
}}
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ classifiers = [
# Installation command:
# pip install triton-xdna \
# --find-links https://github.com/amd/Triton-XDNA/releases/expanded_assets/latest-wheels \
# --find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
# --find-links https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
# --find-links https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly \
# --find-links https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti

Expand Down
16 changes: 14 additions & 2 deletions third_party/triton_shared.patch
Original file line number Diff line number Diff line change
Expand Up @@ -69,11 +69,23 @@ index a4ac9ef..69f50b3 100644

def get_device_capability(self):
return ("cpu", 0)
diff --git a/include/triton-shared/Analysis/UseAnalysis.h b/include/triton-shared/Analysis/UseAnalysis.h
index d4e6675..98a8034 100644
--- a/include/triton-shared/Analysis/UseAnalysis.h
+++ b/include/triton-shared/Analysis/UseAnalysis.h
@@ -49,6 +49,7 @@ struct UseInfo : public dataflow::AbstractSparseLattice {
case UseType::MixUse:
return ChangeResult::NoChange;
}
+ llvm_unreachable("unhandled UseType");
}

ChangeResult meet(const AbstractSparseLattice &other) override {
diff --git a/lib/Analysis/PtrAnalysis.cpp b/lib/Analysis/PtrAnalysis.cpp
index 0fe5f84..b387759 100644
index d2e8e77..35a9d88 100644
--- a/lib/Analysis/PtrAnalysis.cpp
+++ b/lib/Analysis/PtrAnalysis.cpp
@@ -1051,7 +1051,7 @@ void PtrAnalysis::visitOperandUnrealizedCast(
@@ -977,7 +977,7 @@ void PtrAnalysis::visitOperandUnrealizedCast(
struct ModuloChunkInitArg {
Value reinterpretCast = nullptr;
// where in the init args is the first chunk placed
Expand Down
2 changes: 1 addition & 1 deletion utils/env_setup.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ Write-Host "mlir-air timestamp: $MLIR_AIR_TIMESTAMP"

python -m pip install "mlir_air[aie]==$MLIR_AIR_VERSION.$MLIR_AIR_TIMESTAMP+$SHORT_AIR_COMMIT.no.rtti" `
-f https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti `
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti `
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 `
-f https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly

# The [aie] extra requires llvm-aie without a version pin. To track the
Expand Down
2 changes: 1 addition & 1 deletion utils/env_setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ MLIR_AIR_TIMESTAMP=$(awk -v kw="Timestamp:" '$0 ~ kw {for (i=1; i<NF; i++) if ($
echo "mlir-air timestamp: $MLIR_AIR_TIMESTAMP"
python3 -m pip install "mlir_air[aie]==$MLIR_AIR_VERSION.$MLIR_AIR_TIMESTAMP+$SHORT_MLIR_AIR_COMMIT_HASH.no.rtti" \
-f https://github.com/Xilinx/mlir-air/releases/expanded_assets/latest-air-wheels-no-rtti \
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti \
-f https://github.com/Xilinx/mlir-aie/releases/expanded_assets/latest-wheels-no-rtti-2 \
-f https://github.com/Xilinx/llvm-aie/releases/expanded_assets/nightly

# The [aie] extra requires llvm-aie without a version pin. To track the
Expand Down
4 changes: 2 additions & 2 deletions utils/mlir-air-hash.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
Commit: dfa6d08
Timestamp: 2026050805
Commit: 9377b0e
Timestamp: 2026060303
Version: 0.0.1
Loading