From 4c0650c44e3154c864e76f708020a21b5c2d19c3 Mon Sep 17 00:00:00 2001 From: alexxu-amd <159800977+alexxu-amd@users.noreply.github.com> Date: Mon, 12 Aug 2024 14:23:43 -0400 Subject: [PATCH] External CI: Add hipBLAS-common pipeline (#3572) * Add hipBLAS-common pipeline * change task name - to _ * add hipblas-common pipeline id and default branch * Update MIOpen.yml * add variables for manual test * delete manual installation of hipblas-common * reorder dependencies, add hipblas-common * add variables for manual test * add hipBLAS-common to hipBLASLt * Change GPU target * revert variables from manual test * Update MIOpen.yml * Update MIOpen.yml * remove hipBLAS-common dependency * revert change to hipblaslt * remove an unused cmake flag --- .azuredevops/components/hipBLAS-common.yml | 62 +++++++++++++++++++ .azuredevops/components/hipBLAS.yml | 8 +-- .azuredevops/tag-builds/hipBLAS-common.yml | 29 +++++++++ .../templates/steps/artifact-download.yml | 1 + .../templates/steps/dependencies-rocm.yml | 2 + 5 files changed, 98 insertions(+), 4 deletions(-) create mode 100644 .azuredevops/components/hipBLAS-common.yml create mode 100644 .azuredevops/tag-builds/hipBLAS-common.yml diff --git a/.azuredevops/components/hipBLAS-common.yml b/.azuredevops/components/hipBLAS-common.yml new file mode 100644 index 000000000..2fb39a591 --- /dev/null +++ b/.azuredevops/components/hipBLAS-common.yml @@ -0,0 +1,62 @@ +parameters: +- name: checkoutRepo + type: string + default: 'self' +- name: checkoutRef + type: string + default: '' +- name: aptPackages + type: object + default: + - cmake + - ninja-build + - git + - wget + - python3-pip +- name: rocmDependencies + type: object + default: + - rocm-cmake + - llvm-project + - ROCR-Runtime + - clr + - rocminfo + +jobs: +- job: hipBLAS_common + variables: + - group: common + - name: ROCM_PATH + value: $(Agent.BuildDirectory)/rocm + - template: /.azuredevops/variables-global.yml + pool: + vmImage: ${{ variables.BASE_BUILD_POOL }} + workspace: + clean: all + steps: + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/dependencies-other.yml + parameters: + aptPackages: ${{ parameters.aptPackages }} + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/preamble.yml + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/checkout.yml + parameters: + checkoutRepo: ${{ parameters.checkoutRepo }} +# CI case: download latest default branch build + - ${{ if eq(parameters.checkoutRef, '') }}: + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/dependencies-rocm.yml + parameters: + dependencyList: ${{ parameters.rocmDependencies }} + dependencySource: staging +# manual build case: triggered by ROCm/ROCm repo + - ${{ if ne(parameters.checkoutRef, '') }}: + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/dependencies-rocm.yml + parameters: + dependencyList: ${{ parameters.rocmDependencies }} + dependencySource: tag-builds + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/build-cmake.yml + parameters: + extraBuildFlags: >- + -DCMAKE_PREFIX_PATH=$(Agent.BuildDirectory)/rocm + -DCMAKE_CXX_COMPILER=$(Agent.BuildDirectory)/rocm/llvm/bin/amdclang++ + -GNinja + - template: ${{ variables.CI_TEMPLATE_PATH }}/steps/artifact-upload.yml diff --git a/.azuredevops/components/hipBLAS.yml b/.azuredevops/components/hipBLAS.yml index fe836a078..c25e3e051 100644 --- a/.azuredevops/components/hipBLAS.yml +++ b/.azuredevops/components/hipBLAS.yml @@ -20,16 +20,16 @@ parameters: - name: rocmDependencies type: object default: - - rocm-cmake - - llvm-project - - ROCR-Runtime + - aomp - clr + - llvm-project + - rocm-cmake + - ROCR-Runtime - rocminfo - rocprofiler-register - rocBLAS - rocSPARSE - rocSOLVER - - aomp jobs: - job: hipBLAS diff --git a/.azuredevops/tag-builds/hipBLAS-common.yml b/.azuredevops/tag-builds/hipBLAS-common.yml new file mode 100644 index 000000000..c2314cf5b --- /dev/null +++ b/.azuredevops/tag-builds/hipBLAS-common.yml @@ -0,0 +1,29 @@ +variables: +- group: common +- template: /.azuredevops/variables-global.yml + +parameters: +- name: checkoutRef + type: string + default: develop + +resources: + repositories: + - repository: pipelines_repo + type: github + endpoint: ROCm + name: ROCm/ROCm + - repository: release_repo + type: github + endpoint: ROCm + name: ROCm/hipBLAS-common + ref: ${{ parameters.checkoutRef }} + +trigger: none +pr: none + +jobs: + - template: ${{ variables.CI_COMPONENT_PATH }}/hipBLAS-common.yml + parameters: + checkoutRepo: release_repo + checkoutRef: ${{ parameters.checkoutRef }} diff --git a/.azuredevops/templates/steps/artifact-download.yml b/.azuredevops/templates/steps/artifact-download.yml index 8858dbe20..9f019eef1 100644 --- a/.azuredevops/templates/steps/artifact-download.yml +++ b/.azuredevops/templates/steps/artifact-download.yml @@ -31,6 +31,7 @@ parameters: HIP: develop hipBLAS: develop hipBLASLt: develop + hipBLAS-common: develop hipCUB: develop hipFFT: develop hipfort: develop diff --git a/.azuredevops/templates/steps/dependencies-rocm.yml b/.azuredevops/templates/steps/dependencies-rocm.yml index 8d9e85f55..82015722b 100644 --- a/.azuredevops/templates/steps/dependencies-rocm.yml +++ b/.azuredevops/templates/steps/dependencies-rocm.yml @@ -39,6 +39,7 @@ parameters: HIP: $(hip-pipeline-id) hipBLAS: $(hipblas-pipeline-id) hipBLASLt: $(hipblaslt-pipeline-id) + hipBLAS-common: $(hipblas-common-pipeline-id) hipCUB: $(hipcub-pipeline-id) hipFFT: $(hipfft-pipeline-id) hipfort: $(hipfort-pipeline-id) @@ -94,6 +95,7 @@ parameters: HIP: $(hip-tagged-pipeline-id) hipBLAS: $(hipblas-tagged-pipeline-id) hipBLASLt: $(hipblaslt-tagged-pipeline-id) + hipBLAS-common: $(hipblas-common-tagged-pipeline-id) hipCUB: $(hipcub-tagged-pipeline-id) hipFFT: $(hipfft-tagged-pipeline-id) hipfort: $(hipfort-tagged-pipeline-id)