@@ -21,49 +21,13 @@ Write-Host "Installing triton-windows..."
2121python - m pip install triton- windows
2222
2323# =============================================================================
24- # Install mlir-aie
24+ # Install mlir-air with [ aie] extra
2525# =============================================================================
26+ # The mlir-air wheel pins the matching mlir-aie commit and requires llvm-aie,
27+ # so a single pip install resolves the whole MLIR-AIE/AIR/LLVM-AIE stack with
28+ # a guaranteed-compatible mlir-aie.
2629
27- if (-not $env: MLIR_AIE_INSTALL_DIR ) {
28- $HashFile = Join-Path $ScriptDir " mlir-aie-hash-windows.txt"
29- $MLIR_AIE_COMMIT = (Select-String - Path $HashFile - Pattern " ^Commit:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
30- $SHORT_COMMIT = $MLIR_AIE_COMMIT.Substring (0 , 7 )
31- $MLIR_AIE_VERSION = (Select-String - Path $HashFile - Pattern " ^Version:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
32- $TIMESTAMP = (Select-String - Path $HashFile - Pattern " ^Timestamp:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
33-
34- Write-Host " Using mlir-aie hash: $SHORT_COMMIT "
35- Write-Host " Version: $MLIR_AIE_VERSION "
36- Write-Host " Timestamp: $TIMESTAMP "
37-
38- python - m pip install " mlir_aie==$MLIR_AIE_VERSION .$TIMESTAMP +$SHORT_COMMIT .no.rtti" -f https:// github.com / Xilinx/ mlir- aie/ releases/ expanded_assets/ latest- wheels- no- rtti
39-
40- $MLIR_AIE_INSTALL_DIR = (python - c " import importlib.util; spec = importlib.util.find_spec('mlir_aie'); print(spec.submodule_search_locations[0])" )
41- $env: MLIR_AIE_INSTALL_DIR = $MLIR_AIE_INSTALL_DIR
42- }
43-
44- $env: PATH = " $env: MLIR_AIE_INSTALL_DIR \bin;$env: PATH "
45- $env: PYTHONPATH = " $env: MLIR_AIE_INSTALL_DIR \python;$env: PYTHONPATH "
46-
47- # =============================================================================
48- # Install llvm-aie
49- # =============================================================================
50-
51- $HashFile = Join-Path $ScriptDir " llvm-aie-hash-windows.txt"
52- $LLVM_AIE_COMMIT = (Select-String - Path $HashFile - Pattern " ^Commit:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
53- $LLVM_AIE_VERSION = (Select-String - Path $HashFile - Pattern " ^Version:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
54- $LLVM_AIE_TIMESTAMP = (Select-String - Path $HashFile - Pattern " ^Timestamp:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
55-
56- Write-Host " Using llvm-aie hash: $LLVM_AIE_COMMIT "
57- Write-Host " llvm-aie version: $LLVM_AIE_VERSION "
58- Write-Host " llvm-aie timestamp: $LLVM_AIE_TIMESTAMP "
59-
60- python - m pip install " llvm_aie==$LLVM_AIE_VERSION .$LLVM_AIE_TIMESTAMP +$LLVM_AIE_COMMIT " -f https:// github.com / Xilinx/ llvm- aie/ releases/ expanded_assets/ nightly
61-
62- # =============================================================================
63- # Install mlir-air
64- # =============================================================================
65-
66- $HashFile = Join-Path $ScriptDir " mlir-air-hash-windows.txt"
30+ $HashFile = Join-Path $ScriptDir " mlir-air-hash.txt"
6731$MLIR_AIR_COMMIT = (Select-String - Path $HashFile - Pattern " ^Commit:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
6832$SHORT_AIR_COMMIT = $MLIR_AIR_COMMIT.Substring (0 , 7 )
6933$MLIR_AIR_VERSION = (Select-String - Path $HashFile - Pattern " ^Version:" | ForEach-Object { ($_ -split " :\s+" )[1 ] }).Trim()
@@ -73,7 +37,24 @@ Write-Host "Using mlir-air hash: $SHORT_AIR_COMMIT"
7337Write-Host " mlir-air version: $MLIR_AIR_VERSION "
7438Write-Host " mlir-air timestamp: $MLIR_AIR_TIMESTAMP "
7539
76- python - m pip install " mlir_air==$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
40+ python - m pip install " mlir_air[aie]==$MLIR_AIR_VERSION .$MLIR_AIR_TIMESTAMP +$SHORT_AIR_COMMIT .no.rtti" `
41+ -f https:// github.com / Xilinx/ mlir- air/ releases/ expanded_assets/ latest- air- wheels- no- rtti `
42+ -f https:// github.com / Xilinx/ mlir- aie/ releases/ expanded_assets/ latest- wheels- no- rtti `
43+ -f https:// github.com / Xilinx/ llvm- aie/ releases/ expanded_assets/ nightly
44+
45+ # The [aie] extra requires llvm-aie without a version pin. To track the
46+ # nightly wheel, force-upgrade llvm-aie explicitly so an existing installation
47+ # doesn't silently satisfy the unpinned requirement.
48+ python - m pip install -- upgrade llvm- aie `
49+ -f https:// github.com / Xilinx/ llvm- aie/ releases/ expanded_assets/ nightly
50+
51+ if (-not $env: MLIR_AIE_INSTALL_DIR ) {
52+ $MLIR_AIE_INSTALL_DIR = (python - c " import importlib.util; spec = importlib.util.find_spec('mlir_aie'); print(spec.submodule_search_locations[0])" )
53+ $env: MLIR_AIE_INSTALL_DIR = $MLIR_AIE_INSTALL_DIR
54+ }
55+
56+ $env: PATH = " $env: MLIR_AIE_INSTALL_DIR \bin;$env: PATH "
57+ $env: PYTHONPATH = " $env: MLIR_AIE_INSTALL_DIR \python;$env: PYTHONPATH "
7758
7859# =============================================================================
7960# Install triton-xdna (copies backend into triton-windows)
0 commit comments