mirror of
				https://github.com/ggml-org/llama.cpp.git
				synced 2025-10-31 08:51:55 +00:00 
			
		
		
		
	ci : add caching for ROCm installation in release workflow (#15924)
This commit applies the same caching to the release workflow which
currently exists for the main CI workflow that was introduced in Commit
ff02caf9ee ("ci : cache ROCm installation
in windows-latest-cmake-hip (#15887)").
			
			
This commit is contained in:
		
							
								
								
									
										31
									
								
								.github/workflows/release.yml
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										31
									
								
								.github/workflows/release.yml
									
									
									
									
										vendored
									
									
								
							| @@ -544,13 +544,23 @@ jobs: | |||||||
|         run: | |         run: | | ||||||
|           git clone https://github.com/rocm/rocwmma --branch rocm-6.2.4 --depth 1 |           git clone https://github.com/rocm/rocwmma --branch rocm-6.2.4 --depth 1 | ||||||
|  |  | ||||||
|  |       - name: Cache ROCm Installation | ||||||
|  |         id: cache-rocm | ||||||
|  |         uses: actions/cache@v4 | ||||||
|  |         with: | ||||||
|  |           path: C:\Program Files\AMD\ROCm | ||||||
|  |           key: rocm-6.1-${{ runner.os }}-v1 | ||||||
|  |           restore-keys: | | ||||||
|  |             rocm-6.1-${{ runner.os }}- | ||||||
|  |  | ||||||
|       - name: ccache |       - name: ccache | ||||||
|         uses: ggml-org/ccache-action@v1.2.16 |         uses: ggml-org/ccache-action@v1.2.16 | ||||||
|         with: |         with: | ||||||
|           key: windows-latest-cmake-hip-${{ matrix.name }}-x64 |           key: windows-latest-cmake-hip-${{ matrix.name }}-x64 | ||||||
|           evict-old-files: 1d |           evict-old-files: 1d | ||||||
|  |  | ||||||
|       - name: Install |       - name: Install ROCm | ||||||
|  |         if: steps.cache-rocm.outputs.cache-hit != 'true' | ||||||
|         id: depends |         id: depends | ||||||
|         run: | |         run: | | ||||||
|           $ErrorActionPreference = "Stop" |           $ErrorActionPreference = "Stop" | ||||||
| @@ -558,13 +568,28 @@ jobs: | |||||||
|           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" |           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" | ||||||
|           write-host "Installing AMD HIP SDK" |           write-host "Installing AMD HIP SDK" | ||||||
|           $proc = Start-Process "${env:RUNNER_TEMP}\rocm-install.exe" -ArgumentList '-install' -NoNewWindow -PassThru |           $proc = Start-Process "${env:RUNNER_TEMP}\rocm-install.exe" -ArgumentList '-install' -NoNewWindow -PassThru | ||||||
|           $proc.WaitForExit(600000) |           $completed = $proc.WaitForExit(600000) | ||||||
|  |           if (-not $completed) { | ||||||
|  |               Write-Error "ROCm installation timed out after 10 minutes. Killing the process" | ||||||
|  |               $proc.Kill() | ||||||
|  |               exit 1 | ||||||
|  |           } | ||||||
|  |           if ($proc.ExitCode -ne 0) { | ||||||
|  |               Write-Error "ROCm installation failed with exit code $($proc.ExitCode)" | ||||||
|  |               exit 1 | ||||||
|  |           } | ||||||
|           write-host "Completed AMD HIP SDK installation" |           write-host "Completed AMD HIP SDK installation" | ||||||
|  |  | ||||||
|       - name: Verify ROCm |       - name: Verify ROCm | ||||||
|         id: verify |         id: verify | ||||||
|         run: | |         run: | | ||||||
|           & 'C:\Program Files\AMD\ROCm\*\bin\clang.exe' --version |           # Find and test ROCm installation | ||||||
|  |           $clangPath = Get-ChildItem 'C:\Program Files\AMD\ROCm\*\bin\clang.exe' | Select-Object -First 1 | ||||||
|  |           if (-not $clangPath) { | ||||||
|  |             Write-Error "ROCm installation not found" | ||||||
|  |             exit 1 | ||||||
|  |           } | ||||||
|  |           & $clangPath.FullName --version | ||||||
|  |  | ||||||
|       - name: Build |       - name: Build | ||||||
|         id: cmake_build |         id: cmake_build | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user
	 Daniel Bevenius
					Daniel Bevenius