From 1858821074ff8fc52e2cf4a8866fe91d2fd29c7b Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 13 Oct 2025 11:41:17 +0000 Subject: [PATCH 01/85] Add Action --- .github/workflows/CI.yml | 33 ++++++++ .github/workflows/_Clone-linux.yml | 110 +++++++++++++++++++++++++ .github/workflows/_Codestyle-Check.yml | 82 ++++++++++++++++++ 3 files changed, 225 insertions(+) create mode 100644 .github/workflows/CI.yml create mode 100644 .github/workflows/_Clone-linux.yml create mode 100644 .github/workflows/_Codestyle-Check.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml new file mode 100644 index 00000000000..2e7ad2102a0 --- /dev/null +++ b/.github/workflows/CI.yml @@ -0,0 +1,33 @@ +name: CI + +on: + pull_request: + types: [opened, synchronize] + branches: [develop, release/**, fleety_*] + +permissions: read-all + +concurrency: + group: ${{ github.event.pull_request.number }}-${{ github.workflow }} + cancel-in-progress: true + +env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + +jobs: + clone: + name: Clone-linux + uses: ./.github/workflows/_Clone-linux.yml + with: + workflow-name: 'CI' + + Codestyle-Check: + name: Codestyle-Check + uses: ./.github/workflows/_Codestyle-Check.yml + needs: [clone] + + GCU: + name: PR-CI-GCU + uses: ./.github/workflows/_GCU.yml + needs: [clone, Codestyle-Check] diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml new file mode 100644 index 00000000000..b617f7c503f --- /dev/null +++ b/.github/workflows/_Clone-linux.yml @@ -0,0 +1,110 @@ +name: Clone-linux + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + outputs: + can-skip: + value: ${{ jobs.clone.outputs.can-skip }} + slice-check: + value: ${{ jobs.clone.outputs.slice-check }} + +permissions: read-all + +defaults: + run: + shell: bash + +env: + PR_ID: ${{ github.event.pull_request.number || '0' }} + COMMIT_ID: ${{ github.event.pull_request.head.sha || github.sha }} + ci_scripts: ${{ github.workspace }}/ci + BRANCH: ${{ github.event.pull_request.base.ref || github.ref_name }} + +jobs: + clone: + name: Clone PaddlecustomDevice + if: ${{ github.repository_owner == 'PaddlePaddle' }} + outputs: + can-skip: ${{ steps.check-bypass.outputs.can-skip }} + slice-check: ${{ steps.check-execution.outputs.slice-check }} + runs-on: + group: HK-Clone + + steps: + - name: Clone paddle + uses: actions/checkout@v4 + with: + ref: ${{ github.event.pull_request.base.ref }} + submodules: 'recursive' + fetch-depth: 1000 + + - name: Merge PR to test branch + id: check-execution + if: ${{ inputs.is_pr == 'true' }} + run: | + git config --unset http.https://github.com/.extraheader + git submodule foreach --recursive sh -c "git config --local --unset-all 'http.https://github.com/.extraheader'" + git submodule foreach --recursive sh -c "git config remote.origin.fetch '+refs/heads/*:refs/remotes/origin/*'" + git switch ${{ github.event.pull_request.base.ref }} + set +e + git branch -D test + set -e + git gc + git switch -c test + git config user.name "PaddleCI" + git config user.email "paddle_ci@example.com" + git fetch origin pull/${{ github.event.pull_request.number }}/head:pr + git merge --no-ff pr + git submodule update --init + git branch -d pr + source ${ci_scripts}/check_execution.sh + bash ${ci_scripts}/third_party_tag.sh + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: ${{ inputs.workflow-name }} + + - name: Download bos client + env: + home_path: "/home/paddle/actions-runner/" + bos_file: "/home/paddle/actions-runner/bos/BosClient.py" + run: | + if [ ! -f "${bos_file}" ]; then + wget -q --no-proxy -O ${home_path}/bos_new.tar.gz https://xly-devops.bj.bcebos.com/home/bos_new.tar.gz --no-check-certificate + mkdir ${home_path}/bos + tar xf ${home_path}/bos_new.tar.gz -C ${home_path}/bos + fi + + - name: Push paddle-action.tar.gz to bos + env: + AK: paddle + SK: paddle + bos_file: "/home/paddle/actions-runner/bos/BosClient.py" + run: | + cd .. + tar -I 'zstd -T0' -cf PaddlecustomDevice.tar.gz PaddlecustomDevice + echo "::group::Install bce-python-sdk" + python -m pip install bce-python-sdk==0.8.74 + echo "::endgroup::" + python ${bos_file} PaddlecustomDevice.tar.gz paddle-github-action/PaddleCustomDevice/PR/${{ inputs.clone_dir }}/${PR_ID}/${COMMIT_ID} + rm PaddlecustomDevice.tar.gz + cd - + git switch ${BRANCH} + set +e + git branch -D test + git gc diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml new file mode 100644 index 00000000000..3e6c15f984b --- /dev/null +++ b/.github/workflows/_Codestyle-Check.yml @@ -0,0 +1,82 @@ +name: Codestyle-Check + +on: + pull_request: + branches: ["develop"] + +jobs: + pre-commit: + name: Pre Commit + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: APPROVAL + env: + PR_ID: ${{ github.event.pull_request.number }} + BRANCH: develop + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - name: Check docker image and run container + env: + python: "python3.10" + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + docker_image: iregistry.baidu-int.com/tiangexiao/paddle-npu:cann800-910B-ubuntu18-x86_64 + run: | + container_name=${TASK}-${core_index}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker container ls -a --filter "name=paddle-CI-*-api-benchmark-${core_index}*" --format "{{.ID}}" | xargs -r docker rm -f + docker container ls -a --filter "name=api_benchmark_ci_baseline_" --format "{{.ID}} {{.CreatedAt}}" | awk '$2 <= "'$(date -d '1 day ago' +'%Y-%m-%d')'" {print $1}' | xargs -r docker rm -f + docker run -d -t --name ${container_name} --shm-size=128g \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/paddle \ + -e python \ + -e core_index \ + -e BRANCH \ + -e PR_ID \ + -e COMMIT_ID \ + -e RUN_ID \ + -e wheel_link \ + -e work_dir \ + -e PADDLE_ROOT \ + -e ci_scripts \ + -e GIT_PR_ID \ + -e PADDLE_VERSION \ + -e no_proxy \ + -e CI_name \ + -e GITHUB_API_TOKEN \ + -w /paddle --network host ${docker_image} + + - name: Download PaddleCustomDevice.tar.gz + run: | + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleTest.tar.gz" + # git config --global --add safe.directory ${work_dir} + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git fetch origin pull/${PR_ID}/merge + git checkout -b test FETCH_HEAD + + - name: Setup python3.12 + if: steps.check-bypass.outputs.can-skip != 'true' + uses: actions/setup-python@v5 + with: + python-version: '3.12' + cache: 'pip' + + - name: Install dependencies + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + pip install pre-commit==2.17.0 cpplint==1.6.0 clang-format==13.0.0 + + - name: Check pre-commit + if: steps.check-bypass.outputs.can-skip != 'true' + env: + SKIP_CLANG_TIDY_CHECK: "ON" + run: | + set +e + bash -x tools/codestyle/pre_commit.sh;EXCODE=$? + exit $EXCODE From 5357263691ca29d37ab12a4e2a5cf54924967c10 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 01:46:07 +0000 Subject: [PATCH 02/85] update --- .github/workflows/_Codestyle-Check.yml | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 3e6c15f984b..dcdd08695c3 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -1,8 +1,19 @@ name: Codestyle-Check on: - pull_request: - branches: ["develop"] + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' jobs: pre-commit: @@ -13,6 +24,7 @@ jobs: env: PR_ID: ${{ github.event.pull_request.number }} BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-cpu steps: - name: Cleanup From 062331b4665468ea1e81f54697b902d72ef2291b Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 01:50:27 +0000 Subject: [PATCH 03/85] update --- .github/workflows/CI.yml | 5 ----- 1 file changed, 5 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 2e7ad2102a0..0b5ee53bbd0 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -26,8 +26,3 @@ jobs: name: Codestyle-Check uses: ./.github/workflows/_Codestyle-Check.yml needs: [clone] - - GCU: - name: PR-CI-GCU - uses: ./.github/workflows/_GCU.yml - needs: [clone, Codestyle-Check] From ba83b9221da861808803b2878434aa688451aa67 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 02:43:45 +0000 Subject: [PATCH 04/85] update --- .github/workflows/_Clone-linux.yml | 20 ++++++++------------ .github/workflows/_Codestyle-Check.yml | 2 +- 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index b617f7c503f..0ecb55f87d1 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -43,7 +43,7 @@ jobs: group: HK-Clone steps: - - name: Clone paddle + - name: Clone PaddleCustomDevice uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.base.ref }} @@ -54,20 +54,16 @@ jobs: id: check-execution if: ${{ inputs.is_pr == 'true' }} run: | - git config --unset http.https://github.com/.extraheader - git submodule foreach --recursive sh -c "git config --local --unset-all 'http.https://github.com/.extraheader'" - git submodule foreach --recursive sh -c "git config remote.origin.fetch '+refs/heads/*:refs/remotes/origin/*'" - git switch ${{ github.event.pull_request.base.ref }} - set +e - git branch -D test - set -e - git gc - git switch -c test + set -x git config user.name "PaddleCI" git config user.email "paddle_ci@example.com" - git fetch origin pull/${{ github.event.pull_request.number }}/head:pr - git merge --no-ff pr + git fetch origin pull/${{ github.event.pull_request.number }}/head + git checkout -b test FETCH_HEAD + echo 123 + git merge --no-edit {{ env.BRANCH }} + echo 456 git submodule update --init + echo 789 git branch -d pr source ${ci_scripts}/check_execution.sh bash ${ci_scripts}/third_party_tag.sh diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index dcdd08695c3..cce0d8d2b82 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -68,7 +68,7 @@ jobs: wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleTest.tar.gz" # git config --global --add safe.directory ${work_dir} - tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 git fetch origin pull/${PR_ID}/merge git checkout -b test FETCH_HEAD From 7a42c65068cb212bc4c9e40a4528ed71a47141c0 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 02:51:34 +0000 Subject: [PATCH 05/85] update --- .github/workflows/_Clone-linux.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index 0ecb55f87d1..55efaec7a12 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -60,7 +60,7 @@ jobs: git fetch origin pull/${{ github.event.pull_request.number }}/head git checkout -b test FETCH_HEAD echo 123 - git merge --no-edit {{ env.BRANCH }} + git merge --no-edit ${BRANCH} echo 456 git submodule update --init echo 789 From 8b9ef34348330d09bbf53addbc41f8367d0ffa32 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 02:56:56 +0000 Subject: [PATCH 06/85] update --- .github/workflows/_Clone-linux.yml | 6 ------ 1 file changed, 6 deletions(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index 55efaec7a12..cb39c4913d8 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -59,14 +59,8 @@ jobs: git config user.email "paddle_ci@example.com" git fetch origin pull/${{ github.event.pull_request.number }}/head git checkout -b test FETCH_HEAD - echo 123 git merge --no-edit ${BRANCH} - echo 456 git submodule update --init - echo 789 - git branch -d pr - source ${ci_scripts}/check_execution.sh - bash ${ci_scripts}/third_party_tag.sh - name: Check bypass id: check-bypass From 9d152dc21218d0ad52ff3bdd70a29eeaeb210b36 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 03:00:03 +0000 Subject: [PATCH 07/85] update --- .github/workflows/_Clone-linux.yml | 7 ------- 1 file changed, 7 deletions(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index cb39c4913d8..0ac1ba95070 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -62,13 +62,6 @@ jobs: git merge --no-edit ${BRANCH} git submodule update --init - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: ${{ inputs.workflow-name }} - - name: Download bos client env: home_path: "/home/paddle/actions-runner/" From f73acc6ff7c9b051d043bc7f16aee6f79716f826 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 03:13:01 +0000 Subject: [PATCH 08/85] update --- .github/workflows/_Clone-linux.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index 0ac1ba95070..58d76ebd52e 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -60,7 +60,7 @@ jobs: git fetch origin pull/${{ github.event.pull_request.number }}/head git checkout -b test FETCH_HEAD git merge --no-edit ${BRANCH} - git submodule update --init + git submodule sync && git submodule update --init - name: Download bos client env: @@ -79,7 +79,10 @@ jobs: SK: paddle bos_file: "/home/paddle/actions-runner/bos/BosClient.py" run: | + set -x cd .. + pwd + ls tar -I 'zstd -T0' -cf PaddlecustomDevice.tar.gz PaddlecustomDevice echo "::group::Install bce-python-sdk" python -m pip install bce-python-sdk==0.8.74 From 49dffaed61fc08f0874a5bcfb97b83630c9be9b2 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 03:18:50 +0000 Subject: [PATCH 09/85] update --- .github/workflows/_Clone-linux.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index 58d76ebd52e..e27be376ada 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -83,6 +83,7 @@ jobs: cd .. pwd ls + rm -rf PaddlecustomDevice.tar.gz tar -I 'zstd -T0' -cf PaddlecustomDevice.tar.gz PaddlecustomDevice echo "::group::Install bce-python-sdk" python -m pip install bce-python-sdk==0.8.74 From 5a54ef52517dd9fdd898d6305465349f295c5c19 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 03:24:48 +0000 Subject: [PATCH 10/85] update --- .github/workflows/_Clone-linux.yml | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index e27be376ada..6ea34f7d073 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -83,13 +83,12 @@ jobs: cd .. pwd ls - rm -rf PaddlecustomDevice.tar.gz - tar -I 'zstd -T0' -cf PaddlecustomDevice.tar.gz PaddlecustomDevice + tar -I 'zstd -T0' -cf PaddleCustomDevice.tar.gz PaddleCustomDevice echo "::group::Install bce-python-sdk" python -m pip install bce-python-sdk==0.8.74 echo "::endgroup::" - python ${bos_file} PaddlecustomDevice.tar.gz paddle-github-action/PaddleCustomDevice/PR/${{ inputs.clone_dir }}/${PR_ID}/${COMMIT_ID} - rm PaddlecustomDevice.tar.gz + python ${bos_file} PaddleCustomDevice.tar.gz paddle-github-action/PaddleCustomDevice/PR/${{ inputs.clone_dir }}/${PR_ID}/${COMMIT_ID} + rm PaddleCustomDevice.tar.gz cd - git switch ${BRANCH} set +e From 410441560a83dfbdb9d245ae24b01b51cb1ba39b Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 06:13:15 +0000 Subject: [PATCH 11/85] update --- .github/workflows/_Codestyle-Check.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index cce0d8d2b82..803beba9ab6 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -23,6 +23,7 @@ jobs: group: APPROVAL env: PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} BRANCH: develop TASK: paddle-CI-${{ github.event.pull_request.number }}-cpu From b0dbf758c1217df356645b7558b426648f37935d Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 06:38:17 +0000 Subject: [PATCH 12/85] update --- .github/workflows/_Clone-linux.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index 6ea34f7d073..c29123c2eb6 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -87,7 +87,7 @@ jobs: echo "::group::Install bce-python-sdk" python -m pip install bce-python-sdk==0.8.74 echo "::endgroup::" - python ${bos_file} PaddleCustomDevice.tar.gz paddle-github-action/PaddleCustomDevice/PR/${{ inputs.clone_dir }}/${PR_ID}/${COMMIT_ID} + python ${bos_file} PaddleCustomDevice.tar.gz paddle-github-action/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID} rm PaddleCustomDevice.tar.gz cd - git switch ${BRANCH} From 866600aaf65ee63958527b85f69e4252a71b3248 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 06:57:42 +0000 Subject: [PATCH 13/85] update --- .github/workflows/_Codestyle-Check.yml | 31 +++++++------------------- 1 file changed, 8 insertions(+), 23 deletions(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 803beba9ab6..0ac668e3db1 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -66,30 +66,15 @@ jobs: - name: Download PaddleCustomDevice.tar.gz run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate - echo "Extracting PaddleTest.tar.gz" + echo "Extracting PaddleCustomDevice.tar.gz" # git config --global --add safe.directory ${work_dir} tar -xf PaddleCustomDevice.tar.gz --strip-components=1 - git fetch origin pull/${PR_ID}/merge - git checkout -b test FETCH_HEAD + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git log --pretty=oneline -20 - - name: Setup python3.12 - if: steps.check-bypass.outputs.can-skip != 'true' - uses: actions/setup-python@v5 - with: - python-version: '3.12' - cache: 'pip' - - - name: Install dependencies - if: steps.check-bypass.outputs.can-skip != 'true' - run: | - pip install pre-commit==2.17.0 cpplint==1.6.0 clang-format==13.0.0 - - - name: Check pre-commit - if: steps.check-bypass.outputs.can-skip != 'true' - env: - SKIP_CLANG_TIDY_CHECK: "ON" - run: | - set +e - bash -x tools/codestyle/pre_commit.sh;EXCODE=$? - exit $EXCODE + pip install cpplint==1.6.0 + pre-commit install + bash tools/codestyle/pre_commit.sh ' From 653cf9192962edd65d69c39ffc57f32a9b0e1920 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 07:08:28 +0000 Subject: [PATCH 14/85] update --- .github/workflows/_Codestyle-Check.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 0ac668e3db1..01221b15f66 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -66,6 +66,8 @@ jobs: - name: Download PaddleCustomDevice.tar.gz run: | + set -x + docker ps -a docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" From ec77703f249566f106ad2aa460c3d3ff971bde02 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 07:12:32 +0000 Subject: [PATCH 15/85] update --- .github/workflows/_Codestyle-Check.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 01221b15f66..eafd4d5da42 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -62,7 +62,7 @@ jobs: -e no_proxy \ -e CI_name \ -e GITHUB_API_TOKEN \ - -w /paddle --network host ${docker_image} + -w /paddle --network host ${docker_image} /bin/bash - name: Download PaddleCustomDevice.tar.gz run: | From c5d24b43d8789c1cdd596652f673eeec9b73aaf8 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 07:28:47 +0000 Subject: [PATCH 16/85] update --- .github/workflows/_Codestyle-Check.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index eafd4d5da42..3ab3a07dd40 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -38,7 +38,8 @@ jobs: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} RUN_ID: ${{ github.run_id }} - docker_image: iregistry.baidu-int.com/tiangexiao/paddle-npu:cann800-910B-ubuntu18-x86_64 + #docker_image: iregistry.baidu-int.com/tiangexiao/paddle-npu:cann800-910B-ubuntu18-x86_64 + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/ci/paddle:19d3669ca5ff0b19144a785bb3126d7e run: | container_name=${TASK}-${core_index}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} From e55234aae02ac39cfcb14081bd7b410c4b1ee493 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 08:22:49 +0000 Subject: [PATCH 17/85] add gcu --- .github/workflows/_Codestyle-Check.yml | 3 - .github/workflows/_GCU.yml | 92 ++++++++++++++++++++++++++ 2 files changed, 92 insertions(+), 3 deletions(-) create mode 100644 .github/workflows/_GCU.yml diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 3ab3a07dd40..e5c4561b9a8 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -38,7 +38,6 @@ jobs: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} RUN_ID: ${{ github.run_id }} - #docker_image: iregistry.baidu-int.com/tiangexiao/paddle-npu:cann800-910B-ubuntu18-x86_64 docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/ci/paddle:19d3669ca5ff0b19144a785bb3126d7e run: | container_name=${TASK}-${core_index}-$(date +%Y%m%d-%H%M%S) @@ -68,11 +67,9 @@ jobs: - name: Download PaddleCustomDevice.tar.gz run: | set -x - docker ps -a docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" - # git config --global --add safe.directory ${work_dir} tar -xf PaddleCustomDevice.tar.gz --strip-components=1 git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml new file mode 100644 index 00000000000..cb6a4f3716b --- /dev/null +++ b/.github/workflows/_GCU.yml @@ -0,0 +1,92 @@ +name: Codestyle-Check + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + pre-commit: + name: Pre Commit + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: GCU + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-cpu + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - name: Check docker image and run container + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/ci/paddle:19d3669ca5ff0b19144a785bb3126d7e + run: | + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker run --shm-size=128G \ + -d -t --name ${container_name} \ + --privileged --network=host \ + -v ${cache_dir}:/root/.cache \ + -v ${ccache_dir}:/root/.ccache \ + -v ${PWD}:/paddle -w /paddle \ + ${PADDLE_DEV_NAME} /bin/bash + + - name: Check GCU Files + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + # git config --global --add safe.directory ${work_dir} + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git log --pretty=oneline -20 + + # !!!!! SKIP IF NO GCU CHANGE !!!! + echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_gcu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/gcu"| wc -l) + git diff --name-only remotes/origin/${BRANCH} + + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run GCU FULL CI test ..." + elif [ $change_gcu_only -eq 0 ] ; then + echo "NO GCU backend changes found, skip GCU FULL CI ...." + exit 0 + fi + ' + + - name: Run GCU + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + bash backends/gcu/ci_test.sh ' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From 81838284f93560ba178b2a02f9270d3959df3098 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 08:24:07 +0000 Subject: [PATCH 18/85] update gcu --- .github/workflows/CI.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 0b5ee53bbd0..5a66e9e518a 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -26,3 +26,8 @@ jobs: name: Codestyle-Check uses: ./.github/workflows/_Codestyle-Check.yml needs: [clone] + + gcu: + name: gcu + uses: ./.github/workflows/_GCU.yml + needs: [Codestyle-Check] From ad6af77f71ff329ef3026c6f124deaf27b62ccd0 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 08:38:53 +0000 Subject: [PATCH 19/85] update gcu --- .github/workflows/_GCU.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index cb6a4f3716b..146ffa2d7fc 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -45,11 +45,11 @@ jobs: echo "container_name=${container_name}" >> ${{ github.env }} docker run --shm-size=128G \ -d -t --name ${container_name} \ - --privileged --network=host \ + --privileged --network=host \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${PWD}:/paddle -w /paddle \ - ${PADDLE_DEV_NAME} /bin/bash + ${PADDLE_DEV_NAME} /bin/bash - name: Check GCU Files run: | @@ -68,7 +68,7 @@ jobs: change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) change_gcu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/gcu"| wc -l) git diff --name-only remotes/origin/${BRANCH} - + if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run GCU FULL CI test ..." elif [ $change_gcu_only -eq 0 ] ; then From 4a934bff36005a5d583bc4faebdffdf1f99126cc Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 09:11:20 +0000 Subject: [PATCH 20/85] update gcu --- .github/workflows/_GCU.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 146ffa2d7fc..97072b13913 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -68,7 +68,7 @@ jobs: change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) change_gcu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/gcu"| wc -l) git diff --name-only remotes/origin/${BRANCH} - + if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run GCU FULL CI test ..." elif [ $change_gcu_only -eq 0 ] ; then From cd65823f590667590b820734d5021c1f5634def5 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 14 Oct 2025 09:19:52 +0000 Subject: [PATCH 21/85] update gcu --- .github/workflows/_Codestyle-Check.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index e5c4561b9a8..df19618320a 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -78,3 +78,12 @@ jobs: pip install cpplint==1.6.0 pre-commit install bash tools/codestyle/pre_commit.sh ' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From ab54fa14c55756aa7a0c6c7df4fbb9e1abec50e0 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 15 Oct 2025 07:57:49 +0000 Subject: [PATCH 22/85] test --- .github/workflows/_GCU.yml | 4 +- .github/workflows/_HPU.yml | 93 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 95 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/_HPU.yml diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 97072b13913..bd59c024b1e 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -1,4 +1,4 @@ -name: Codestyle-Check +name: PR-CI-GCU on: workflow_call: @@ -25,7 +25,7 @@ jobs: PR_ID: ${{ github.event.pull_request.number }} COMMIT_ID: ${{ github.event.pull_request.head.sha }} BRANCH: develop - TASK: paddle-CI-${{ github.event.pull_request.number }}-cpu + TASK: paddle-CI-${{ github.event.pull_request.number }}-gcu steps: - name: Cleanup diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml new file mode 100644 index 00000000000..9648640ea6e --- /dev/null +++ b/.github/workflows/_HPU.yml @@ -0,0 +1,93 @@ +name: PR-CI-HPU + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + pre-commit: + name: Pre Commit + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: HPU + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-hpu + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - name: Check docker image and run container + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-hpu:ci + run: | + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker run --shm-size=128G \ + -d -t --name ${container_name} \ + --privileged --network=host \ + -v ${cache_dir}:/root/.cache \ + -v ${ccache_dir}:/root/.ccache \ + -v ${PWD}:/PaddleCustomDevice -w /PaddleCustomDevice \ + ${PADDLE_DEV_NAME} /bin/bash + + - name: Check HPU Files + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + # git config --global --add safe.directory ${work_dir} + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git log --pretty=oneline -20 + # !!!!! SKIP IF NO HPU CHANGE !!!! + echo "=========== Checking PR Changes If HPU FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) + change_hpu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/intel_hpu"| wc -l) + git diff --name-only remotes/origin/${PADDLE_BRANCH} + + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run HPU FULL CI test ..." + elif [ $change_hpu_only -eq 0 ] ; then + echo "NO HPU backend changes found, skip HPU FULL CI ...." + exit 0 + fi + ' + - name: Run HPU + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + mkdir -p /PaddleCustomDevice/backends/intel_hpu/build/ + cp /usr/lib/habanalabs/libcustom_tpc_perf_lib.so /PaddleCustomDevice/backends/intel_hpu/build/ + export GC_KERNEL_PATH=/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so + bash /PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From ee13d88b77bbc5fa3dc99794d44716387f293e2e Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 15 Oct 2025 16:50:23 +0800 Subject: [PATCH 23/85] Update _Codestyle-Check.yml --- .github/workflows/_Codestyle-Check.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index df19618320a..4b0b60ac63d 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -73,8 +73,6 @@ jobs: tar -xf PaddleCustomDevice.tar.gz --strip-components=1 git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 - pip install cpplint==1.6.0 pre-commit install bash tools/codestyle/pre_commit.sh ' From 817a744d09be9caf0bdc8787f0ed1c256df91ef4 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 15 Oct 2025 08:58:42 +0000 Subject: [PATCH 24/85] update --- .github/workflows/_Codestyle-Check.yml | 2 -- .github/workflows/_HPU.yml | 6 ++---- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index df19618320a..4b0b60ac63d 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -73,8 +73,6 @@ jobs: tar -xf PaddleCustomDevice.tar.gz --strip-components=1 git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 - pip install cpplint==1.6.0 pre-commit install bash tools/codestyle/pre_commit.sh ' diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 9648640ea6e..a96a9201620 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -30,8 +30,7 @@ jobs: steps: - name: Cleanup run: | - rm -rf * .[^.]* - + rm -rf * .[^.]* - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -66,8 +65,7 @@ jobs: change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) change_hpu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/intel_hpu"| wc -l) - git diff --name-only remotes/origin/${PADDLE_BRANCH} - + git diff --name-only remotes/origin/${PADDLE_BRANCH} if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run HPU FULL CI test ..." elif [ $change_hpu_only -eq 0 ] ; then From 0aa2bc904b3b8807b87c51da998253facb72f621 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 00:41:07 +0000 Subject: [PATCH 25/85] Update --- .github/workflows/CI.yml | 5 +++++ .github/workflows/_GCU.yml | 2 +- .github/workflows/_HPU.yml | 8 ++++---- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 5a66e9e518a..2038a8ac8a5 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -31,3 +31,8 @@ jobs: name: gcu uses: ./.github/workflows/_GCU.yml needs: [Codestyle-Check] + + hpu: + name: hpu + uses: ./.github/workflows/_HPU.yml + needs: [Codestyle-Check] diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index bd59c024b1e..560b54c6677 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -1,4 +1,4 @@ -name: PR-CI-GCU +name: PR-CI-GCU on: workflow_call: diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index a96a9201620..2f1c635258b 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -1,4 +1,4 @@ -name: PR-CI-HPU +name: PR-CI-HPU on: workflow_call: @@ -30,7 +30,7 @@ jobs: steps: - name: Cleanup run: | - rm -rf * .[^.]* + rm -rf * .[^.]* - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -38,7 +38,7 @@ jobs: RUN_ID: ${{ github.run_id }} cache_dir: /root/.cache ccache_dir: /root/.ccache - docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-hpu:ci + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-hpu:ci run: | container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} @@ -65,7 +65,7 @@ jobs: change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) change_hpu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/intel_hpu"| wc -l) - git diff --name-only remotes/origin/${PADDLE_BRANCH} + git diff --name-only remotes/origin/${PADDLE_BRANCH} if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run HPU FULL CI test ..." elif [ $change_hpu_only -eq 0 ] ; then From 86eee359fa9e08edbcbf7ea8fba3c404c824e4ab Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 00:52:40 +0000 Subject: [PATCH 26/85] Update --- .github/workflows/_HPU.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 2f1c635258b..37eeca9e58b 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -48,7 +48,7 @@ jobs: -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${PWD}:/PaddleCustomDevice -w /PaddleCustomDevice \ - ${PADDLE_DEV_NAME} /bin/bash + ${docker_image} /bin/bash - name: Check HPU Files run: | From 95927e9295e4af3abe34dfadfb9d14cc8536c3a4 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 01:35:15 +0000 Subject: [PATCH 27/85] Update --- .github/workflows/_HPU.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 37eeca9e58b..40e4baeee12 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -50,7 +50,7 @@ jobs: -v ${PWD}:/PaddleCustomDevice -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: Check HPU Files + - name: RUN HPU run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -72,12 +72,7 @@ jobs: echo "NO HPU backend changes found, skip HPU FULL CI ...." exit 0 fi - ' - - name: Run HPU - run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' mkdir -p /PaddleCustomDevice/backends/intel_hpu/build/ - cp /usr/lib/habanalabs/libcustom_tpc_perf_lib.so /PaddleCustomDevice/backends/intel_hpu/build/ export GC_KERNEL_PATH=/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so bash /PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' From b903099b450794b9012b805d1caaad1eaf23aeb8 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 01:35:58 +0000 Subject: [PATCH 28/85] Update --- .github/workflows/_GCU.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 560b54c6677..7b09ab0538a 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -49,7 +49,7 @@ jobs: -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${PWD}:/paddle -w /paddle \ - ${PADDLE_DEV_NAME} /bin/bash + ${docker_image} /bin/bash - name: Check GCU Files run: | From 46f8f573b1df9c2b0cf69b38c23a26e9314005eb Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 02:19:19 +0000 Subject: [PATCH 29/85] Update --- .github/workflows/_GCU.yml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 7b09ab0538a..fb60ed81f4e 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -39,7 +39,7 @@ jobs: RUN_ID: ${{ github.run_id }} cache_dir: /root/.cache ccache_dir: /root/.ccache - docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/ci/paddle:19d3669ca5ff0b19144a785bb3126d7e + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-gcu:topsrider3.5.102-ubuntu20-x86_64-gcc84 run: | container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} @@ -51,7 +51,7 @@ jobs: -v ${PWD}:/paddle -w /paddle \ ${docker_image} /bin/bash - - name: Check GCU Files + - name: RUN GCU run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -75,10 +75,6 @@ jobs: echo "NO GCU backend changes found, skip GCU FULL CI ...." exit 0 fi - ' - - - name: Run GCU - run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' bash backends/gcu/ci_test.sh ' From 382a2a29066a8c48db7f10f442e27f7bc6706f2d Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 02:46:23 +0000 Subject: [PATCH 30/85] Update --- .github/workflows/_GCU.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index fb60ed81f4e..f4c480772ca 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -39,7 +39,7 @@ jobs: RUN_ID: ${{ github.run_id }} cache_dir: /root/.cache ccache_dir: /root/.ccache - docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-gcu:topsrider3.5.102-ubuntu20-x86_64-gcc84 + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-gcu:topsrider3.5.102-ubuntu20-x86_64-gcc84 run: | container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} From 19a303406919ad26b02b3fb1ec0d2752e074bb03 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 03:17:22 +0000 Subject: [PATCH 31/85] Update --- .github/workflows/_GCU.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index f4c480772ca..6b7bf54088b 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -75,7 +75,6 @@ jobs: echo "NO GCU backend changes found, skip GCU FULL CI ...." exit 0 fi - docker exec -t ${{ env.container_name }} /bin/bash -c ' bash backends/gcu/ci_test.sh ' - name: Terminate and delete the container From d39db81bd163df0499afeb1ddf950a990e8e1d8e Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 03:19:32 +0000 Subject: [PATCH 32/85] Update --- backends/gcu/ci_test.sh | 1 - backends/intel_hpu/tools/pr_hpu_ci.sh | 1 - 2 files changed, 2 deletions(-) diff --git a/backends/gcu/ci_test.sh b/backends/gcu/ci_test.sh index 1b61e22ccce..a8c8ed140c1 100644 --- a/backends/gcu/ci_test.sh +++ b/backends/gcu/ci_test.sh @@ -32,5 +32,4 @@ cmake .. -DWITH_TESTING=ON -DCMAKE_EXPORT_COMPILE_COMMANDS=ON -DPY_VERSION=3.10 make -j $(nproc) python -m pip install --force-reinstall -U dist/paddle_custom_gcu*.whl - ctest -j4 --output-on-failure diff --git a/backends/intel_hpu/tools/pr_hpu_ci.sh b/backends/intel_hpu/tools/pr_hpu_ci.sh index b0cb0f373ed..4c458583392 100644 --- a/backends/intel_hpu/tools/pr_hpu_ci.sh +++ b/backends/intel_hpu/tools/pr_hpu_ci.sh @@ -32,7 +32,6 @@ echo "custom_ops install" cd ${WORKSPACE}/PaddleCustomDevice/backends/intel_hpu/custom_ops python setup.py install - echo "Start build" cd ${WORKSPACE}/PaddleCustomDevice/backends/intel_hpu mkdir -p build && cd build From 23c3e16b0c3aace2c1b3a404dbc98c461f6614bc Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 04:42:01 +0000 Subject: [PATCH 33/85] Update --- .github/workflows/_HPU.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 40e4baeee12..a211a995711 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -62,10 +62,10 @@ jobs: git log --pretty=oneline -20 # !!!!! SKIP IF NO HPU CHANGE !!!! echo "=========== Checking PR Changes If HPU FULL CI Needed ===========" - change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) - change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) - change_hpu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/intel_hpu"| wc -l) - git diff --name-only remotes/origin/${PADDLE_BRANCH} + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_hpu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/intel_hpu"| wc -l) + git diff --name-only remotes/origin/${BRANCH} if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run HPU FULL CI test ..." elif [ $change_hpu_only -eq 0 ] ; then From 7b72e09d59130ed2cb5d857a49ee980bfcfc6bbf Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 06:39:44 +0000 Subject: [PATCH 34/85] Update --- .github/workflows/_GCU.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 6b7bf54088b..290689b59b7 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -39,7 +39,7 @@ jobs: RUN_ID: ${{ github.run_id }} cache_dir: /root/.cache ccache_dir: /root/.ccache - docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-gcu:topsrider3.5.102-ubuntu20-x86_64-gcc84 + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-gcu:topsrider3.5.102-ubuntu20-x86_64-gcc84-ci run: | container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} From 2e1450e3c755de8cc85c0f1085348b4cc3b7654e Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 06:44:50 +0000 Subject: [PATCH 35/85] Update --- .github/workflows/_GCU.yml | 4 ++-- .github/workflows/_HPU.yml | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 290689b59b7..78450865b69 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -16,8 +16,8 @@ on: default: 'true' jobs: - pre-commit: - name: Pre Commit + PR-CI-GCU: + name: PR-CI-GCU if: ${{ github.repository_owner == 'PaddlePaddle' }} runs-on: group: GCU diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index a211a995711..5278ed9fd58 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -16,8 +16,8 @@ on: default: 'true' jobs: - pre-commit: - name: Pre Commit + PR-CI-HPU: + name: PR-CI-HPU if: ${{ github.repository_owner == 'PaddlePaddle' }} runs-on: group: HPU From 6dedb00df99f1be044cada6aa15cb7c5aae45389 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 06:53:09 +0000 Subject: [PATCH 36/85] Update --- .github/workflows/_GCU.yml | 3 +++ .github/workflows/_HPU.yml | 3 +++ 2 files changed, 6 insertions(+) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 78450865b69..44cbc11fc42 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -46,6 +46,9 @@ jobs: docker run --shm-size=128G \ -d -t --name ${container_name} \ --privileged --network=host \ + -e PR_ID \ + -e COMMIT_ID \ + -e BRANCH \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${PWD}:/paddle -w /paddle \ diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 5278ed9fd58..2aec8c231f8 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -45,6 +45,9 @@ jobs: docker run --shm-size=128G \ -d -t --name ${container_name} \ --privileged --network=host \ + -e PR_ID \ + -e COMMIT_ID \ + -e BRANCH \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${PWD}:/PaddleCustomDevice -w /PaddleCustomDevice \ From 3c6e018dba2ea8071e333cad9bb1b7b4f3c29061 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 07:06:57 +0000 Subject: [PATCH 37/85] install zstd --- backends/gcu/tools/dockerfile/Dockerfile.gcu.ubuntu20.gcc84 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backends/gcu/tools/dockerfile/Dockerfile.gcu.ubuntu20.gcc84 b/backends/gcu/tools/dockerfile/Dockerfile.gcu.ubuntu20.gcc84 index 50fc6332065..280adf07717 100644 --- a/backends/gcu/tools/dockerfile/Dockerfile.gcu.ubuntu20.gcc84 +++ b/backends/gcu/tools/dockerfile/Dockerfile.gcu.ubuntu20.gcc84 @@ -10,7 +10,7 @@ ARG TOPS_RIDER_PACKAGE_LINK # install base packages RUN apt-get update -y && apt-get install -y zlib1g zlib1g-dev libsqlite3-dev openssl libssl-dev libffi-dev libbz2-dev \ libxslt1-dev unzip pciutils net-tools libblas-dev gfortran libblas3 liblapack-dev liblapack3 libopenblas-dev \ - python3.10-dev python3.10-distutils + python3.10-dev python3.10-distutils zstd RUN pip install --upgrade pip setuptools wheel && pip install ddt colorlog From dc54bc644d01332aafe26535823d3088632a967e Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 08:19:12 +0000 Subject: [PATCH 38/85] update --- .github/workflows/_GCU.yml | 3 ++- .github/workflows/_HPU.yml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 44cbc11fc42..2a49c349720 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -51,7 +51,7 @@ jobs: -e BRANCH \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ - -v ${PWD}:/paddle -w /paddle \ + -v ${PWD}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: RUN GCU @@ -61,6 +61,7 @@ jobs: echo "Extracting PaddleCustomDevice.tar.gz" # git config --global --add safe.directory ${work_dir} tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git config --global --add safe.directory /PaddleCustomDevice git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 2aec8c231f8..48b929515ca 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -58,7 +58,7 @@ jobs: docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" - # git config --global --add safe.directory ${work_dir} + git config --global --add safe.directory /PaddleCustomDevice tar -xf PaddleCustomDevice.tar.gz --strip-components=1 git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit From b894d32ec38d2649859cec89b5943ba437ee4cd2 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 10:48:59 +0000 Subject: [PATCH 39/85] update --- .github/workflows/_GCU.yml | 6 +++++- .github/workflows/_HPU.yml | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 2a49c349720..9a07ca69a84 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -26,6 +26,7 @@ jobs: COMMIT_ID: ${{ github.event.pull_request.head.sha }} BRANCH: develop TASK: paddle-CI-${{ github.event.pull_request.number }}-gcu + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: - name: Cleanup @@ -49,14 +50,17 @@ jobs: -e PR_ID \ -e COMMIT_ID \ -e BRANCH \ + -e no_proxy \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ - -v ${PWD}:/paddle -w /PaddleCustomDevice \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: RUN GCU run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' + source ${{ github.workspace }}/../../../proxy wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" # git config --global --add safe.directory ${work_dir} diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 48b929515ca..8a828b6c193 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -26,6 +26,7 @@ jobs: COMMIT_ID: ${{ github.event.pull_request.head.sha }} BRANCH: develop TASK: paddle-CI-${{ github.event.pull_request.number }}-hpu + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: - name: Cleanup @@ -48,14 +49,17 @@ jobs: -e PR_ID \ -e COMMIT_ID \ -e BRANCH \ + -e no_proxy \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ - -v ${PWD}:/PaddleCustomDevice -w /PaddleCustomDevice \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/PaddleCustomDevice -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: RUN HPU run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' + source ${{ github.workspace }}/../../../proxy wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" git config --global --add safe.directory /PaddleCustomDevice From 3d9b31fe2c16e25e42d7f360021dc961e4624105 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 16 Oct 2025 11:19:05 +0000 Subject: [PATCH 40/85] update --- .github/workflows/_HPU.yml | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 8a828b6c193..fc913ac22a5 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -53,7 +53,7 @@ jobs: -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ - -v ${{ github.workspace }}:/PaddleCustomDevice -w /PaddleCustomDevice \ + -v ${{ github.workspace }}:/workspace -w /workspace \ ${docker_image} /bin/bash - name: RUN HPU @@ -62,8 +62,9 @@ jobs: source ${{ github.workspace }}/../../../proxy wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz + cd PaddleCustomDevice git config --global --add safe.directory /PaddleCustomDevice - tar -xf PaddleCustomDevice.tar.gz --strip-components=1 git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 @@ -79,9 +80,10 @@ jobs: echo "NO HPU backend changes found, skip HPU FULL CI ...." exit 0 fi - mkdir -p /PaddleCustomDevice/backends/intel_hpu/build/ - export GC_KERNEL_PATH=/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so - bash /PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' + mkdir -p /workspace/PaddleCustomDevice/backends/intel_hpu/build/ + export GC_KERNEL_PATH=/workspace/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so + cd /workspace + bash /workspace/PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' - name: Terminate and delete the container if: always() From 1d585b554a3052cc33adcc354acbd2f331420ce0 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 00:45:06 +0000 Subject: [PATCH 41/85] test --- .github/workflows/_GCU.yml | 1 + .github/workflows/_HPU.yml | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 9a07ca69a84..a9dc36c8c33 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -69,6 +69,7 @@ jobs: git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 + sleep 3d # !!!!! SKIP IF NO GCU CHANGE !!!! echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index fc913ac22a5..320fd464d80 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -68,6 +68,7 @@ jobs: git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 + sleep 3d # !!!!! SKIP IF NO HPU CHANGE !!!! echo "=========== Checking PR Changes If HPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) From 645a81e165df16402a808c373f6f77210bef68db Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 01:13:53 +0000 Subject: [PATCH 42/85] test --- .github/workflows/_GCU.yml | 1 - .github/workflows/_HPU.yml | 4 ++-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index a9dc36c8c33..9a07ca69a84 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -69,7 +69,6 @@ jobs: git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 - sleep 3d # !!!!! SKIP IF NO GCU CHANGE !!!! echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 320fd464d80..767b35966c2 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -64,11 +64,11 @@ jobs: echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz cd PaddleCustomDevice - git config --global --add safe.directory /PaddleCustomDevice + git config --global --add safe.directory /workspace/PaddleCustomDevice git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 - sleep 3d + # !!!!! SKIP IF NO HPU CHANGE !!!! echo "=========== Checking PR Changes If HPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) From 247c9202e76319c9a49ec203f705f00406456628 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 01:40:13 +0000 Subject: [PATCH 43/85] test --- .github/workflows/_HPU.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 767b35966c2..0630fd121f0 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -64,7 +64,7 @@ jobs: echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz cd PaddleCustomDevice - git config --global --add safe.directory /workspace/PaddleCustomDevice + git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 From d1f3fb70fd3812095a8f126e2bc6355c496b343c Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 01:40:38 +0000 Subject: [PATCH 44/85] test --- .github/workflows/_GCU.yml | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 9a07ca69a84..6765b87cf69 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -63,9 +63,8 @@ jobs: source ${{ github.workspace }}/../../../proxy wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" - # git config --global --add safe.directory ${work_dir} tar -xf PaddleCustomDevice.tar.gz --strip-components=1 - git config --global --add safe.directory /PaddleCustomDevice + git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit git log --pretty=oneline -20 From 5f000f1490944112fbb463c3edd189284eb5b703 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 02:30:51 +0000 Subject: [PATCH 45/85] update --- .github/workflows/CI.yml | 5 ++ .github/workflows/_MLU.yml | 109 +++++++++++++++++++++++++++++++++++++ 2 files changed, 114 insertions(+) create mode 100644 .github/workflows/_MLU.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 2038a8ac8a5..510585f5542 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -36,3 +36,8 @@ jobs: name: hpu uses: ./.github/workflows/_HPU.yml needs: [Codestyle-Check] + + mlu: + name: mlu + uses: ./.github/workflows/_MLU.yml + needs: [Codestyle-Check] diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml new file mode 100644 index 00000000000..e0055f4cddd --- /dev/null +++ b/.github/workflows/_MLU.yml @@ -0,0 +1,109 @@ +name: PR-CI-MLU + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + PR-CI-MLU: + name: PR-CI-MLU + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: MLU + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-mlu + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - name: Check docker image and run container + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + docker_image: registry.baidubce.com/device/paddle-mlu:ctr2.15.0-ubuntu20-gcc84-py310 + run: | + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker run --shm-size=128G \ + -d -t --name ${container_name} \ + --privileged --network=host \ + -e PR_ID \ + -e COMMIT_ID \ + -e BRANCH \ + -e no_proxy \ + -e PADDLE_PDX_DISABLE_DEV_MODEL_WL=True \ + -v ${cache_dir}:/root/.cache \ + -v ${ccache_dir}:/root/.ccache \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + ${docker_image} /bin/bash + + - name: RUN MLU + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + source ${{ github.workspace }}/../../../proxy + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git config --global --add safe.directory "*" + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git log --pretty=oneline -20 + + # !!!!! SKIP IF NO MLU CHANGE !!!! + echo "=========== Checking PR Changes If MLU FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) + change_mlu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/mlu"| wc -l) + git diff --name-only remotes/origin/${PADDLE_BRANCH} + + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run MLU FULL CI test ..." + elif [ $change_mlu_only -eq 0 ] ; then + echo "NO MLU backend changes found, skip MLU FULL CI ...." + exit 0 + fi + + echo "============ NeuWare Version Check =============" + dpkg -l | grep cntoolkit + dpkg -l | grep cnnl + dpkg -l | grep cncl + dpkg -l | grep mluops + + echo "============ Install PaddlePaddle CPU =============" + pip install safetensors==0.6.2 + python -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ + + python -c "import paddle; print(paddle.__version__)" + python -c "import paddle; print(paddle.version.commit)" + + bash backends/mlu/tools/pr_ci_mlu.sh' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From 1d899c2168b9a64ccf0b093486c683b162564e0a Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 02:58:08 +0000 Subject: [PATCH 46/85] update --- .github/workflows/_MLU.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index e0055f4cddd..f2ddc16bfb0 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -40,7 +40,7 @@ jobs: RUN_ID: ${{ github.run_id }} cache_dir: /root/.cache ccache_dir: /root/.ccache - docker_image: registry.baidubce.com/device/paddle-mlu:ctr2.15.0-ubuntu20-gcc84-py310 + docker_image: registry.baidubce.com/device/paddle-mlu:ctr2.15.0-ubuntu20-gcc84-py310 run: | container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} @@ -76,7 +76,7 @@ jobs: change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) change_mlu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/mlu"| wc -l) git diff --name-only remotes/origin/${PADDLE_BRANCH} - + if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run MLU FULL CI test ..." elif [ $change_mlu_only -eq 0 ] ; then @@ -89,11 +89,11 @@ jobs: dpkg -l | grep cnnl dpkg -l | grep cncl dpkg -l | grep mluops - + echo "============ Install PaddlePaddle CPU =============" pip install safetensors==0.6.2 python -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ - + python -c "import paddle; print(paddle.__version__)" python -c "import paddle; print(paddle.version.commit)" From 3c88941655991fdbe94297bdf1f12ff39b4c21ce Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 03:00:51 +0000 Subject: [PATCH 47/85] update --- .github/workflows/_910B-ARM.yml | 110 ++++++++++++++++++++++++++++++++ 1 file changed, 110 insertions(+) create mode 100644 .github/workflows/_910B-ARM.yml diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml new file mode 100644 index 00000000000..772644cce20 --- /dev/null +++ b/.github/workflows/_910B-ARM.yml @@ -0,0 +1,110 @@ +name: PR-CI-910B-ARM + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + PR-CI-910B-ARM: + name: PR-CI-910B-ARM + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: 910B-ARM + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-gcu + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - name: Check docker image and run container + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + docker_image: registry.baidubce.com/device/paddle-npu:cann80RC1-ubuntu20-aarch64-gcc84-py39 + run: | + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker run --shm-size=128G \ + -d -t --name ${container_name} \ + --privileged --network=host \ + -e PR_ID \ + -e COMMIT_ID \ + -e BRANCH \ + -e no_proxy \ + -e USE_910B=1 \ + -e FLAGS_npu_storage_format=0 \ + -v ${cache_dir}:/root/.cache \ + -v ${ccache_dir}:/root/.ccache \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + ${docker_image} /bin/bash + + - name: RUN GCU + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + source ${{ github.workspace }}/../../../proxy + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git config --global --add safe.directory "*" + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git log --pretty=oneline -20 + + # !!!!! SKIP IF NO NPU CHANGE !!!! + echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/develop | wc -l) + change_backend=$(git diff --name-only remotes/origin/develop | grep "backends/"| wc -l) + change_npu_only=$(git diff --name-only remotes/origin/develop | grep "backends/npu"| wc -l) + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run NPU FULL CI test ..." + elif [ $change_npu_only -eq 0 ] ; then + echo "NO NPU backend changes found, skip NPU FULL CI ...." + exit 0 + fi + + echo "============ CANN Version =============" + source ~/.bashrc + echo "============ Install PaddlePaddle CPU =============" + PATH=/usr/local/bin:${PATH} + ln -sf $(which python3.9) /usr/local/bin/python + ln -sf $(which pip3.9) /usr/local/bin/pip + + pip install -U numpy==1.26.4 safetensors + python -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ + python -c "import paddle; print(paddle.__version__)" + python -c "import paddle; print(paddle.version.commit)" + # Install python packages required for incremental coverage + python -m pip install PyGithub + export LD_PRELOAD=/lib/aarch64-linux-gnu/libgomp.so.1:$LD_PRELOAD + + bash backends/gcu/ci_test.sh' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From 41f351db9c37cef86d79f6e765c74449ad4fb00e Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 06:29:19 +0000 Subject: [PATCH 48/85] test --- .github/workflows/CI.yml | 5 +++++ .github/workflows/_910B-ARM.yml | 1 + .github/workflows/_GCU.yml | 1 + .github/workflows/_HPU.yml | 1 + .github/workflows/_MLU.yml | 1 + 5 files changed, 9 insertions(+) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 510585f5542..be0f66b1927 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -41,3 +41,8 @@ jobs: name: mlu uses: ./.github/workflows/_MLU.yml needs: [Codestyle-Check] + + 910b-arm: + name: 910B-ARM + uses: ./.github/workflows/_910B-ARM.yml + needs: [Codestyle-Check] diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 772644cce20..81a25bcd046 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -63,6 +63,7 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy + set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz --strip-components=1 diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 6765b87cf69..bdbfe437960 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -61,6 +61,7 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy + set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz --strip-components=1 diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 0630fd121f0..15a113277c3 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -60,6 +60,7 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy + set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index f2ddc16bfb0..8860655b703 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -62,6 +62,7 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy + set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz --strip-components=1 From 62734584ffe40d21ec4101e20e4fdf4eeacba909 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 06:33:26 +0000 Subject: [PATCH 49/85] test --- .github/workflows/CI.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index be0f66b1927..2832d7aa363 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -42,7 +42,7 @@ jobs: uses: ./.github/workflows/_MLU.yml needs: [Codestyle-Check] - 910b-arm: - name: 910B-ARM + npu-910b-arm: + name: npu-910B-ARM uses: ./.github/workflows/_910B-ARM.yml needs: [Codestyle-Check] From b17b68e20c85e077ed44056d0cd1e3d634eae78c Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 06:59:39 +0000 Subject: [PATCH 50/85] test --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_910B-X86.yml | 111 ++++++++++++++++++++++++++++++++ 2 files changed, 112 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/_910B-X86.yml diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 81a25bcd046..9adbdf9f274 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -99,7 +99,7 @@ jobs: python -m pip install PyGithub export LD_PRELOAD=/lib/aarch64-linux-gnu/libgomp.so.1:$LD_PRELOAD - bash backends/gcu/ci_test.sh' + bash backends/npu/tools/pr_ci_npu.sh' - name: Terminate and delete the container if: always() diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml new file mode 100644 index 00000000000..abb653e22f5 --- /dev/null +++ b/.github/workflows/_910B-X86.yml @@ -0,0 +1,111 @@ +name: PR-CI-910B-X86 + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + PR-CI-910B-X86: + name: PR-CI-910B-X86 + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: NPU + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-gcu + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - name: Check docker image and run container + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + docker_image: registry.baidubce.com/device/paddle-npu:cann80RC1-ubuntu20-aarch64-gcc84-py39 + run: | + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker run --shm-size=128G \ + -d -t --name ${container_name} \ + --privileged --network=host \ + -e PR_ID \ + -e COMMIT_ID \ + -e BRANCH \ + -e no_proxy \ + -e USE_910B=1 \ + -e FLAGS_npu_storage_format=0 \ + -v ${cache_dir}:/root/.cache \ + -v ${ccache_dir}:/root/.ccache \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + ${docker_image} /bin/bash + + - name: RUN GCU + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + source ${{ github.workspace }}/../../../proxy + set -x + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git config --global --add safe.directory "*" + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git log --pretty=oneline -20 + + # !!!!! SKIP IF NO NPU CHANGE !!!! + echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_npu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/npu"| wc -l) + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run NPU FULL CI test ..." + elif [ $change_npu_only -eq 0 ] ; then + echo "NO NPU backend changes found, skip NPU FULL CI ...." + exit 0 + fi + + echo "============ CANN Version =============" + source ~/.bashrc + echo "============ Install PaddlePaddle CPU =============" + PATH=/usr/local/bin:${PATH} + ln -sf $(which python3.9) /usr/local/bin/python + ln -sf $(which pip3.9) /usr/local/bin/pip + + pip install -U numpy==1.26.4 safetensors + python -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ + python -c "import paddle; print(paddle.__version__)" + python -c "import paddle; print(paddle.version.commit)" + # Install python packages required for incremental coverage + python -m pip install PyGithub + export LD_PRELOAD=/lib/aarch64-linux-gnu/libgomp.so.1:$LD_PRELOAD + + bash backends/npu/tools/pr_ci_npu.sh' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From 0bf31b3206881512fba8a30d26da04cf2cf85309 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 07:19:33 +0000 Subject: [PATCH 51/85] test --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_910B-X86.yml | 2 +- .github/workflows/_GCU.yml | 2 +- .github/workflows/_HPU.yml | 2 +- .github/workflows/_MLU.yml | 2 +- .../mlu/tools/dockerfile/Dockerfile.mlu.ubuntu20.gcc84.py310 | 3 ++- 6 files changed, 7 insertions(+), 6 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 9adbdf9f274..090235fd7d9 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -70,7 +70,7 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 + git --no-pager log --pretty=oneline -5 # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index abb653e22f5..3d2ffb40913 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -70,7 +70,7 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 + git --no-pager log --pretty=oneline -5 # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index bdbfe437960..09e29abd21f 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -68,7 +68,7 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 + git --no-pager log --pretty=oneline -5 # !!!!! SKIP IF NO GCU CHANGE !!!! echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 15a113277c3..246aa33ad65 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -68,7 +68,7 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 + git --no-pager log --pretty=oneline -5 # !!!!! SKIP IF NO HPU CHANGE !!!! echo "=========== Checking PR Changes If HPU FULL CI Needed ===========" diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 8860655b703..a0d0edf486c 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -69,7 +69,7 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git log --pretty=oneline -20 + git --no-pager log --pretty=oneline -5 # !!!!! SKIP IF NO MLU CHANGE !!!! echo "=========== Checking PR Changes If MLU FULL CI Needed ===========" diff --git a/backends/mlu/tools/dockerfile/Dockerfile.mlu.ubuntu20.gcc84.py310 b/backends/mlu/tools/dockerfile/Dockerfile.mlu.ubuntu20.gcc84.py310 index 08e3965beb4..8542b680b58 100644 --- a/backends/mlu/tools/dockerfile/Dockerfile.mlu.ubuntu20.gcc84.py310 +++ b/backends/mlu/tools/dockerfile/Dockerfile.mlu.ubuntu20.gcc84.py310 @@ -35,7 +35,8 @@ RUN wget -qO - https://www.mellanox.com/downloads/ofed/RPM-GPG-KEY-Mellanox | ap libibverbs-dev \ libibverbs1 \ librdmacm-dev \ - librdmacm1 + librdmacm1 \ + zstd # install cntoolkit RUN cd /tmp && \ From a743d57d4a275f31de8046673be64a57f0c712e7 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 07:40:32 +0000 Subject: [PATCH 52/85] test --- .github/workflows/_HPU.yml | 1 + .github/workflows/_MLU.yml | 8 ++++---- .../npu/tools/dockerfile/Dockerfile.npu.ubuntu20.gcc84 | 2 +- 3 files changed, 6 insertions(+), 5 deletions(-) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 246aa33ad65..d6145ef542f 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -50,6 +50,7 @@ jobs: -e COMMIT_ID \ -e BRANCH \ -e no_proxy \ + -e FLAGS_selected_intel_hpus=6 \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index a0d0edf486c..85f5dda9867 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -73,10 +73,10 @@ jobs: # !!!!! SKIP IF NO MLU CHANGE !!!! echo "=========== Checking PR Changes If MLU FULL CI Needed ===========" - change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) - change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) - change_mlu_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/mlu"| wc -l) - git diff --name-only remotes/origin/${PADDLE_BRANCH} + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_mlu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/mlu"| wc -l) + git diff --name-only remotes/origin/${BRANCH} if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run MLU FULL CI test ..." diff --git a/backends/npu/tools/dockerfile/Dockerfile.npu.ubuntu20.gcc84 b/backends/npu/tools/dockerfile/Dockerfile.npu.ubuntu20.gcc84 index 733f514b2cc..3502c01b5f1 100644 --- a/backends/npu/tools/dockerfile/Dockerfile.npu.ubuntu20.gcc84 +++ b/backends/npu/tools/dockerfile/Dockerfile.npu.ubuntu20.gcc84 @@ -18,7 +18,7 @@ ARG NPU_VERSION # install CANN requirement # https://www.hiascend.com/document/detail/zh/CANNCommunityEdition/700alpha003/softwareinstall/instg/instg_0026.html RUN apt-get update -y && apt-get install -y zlib1g zlib1g-dev libsqlite3-dev openssl libssl-dev libffi-dev libbz2-dev \ - libxslt1-dev unzip pciutils net-tools libblas-dev gfortran libblas3 liblapack-dev liblapack3 libopenblas-dev + libxslt1-dev unzip pciutils net-tools libblas-dev gfortran libblas3 liblapack-dev liblapack3 libopenblas-dev zstd RUN pip3.8 install --upgrade pip setuptools wheel && \ pip3.9 install --upgrade pip setuptools wheel && \ From 49400e6369e81f64a0069922d9c85e12b4e0f1a6 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Fri, 17 Oct 2025 08:06:52 +0000 Subject: [PATCH 53/85] Update --- .github/workflows/_910B-ARM.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 090235fd7d9..9bd304ff733 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -55,6 +55,9 @@ jobs: -e FLAGS_npu_storage_format=0 \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ + -v /usr/local/Ascend/driver:/usr/local/Ascend/driver \ + -v /usr/local/bin/npu-smi:/usr/local/bin/npu-smi \ + -v /usr/local/dcmi:/usr/local/dcmi \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash From 327b906d7392176184f5af111f220a9964caf328 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 01:29:16 +0000 Subject: [PATCH 54/85] Update --- .github/workflows/_910B-ARM.yml | 8 +++++--- .github/workflows/_HPU.yml | 1 + .github/workflows/_MLU.yml | 1 - 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 9bd304ff733..ab9a2d837c5 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -77,9 +77,11 @@ jobs: # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" - change_numbers=$(git diff --name-only remotes/origin/develop | wc -l) - change_backend=$(git diff --name-only remotes/origin/develop | grep "backends/"| wc -l) - change_npu_only=$(git diff --name-only remotes/origin/develop | grep "backends/npu"| wc -l) + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_npu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/npu"| wc -l) + git diff --name-only remotes/origin/${BRANCH} + if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run NPU FULL CI test ..." elif [ $change_npu_only -eq 0 ] ; then diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index d6145ef542f..d21eea9fa24 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -86,6 +86,7 @@ jobs: mkdir -p /workspace/PaddleCustomDevice/backends/intel_hpu/build/ export GC_KERNEL_PATH=/workspace/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so cd /workspace + sleep 3d bash /workspace/PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' - name: Terminate and delete the container diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 85f5dda9867..f3e4d73c1d4 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -62,7 +62,6 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy - set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz --strip-components=1 From 90306ac80f3b39449f842485221dbe5709e9d1ef Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 03:01:09 +0000 Subject: [PATCH 55/85] Update --- .github/workflows/CI.yml | 5 +++++ .github/workflows/_910B-ARM.yml | 16 ++++++++++++++++ .github/workflows/_HPU.yml | 2 -- 3 files changed, 21 insertions(+), 2 deletions(-) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index 2832d7aa363..fb196bfd24b 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -42,6 +42,11 @@ jobs: uses: ./.github/workflows/_MLU.yml needs: [Codestyle-Check] + ixuca: + name: ixuca + uses: ./.github/workflows/_IXUCA.yml + needs: [Codestyle-Check] + npu-910b-arm: name: npu-910B-ARM uses: ./.github/workflows/_910B-ARM.yml diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index ab9a2d837c5..69bb28d5c8d 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -42,6 +42,21 @@ jobs: ccache_dir: /root/.ccache docker_image: registry.baidubce.com/device/paddle-npu:cann80RC1-ubuntu20-aarch64-gcc84-py39 run: | + if [[ "${{ runner.name }}" == "IXUCA-2" ]];then + echo "IXUCA-2" + export ASCEND_RT_VISIBLE_DEVICES=4,5,6,7 + elif [[ "${{ runner.name }}" == "IXUCA-3" ]];then + echo "IXUCA-3" + export ASCEND_RT_VISIBLE_DEVICES=8,9,10,11 + elif [[ "${{ runner.name }}" == "IXUCA-4" ]];then + echo "IXUCA-4" + export ASCEND_RT_VISIBLE_DEVICES=12,13,14,15 + else + echo echo "IXUCA-1" + export ASCEND_RT_VISIBLE_DEVICES=0,1,2,3 + fi + echo ${ASCEND_RT_VISIBLE_DEVICES} + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} docker run --shm-size=128G \ @@ -53,6 +68,7 @@ jobs: -e no_proxy \ -e USE_910B=1 \ -e FLAGS_npu_storage_format=0 \ + -e ASCEND_RT_VISIBLE_DEVICES=${ASCEND_RT_VISIBLE_DEVICES} \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v /usr/local/Ascend/driver:/usr/local/Ascend/driver \ diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index d21eea9fa24..246aa33ad65 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -50,7 +50,6 @@ jobs: -e COMMIT_ID \ -e BRANCH \ -e no_proxy \ - -e FLAGS_selected_intel_hpus=6 \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ @@ -86,7 +85,6 @@ jobs: mkdir -p /workspace/PaddleCustomDevice/backends/intel_hpu/build/ export GC_KERNEL_PATH=/workspace/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so cd /workspace - sleep 3d bash /workspace/PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' - name: Terminate and delete the container From 6606296de372c0f97318e128661842c89867bb61 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 03:04:23 +0000 Subject: [PATCH 56/85] Update --- .github/workflows/_IXUCA.yml | 109 +++++++++++++++++++++++++++++++++++ 1 file changed, 109 insertions(+) create mode 100644 .github/workflows/_IXUCA.yml diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml new file mode 100644 index 00000000000..341dbd05443 --- /dev/null +++ b/.github/workflows/_IXUCA.yml @@ -0,0 +1,109 @@ +name: PR-CI-IXUCA + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + PR-CI-HPU: + name: PR-CI-IXUCA + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: IXUCA + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-ixuca + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" + + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + - name: Check docker image and run container + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-ixuca:latest + run: | + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) + echo "container_name=${container_name}" >> ${{ github.env }} + docker run --shm-size=128G \ + -d -t --name ${container_name} \ + --privileged --network=host \ + -e PR_ID \ + -e COMMIT_ID \ + -e BRANCH \ + -e no_proxy \ + -e LD_LIBRARY_PATH=/usr/local/corex-4.3.0/lib \ + -e LIBRARY_PATH=/usr/local/corex-4.3.0/lib \ + -v ${cache_dir}:/root/.cache \ + -v ${ccache_dir}:/root/.ccache \ + -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ + -v ${{ github.workspace }}:/workspace -w /workspace \ + ${docker_image} /bin/bash + + - name: RUN IXUCA + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + source ${{ github.workspace }}/../../../proxy + set -x + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz + cd PaddleCustomDevice + git config --global --add safe.directory "*" + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git --no-pager log --pretty=oneline -5 + + # !!!!! SKIP IF NO IXUCA CHANGE !!!! + echo "=========== Checking PR Changes If IXUCA FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_ixuca_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/iluvatar_gpu"| wc -l) + git diff --name-only remotes/origin/${BRANCH} + + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run IXUCA FULL CI test ..." + elif [ $change_ixuca_only -eq 0 ] ; then + echo "NO IXUCA backend changes found, skip IXUCA FULL CI ...." + exit 0 + fi + + export PATH=/usr/local/corex-4.3.0/bin:$PATH + mkdir -p /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux + curl -o /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz http://paddlepaddledeps.bj.bcebos.com/csrmm_mklml_lnx_2019.0.5.tgz + tar xf /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz + # build + cd backends/iluvatar_gpu + bash build_paddle.sh + # Install + bash install_paddle.sh + # Run tests + cd tests + bash run_test.sh' + + - name: Terminate and delete the container + if: always() + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* + ' + docker stop ${container_name} + docker rm ${container_name} From abf833d02c27388b13b77cd2169db406598e4cab Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 03:20:27 +0000 Subject: [PATCH 57/85] Update --- .github/workflows/_IXUCA.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 341dbd05443..06cf04171f7 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -20,7 +20,7 @@ jobs: name: PR-CI-IXUCA if: ${{ github.repository_owner == 'PaddlePaddle' }} runs-on: - group: IXUCA + group: test2 env: PR_ID: ${{ github.event.pull_request.number }} COMMIT_ID: ${{ github.event.pull_request.head.sha }} From ce6bc9bebe722f16773d56bee60a32a99a7dbac2 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 08:53:45 +0000 Subject: [PATCH 58/85] update --- .github/workflows/_910B-ARM.yml | 1 - .github/workflows/_IXUCA.yml | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 69bb28d5c8d..12d6ea83821 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -32,7 +32,6 @@ jobs: - name: Cleanup run: | rm -rf * .[^.]* - - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 06cf04171f7..da8ce450f4c 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -90,6 +90,7 @@ jobs: mkdir -p /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux curl -o /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz http://paddlepaddledeps.bj.bcebos.com/csrmm_mklml_lnx_2019.0.5.tgz tar xf /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz + python3 -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ # build cd backends/iluvatar_gpu bash build_paddle.sh From bc0c9f0f4dd738fa7f537a8ea1555df4826a9026 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 10:35:02 +0000 Subject: [PATCH 59/85] update --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_IXUCA.yml | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 12d6ea83821..f1965f319c1 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -77,7 +77,7 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: RUN GCU + - name: RUN 910B-ARM run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index da8ce450f4c..9827fb50f15 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -91,6 +91,7 @@ jobs: curl -o /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz http://paddlepaddledeps.bj.bcebos.com/csrmm_mklml_lnx_2019.0.5.tgz tar xf /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz python3 -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ + python3 -m pip install parameterized # build cd backends/iluvatar_gpu bash build_paddle.sh From eee363ea988597c2dec231ce4ea7f98ccd5c9f64 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Mon, 20 Oct 2025 11:05:58 +0000 Subject: [PATCH 60/85] Update --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_910B-X86.yml | 29 ++++++++++++++++++++++++----- 2 files changed, 25 insertions(+), 6 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index f1965f319c1..28a55c956ce 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -25,7 +25,7 @@ jobs: PR_ID: ${{ github.event.pull_request.number }} COMMIT_ID: ${{ github.event.pull_request.head.sha }} BRANCH: develop - TASK: paddle-CI-${{ github.event.pull_request.number }}-gcu + TASK: paddle-CI-${{ github.event.pull_request.number }}-npu no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 3d2ffb40913..a12504ed52c 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -25,14 +25,13 @@ jobs: PR_ID: ${{ github.event.pull_request.number }} COMMIT_ID: ${{ github.event.pull_request.head.sha }} BRANCH: develop - TASK: paddle-CI-${{ github.event.pull_request.number }}-gcu + TASK: paddle-CI-${{ github.event.pull_request.number }}-npu no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: - name: Cleanup run: | rm -rf * .[^.]* - - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -40,8 +39,23 @@ jobs: RUN_ID: ${{ github.run_id }} cache_dir: /root/.cache ccache_dir: /root/.ccache - docker_image: registry.baidubce.com/device/paddle-npu:cann80RC1-ubuntu20-aarch64-gcc84-py39 + docker_image: ccr-2vdh3abv-pub.cnc.bj.baidubce.com/device/paddle-npu:cann80RC2-ubuntu20-npu-base-x86_64-gcc84 run: | + if [[ "${{ runner.name }}" == "npu-2" ]];then + echo "IXUCA-2" + export ASCEND_RT_VISIBLE_DEVICES=4,5,6,7 + elif [[ "${{ runner.name }}" == "npu-3" ]];then + echo "IXUCA-3" + export ASCEND_RT_VISIBLE_DEVICES=8,9,10,11 + elif [[ "${{ runner.name }}" == "npu-4" ]];then + echo "IXUCA-4" + export ASCEND_RT_VISIBLE_DEVICES=12,13,14,15 + else + echo echo "npu-1" + export ASCEND_RT_VISIBLE_DEVICES=0,1,2,3 + fi + echo ${ASCEND_RT_VISIBLE_DEVICES} + container_name=${TASK}-$(date +%Y%m%d-%H%M%S) echo "container_name=${container_name}" >> ${{ github.env }} docker run --shm-size=128G \ @@ -53,13 +67,17 @@ jobs: -e no_proxy \ -e USE_910B=1 \ -e FLAGS_npu_storage_format=0 \ + -e ASCEND_RT_VISIBLE_DEVICES=${ASCEND_RT_VISIBLE_DEVICES} \ -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ + -v /usr/local/Ascend/driver:/usr/local/Ascend/driver \ + -v /usr/local/bin/npu-smi:/usr/local/bin/npu-smi \ + -v /usr/local/dcmi:/usr/local/dcmi \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: RUN GCU + - name: RUN 910B-X86 run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy @@ -77,6 +95,8 @@ jobs: change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) change_npu_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/npu"| wc -l) + git diff --name-only remotes/origin/${BRANCH} + if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run NPU FULL CI test ..." elif [ $change_npu_only -eq 0 ] ; then @@ -97,7 +117,6 @@ jobs: python -c "import paddle; print(paddle.version.commit)" # Install python packages required for incremental coverage python -m pip install PyGithub - export LD_PRELOAD=/lib/aarch64-linux-gnu/libgomp.so.1:$LD_PRELOAD bash backends/npu/tools/pr_ci_npu.sh' From bcf8a46750ceac32a1e2a5d0ac2c7f9ec6a79ed0 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 02:54:46 +0000 Subject: [PATCH 61/85] Test --- .github/workflows/CI.yml | 5 +++++ .github/workflows/_IXUCA.yml | 1 + 2 files changed, 6 insertions(+) diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index fb196bfd24b..c52c7839d61 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -51,3 +51,8 @@ jobs: name: npu-910B-ARM uses: ./.github/workflows/_910B-ARM.yml needs: [Codestyle-Check] + + npu-910b-x86: + name: npu-910B-X86 + uses: ./.github/workflows/_910B-X86.yml + needs: [Codestyle-Check] diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 9827fb50f15..42ccab22f97 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -92,6 +92,7 @@ jobs: tar xf /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz python3 -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ python3 -m pip install parameterized + sleep 3d # build cd backends/iluvatar_gpu bash build_paddle.sh From 3ecfb6a89c483d9077f8a88470d6c8ab172101c4 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 07:04:40 +0000 Subject: [PATCH 62/85] Add Check bypass --- .github/workflows/_910B-ARM.yml | 10 ++++++++++ .github/workflows/_910B-X86.yml | 12 ++++++++++++ .github/workflows/_Codestyle-Check.yml | 9 +++++++++ .github/workflows/_GCU.yml | 9 +++++++++ .github/workflows/_HPU.yml | 10 ++++++++++ .github/workflows/_IXUCA.yml | 11 ++++++++++- .github/workflows/_MLU.yml | 9 +++++++++ 7 files changed, 69 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 28a55c956ce..654af0f27f5 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -32,7 +32,16 @@ jobs: - name: Cleanup run: | rm -rf * .[^.]* + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -78,6 +87,7 @@ jobs: ${docker_image} /bin/bash - name: RUN 910B-ARM + if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index a12504ed52c..ec6d3c6c4b3 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -32,7 +32,16 @@ jobs: - name: Cleanup run: | rm -rf * .[^.]* + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -78,6 +87,7 @@ jobs: ${docker_image} /bin/bash - name: RUN 910B-X86 + if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy @@ -110,6 +120,8 @@ jobs: PATH=/usr/local/bin:${PATH} ln -sf $(which python3.9) /usr/local/bin/python ln -sf $(which pip3.9) /usr/local/bin/pip + ln -sf $(which python3.9) /usr/bin/python + ln -sf $(which pip3.9) /usr/bin/pip pip install -U numpy==1.26.4 safetensors python -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 4b0b60ac63d..7c1b47c4860 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -32,7 +32,15 @@ jobs: run: | rm -rf * .[^.]* + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: python: "python3.10" GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -65,6 +73,7 @@ jobs: -w /paddle --network host ${docker_image} /bin/bash - name: Download PaddleCustomDevice.tar.gz + if: steps.check-bypass.outputs.can-skip != 'true' run: | set -x docker exec -t ${{ env.container_name }} /bin/bash -c ' diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 09e29abd21f..8f14c18d5a7 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -33,7 +33,15 @@ jobs: run: | rm -rf * .[^.]* + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -58,6 +66,7 @@ jobs: ${docker_image} /bin/bash - name: RUN GCU + if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 246aa33ad65..887c613a3fd 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -32,7 +32,16 @@ jobs: - name: Cleanup run: | rm -rf * .[^.]* + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -57,6 +66,7 @@ jobs: ${docker_image} /bin/bash - name: RUN HPU + if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 42ccab22f97..8c59f512ff0 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -32,7 +32,16 @@ jobs: - name: Cleanup run: | rm -rf * .[^.]* + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -59,6 +68,7 @@ jobs: ${docker_image} /bin/bash - name: RUN IXUCA + if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy @@ -92,7 +102,6 @@ jobs: tar xf /workspace/PaddleCustomDevice/Paddle/third_party/mklml/Linux/csrmm_mklml_lnx_2019.0.5.tgz python3 -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ python3 -m pip install parameterized - sleep 3d # build cd backends/iluvatar_gpu bash build_paddle.sh diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index f3e4d73c1d4..cb0b7c1fa74 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -33,7 +33,15 @@ jobs: run: | rm -rf * .[^.]* + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Check docker image and run container + if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -59,6 +67,7 @@ jobs: ${docker_image} /bin/bash - name: RUN MLU + if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy From 14920431c0ed67dd719349e9f06cd8c42d671ba9 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 07:13:31 +0000 Subject: [PATCH 63/85] Add Check bypass --- .github/workflows/cancel-CI.yml | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 .github/workflows/cancel-CI.yml diff --git a/.github/workflows/cancel-CI.yml b/.github/workflows/cancel-CI.yml new file mode 100644 index 00000000000..a52ae7ff73d --- /dev/null +++ b/.github/workflows/cancel-CI.yml @@ -0,0 +1,25 @@ +name: CI + +on: + pull_request: + types: [closed] + branches: [develop, release/**] + +permissions: read-all + +concurrency: + group: ${{ github.event.pull_request.number }}-${{ github.workflow }} + cancel-in-progress: true + +env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + +jobs: + cancel: + name: Cancel CI for ${{ github.event.pull_request.number }} + runs-on: ubuntu-latest + steps: + - name: Cancel CI + run: | + exit 0 From d065a8772bf2702c9fba77bed201f9e34cfdd7f9 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 07:24:27 +0000 Subject: [PATCH 64/85] Add Check bypass --- .github/actions/check-bypass/action.yml | 41 +++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/actions/check-bypass/action.yml diff --git a/.github/actions/check-bypass/action.yml b/.github/actions/check-bypass/action.yml new file mode 100644 index 00000000000..f293d6ba6c4 --- /dev/null +++ b/.github/actions/check-bypass/action.yml @@ -0,0 +1,41 @@ +name: "Check bypass" +description: "A custom action to encapsulate PFCCLab/ci-bypass" +inputs: + github-token: + description: "GitHub token" + required: true + workflow-name: + description: "Workflow name" + required: true +outputs: + can-skip: + description: "Whether the workflow can be skipped." + value: ${{ steps.check-bypass.outputs.can-skip }} + +runs: + using: "composite" + steps: + - id: check-bypass + name: Check Bypass + env: + CI_TEAM_MEMBERS: '["tianshuo78520a", "yongqiangma", "Yuqiang Ge"]' + uses: PFCCLab/ci-bypass@v2 + with: + github-token: ${{ inputs.github-token }} + non-pull-request-event-strategy: 'never-skipped' + type: 'composite' + composite-rule: | + { + "any": [ + { + "type": "labeled", + "label": ["skip-ci: ${{ inputs.workflow-name }}", "skip-ci: all"], + "username": ${{ env.CI_TEAM_MEMBERS }} + }, + { + "type": "commented", + "comment-pattern": [".*/skip-ci ${{ inputs.workflow-name }}.*", ".*/skip-ci all.*"], + "username": ${{ env.CI_TEAM_MEMBERS }} + } + ] + } From a88c2a8447af40a6d615f4e32351728e13c19a83 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 07:41:32 +0000 Subject: [PATCH 65/85] update check-bypass --- .github/workflows/_910B-ARM.yml | 15 +++++++-------- .github/workflows/_910B-X86.yml | 15 +++++++-------- .github/workflows/_Codestyle-Check.yml | 15 +++++++-------- .github/workflows/_GCU.yml | 15 +++++++-------- .github/workflows/_HPU.yml | 15 +++++++-------- .github/workflows/_IXUCA.yml | 15 +++++++-------- .github/workflows/_MLU.yml | 15 +++++++-------- 7 files changed, 49 insertions(+), 56 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 654af0f27f5..d1ed02f86b2 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -33,15 +33,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -86,6 +78,13 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: 910b-arm + - name: RUN 910B-ARM if: steps.check-bypass.outputs.can-skip != 'true' run: | diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index ec6d3c6c4b3..297737821f3 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -33,15 +33,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -86,6 +78,13 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: 910b-x86 + - name: RUN 910B-X86 if: steps.check-bypass.outputs.can-skip != 'true' run: | diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 7c1b47c4860..452c8932ef7 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -32,15 +32,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: python: "python3.10" GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -72,6 +64,13 @@ jobs: -e GITHUB_API_TOKEN \ -w /paddle --network host ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + - name: Download PaddleCustomDevice.tar.gz if: steps.check-bypass.outputs.can-skip != 'true' run: | diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 8f14c18d5a7..15141548b0e 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -33,15 +33,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -65,6 +57,13 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: gcu + - name: RUN GCU if: steps.check-bypass.outputs.can-skip != 'true' run: | diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 887c613a3fd..ae85cb5c110 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -33,15 +33,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -65,6 +57,13 @@ jobs: -v ${{ github.workspace }}:/workspace -w /workspace \ ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: hpu + - name: RUN HPU if: steps.check-bypass.outputs.can-skip != 'true' run: | diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 8c59f512ff0..f00144e7dc3 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -33,15 +33,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -67,6 +59,13 @@ jobs: -v ${{ github.workspace }}:/workspace -w /workspace \ ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: ixuca + - name: RUN IXUCA if: steps.check-bypass.outputs.can-skip != 'true' run: | diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index cb0b7c1fa74..0a6488b7408 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -33,15 +33,7 @@ jobs: run: | rm -rf * .[^.]* - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Check docker image and run container - if: steps.check-bypass.outputs.can-skip != 'true' env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -66,6 +58,13 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: mlu + - name: RUN MLU if: steps.check-bypass.outputs.can-skip != 'true' run: | From 93baa97e4dffab349ce8a11d195210bc900653a7 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 07:52:42 +0000 Subject: [PATCH 66/85] update check-bypass --- .github/workflows/_Codestyle-Check.yml | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 452c8932ef7..9a1af02a4d0 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -64,15 +64,7 @@ jobs: -e GITHUB_API_TOKEN \ -w /paddle --network host ${docker_image} /bin/bash - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: codestyle - - name: Download PaddleCustomDevice.tar.gz - if: steps.check-bypass.outputs.can-skip != 'true' run: | set -x docker exec -t ${{ env.container_name }} /bin/bash -c ' @@ -82,8 +74,18 @@ jobs: git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit pip install cpplint==1.6.0 - pre-commit install - bash tools/codestyle/pre_commit.sh ' + pre-commit install' + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: codestyle + + - name: RUN Codestyle Check + if: steps.check-bypass.outputs.can-skip != 'true' + run: bash tools/codestyle/pre_commit.sh - name: Terminate and delete the container if: always() From 6246b6156680f931fe9373605555caff6562501e Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 08:03:30 +0000 Subject: [PATCH 67/85] update check-bypass --- .github/workflows/_Codestyle-Check.yml | 5 +++-- .github/workflows/_GCU.yml | 23 +++++++++++++---------- 2 files changed, 16 insertions(+), 12 deletions(-) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 9a1af02a4d0..43d729c1eef 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -66,7 +66,6 @@ jobs: - name: Download PaddleCustomDevice.tar.gz run: | - set -x docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" @@ -85,7 +84,9 @@ jobs: - name: RUN Codestyle Check if: steps.check-bypass.outputs.can-skip != 'true' - run: bash tools/codestyle/pre_commit.sh + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' + bash tools/codestyle/pre_commit.sh' - name: Terminate and delete the container if: always() diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 15141548b0e..9bb70ef0d46 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -57,15 +57,7 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: gcu - - name: RUN GCU - if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy @@ -76,8 +68,19 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git --no-pager log --pretty=oneline -5 + git --no-pager log --pretty=oneline -5' + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: gcu + + - name: RUN GCU + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO GCU CHANGE !!!! echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) @@ -91,7 +94,7 @@ jobs: echo "NO GCU backend changes found, skip GCU FULL CI ...." exit 0 fi - bash backends/gcu/ci_test.sh ' + bash backends/gcu/ci_test.sh' - name: Terminate and delete the container if: always() From d4087413ed1f5af13daf33cd9197877a3fc5de2f Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 08:24:25 +0000 Subject: [PATCH 68/85] update check-bypass --- .github/workflows/_910B-ARM.yml | 25 +++++++++++++----------- .github/workflows/_910B-X86.yml | 25 +++++++++++++----------- .github/workflows/_Codestyle-Check.yml | 2 +- .github/workflows/_GCU.yml | 6 +++--- .github/workflows/_HPU.yml | 27 ++++++++++++++------------ .github/workflows/_IXUCA.yml | 25 +++++++++++++----------- .github/workflows/_MLU.yml | 23 ++++++++++++---------- 7 files changed, 74 insertions(+), 59 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index d1ed02f86b2..b85a649b989 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -78,17 +78,9 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: 910b-arm - - - name: RUN 910B-ARM - if: steps.check-bypass.outputs.can-skip != 'true' + - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' + docker exec -t ${{ env.container_name }} /bin/bash -c' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -97,8 +89,19 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git --no-pager log --pretty=oneline -5 + git --no-pager log --pretty=oneline -5' + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: 910b-arm + + - name: RUN 910B-ARM + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c' # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 297737821f3..847f57f495c 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -78,17 +78,9 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: 910b-x86 - - - name: RUN 910B-X86 - if: steps.check-bypass.outputs.can-skip != 'true' + - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' + docker exec -t ${{ env.container_name }} /bin/bash -c' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -97,8 +89,19 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git --no-pager log --pretty=oneline -5 + git --no-pager log --pretty=oneline -5' + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: 910b-x86 + + -name: RUN 910B-X86 + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c' # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_Codestyle-Check.yml b/.github/workflows/_Codestyle-Check.yml index 43d729c1eef..ba38f0febdd 100644 --- a/.github/workflows/_Codestyle-Check.yml +++ b/.github/workflows/_Codestyle-Check.yml @@ -64,7 +64,7 @@ jobs: -e GITHUB_API_TOKEN \ -w /paddle --network host ${docker_image} /bin/bash - - name: Download PaddleCustomDevice.tar.gz + - name: Download Code run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index 9bb70ef0d46..e0deeed3145 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -57,9 +57,9 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash - - name: RUN GCU + - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' + docker exec -t ${{ env.container_name }} /bin/bash -c' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -80,7 +80,7 @@ jobs: - name: RUN GCU if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' + docker exec -t ${{ env.container_name }} /bin/bash -c' # !!!!! SKIP IF NO GCU CHANGE !!!! echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index ae85cb5c110..98644bd0361 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -57,17 +57,9 @@ jobs: -v ${{ github.workspace }}:/workspace -w /workspace \ ${docker_image} /bin/bash - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: hpu - - - name: RUN HPU - if: steps.check-bypass.outputs.can-skip != 'true' + - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' + docker exec -t ${{ env.container_name }} /bin/bash -c' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -77,8 +69,19 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git --no-pager log --pretty=oneline -5 + git --no-pager log --pretty=oneline -5' + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: hpu + + - name: RUN HPU + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO HPU CHANGE !!!! echo "=========== Checking PR Changes If HPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) @@ -94,7 +97,7 @@ jobs: mkdir -p /workspace/PaddleCustomDevice/backends/intel_hpu/build/ export GC_KERNEL_PATH=/workspace/PaddleCustomDevice/backends/intel_hpu/build/libcustom_tpc_perf_lib.so:/usr/lib/habanalabs/libtpc_kernels.so cd /workspace - bash /workspace/PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh ' + bash /workspace/PaddleCustomDevice/backends/intel_hpu/tools/pr_hpu_ci.sh' - name: Terminate and delete the container if: always() diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index f00144e7dc3..0bcd957cd59 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -59,17 +59,9 @@ jobs: -v ${{ github.workspace }}:/workspace -w /workspace \ ${docker_image} /bin/bash - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: ixuca - - - name: RUN IXUCA - if: steps.check-bypass.outputs.can-skip != 'true' + - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' + docker exec -t ${{ env.container_name }} /bin/bash -c' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate @@ -79,8 +71,19 @@ jobs: git config --global --add safe.directory "*" git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git git merge ${BRANCH} --no-edit - git --no-pager log --pretty=oneline -5 + git --no-pager log --pretty=oneline -5' + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: ixuca + + - name: RUN IXUCA + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c' # !!!!! SKIP IF NO IXUCA CHANGE !!!! echo "=========== Checking PR Changes If IXUCA FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 0a6488b7408..02f5d60806a 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -58,6 +58,18 @@ jobs: -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ ${docker_image} /bin/bash + - name: Download Code + run: | + docker exec -t ${{ env.container_name }} /bin/bash -c' + source ${{ github.workspace }}/../../../proxy + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git config --global --add safe.directory "*" + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git --no-pager log --pretty=oneline -5' + - name: Check bypass id: check-bypass uses: ./.github/actions/check-bypass @@ -68,16 +80,7 @@ jobs: - name: RUN MLU if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c ' - source ${{ github.workspace }}/../../../proxy - wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate - echo "Extracting PaddleCustomDevice.tar.gz" - tar -xf PaddleCustomDevice.tar.gz --strip-components=1 - git config --global --add safe.directory "*" - git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git - git merge ${BRANCH} --no-edit - git --no-pager log --pretty=oneline -5 - + docker exec -t ${{ env.container_name }} /bin/bash -c' # !!!!! SKIP IF NO MLU CHANGE !!!! echo "=========== Checking PR Changes If MLU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) From 840deba688425acf775a0b9ebc9379497d6a979d Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 08:29:19 +0000 Subject: [PATCH 69/85] update check-bypass --- .github/workflows/_910B-X86.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 847f57f495c..e5070483555 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -98,7 +98,7 @@ jobs: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: 910b-x86 - -name: RUN 910B-X86 + - name: RUN 910B-X86 if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c' From 0bae39cfc0949fcc97a3cca118f4544631ffbd93 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 08:49:43 +0000 Subject: [PATCH 70/85] update check-bypass --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_910B-X86.yml | 2 +- .github/workflows/_GCU.yml | 2 +- .github/workflows/_HPU.yml | 2 +- .github/workflows/_IXUCA.yml | 2 +- .github/workflows/_MLU.yml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index b85a649b989..19db97a9826 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -80,7 +80,7 @@ jobs: - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index e5070483555..64c6db9b9ee 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -80,7 +80,7 @@ jobs: - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index e0deeed3145..ccd85f33992 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -59,7 +59,7 @@ jobs: - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 98644bd0361..6d5c2c66b2a 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -59,7 +59,7 @@ jobs: - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 0bcd957cd59..84b8717fbdb 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -61,7 +61,7 @@ jobs: - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 02f5d60806a..72259198b26 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -60,7 +60,7 @@ jobs: - name: Download Code run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" From 7150b2673cf910017de564bc400a85e72c593473 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 09:23:54 +0000 Subject: [PATCH 71/85] update check-bypass --- .github/workflows/_910B-ARM.yml | 4 ++-- .github/workflows/_910B-X86.yml | 4 ++-- .github/workflows/_GCU.yml | 4 ++-- .github/workflows/_HPU.yml | 2 +- .github/workflows/_IXUCA.yml | 4 ++-- .github/workflows/_MLU.yml | 4 ++-- 6 files changed, 11 insertions(+), 11 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 19db97a9826..1bf22689ef9 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -75,7 +75,7 @@ jobs: -v /usr/local/bin/npu-smi:/usr/local/bin/npu-smi \ -v /usr/local/dcmi:/usr/local/dcmi \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ - -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + -v ${{ github.workspace }}:/_910B-ARM.yml -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: Download Code @@ -101,7 +101,7 @@ jobs: - name: RUN 910B-ARM if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 64c6db9b9ee..99a69d9917e 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -75,7 +75,7 @@ jobs: -v /usr/local/bin/npu-smi:/usr/local/bin/npu-smi \ -v /usr/local/dcmi:/usr/local/dcmi \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ - -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + -v ${{ github.workspace }}:/PaddleCustomDevice -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: Download Code @@ -101,7 +101,7 @@ jobs: - name: RUN 910B-X86 if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO NPU CHANGE !!!! echo "=========== Checking PR Changes If NPU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index ccd85f33992..b5e6fb46995 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -54,7 +54,7 @@ jobs: -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ - -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + -v ${{ github.workspace }}:/PaddleCustomDevice -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: Download Code @@ -80,7 +80,7 @@ jobs: - name: RUN GCU if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO GCU CHANGE !!!! echo "=========== Checking PR Changes If GCU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 6d5c2c66b2a..75977856f80 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -73,7 +73,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/actions/check-bypass + uses: ./PaddleCustomDevice/.github/actions/check-bypass with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: hpu diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index 84b8717fbdb..f34b85b2aec 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -75,7 +75,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/actions/check-bypass + uses: ./PaddleCustomDevice/.github/actions/check-bypass with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: ixuca @@ -83,7 +83,7 @@ jobs: - name: RUN IXUCA if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO IXUCA CHANGE !!!! echo "=========== Checking PR Changes If IXUCA FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 72259198b26..f17e64bd7d1 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -55,7 +55,7 @@ jobs: -v ${cache_dir}:/root/.cache \ -v ${ccache_dir}:/root/.ccache \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ - -v ${{ github.workspace }}:/paddle -w /PaddleCustomDevice \ + -v ${{ github.workspace }}:/PaddleCustomDevice -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: Download Code @@ -80,7 +80,7 @@ jobs: - name: RUN MLU if: steps.check-bypass.outputs.can-skip != 'true' run: | - docker exec -t ${{ env.container_name }} /bin/bash -c' + docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO MLU CHANGE !!!! echo "=========== Checking PR Changes If MLU FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) From 4977aa09befc0be834996606187cbdd4f944a034 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 11:02:24 +0000 Subject: [PATCH 72/85] update --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_HPU.yml | 2 ++ .github/workflows/_IXUCA.yml | 1 + .github/workflows/_MLU.yml | 2 ++ 4 files changed, 6 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 1bf22689ef9..03ad3d1e463 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -75,7 +75,7 @@ jobs: -v /usr/local/bin/npu-smi:/usr/local/bin/npu-smi \ -v /usr/local/dcmi:/usr/local/dcmi \ -v ${{ github.workspace }}/../../..:${{ github.workspace }}/../../.. \ - -v ${{ github.workspace }}:/_910B-ARM.yml -w /PaddleCustomDevice \ + -v ${{ github.workspace }}:/PaddleCustomDevice -w /PaddleCustomDevice \ ${docker_image} /bin/bash - name: Download Code diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 75977856f80..be962a9443e 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -74,6 +74,8 @@ jobs: - name: Check bypass id: check-bypass uses: ./PaddleCustomDevice/.github/actions/check-bypass + env: + LD_LIBRARY_PATH: "/home/opt/compiler/gcc-12/lib:$LD_LIBRARY_PATH" with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: hpu diff --git a/.github/workflows/_IXUCA.yml b/.github/workflows/_IXUCA.yml index f34b85b2aec..045437e9fed 100644 --- a/.github/workflows/_IXUCA.yml +++ b/.github/workflows/_IXUCA.yml @@ -84,6 +84,7 @@ jobs: if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' + cd /workspace/PaddleCustomDevice # !!!!! SKIP IF NO IXUCA CHANGE !!!! echo "=========== Checking PR Changes If IXUCA FULL CI Needed ===========" change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index f17e64bd7d1..2c09971aba5 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -73,6 +73,8 @@ jobs: - name: Check bypass id: check-bypass uses: ./.github/actions/check-bypass + env: + LD_LIBRARY_PATH: "/home/opt/compiler/gcc-12/lib:$LD_LIBRARY_PATH" with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: mlu From 49e92492c1ae635e5f098f468e9792bc384f29e7 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Tue, 21 Oct 2025 11:23:22 +0000 Subject: [PATCH 73/85] update --- .github/workflows/_910B-ARM.yml | 4 +++- .github/workflows/_910B-X86.yml | 2 +- .github/workflows/_HPU.yml | 4 +--- .github/workflows/_MLU.yml | 4 +--- 4 files changed, 6 insertions(+), 8 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 03ad3d1e463..90c19edacaf 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -93,7 +93,9 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/actions/check-bypass + uses: ./.github/workflows/check-bypass + env: + LD_LIBRARY_PATH: "/home/opt/compiler/gcc-8.2/gcc-8.2/lib:$LD_LIBRARY_PATH" with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: 910b-arm diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 99a69d9917e..95c28b18720 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -93,7 +93,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/actions/check-bypass + uses: ./.github/workflows/check-bypass with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: 910b-x86 diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index be962a9443e..e4c3ff658d6 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -73,9 +73,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./PaddleCustomDevice/.github/actions/check-bypass - env: - LD_LIBRARY_PATH: "/home/opt/compiler/gcc-12/lib:$LD_LIBRARY_PATH" + uses: ./PaddleCustomDevice/.github/workflows/check-bypass with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: hpu diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 2c09971aba5..3285dcd19d8 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -72,9 +72,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/actions/check-bypass - env: - LD_LIBRARY_PATH: "/home/opt/compiler/gcc-12/lib:$LD_LIBRARY_PATH" + uses: ./.github/workflows/check-bypass with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: mlu From 49aa398f021fbe70dae721a9ac1654c2ee9dc513 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 00:38:15 +0000 Subject: [PATCH 74/85] Update --- .github/workflows/_910B-ARM.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 90c19edacaf..59317b99362 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -95,7 +95,7 @@ jobs: id: check-bypass uses: ./.github/workflows/check-bypass env: - LD_LIBRARY_PATH: "/home/opt/compiler/gcc-8.2/gcc-8.2/lib:$LD_LIBRARY_PATH" + LD_LIBRARY_PATH: "/home/opt/compiler/gcc-8.2/gcc-8.2/lib:$LD_LIBRARY_PATH" with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: 910b-arm From 7c9d42df59dce791b634393ed7f0ac9ecee1adc7 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 00:56:05 +0000 Subject: [PATCH 75/85] Update --- .github/workflows/_910B-ARM.yml | 2 +- .github/workflows/_910B-X86.yml | 2 +- .github/workflows/_HPU.yml | 2 +- .github/workflows/_MLU.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 59317b99362..41d71de1389 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -93,7 +93,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/workflows/check-bypass + uses: ./.github/actions/check-bypass env: LD_LIBRARY_PATH: "/home/opt/compiler/gcc-8.2/gcc-8.2/lib:$LD_LIBRARY_PATH" with: diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 95c28b18720..224c19df248 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -93,7 +93,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/workflows/check-bypass + uses: ./.github/workflows/check-bypass.yml with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: 910b-x86 diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index e4c3ff658d6..535ecacd75b 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -73,7 +73,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./PaddleCustomDevice/.github/workflows/check-bypass + uses: ./PaddleCustomDevice/.github/workflows/check-bypass.yml with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: hpu diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 3285dcd19d8..63e4cfcfa8a 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -72,7 +72,7 @@ jobs: - name: Check bypass id: check-bypass - uses: ./.github/workflows/check-bypass + uses: ./.github/workflows/check-bypass.yml with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: mlu From 4655ee51148c0b41470c6c5741b209f086521d3b Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 01:14:08 +0000 Subject: [PATCH 76/85] Update --- .github/workflows/_910B-ARM.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 41d71de1389..cca931e3135 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -95,7 +95,7 @@ jobs: id: check-bypass uses: ./.github/actions/check-bypass env: - LD_LIBRARY_PATH: "/home/opt/compiler/gcc-8.2/gcc-8.2/lib:$LD_LIBRARY_PATH" + LD_LIBRARY_PATH: "/opt/compiler/gcc-8.2/lib:$LD_LIBRARY_PATH" with: github-token: ${{ secrets.GITHUB_TOKEN }} workflow-name: 910b-arm From ac62e4a698b5b2dc83cedfe6f8aa5ee4368b8007 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 01:52:27 +0000 Subject: [PATCH 77/85] Update --- .github/workflows/_910B-X86.yml | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index 224c19df248..e6896d445b4 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -16,9 +16,19 @@ on: default: 'true' jobs: + check-bypass: + name: Check bypass + if: ${{ inputs.can-skip != 'true' }} + uses: ./.github/workflows/check-bypass.yml + with: + workflow-name: '910b-x86' + secrets: + github-token: ${{ secrets.GITHUB_TOKEN }} + PR-CI-910B-X86: name: PR-CI-910B-X86 - if: ${{ github.repository_owner == 'PaddlePaddle' }} + needs: check-bypass + if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: NPU env: @@ -91,15 +101,7 @@ jobs: git merge ${BRANCH} --no-edit git --no-pager log --pretty=oneline -5' - - name: Check bypass - id: check-bypass - uses: ./.github/workflows/check-bypass.yml - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: 910b-x86 - - name: RUN 910B-X86 - if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO NPU CHANGE !!!! From b48e57bb48766ef53f9446ab3f75ed8f6cc5abca Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 02:06:37 +0000 Subject: [PATCH 78/85] Update --- .github/workflows/_910B-X86.yml | 1 - .github/workflows/check-bypass.yml | 52 ++++++++++++++++++++++++++++++ 2 files changed, 52 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/check-bypass.yml diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index e6896d445b4..fec64f23583 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -18,7 +18,6 @@ on: jobs: check-bypass: name: Check bypass - if: ${{ inputs.can-skip != 'true' }} uses: ./.github/workflows/check-bypass.yml with: workflow-name: '910b-x86' diff --git a/.github/workflows/check-bypass.yml b/.github/workflows/check-bypass.yml new file mode 100644 index 00000000000..e0281925b53 --- /dev/null +++ b/.github/workflows/check-bypass.yml @@ -0,0 +1,52 @@ +on: + workflow_call: + inputs: + workflow-name: + required: true + type: string + secrets: + github-token: + required: true + outputs: + can-skip: + description: "Whether the workflow can be skipped." + value: ${{ jobs.check-bypass.outputs.can-skip }} + +jobs: + check-bypass: + name: Check bypass + runs-on: + group: APPROVAL + permissions: + contents: read + env: + CI_TEAM_MEMBERS: '["tianshuo78520a", "yongqiangma", "Yuqiang Ge"]' + outputs: + can-skip: ${{ steps.check-bypass.outputs.can-skip }} + steps: + - name: Cleanup + run: | + rm -rf * .[^.]* + + - id: check-bypass + name: Check Bypass + uses: PFCCLab/ci-bypass@v2 + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + non-pull-request-event-strategy: 'never-skipped' + type: 'composite' + composite-rule: | + { + "any": [ + { + "type": "labeled", + "label": ["skip-ci: ${{ inputs.workflow-name }}", "skip-ci: all"], + "username": ${{ env.CI_TEAM_MEMBERS }} + }, + { + "type": "commented", + "comment-pattern": [".*/skip-ci ${{ inputs.workflow-name }}.*", ".*/skip-ci all.*"], + "username": ${{ env.CI_TEAM_MEMBERS }} + } + ] + } From 55073096650763717bbe05603b96fc27ce1f6b8a Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 02:19:38 +0000 Subject: [PATCH 79/85] Update --- .github/workflows/_910B-ARM.yml | 21 ++++++++++----------- .github/workflows/_910B-X86.yml | 6 ++---- .github/workflows/_HPU.yml | 19 ++++++++++--------- .github/workflows/_MLU.yml | 18 ++++++++++-------- 4 files changed, 32 insertions(+), 32 deletions(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index cca931e3135..7e423aefd2a 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -16,9 +16,18 @@ on: default: 'true' jobs: + check-bypass: + name: Check bypass + if: ${{ inputs.can-skip != 'true' }} + uses: ./.github/workflows/check-bypass.yml + with: + workflow-name: '910b-arm' + secrets: + github-token: ${{ secrets.GITHUB_TOKEN }} + PR-CI-910B-ARM: name: PR-CI-910B-ARM - if: ${{ github.repository_owner == 'PaddlePaddle' }} + if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: 910B-ARM env: @@ -91,17 +100,7 @@ jobs: git merge ${BRANCH} --no-edit git --no-pager log --pretty=oneline -5' - - name: Check bypass - id: check-bypass - uses: ./.github/actions/check-bypass - env: - LD_LIBRARY_PATH: "/opt/compiler/gcc-8.2/lib:$LD_LIBRARY_PATH" - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: 910b-arm - - name: RUN 910B-ARM - if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO NPU CHANGE !!!! diff --git a/.github/workflows/_910B-X86.yml b/.github/workflows/_910B-X86.yml index fec64f23583..899248a35c5 100644 --- a/.github/workflows/_910B-X86.yml +++ b/.github/workflows/_910B-X86.yml @@ -121,10 +121,8 @@ jobs: source ~/.bashrc echo "============ Install PaddlePaddle CPU =============" PATH=/usr/local/bin:${PATH} - ln -sf $(which python3.9) /usr/local/bin/python - ln -sf $(which pip3.9) /usr/local/bin/pip - ln -sf $(which python3.9) /usr/bin/python - ln -sf $(which pip3.9) /usr/bin/pip + ln -sf $(which python3.10) /usr/local/bin/python + ln -sf $(which pip3.10) /usr/local/bin/pip pip install -U numpy==1.26.4 safetensors python -m pip install --pre paddlepaddle -i https://www.paddlepaddle.org.cn/packages/nightly/cpu/ diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 535ecacd75b..d043d5783d2 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -16,9 +16,18 @@ on: default: 'true' jobs: + check-bypass: + name: Check bypass + if: ${{ inputs.can-skip != 'true' }} + uses: ./.github/workflows/check-bypass.yml + with: + workflow-name: 'hpu' + secrets: + github-token: ${{ secrets.GITHUB_TOKEN }} + PR-CI-HPU: name: PR-CI-HPU - if: ${{ github.repository_owner == 'PaddlePaddle' }} + if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: HPU env: @@ -71,15 +80,7 @@ jobs: git merge ${BRANCH} --no-edit git --no-pager log --pretty=oneline -5' - - name: Check bypass - id: check-bypass - uses: ./PaddleCustomDevice/.github/workflows/check-bypass.yml - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: hpu - - name: RUN HPU - if: steps.check-bypass.outputs.can-skip != 'true' run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' # !!!!! SKIP IF NO HPU CHANGE !!!! diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 63e4cfcfa8a..133b46e9ade 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -16,9 +16,18 @@ on: default: 'true' jobs: + check-bypass: + name: Check bypass + if: ${{ inputs.can-skip != 'true' }} + uses: ./.github/workflows/check-bypass.yml + with: + workflow-name: 'mlu' + secrets: + github-token: ${{ secrets.GITHUB_TOKEN }} + PR-CI-MLU: name: PR-CI-MLU - if: ${{ github.repository_owner == 'PaddlePaddle' }} + if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: MLU env: @@ -70,13 +79,6 @@ jobs: git merge ${BRANCH} --no-edit git --no-pager log --pretty=oneline -5' - - name: Check bypass - id: check-bypass - uses: ./.github/workflows/check-bypass.yml - with: - github-token: ${{ secrets.GITHUB_TOKEN }} - workflow-name: mlu - - name: RUN MLU if: steps.check-bypass.outputs.can-skip != 'true' run: | From 97f67e610cc663e0953e1f027a4b83858d7d6d04 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 02:34:27 +0000 Subject: [PATCH 80/85] Update --- .github/workflows/_910B-ARM.yml | 1 + .github/workflows/_Clone-linux.yml | 3 ++- .github/workflows/_HPU.yml | 1 + .github/workflows/_MLU.yml | 1 + 4 files changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/workflows/_910B-ARM.yml b/.github/workflows/_910B-ARM.yml index 7e423aefd2a..f09a2857e83 100644 --- a/.github/workflows/_910B-ARM.yml +++ b/.github/workflows/_910B-ARM.yml @@ -27,6 +27,7 @@ jobs: PR-CI-910B-ARM: name: PR-CI-910B-ARM + needs: check-bypass if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: 910B-ARM diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index c29123c2eb6..bddad3b1fa9 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -60,7 +60,8 @@ jobs: git fetch origin pull/${{ github.event.pull_request.number }}/head git checkout -b test FETCH_HEAD git merge --no-edit ${BRANCH} - git submodule sync && git submodule update --init + git submodule sync + git submodule update --init --remote --recursive - name: Download bos client env: diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index d043d5783d2..05cede2c213 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -27,6 +27,7 @@ jobs: PR-CI-HPU: name: PR-CI-HPU + needs: check-bypass if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: HPU diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index 133b46e9ade..a957a69202d 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -27,6 +27,7 @@ jobs: PR-CI-MLU: name: PR-CI-MLU + needs: check-bypass if: ${{ needs.check-bypass.outputs.can-skip != 'true' }} runs-on: group: MLU From a160b0534db305b9e43156c43187d0c2ed64b0c0 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 02:34:45 +0000 Subject: [PATCH 81/85] Update --- .github/workflows/_GCU.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index b5e6fb46995..c6f7f55c037 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -100,6 +100,7 @@ jobs: if: always() run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' + sleep 3d rm -rf * .[^.]* ' docker stop ${container_name} From c32c882ec74ea54ce6288fea4ca0ca538b6c83d7 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 02:42:07 +0000 Subject: [PATCH 82/85] Update --- .github/workflows/_Clone-linux.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/_Clone-linux.yml b/.github/workflows/_Clone-linux.yml index bddad3b1fa9..ace1d9a49c6 100644 --- a/.github/workflows/_Clone-linux.yml +++ b/.github/workflows/_Clone-linux.yml @@ -61,7 +61,7 @@ jobs: git checkout -b test FETCH_HEAD git merge --no-edit ${BRANCH} git submodule sync - git submodule update --init --remote --recursive + git submodule update --init --recursive --force - name: Download bos client env: From fd7ef6f8eeb9fd5415b1f7fa20d5016312e14893 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Wed, 22 Oct 2025 05:57:11 +0000 Subject: [PATCH 83/85] Update --- .github/workflows/_GCU.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index c6f7f55c037..b5e6fb46995 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -100,7 +100,6 @@ jobs: if: always() run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' - sleep 3d rm -rf * .[^.]* ' docker stop ${container_name} From 3dcc6f40395fc899a024b1342c6e258c67eb9abc Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 23 Oct 2025 06:02:59 +0000 Subject: [PATCH 84/85] update --- .github/workflows/CI.yml | 5 +++ .github/workflows/_GCU.yml | 5 +-- .github/workflows/_HPU.yml | 5 +-- .github/workflows/_MLU.yml | 5 +-- .github/workflows/_SDAA.yml | 73 +++++++++++++++++++++++++++++++++++++ 5 files changed, 81 insertions(+), 12 deletions(-) create mode 100644 .github/workflows/_SDAA.yml diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index c52c7839d61..e1ff7901175 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -47,6 +47,11 @@ jobs: uses: ./.github/workflows/_IXUCA.yml needs: [Codestyle-Check] + sdaa: + name: sdaa + uses: ./.github/workflows/_SDAA.yml + needs: [Codestyle-Check] + npu-910b-arm: name: npu-910B-ARM uses: ./.github/workflows/_910B-ARM.yml diff --git a/.github/workflows/_GCU.yml b/.github/workflows/_GCU.yml index b5e6fb46995..ffbb7f36182 100644 --- a/.github/workflows/_GCU.yml +++ b/.github/workflows/_GCU.yml @@ -29,10 +29,6 @@ jobs: no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: - - name: Cleanup - run: | - rm -rf * .[^.]* - - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -61,6 +57,7 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy + rm -rf * .[^.]* set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" diff --git a/.github/workflows/_HPU.yml b/.github/workflows/_HPU.yml index 05cede2c213..e7e3277d3e0 100644 --- a/.github/workflows/_HPU.yml +++ b/.github/workflows/_HPU.yml @@ -39,10 +39,6 @@ jobs: no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: - - name: Cleanup - run: | - rm -rf * .[^.]* - - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -70,6 +66,7 @@ jobs: - name: Download Code run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' + rm -rf * .[^.]* source ${{ github.workspace }}/../../../proxy set -x wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate diff --git a/.github/workflows/_MLU.yml b/.github/workflows/_MLU.yml index a957a69202d..28efd999543 100644 --- a/.github/workflows/_MLU.yml +++ b/.github/workflows/_MLU.yml @@ -39,10 +39,6 @@ jobs: no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" steps: - - name: Cleanup - run: | - rm -rf * .[^.]* - - name: Check docker image and run container env: GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} @@ -72,6 +68,7 @@ jobs: run: | docker exec -t ${{ env.container_name }} /bin/bash -c ' source ${{ github.workspace }}/../../../proxy + rm -rf * .[^.]* wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate echo "Extracting PaddleCustomDevice.tar.gz" tar -xf PaddleCustomDevice.tar.gz --strip-components=1 diff --git a/.github/workflows/_SDAA.yml b/.github/workflows/_SDAA.yml new file mode 100644 index 00000000000..cbfd0b6e126 --- /dev/null +++ b/.github/workflows/_SDAA.yml @@ -0,0 +1,73 @@ +name: PR-CI-SDAA + +on: + workflow_call: + inputs: + workflow-name: + type: string + required: false + clone_dir: + type: string + required: false + default: 'PaddlecustomDevice' + is_pr: + type: string + required: false + default: 'true' + +jobs: + PR-CI-SDAA: + name: PR-CI-SDAA + if: ${{ github.repository_owner == 'PaddlePaddle' }} + runs-on: + group: SDAA + env: + PR_ID: ${{ github.event.pull_request.number }} + COMMIT_ID: ${{ github.event.pull_request.head.sha }} + BRANCH: develop + TASK: paddle-CI-${{ github.event.pull_request.number }}-sdaa + no_proxy: "bcebos.com,apiin.im.baidu.com,gitee.com,aliyun.com,.baidu.com,.tuna.tsinghua.edu.cn" + + steps: + - name: Download Code + env: + GIT_PR_ID: ${{ github.event.pull_request.number || '0' }} + GITHUB_API_TOKEN: ${{ secrets.GITHUB_TOKEN }} + RUN_ID: ${{ github.run_id }} + cache_dir: /root/.cache + ccache_dir: /root/.ccache + run: | + rm -rf * .[^.]* + set -x + wget -q --tries=5 --no-proxy https://paddle-github-action.bj.bcebos.com/PaddleCustomDevice/PR/${PR_ID}/${COMMIT_ID}/PaddleCustomDevice.tar.gz --no-check-certificate + echo "Extracting PaddleCustomDevice.tar.gz" + tar -xf PaddleCustomDevice.tar.gz --strip-components=1 + git config --global --add safe.directory "*" + git remote add upstream https://github.com/PaddlePaddle/PaddleCustomDevice.git + git merge ${BRANCH} --no-edit + git --no-pager log --pretty=oneline -5 + + - name: Check bypass + id: check-bypass + uses: ./.github/actions/check-bypass + with: + github-token: ${{ secrets.GITHUB_TOKEN }} + workflow-name: sdaa + + - name: RUN SDAA + if: steps.check-bypass.outputs.can-skip != 'true' + run: | + # !!!!! SKIP IF NO SDAA CHANGE !!!! + echo "=========== Checking PR Changes If SDAA FULL CI Needed ===========" + change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) + change_sdaa_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/sdaa"| wc -l) + git diff --name-only remotes/origin/${PADDLE_BRANCH} + + if [ $change_numbers -ne $change_backend ]; then + echo "Common file changed, continue to run SDAA FULL CI test ..." + elif [ $change_sdaa_only -eq 0 ] ; then + echo "NO SDAA backend changes found, skip SDAA FULL CI ...." + exit 0 + fi + cd backends/sdaa/ && bash pr_ci_sdaa.sh From f39dd1c2ccd96f3de39e1f7f96cfda82f73b8256 Mon Sep 17 00:00:00 2001 From: tianshuo78520a <707759223@qq.com> Date: Thu, 23 Oct 2025 23:06:30 +0000 Subject: [PATCH 85/85] Update --- .github/workflows/_SDAA.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/_SDAA.yml b/.github/workflows/_SDAA.yml index cbfd0b6e126..82dc544fd25 100644 --- a/.github/workflows/_SDAA.yml +++ b/.github/workflows/_SDAA.yml @@ -59,10 +59,10 @@ jobs: run: | # !!!!! SKIP IF NO SDAA CHANGE !!!! echo "=========== Checking PR Changes If SDAA FULL CI Needed ===========" - change_numbers=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | wc -l) - change_backend=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/"| wc -l) - change_sdaa_only=$(git diff --name-only remotes/origin/${PADDLE_BRANCH} | grep "backends/sdaa"| wc -l) - git diff --name-only remotes/origin/${PADDLE_BRANCH} + change_numbers=$(git diff --name-only remotes/origin/${BRANCH} | wc -l) + change_backend=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/"| wc -l) + change_sdaa_only=$(git diff --name-only remotes/origin/${BRANCH} | grep "backends/sdaa"| wc -l) + git diff --name-only remotes/origin/${BRANCH} if [ $change_numbers -ne $change_backend ]; then echo "Common file changed, continue to run SDAA FULL CI test ..."