[llvm] Add pre-merge workflow for HLSL testing (PR #122184)

Chris B via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 8 19:18:29 PST 2025


================
@@ -0,0 +1,157 @@
+name: HLSL Test
+
+permissions:
+  contents: read
+
+on:
+  workflow_dispatch:
+    inputs:
+      LLVM-Ref:
+        description: 'Test Suite Branch'
+        required: false
+        default: 'main'
+        type: string
+      LLVM-branch:
+        description: 'LLVM Branch'
+        required: false
+        default: 'main'
+        type: string
+      DXC-branch:
+        description: 'DXC Branch'
+        required: false
+        default: 'main'
+        type: string
+      BuildType:
+        description: 'Build Type'
+        required: false
+        default: 'Release'
+        type: choice
+        options:
+        - Release
+        - RelWithDebInfo
+        - Debug
+      TestTarget:
+        required: false
+        default: 'check-hlsl'
+        type: string
+      Test-Clang:
+        required: true
+        type: choice
+        options:
+        - On
+        - Off
+      SKU:
+        required: true
+        type: choice
+        options:
+        - hlsl-metal
+      LLVM-ExtraCMakeArgs:
+        description: 'Extra CMake Args for LLVM'
+        required: false
+        default: ''
+        type: string
+  workflow_call:
+    inputs:
+      OffloadTest-branch:
+        description: 'Test Suite Branch'
+        required: false
+        default: 'main'
+        type: string
+      LLVM-branch:
+        description: 'LLVM Branch'
+        required: false
+        default: 'main'
+        type: string
+      DXC-branch:
+        description: 'DXC Branch'
+        required: false
+        default: 'main'
+        type: string
+      SKU:
+        required: true
+        type: string
+      BuildType:
+        description: 'Build Type'
+        required: false
+        default: 'Release'
+        type: string
+      Test-Clang:
+        required: false
+        default: 'On'
+        type: string
+      TestTarget:
+        required: false
+        default: 'check-hlsl'
+        type: string
+      LLVM-ExtraCMakeArgs:
+        description: 'Extra CMake Args for LLVM'
+        required: false
+        default: ''
+        type: string
+
+jobs:
+  build:
+    runs-on: [self-hosted, "${{ inputs.SKU }}"]
+    steps:
+      - name: Checkout DXC
+        uses: actions/checkout at v4
+        with:
+          repository: Microsoft/DirectXShaderCompiler
+          ref: ${{ inputs.DXC-branch }}
+          path: DXC
+          fetch-depth: 1
+          submodules: true
+      - name: Checkout LLVM
+        uses: actions/checkout at v4
+        with:
+          repository: llvm/llvm-project
+          ref: ${{ inputs.LLVM-branch }}
+          path: llvm-project
+          fetch-depth: 1
+      - name: Checkout OffloadTest
+        uses: actions/checkout at v4
+        with:
+          repository: llvm-beanz/offload-test-suite
+          ref: ${{ inputs.OffloadTest-branch }}
+          path: OffloadTest
+          fetch-depth: 1
+      - name: Checkout Golden Images
+        uses: actions/checkout at v4
+        with:
+          repository: llvm-beanz/offload-golden-images
----------------
llvm-beanz wrote:

They are expected to mostly remain static, but also expected to be significant in size as we flesh out the test coverage. They're in a separate repository from the other tests because they are optional. Most tests do not rely on image comparison for correctness.

https://github.com/llvm/llvm-project/pull/122184


More information about the llvm-commits mailing list