Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
82 changes: 1 addition & 81 deletions .github/workflows/aipu-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,86 +6,6 @@ on:
pull_request:
branches: [ "triton_v3.3.x" ]

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
aipu-build-and-test:
runs-on: aipu
if: ${{ github.repository == 'FlagTree/flagtree' || github.repository == 'flagos-ai/flagtree' }}
steps:
- name: Setup environment
shell: bash
run: |
source ~/env.sh
env | grep -E '^(http_proxy|https_proxy|all_proxy|no_proxy)=' >> $GITHUB_ENV || true

- name: Checkout code (attempt 1)
id: checkout1
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before checkout2
if: steps.checkout1.outcome == 'failure'
run: |
echo "First checkout attempt failed. Sleeping for 120 seconds before retry..."
sleep 120

- name: Checkout code (attempt 2)
id: checkout2
if: steps.checkout1.outcome == 'failure'
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before final checkout
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
run: |
echo "Second checkout attempt failed. Sleeping for 180 seconds before final retry..."
sleep 180

- name: Checkout code (final attempt)
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
uses: actions/checkout@v5

- name: Verify checkout success
if: success()
run: echo "Checkout completed successfully"

- name: FlagTree Build on AIPU
shell: bash
run: |
set -x
pip uninstall -y triton
source ~/env_setup.sh
export FLAGTREE_BACKEND=aipu
cd python
MAX_JOBS=32 python3.10 -m pip install . --no-build-isolation -v

- name: FlagTree Test on AIPU
shell: bash
run: |
set -x
source ~/env_setup.sh
python3.10 third_party/aipu/python/test/test_01_vector_add.py
python3.10 third_party/aipu/python/test/test_01_vector_add_shared_memory.py
python3.10 third_party/aipu/python/test/test_01_vector_add_dma.py
python3.10 third_party/aipu/python/test/test_02_fused_softmax.py
python3.10 third_party/aipu/python/test/test_02_fused_softmax_shared_memory.py
python3.10 third_party/aipu/python/test/test_02_fused_softmax_dma.py
python3.10 third_party/aipu/python/test/test_libdevice_fmod.py
python3.10 third_party/aipu/python/test/test_libdevice_fmod_shared_memory.py
python3.10 third_party/aipu/python/test/test_libdevice_fmod_dma.py
python3.10 third_party/aipu/python/test/test_libdevice_pow.py
python3.10 third_party/aipu/python/test/test_libdevice_pow_shared_memory.py
python3.10 third_party/aipu/python/test/test_libdevice_pow_dma.py
python3.10 third_party/aipu/python/test/test_codegen_dma.py
python3.10 third_party/aipu/python/test/test_01_vector_add_structured_1d.py
python3.10 third_party/aipu/python/test/test_01_vector_add_structured_1d_shared_memory.py
python3.10 third_party/aipu/python/test/test_01_vector_add_structured_1d_dma.py
python3.10 third_party/aipu/python/test/min.py
python3.10 third_party/aipu/python/test/min_shared_memory.py
#python3.10 third_party/aipu/python/test/min_dma.py
python3.10 third_party/aipu/python/test/var_mean.py
python3.10 third_party/aipu/python/test/var_mean_shared_memory.py
#python3.10 third_party/aipu/python/test/var_mean_dma.py
uses: flagos-ai/flagtree/.github/workflows/aipu-build-and-test.yml@workflow_unifiy
99 changes: 1 addition & 98 deletions .github/workflows/ascend-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,103 +6,6 @@ on:
pull_request:
branches: [ "triton_v3.2.x" ]

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
ascend-build-and-test:
runs-on: ascend
steps:
- name: Checkout code (attempt 1)
id: checkout1
uses: actions/checkout@v6
with:
fetch-depth: 0
continue-on-error: true

- name: Sleep before checkout2
if: steps.checkout1.outcome == 'failure'
run: |
echo "First checkout attempt failed. Sleeping for 120 seconds before retry..."
sleep 120

- name: Checkout code (attempt 2)
id: checkout2
if: steps.checkout1.outcome == 'failure'
uses: actions/checkout@v6
with:
fetch-depth: 0
continue-on-error: true

- name: Sleep before final checkout
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
run: |
echo "Second checkout attempt failed. Sleeping for 180 seconds before final retry..."
sleep 180

- name: Checkout code (final attempt)
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
uses: actions/checkout@v6
with:
fetch-depth: 0

- name: Verify checkout success
if: success()
run: echo "Checkout completed successfully"

- name: Check if only docs files changed
id: check_files
uses: ./.github/actions/check-docs-only

- name: FlagTree Build on Ascend
if: steps.check_files.outputs.only_docs_changed != 'true'
shell: bash
run: |
set -x
pip uninstall -y triton
export FLAGTREE_BACKEND=ascend
source ~/env.sh
cd python
MAX_JOBS=32 python3 -m pip install . --no-build-isolation

- name: FlagTree Test on Ascend
if: steps.check_files.outputs.only_docs_changed != 'true'
shell: bash
run: |
set -x
source /usr/local/Ascend/ascend-toolkit/set_env.sh
python3 third_party/tests/ascend/vector-add.py
python3 third_party/ascend/examples/tutorials/01-vector-add.py
python3 third_party/ascend/examples/tutorials/02-fused-softmax.py
python3 third_party/ascend/examples/tutorials/03-layer-norm.py
python3 third_party/ascend/examples/tutorials/04-fused-attention.py
python3 third_party/ascend/examples/tutorials/06-demo-autotune.py
python3 third_party/ascend/examples/tutorials/07-profiler.py
python3 third_party/ascend/examples/tutorials/09-gather.py
python3 third_party/ascend/examples/tutorials/10-gather_sorted.py
python3 third_party/ascend/examples/tutorials/11-rab_time.py
python3 third_party/ascend/examples/tutorials/13-matrix-multiplication-optimized.py
python3 third_party/ascend/examples/tutorials/13-matrix-multiplication-optimized-flagtree.py
python3 third_party/ascend/examples/tutorials/14-accuracy-comparison.py
python3 python/test/ops/01_vector_add/01_vector_add.py
python3 python/test/ops/abs/abs.py
python3 python/test/ops/addmm/addmm.py
python3 python/test/ops/addmm/addmm_ascend.py
python3 python/test/ops/amax/amax.py
python3 python/test/ops/amax/amax_ascend_perf.py
python3 python/test/ops/apply_rotary_pos_emb/apply_rotary_pos_emb.py
python3 python/test/ops/apply_rotary_pos_emb/apply_rotary_pos_emb_ascend.py
python3 python/test/ops/argmin/argmin.py
python3 python/test/ops/argmin/argmin_ascend_perf.py
python3 python/test/ops/bmm/bmm_ascend.py
python3 python/test/ops/cumsum/cumsum.py
python3 python/test/ops/min_dim/min_dim.py
python3 python/test/ops/min_dim/min_dim_ascend_perf.py
python3 python/test/ops/sum_dim/sum_dim.py
python3 python/test/ops/varmean/var_mean_ascend.py
python3 -m pytest third_party/ascend/examples/pytest_ut --ignore=third_party/ascend/examples/pytest_ut/test_index_select.py \
--ignore=third_party/ascend/examples/pytest_ut/test_linearize_permute.py \
--ignore=third_party/ascend/examples/pytest_ut/test_logical_and.py \
--ignore=third_party/ascend/examples/pytest_ut/test_logical_or.py \
--ignore=third_party/ascend/examples/pytest_ut/test_triton_unified_attention.py
uses: flagos-ai/flagtree/.github/workflows/ascend-build-and-test.yml@workflow_unifiy
53 changes: 1 addition & 52 deletions .github/workflows/cambricon-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,57 +6,6 @@ on:
pull_request:
branches: [ "main" ]

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
cambricon-build-and-test:
runs-on: cambricon
if: ${{ github.repository == 'FlagTree/flagtree' || github.repository == 'flagos-ai/flagtree' }}
steps:
- name: Setup environment
shell: bash
run: |
source ~/env.sh
env | grep -E '^(http_proxy|https_proxy|all_proxy|no_proxy)=' >> $GITHUB_ENV || true

- name: Checkout code (attempt 1)
id: checkout1
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before checkout2
if: steps.checkout1.outcome == 'failure'
run: |
echo "First checkout attempt failed. Sleeping for 120 seconds before retry..."
sleep 120

- name: Checkout code (attempt 2)
id: checkout2
if: steps.checkout1.outcome == 'failure'
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before final checkout
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
run: |
echo "Second checkout attempt failed. Sleeping for 180 seconds before final retry..."
sleep 180

- name: Checkout code (final attempt)
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
uses: actions/checkout@v5

- name: Verify checkout success
if: success()
run: echo "Checkout completed successfully"

- name: FlagTree Build on Cambricon
shell: bash
run: |
set -x
pip uninstall -y triton
export FLAGTREE_BACKEND=cambricon
cd python
MAX_JOBS=8 python3 -m pip install . --no-build-isolation
uses: flagos-ai/flagtree/.github/workflows/cambricon-build-and-test.yml@workflow_unifiy
60 changes: 1 addition & 59 deletions .github/workflows/hcu-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,64 +6,6 @@ on:
pull_request:
branches: [ "main" ]

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
hcu-build-and-test:
runs-on: hcu
if: ${{ github.repository == 'FlagTree/flagtree' || github.repository == 'flagos-ai/flagtree' }}
steps:
- name: Setup environment
shell: bash
run: |
source ~/env.sh
env | grep -E '^(http_proxy|https_proxy|all_proxy|no_proxy)=' >> $GITHUB_ENV || true

- name: Checkout code (attempt 1)
id: checkout1
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before checkout2
if: steps.checkout1.outcome == 'failure'
run: |
echo "First checkout attempt failed. Sleeping for 120 seconds before retry..."
sleep 120

- name: Checkout code (attempt 2)
id: checkout2
if: steps.checkout1.outcome == 'failure'
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before final checkout
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
run: |
echo "Second checkout attempt failed. Sleeping for 180 seconds before final retry..."
sleep 180

- name: Checkout code (final attempt)
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
uses: actions/checkout@v5

- name: Verify checkout success
if: success()
run: echo "Checkout completed successfully"

- name: FlagTree Build on Hcu
shell: bash
run: |
set -x
pip uninstall -y triton
export FLAGTREE_BACKEND=hcu
cd python
MAX_JOBS=32 python3 -m pip install . --no-build-isolation

- name: FlagTree Test on Hcu
shell: bash
run: |
set -x
cd third_party/hcu/python/test/unit
sh flagtree_test.sh
uses: flagos-ai/flagtree/.github/workflows/hcu-build-and-test.yml@workflow_unifiy
61 changes: 1 addition & 60 deletions .github/workflows/iluvatar-build-and-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,65 +6,6 @@ on:
pull_request:
branches: [ "main" ]

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
iluvatar-build-and-test:
runs-on: iluvatar
if: ${{ github.repository == 'FlagTree/flagtree' || github.repository == 'flagos-ai/flagtree' }}
steps:
- name: Checkout code (attempt 1)
id: checkout1
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before checkout2
if: steps.checkout1.outcome == 'failure'
run: |
echo "First checkout attempt failed. Sleeping for 120 seconds before retry..."
sleep 120

- name: Checkout code (attempt 2)
id: checkout2
if: steps.checkout1.outcome == 'failure'
uses: actions/checkout@v5
continue-on-error: true

- name: Sleep before final checkout
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
run: |
echo "Second checkout attempt failed. Sleeping for 180 seconds before final retry..."
sleep 180

- name: Checkout code (final attempt)
if: steps.checkout1.outcome == 'failure' && steps.checkout2.outcome == 'failure'
uses: actions/checkout@v5

- name: Verify checkout success
if: success()
run: echo "Checkout completed successfully"

- name: FlagTree Build on Iluvatar
shell: bash
run: |
set -x
pip uninstall -y triton
export FLAGTREE_BACKEND=iluvatar
source ~/env.sh
cd python
MAX_JOBS=32 python3 -m pip install . --no-build-isolation

- name: FlagTree Test on Iluvatar
shell: bash
run: |
set -x
CUDA_VISIBLE_DEVICES=15 python3 -m pytest -s third_party/iluvatar/python/test/unit
./python/build/cmake.linux-x86_64-cpython-3.10/bin/triton-opt --pass-pipeline='builtin.module(convert-triton-to-tritongpu{target="cuda:CC" num-warps=4 threads-per-warp=32 num-ctas=1})' ./test/bin/iluvatar/add_kernel.ttir
./python/build/cmake.linux-x86_64-cpython-3.10/bin/triton-opt --convert-arith-to-llvm ./test/bin/iluvatar/add_kernel.ttgir
cd python/tutorials
python3 01-vector-add.py
python3 04-low-memory-dropout.py
python3 07-extern-functions.py
python3 08-grouped-gemm.py
uses: flagos-ai/flagtree/.github/workflows/iluvatar-build-and-test.yml@workflow_unifiy
Loading
Loading