Testing - Add Windows ARM64 build and test support (#1135)

- Introduces new Windows ARM64 jobs in the multi-platform workflow (build, test, retest, gtest).
- Extends composite GitHub actions with a `target-arch` input and adds ARM64 Mesa llvmpipe setup for headless rendering.
- Adjusts architecture reporting (`dversion`) and updates one mesh regression test with ARM64-specific expected values; updates a DE enum definition to avoid an MSVC ARM64 LTCG miscompile.
This commit is contained in:
Harish RS
2026-03-24 15:54:31 +05:30
committed by GitHub
parent 4ec89df6f5
commit 71b50963ea
9 changed files with 178 additions and 17 deletions
@@ -2,6 +2,13 @@ name: 'Download vcpkg Cache'
description: 'Download and restore vcpkg installed packages and cache'
inputs:
platform:
description: 'Platform (windows, macos, linux)'
required: true
target-arch:
description: 'Target architecture (x64, arm64)'
required: false
default: 'x64'
artifact-name:
description: 'Name of the artifact containing vcpkg cache'
required: true
@@ -28,7 +35,7 @@ runs:
shell: bash
- name: Copy manual-link libraries and set paths for Windows
if: runner.os == 'Windows'
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'x64' }}
run: |
$vcpkg_bin = "${{ inputs.build-directory }}/vcpkg_installed/x64-windows/bin"
$vcpkg_lib = "${{ inputs.build-directory }}/vcpkg_installed/x64-windows/lib"
@@ -45,6 +52,25 @@ runs:
echo "PATH=$vcpkg_bin;$vcpkg_lib;$vcpkg_manual;$current_path" >> $env:GITHUB_ENV
shell: pwsh
- name: Copy manual-link libraries and set paths for Windows arm64
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'arm64' }}
run: |
$vcpkg_bin = "${{ inputs.build-directory }}/vcpkg_installed/arm64-windows/bin"
$vcpkg_lib = "${{ inputs.build-directory }}/vcpkg_installed/arm64-windows/lib"
$vcpkg_manual = "${{ inputs.build-directory }}/vcpkg_installed/arm64-windows/lib/manual-link"
# Copy manual-link DLLs to bin directory for runtime access
if (Test-Path $vcpkg_manual) {
Write-Host "Copying manual-link libraries to bin directory"
Copy-Item "$vcpkg_manual\*" "$vcpkg_bin\" -Force -ErrorAction SilentlyContinue
}
# Set library search paths
$current_path = $env:PATH
echo "PATH=$vcpkg_bin;$vcpkg_lib;$vcpkg_manual;$current_path" >> $env:GITHUB_ENV
shell: pwsh
- name: Copy manual-link libraries and set paths for Linux
if: runner.os == 'Linux'
run: |
+19 -7
View File
@@ -8,6 +8,10 @@ inputs:
compiler:
description: 'Compiler (msvc, clang, gcc)'
required: true
target-arch:
description: 'Target architecture (x64, arm64)'
required: false
default: 'x64'
install-artifact-name:
description: 'Name of the artifact containing the install directory'
required: true
@@ -124,20 +128,27 @@ runs:
path: install
- name: Download and extract Mesa3D (Windows)
if: ${{ inputs.platform == 'windows' && steps.check_failures.outputs.failed_count > 0 }}
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'x64' && steps.check_failures.outputs.failed_count > 0 }}
shell: pwsh
run: |
curl -L -o mesa3d.7z https://github.com/pal1000/mesa-dist-win/releases/download/24.3.2/mesa3d-24.3.2-release-mingw.7z
7z x mesa3d.7z -omesa3d
- name: Run system-wide deployment (Windows)
if: ${{ inputs.platform == 'windows' && steps.check_failures.outputs.failed_count > 0 }}
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'x64' && steps.check_failures.outputs.failed_count > 0 }}
shell: cmd
run: |
cd mesa3d
.\systemwidedeploy.cmd 1
.\systemwidedeploy.cmd 5
- name: Download and extract Mesa3D (Windows arm64)
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'arm64' && steps.check_failures.outputs.failed_count > 0 }}
run: |
curl -L -o mesa3d-arm64.zip https://github.com/mmozeiko/build-mesa/releases/download/24.3.2/mesa-llvmpipe-arm64-24.3.2.zip
7z x mesa3d-arm64.zip -oinstall\win64\vc14\bin -y
shell: pwsh
- name: Install CJK Fonts (Windows)
if: ${{ inputs.platform == 'windows' && steps.check_failures.outputs.failed_count > 0 }}
shell: pwsh
@@ -291,11 +302,12 @@ runs:
$failedCount = ($totalLine | ForEach-Object { $_.Line -replace '.*?(\d+) FAILED.*','$1' }) -as [int]
}
}
if ($failedCount -gt 0) {
Write-Error "Number of FAILED tests ($failedCount) exceeds threshold of 0"
echo "FAILED_COUNT=$failedCount" >> $env:GITHUB_ENV
exit 1
}
$threshold = if ("${{ inputs.target-arch }}" -eq "arm64") { 1 } else { 0 }
if ($failedCount -gt $threshold) {
Write-Error "Number of FAILED tests ($failedCount) exceeds threshold of $threshold"
echo "FAILED_COUNT=$failedCount" >> $env:GITHUB_ENV
exit 1
}
Write-Output "Found $failedCount FAILED tests"
}
+4
View File
@@ -8,6 +8,10 @@ inputs:
compiler:
description: 'Compiler (msvc, clang, gcc)'
required: true
target-arch:
description: 'Target architecture (x64, arm64)'
required: false
default: 'x64'
install-artifact-name:
description: 'Name of the artifact containing the installed files'
required: true
+13 -2
View File
@@ -8,6 +8,10 @@ inputs:
compiler:
description: 'Compiler (msvc, clang, gcc)'
required: true
target-arch:
description: 'Target architecture (x64, arm64)'
required: false
default: 'x64'
install-artifact-name:
description: 'Name of the artifact containing the install directory'
required: true
@@ -59,20 +63,27 @@ runs:
path: install
- name: Download and extract Mesa3D (Windows)
if: ${{ inputs.platform == 'windows' }}
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'x64' }}
run: |
curl -L -o mesa3d.7z https://github.com/pal1000/mesa-dist-win/releases/download/24.3.2/mesa3d-24.3.2-release-mingw.7z
7z x mesa3d.7z -omesa3d
shell: pwsh
- name: Run system-wide deployment (Windows)
if: ${{ inputs.platform == 'windows' }}
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'x64' }}
run: |
cd mesa3d
.\systemwidedeploy.cmd 1
.\systemwidedeploy.cmd 5
shell: cmd
- name: Download and extract Mesa3D (Windows arm64)
if: ${{ inputs.platform == 'windows' && inputs.target-arch == 'arm64' }}
run: |
curl -L -o mesa3d-arm64.zip https://github.com/mmozeiko/build-mesa/releases/download/24.3.2/mesa-llvmpipe-arm64-24.3.2.zip
7z x mesa3d-arm64.zip -oinstall\win64\vc14\bin -y
shell: pwsh
- name: Install CJK Fonts (Windows)
if: ${{ inputs.platform == 'windows' }}
run: |
@@ -0,0 +1,30 @@
set exclude_list [list \
"bugs fclasses bug6143" \
"bugs modalg_5 bug24639" \
"bugs modalg_7 bug83" \
"bugs caf bug31918_1" \
"chamfer dist_angle_sequence A5" \
"opengl background bug27836" \
"opengl drivers d3dhost" \
"opengl background srgb" \
"opengl text C4" \
"opengles2 text C4" \
"opengles3 text C4" \
"boolean gdml_private B5" \
"chamfer dist_angle A3" \
"chamfer dist_angle E5" \
"chamfer dist_angle_complex A1" \
"chamfer dist_angle_complex A4" \
"chamfer dist_angle_complex A5" \
"chamfer dist_angle_sequence A1" \
"chamfer dist_angle_sequence A4" \
"caf basic W12" \
"opengles3 general msaa" \
"opengles3 geom interior1" \
"opengles3 geom interior2" \
"opengles3 shadows dir2" \
"opengles3 textures alpha_mask"
]
set exclude_str [join $exclude_list ,]
testgrid -exclude {*}$exclude_str -outdir results/windows-arm64
@@ -88,6 +88,23 @@ jobs:
artifact-name: install-windows-x64
github-token: ${{ secrets.GITHUB_TOKEN }}
prepare-and-build-windows-arm64:
name: Prepare and Build on Windows with MSVC (ARM64)
runs-on: windows-11-arm
steps:
- name: Checkout repository
uses: actions/checkout@v4.2.2
- name: Build OCCT
uses: ./.github/actions/build-occt
with:
platform: windows
compiler: msvc
target-arch: arm64
artifact-name: install-windows-arm64
github-token: ${{ secrets.GITHUB_TOKEN }}
prepare-and-build-macos-x64:
name: Prepare and Build on macOS with Clang (x64)
runs-on: macos-15
@@ -160,6 +177,25 @@ jobs:
test-directory-name: windows-x64
test-script: .github/actions/testgrid/testwindows.tcl
test-windows-arm64:
name: Test on Windows (arm64)
runs-on: windows-11-arm
needs: prepare-and-build-windows-arm64
steps:
- name: Checkout repository
uses: actions/checkout@v4.2.2
- name: Run tests
uses: ./.github/actions/run-tests
with:
platform: windows
compiler: msvc
target-arch: arm64
install-artifact-name: install-windows-arm64
test-directory-name: windows-arm64
test-script: .github/actions/testgrid/testwindowsarm.tcl
retest-windows-x64:
name: Regression Test on Windows (x64)
runs-on: windows-2025
@@ -178,6 +214,25 @@ jobs:
results-artifact-name: results-windows-x64
test-directory-name: windows-x64
retest-windows-arm64:
name: Regression Test on Windows (arm64)
runs-on: windows-11-arm
needs: test-windows-arm64
steps:
- name: Checkout repository
uses: actions/checkout@v4.2.2
- name: Run retest
uses: ./.github/actions/retest-failures
with:
platform: windows
compiler: msvc
target-arch: arm64
install-artifact-name: install-windows-arm64
results-artifact-name: results-windows-arm64
test-directory-name: windows-arm64
test-macos-x64:
name: Test on macOS (x64)
runs-on: macos-15
@@ -267,6 +322,24 @@ jobs:
install-artifact-name: install-windows-x64
artifact-suffix: x64
run-gtest-windows-arm64:
name: Run GTest on Windows with MSVC (arm64)
needs: prepare-and-build-windows-arm64
runs-on: windows-11-arm
steps:
- name: Checkout repository
uses: actions/checkout@v4.2.2
- name: Run GTests
uses: ./.github/actions/run-gtest
with:
platform: windows
compiler: msvc
target-arch: arm64
install-artifact-name: install-windows-arm64
artifact-suffix: arm64
run-gtest-macos-x64:
name: Run GTest on macOS with Clang (x64)
needs: prepare-and-build-macos-x64