@@ -1010,7 +1010,7 @@ jobs:
1010
1010
1011
1011
strategy :
1012
1012
matrix :
1013
- gpu_target : [gfx1100, gfx1101, gfx1030, '"gfx1100;gfx1101;gfx1102;gfx1030;gfx906"' ]
1013
+ gpu_target : [gfx1100, gfx1101, gfx1030]
1014
1014
1015
1015
steps :
1016
1016
- name : Clone
@@ -1068,6 +1068,70 @@ jobs:
1068
1068
path : llama-${{ steps.tag.outputs.name }}-bin-win-hip-x64-${{ matrix.gpu_target }}.zip
1069
1069
name : llama-bin-win-hip-x64-${{ matrix.gpu_target }}.zip
1070
1070
1071
+ windows-latest-cmake-hip-release-gfx1100-gfx1101-gfx1102-gfx1030-gfx906 :
1072
+ if : ${{ ( github.event_name == 'push' && github.ref == 'refs/heads/master' ) || github.event.inputs.create_release == 'true' }}
1073
+ runs-on : windows-latest
1074
+
1075
+ strategy :
1076
+ matrix :
1077
+ gpu_target : [gfx1100-gfx1101-gfx1102-gfx1030-gfx906]
1078
+
1079
+ steps :
1080
+ - name : Clone
1081
+ id : checkout
1082
+ uses : actions/checkout@v4
1083
+
1084
+ - name : Install
1085
+ id : depends
1086
+ run : |
1087
+ $ErrorActionPreference = "Stop"
1088
+ write-host "Downloading AMD HIP SDK Installer"
1089
+ Invoke-WebRequest -Uri "https://download.amd.com/developer/eula/rocm-hub/AMD-Software-PRO-Edition-24.Q3-WinSvr2022-For-HIP.exe" -OutFile "${env:RUNNER_TEMP}\rocm-install.exe"
1090
+ write-host "Installing AMD HIP SDK"
1091
+ Start-Process "${env:RUNNER_TEMP}\rocm-install.exe" -ArgumentList '-install' -NoNewWindow -Wait
1092
+ write-host "Completed AMD HIP SDK installation"
1093
+
1094
+ - name : Verify ROCm
1095
+ id : verify
1096
+ run : |
1097
+ & 'C:\Program Files\AMD\ROCm\*\bin\clang.exe' --version
1098
+
1099
+ - name : Build
1100
+ id : cmake_build
1101
+ run : |
1102
+ $env:HIP_PATH=$(Resolve-Path 'C:\Program Files\AMD\ROCm\*\bin\clang.exe' | split-path | split-path)
1103
+ $env:CMAKE_PREFIX_PATH="${env:HIP_PATH}"
1104
+ cmake -G "Unix Makefiles" -B build -S . -DCMAKE_C_COMPILER="${env:HIP_PATH}\bin\clang.exe" -DCMAKE_CXX_COMPILER="${env:HIP_PATH}\bin\clang++.exe" -DGGML_HIPBLAS=ON -DCMAKE_BUILD_TYPE=Release -DAMDGPU_TARGETS="gfx1100;gfx1101;gfx1102;gfx1030;gfx906" -DGGML_RPC=ON
1105
+ cmake --build build -j ${env:NUMBER_OF_PROCESSORS}
1106
+ md "build\bin\rocblas\library\"
1107
+ cp "${env:HIP_PATH}\bin\hipblas.dll" "build\bin\"
1108
+ cp "${env:HIP_PATH}\bin\rocblas.dll" "build\bin\"
1109
+ cp "${env:HIP_PATH}\bin\rocblas\library\*" "build\bin\rocblas\library\"
1110
+
1111
+ - name : Determine tag name
1112
+ id : tag
1113
+ shell : bash
1114
+ run : |
1115
+ BUILD_NUMBER="$(git rev-list --count HEAD)"
1116
+ SHORT_HASH="$(git rev-parse --short=7 HEAD)"
1117
+ if [[ "${{ env.BRANCH_NAME }}" == "master" ]]; then
1118
+ echo "name=b${BUILD_NUMBER}" >> $GITHUB_OUTPUT
1119
+ else
1120
+ SAFE_NAME=$(echo "${{ env.BRANCH_NAME }}" | tr '/' '-')
1121
+ echo "name=${SAFE_NAME}-b${BUILD_NUMBER}-${SHORT_HASH}" >> $GITHUB_OUTPUT
1122
+ fi
1123
+
1124
+ - name : Pack artifacts
1125
+ id : pack_artifacts
1126
+ run : |
1127
+ 7z a llama-${{ steps.tag.outputs.name }}-bin-win-hip-x64-${{ matrix.gpu_target }}.zip .\build\bin\*
1128
+
1129
+ - name : Upload artifacts
1130
+ uses : actions/upload-artifact@v4
1131
+ with :
1132
+ path : llama-${{ steps.tag.outputs.name }}-bin-win-hip-x64-${{ matrix.gpu_target }}.zip
1133
+ name : llama-bin-win-hip-x64-${{ matrix.gpu_target }}.zip
1134
+
1071
1135
ios-xcode-build :
1072
1136
runs-on : macos-latest
1073
1137
@@ -1132,6 +1196,7 @@ jobs:
1132
1196
- windows-latest-cmake
1133
1197
- windows-latest-cmake-cuda
1134
1198
- windows-latest-cmake-hip-release
1199
+ - windows-latest-cmake-hip-release-gfx1100-gfx1101-gfx1102-gfx1030-gfx906
1135
1200
- macOS-latest-cmake-arm64
1136
1201
- macOS-latest-cmake-x64
1137
1202
0 commit comments