|
| 1 | +on: |
| 2 | + workflow_call: |
| 3 | + inputs: |
| 4 | + runner: |
| 5 | + description: 'Machine on which the tests would run' |
| 6 | + type: string |
| 7 | + required: true |
| 8 | + container: |
| 9 | + description: 'JSON to be converted to the value of the "container" configuration for the job' |
| 10 | + type: string |
| 11 | + required: false |
| 12 | + default: '{"image": null}' |
| 13 | + event-name: |
| 14 | + description: 'Name of the event that triggered the workflow' |
| 15 | + type: string |
| 16 | + required: false |
| 17 | + os: |
| 18 | + description: 'OS that is used for building in the form of "ubuntu_20_04"' |
| 19 | + type: string |
| 20 | + required: true |
| 21 | + |
| 22 | +permissions: read-all |
| 23 | + |
| 24 | +env: |
| 25 | + PIP_CACHE_PATH: /mount/caches/pip/linux |
| 26 | + TARGET_BRANCH: ${{ github.base_ref || github.event.merge_group.base_ref || github.ref }} |
| 27 | + |
| 28 | +jobs: |
| 29 | + Build: |
| 30 | + name: Build |
| 31 | + timeout-minutes: 150 |
| 32 | + runs-on: ${{ inputs.runner }} |
| 33 | + container: ${{ fromJSON(inputs.container) }} |
| 34 | + defaults: |
| 35 | + run: |
| 36 | + shell: bash |
| 37 | + env: |
| 38 | + DEBIAN_FRONTEND: noninteractive |
| 39 | + CMAKE_BUILD_TYPE: 'Release' |
| 40 | + CMAKE_CXX_COMPILER_LAUNCHER: sccache |
| 41 | + CMAKE_C_COMPILER_LAUNCHER: sccache |
| 42 | + SCCACHE_IGNORE_SERVER_IO_ERROR: 1 |
| 43 | + SCCACHE_SERVER_PORT: 35555 |
| 44 | + SCCACHE_ERROR_LOG: /__w/npu_compiler/sccache_log.txt |
| 45 | + SCCACHE_LOG: warn |
| 46 | + GITHUB_WORKSPACE: /__w/npu_compiler/npu_compiler |
| 47 | + OPENVINO_REPO: /__w/npu_compiler/npu_compiler/openvino |
| 48 | + NPU_COMPILER_REPO: /__w/npu_compiler/npu_compiler/npu_compiler |
| 49 | + INSTALL_DIR: /__w/npu_compiler/npu_compiler/openvino_install |
| 50 | + INSTALL_TEST_DIR: /__w/npu_compiler/npu_compiler/tests_install |
| 51 | + BUILD_DIR: /__w/npu_compiler/npu_compiler/openvino_build |
| 52 | + SCCACHE_AZURE_KEY_PREFIX: ${{ inputs.os }}_${{ inputs.arch }}_Release |
| 53 | + ARTIFACTS_SHARE: "/mount/build-artifacts" |
| 54 | + PRODUCT_TYPE: public_linux_${{ inputs.os }}_${{ inputs.arch }}_release |
| 55 | + steps: |
| 56 | + - name: Get integrated OpenVINO version |
| 57 | + id: read_openvino_sha |
| 58 | + run: | |
| 59 | + COMMIT_SHA=$(cat ./validation/openvino_config.json | sed -En 's/.*"[A-Za-z0-9]+"\s*:\s*"([a-f0-9]{40})".*/\1/p' |
| 60 | + echo "commit_sha=$COMMIT_SHA" >> $GITHUB_OUTPUT |
| 61 | +
|
| 62 | + - name: Clone OpenVINO |
| 63 | + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 |
| 64 | + timeout-minutes: 15 |
| 65 | + with: |
| 66 | + repository: 'openvinotoolkit/openvino' |
| 67 | + path: ${{ env.OPENVINO_REPO }} |
| 68 | + submodules: 'true' |
| 69 | + ref: ${{ steps.read_openvino_sha.outputs.commit_sha }} |
| 70 | + |
| 71 | + - name: Clone NPU Compiler |
| 72 | + uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2 |
| 73 | + timeout-minutes: 15 |
| 74 | + with: |
| 75 | + path: ${{ env.NPU_COMPILER_REPO }} |
| 76 | + submodules: 'true' |
| 77 | + |
| 78 | + - name: System info |
| 79 | + uses: openvinotoolkit/openvino/.github/actions/system_info |
0 commit comments