|
| 1 | +# This CI workflow is triggered by: |
| 2 | +# - scheduled run |
| 3 | +# |
| 4 | +# In the scheduled run, we run all targets from amdgpu_family_matrix.py and amdgpu_family_matrix_xfail.py |
| 5 | +# As some of these builds are xfail, we allow errors to occur with `continue-on-error`, where the job will fail but the workflow is green |
| 6 | + |
| 7 | +name: CI Weekly (New) |
| 8 | + |
| 9 | +on: |
| 10 | + # For AMD GPU families that expect_failure, we run builds and tests from this scheduled trigger |
| 11 | + schedule: |
| 12 | + - cron: "0 2 * * 0" # Runs weekly at 2 AM UTC every Sunday |
| 13 | + workflow_dispatch: |
| 14 | + inputs: |
| 15 | + linux_amdgpu_families: |
| 16 | + type: string |
| 17 | + description: "Insert comma-separated list of Linux GPU families to build and test. ex: gfx94X, gfx1201X" |
| 18 | + default: "" |
| 19 | + linux_amdgpu_families_predefined_groups: |
| 20 | + type: string |
| 21 | + description: "Insert comma-separated list of predefined group(s) of Linux GPU families found in build_tools/github_actions/new_amdgpu_family_matrix.py (e.g. amdgpu_presubmit)" |
| 22 | + default: "" |
| 23 | + linux_use_prebuilt_artifacts: |
| 24 | + type: boolean |
| 25 | + description: "If enabled, the CI will pull Linux artifacts using artifact_run_id and only run tests" |
| 26 | + windows_amdgpu_families: |
| 27 | + type: string |
| 28 | + description: "Insert comma-separated list of Windows GPU families to build and test. ex: gfx94X, gfx1201X" |
| 29 | + default: "" |
| 30 | + windows_amdgpu_families_predefined_groups: |
| 31 | + type: string |
| 32 | + description: "Insert comma-separated list of predefined group(s) of Windows GPU families found in build_tools/github_actions/new_amdgpu_family_matrix.py (e.g. amdgpu_presubmit)" |
| 33 | + default: "" |
| 34 | + windows_use_prebuilt_artifacts: |
| 35 | + type: boolean |
| 36 | + description: "If enabled, the CI will pull Windows artifacts using artifact_run_id and only run tests" |
| 37 | + artifact_run_id: |
| 38 | + type: string |
| 39 | + description: "If provided, the tests will run on this artifact ID" |
| 40 | + default: "" |
| 41 | + |
| 42 | +permissions: |
| 43 | + contents: read |
| 44 | + |
| 45 | +concurrency: |
| 46 | + # A PR number if a pull request and otherwise the commit hash. This cancels |
| 47 | + # queued and in-progress runs for the same PR (presubmit) or commit |
| 48 | + # (postsubmit). The workflow name is prepended to avoid conflicts between |
| 49 | + # different workflows. |
| 50 | + group: ${{ github.workflow }}-${{ github.event.number || github.sha }} |
| 51 | + cancel-in-progress: true |
| 52 | + |
| 53 | +jobs: |
| 54 | + setup: |
| 55 | + uses: ./.github/workflows/new_setup.yml |
| 56 | + with: |
| 57 | + # ci triggered via cron do not accept input values so we have to set them here |
| 58 | + linux_amdgpu_families: ${{ github.event_name == 'schedule' && 'gfx1151' || github.event.inputs.linux_amdgpu_families }} |
| 59 | + linux_amdgpu_families_predefined_groups: ${{ github.event_name == 'schedule' && '' || github.event.inputs.linux_amdgpu_families_predefined_groups }} |
| 60 | + linux_use_prebuilt_artifacts: ${{ github.event_name == 'schedule' && '' || github.event.inputs.linux_use_prebuilt_artifacts }} |
| 61 | + windows_amdgpu_families: ${{ github.event_name == 'schedule' && '' || github.event.inputs.windows_amdgpu_families }} |
| 62 | + windows_amdgpu_families_predefined_groups: ${{ github.event_name == 'schedule' && '' || github.event.inputs.windows_amdgpu_families_predefined_groups }} |
| 63 | + windows_use_prebuilt_artifacts: ${{ github.event_name == 'schedule' && '' || github.event.inputs.windows_use_prebuilt_artifacts }} |
| 64 | + artifact_run_id: ${{ github.event_name == 'schedule' && '' || github.event.inputs.artifact_run_id }} |
| 65 | + |
| 66 | + setup_cmake4: |
| 67 | + uses: ./.github/workflows/new_setup.yml |
| 68 | + with: |
| 69 | + # ci triggered via cron do not accept input values so we have to set them here |
| 70 | + linux_amdgpu_families: ${{ github.event_name == 'schedule' && 'gfx1151' || github.event.inputs.linux_amdgpu_families }} |
| 71 | + linux_amdgpu_families_predefined_groups: ${{ github.event_name == 'schedule' && '' || github.event.inputs.linux_amdgpu_families_predefined_groups }} |
| 72 | + linux_use_prebuilt_artifacts: ${{ github.event_name == 'schedule' && '' || github.event.inputs.linux_use_prebuilt_artifacts }} |
| 73 | + windows_amdgpu_families: ${{ github.event_name == 'schedule' && '' || github.event.inputs.windows_amdgpu_families }} |
| 74 | + windows_amdgpu_families_predefined_groups: ${{ github.event_name == 'schedule' && '' || github.event.inputs.windows_amdgpu_families_predefined_groups }} |
| 75 | + windows_use_prebuilt_artifacts: ${{ github.event_name == 'schedule' && '' || github.event.inputs.windows_use_prebuilt_artifacts }} |
| 76 | + artifact_run_id: ${{ github.event_name == 'schedule' && '' || github.event.inputs.artifact_run_id }} |
| 77 | + # ghcr.io/rocm/therock_build_manylinux_x86_64:users-lpromber-DockerCmake4 |
| 78 | + container_image_linux: "ghcr.io/rocm/therock_build_manylinux_x86_64@sha256:60d4208c75dfe3025d0744c336729088774758fa06eea5cc622787ba86416425" |
| 79 | + # we always want to build and not use artifacts |
| 80 | + force_build: "true" |
| 81 | + |
| 82 | + weekly_linux_cmake4_build_and_test: |
| 83 | + name: 'Weekly: Linux CMake 4' |
| 84 | + needs: setup_cmake4 |
| 85 | + if: >- |
| 86 | + ${{ needs.setup_cmake4.outputs.amdgpu_family_matrix.linux != '[]' }} |
| 87 | + strategy: |
| 88 | + fail-fast: false |
| 89 | + matrix: |
| 90 | + linux_config: ${{ fromJSON(needs.setup_cmake4.outputs.amdgpu_family_matrix.linux) }} |
| 91 | + uses: ./.github/workflows/new_ci_linux.yml |
| 92 | + secrets: inherit |
| 93 | + with: |
| 94 | + amdgpu_families_config: ${{ matrix.linux_config }} |
| 95 | + artifact_run_id: ${{ inputs.artifact_run_id }} |
| 96 | + linux_use_prebuilt_artifacts: ${{ inputs.linux_use_prebuilt_artifacts == true && 'true' || 'false' }} |
| 97 | + container_image: ${{ fromJSON(needs.setup_cmake4.outputs.container_image_linux) }} |
| 98 | + permissions: |
| 99 | + contents: read |
| 100 | + id-token: write |
| 101 | + |
| 102 | + # windows_build_and_test: |
| 103 | + # name: Windows |
| 104 | + # needs: setup |
| 105 | + # if: >- |
| 106 | + # ${{ |
| 107 | + # needs.setup.outputs.windows_amdgpu_families != '[]' && |
| 108 | + # needs.setup.outputs.enable_build_jobs == 'true' |
| 109 | + # }} |
| 110 | + # strategy: |
| 111 | + # fail-fast: false |
| 112 | + # matrix: |
| 113 | + # families: ${{ fromJSON(needs.setup.outputs.windows_amdgpu_families) }} |
| 114 | + # uses: ./.github/workflows/ci_windows.yml |
| 115 | + # with: |
| 116 | + # amdgpu_families: ${{ matrix.families.family }} |
| 117 | + # test_runs_on: ${{ matrix.families.test-runs-on }} |
| 118 | + # artifact_run_id: ${{ inputs.artifact_run_id }} |
| 119 | + # extra_cmake_options: ${{ matrix.extra_cmake_options }} |
| 120 | + # expect_failure: ${{ matrix.families.expect_failure == true }} |
| 121 | + # windows_use_prebuilt_artifacts: ${{ inputs.windows_use_prebuilt_artifacts == true && 'true' || 'false' }} |
| 122 | + # permissions: |
| 123 | + # contents: read |
| 124 | + # id-token: write |
| 125 | + |
| 126 | + # build_python_packages: |
| 127 | + # name: Build Python Packages |
| 128 | + # uses: ./.github/workflows/build_python_packages.yml |
0 commit comments