Skip to content

test: add qwen3 scope2 pto kernels#426

Open
HecreReed wants to merge 2 commits intohw-native-sys:mainfrom
HecreReed:codex/qwen-scope2-case
Open

test: add qwen3 scope2 pto kernels#426
HecreReed wants to merge 2 commits intohw-native-sys:mainfrom
HecreReed:codex/qwen-scope2-case

Conversation

@HecreReed
Copy link
Copy Markdown
Collaborator

Summary

  • add test/samples/Qwen3Scope2/ with 13 qwen3_32b_decode_scope2.py generated .pto kernels
  • teach test/samples/runop.sh to include Qwen3Scope2 in direct .pto coverage
  • pass --pto-arch a5 --pto-level=level3 for Qwen3Scope2 when no explicit override is provided
  • skip these cases by default in remote validation workflow inputs for now

Details

These kernels are generated from the pypto-lib Qwen3 scope2 decode example and are intended to provide compile-regression coverage for pypto-generated A5 .pto inputs.

The kernels compile with the current ptoas flow when using A5 + level3 lowering. They are added as direct .pto samples instead of handwritten IR.

Remote board validation is intentionally left conservative in this draft: the workflow defaults skip these cases so this PR can land compile coverage first without changing the current board-run default surface.

Validation

  • PTOAS_BIN=/Users/laoda/pto/PTOAS/build/tools/ptoas/ptoas bash test/samples/runop.sh -t Qwen3Scope2

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces Qwen3 scope2 PTO kernels and updates the runop.sh script to include the Qwen3Scope2 directory in the test suite. The script was modified to apply default architecture and lowering level flags for these kernels. A review comment suggests decoupling the logic for these default flags to ensure that --pto-level=level3 is applied even if a user provides an explicit architecture override.

Comment on lines +175 to +190
local has_pto_arch_override=0
if ((${#ptoas_flags[@]})); then
for ((idx=0; idx<${#ptoas_flags[@]}; ++idx)); do
if [[ "${ptoas_flags[idx]}" == "--pto-arch" && $((idx + 1)) -lt ${#ptoas_flags[@]} ]]; then
target_arch="${ptoas_flags[idx + 1]}"
has_pto_arch_override=1
elif [[ "${ptoas_flags[idx]}" == --pto-arch=* ]]; then
target_arch="${ptoas_flags[idx]#--pto-arch=}"
has_pto_arch_override=1
fi
done
fi
if [[ "$A" == "Qwen3Scope2" && $has_pto_arch_override -eq 0 ]]; then
ptoas_flags+=(--pto-arch a5 --pto-level=level3)
target_arch="a5"
fi
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

The logic for applying default flags to the Qwen3Scope2 directory is currently coupled to the presence of the --pto-arch flag. If a user provides an explicit --pto-arch override in PTOAS_FLAGS but omits --pto-level, the required --pto-level=level3 default will not be applied, which will cause compilation failures for these specific kernels as they require Level-3 lowering. It is better to detect and apply these overrides independently.

  local has_pto_arch_override=0
  local has_pto_level_override=0
  if ((${#ptoas_flags[@]})); then
    for ((idx=0; idx<${#ptoas_flags[@]}; ++idx)); do
      if [[ "${ptoas_flags[idx]}" == "--pto-arch" && $((idx + 1)) -lt ${#ptoas_flags[@]} ]]; then
        target_arch="${ptoas_flags[idx + 1]}"
        has_pto_arch_override=1
      elif [[ "${ptoas_flags[idx]}" == --pto-arch=* ]]; then
        target_arch="${ptoas_flags[idx]#--pto-arch=}"
        has_pto_arch_override=1
      elif [[ "${ptoas_flags[idx]}" == "--pto-level" && $((idx + 1)) -lt ${#ptoas_flags[@]} ]]; then
        has_pto_level_override=1
      elif [[ "${ptoas_flags[idx]}" == --pto-level=* ]]; then
        has_pto_level_override=1
      fi
    done
  fi
  if [[ "$A" == "Qwen3Scope2" ]]; then
    if [[ $has_pto_arch_override -eq 0 ]]; then
      ptoas_flags+=(--pto-arch a5)
      target_arch="a5"
    fi
    if [[ $has_pto_level_override -eq 0 ]]; then
      ptoas_flags+=(--pto-level=level3)
    fi
  fi

@HecreReed
Copy link
Copy Markdown
Collaborator Author

/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3
decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7
decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11
decode_attention_incore_12 --pto-level=level3

@HecreReed HecreReed marked this pull request as ready for review April 3, 2026 02:48
@reedhecre
Copy link
Copy Markdown

A5 板测失败

  • 触发方式:manual
  • 源码提交:fc6110570fca
  • 结果汇总:OK 0 / FAIL 0 / SKIP 0
  • 日志:/root/ptoas-board-monitor-a5/logs/20260403_104907_manual_pr426.log
  • 手动指令:/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3
  • 触发人:HecreReed
  • 指定用例:decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3
  • 触发评论:test: add qwen3 scope2 pto kernels #426 (comment)
  • 失败阶段:internal / RUN_ONLY_CASES matched zero buildable cases: decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3

日志尾部

SES], test/samples/planmemory/plan_memory_fragmentation_hole_fit.py [not in RUN_ONLY_CASES], test/samples/planmemory/plan_memory_for_iter_args_yield.py [not in RUN_ONLY_CASES], test/samples/planmemory/plan_memory_bind_tile_alias_liveness.py [not in RUN_ONLY_CASES], test/samples/Xors/xors_golden.py [not in RUN_ONLY_CASES], test/samples/Xors/xors_compare.py [not in RUN_ONLY_CASES], test/samples/Xors/xors.py [not in RUN_ONLY_CASES], test/samples/Xor/xor_golden.py [not in RUN_ONLY_CASES], test/samples/Xor/xor_compare.py [not in RUN_ONLY_CASES], test/samples/Xor/xor.py [not in RUN_ONLY_CASES], ... (+422 more)

===== STAGE sample-build-and-test @ 2026-04-03 10:50:42 =====
bash test/samples/runop.sh --enablebc all
PTOAS_OUT_DIR=/tmp/ptoas-board-monitor-a5/runs/20260403_104907_manual_pr426/payload/test/samples
========== SUMMARY ==========
-----------------------------
OK=0  FAIL=0  SKIP=0
=============================
===== END STAGE sample-build-and-test rc=0 @ 2026-04-03 10:50:44 =====

===== INTERNAL ERROR =====
Traceback (most recent call last):
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1952, in run_once
    summary = runner.run()
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1380, in run
    self.generate_payload()
    ~~~~~~~~~~~~~~~~~~~~~^^
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1344, in generate_payload
    self.resolve_payload_run_only_cases()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1032, in resolve_payload_run_only_cases
    raise RuntimeError(f"RUN_ONLY_CASES matched zero buildable cases: {self.run_only_cases}")
RuntimeError: RUN_ONLY_CASES matched zero buildable cases: decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3

@HecreReed
Copy link
Copy Markdown
Collaborator Author

/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3

Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 45dbf6790c

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +193 to +194
if [[ "$A" == "Qwen3Scope2" && $has_pto_arch_override -eq 0 ]]; then
ptoas_flags+=(--pto-arch a5 --pto-level=level3)
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Preserve level3 default when arch is overridden

For Qwen3Scope2, this branch only injects --pto-level=level3 when no --pto-arch override is present, so a common override like PTOAS_FLAGS='--pto-arch=a5' disables the level3 injection and runs these kernels at ptoas default level2. These new kernels use pto.alloc_tile addr=... (which ptoas documents as level3-only), so this path causes avoidable compile failures even though the user requested the correct arch. Consider detecting --pto-level independently and only auto-injecting level3 when it is not explicitly set.

Useful? React with 👍 / 👎.

@reedhecre
Copy link
Copy Markdown

A5 板测失败

  • 触发方式:manual
  • 源码提交:fc6110570fca
  • 结果汇总:OK 0 / FAIL 0 / SKIP 0
  • 日志:/root/ptoas-board-monitor-a5/logs/20260403_105206_manual_pr426.log
  • 手动指令:/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3
  • 触发人:HecreReed
  • 指定用例:decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12
  • PTOAS 参数:--pto-level=level3
  • 触发评论:test: add qwen3 scope2 pto kernels #426 (comment)
  • 失败阶段:internal / RUN_ONLY_CASES matched zero buildable cases: decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12

日志尾部

.py [not in RUN_ONLY_CASES], test/samples/Xors/xors_golden.py [not in RUN_ONLY_CASES], test/samples/Xors/xors_compare.py [not in RUN_ONLY_CASES], test/samples/Xors/xors.py [not in RUN_ONLY_CASES], test/samples/Xor/xor_golden.py [not in RUN_ONLY_CASES], test/samples/Xor/xor_compare.py [not in RUN_ONLY_CASES], test/samples/Xor/xor.py [not in RUN_ONLY_CASES], ... (+422 more)

===== STAGE sample-build-and-test @ 2026-04-03 10:53:43 =====
bash test/samples/runop.sh --enablebc all
PTOAS_OUT_DIR=/tmp/ptoas-board-monitor-a5/runs/20260403_105206_manual_pr426/payload/test/samples
========== SUMMARY ==========
-----------------------------
OK=0  FAIL=0  SKIP=0
=============================
===== END STAGE sample-build-and-test rc=0 @ 2026-04-03 10:53:44 =====

===== INTERNAL ERROR =====
Traceback (most recent call last):
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1952, in run_once
    summary = runner.run()
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1380, in run
    self.generate_payload()
    ~~~~~~~~~~~~~~~~~~~~~^^
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1344, in generate_payload
    self.resolve_payload_run_only_cases()
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1032, in resolve_payload_run_only_cases
    raise RuntimeError(f"RUN_ONLY_CASES matched zero buildable cases: {self.run_only_cases}")
RuntimeError: RUN_ONLY_CASES matched zero buildable cases: decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12

@HecreReed
Copy link
Copy Markdown
Collaborator Author

/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3

@reedhecre
Copy link
Copy Markdown

A5 板测成功

  • 触发方式:manual
  • 源码提交:fc6110570fca
  • 结果汇总:OK 0 / FAIL 0 / SKIP 0
  • 日志:/root/ptoas-board-monitor-a5/logs/20260403_110405_manual_pr426.log
  • 结果 TSV:/root/ptoas-board-monitor-a5/logs/20260403_110405_manual_pr426.tsv
  • 手动指令:/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3
  • 触发人:HecreReed
  • 指定用例:decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12
  • PTOAS 参数:--pto-level=level3
  • 触发评论:test: add qwen3 scope2 pto kernels #426 (comment)

@HecreReed
Copy link
Copy Markdown
Collaborator Author

/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3

@reedhecre
Copy link
Copy Markdown

A5 板测失败

  • 触发方式:manual
  • 源码提交:fc6110570fca
  • 结果汇总:OK 0 / FAIL 0 / SKIP 0
  • 日志:/root/ptoas-board-monitor-a5/logs/20260403_163706_manual_pr426.log
  • 结果 TSV:/root/ptoas-board-monitor-a5/logs/20260403_163706_manual_pr426.tsv
  • 手动指令:/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3
  • 触发人:HecreReed
  • 指定用例:decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12
  • PTOAS 参数:--pto-level=level3
  • 触发评论:test: add qwen3 scope2 pto kernels #426 (comment)
  • 失败阶段:internal / board validation produced zero testcase rows for RUN_ONLY_CASES: decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9

日志尾部

/usr/local/Ascend/cann-9.0.0/aarch64-linux/simulator/Ascend910B1/lib
[2026-04-03 16:38:49] SIM_SOC_VERSION=Ascend950
[2026-04-03 16:38:49] === NPU Device Check ===
uid=0(root) gid=0(root) groups=0(root),1001(HwHiAiUser)
crw-rw---- 1 HwHiAiUser HwHiAiUser 508, 0 Mar 26 19:44 /dev/davinci0
crw-rw---- 1 HwHiAiUser HwHiAiUser 508, 1 Mar 26 19:44 /dev/davinci1
crw-rw---- 1 HwHiAiUser HwHiAiUser 509, 0 Mar 26 19:39 /dev/davinci_manager
[2026-04-03 16:38:49] Using vendored pto-isa tree at /tmp/ptoas-board-monitor-a5/runs/20260403_163706_manual_pr426/payload/pto-isa (no .git); skipping clone/fetch/checkout.
[2026-04-03 16:38:49] === SUMMARY ===
[2026-04-03 16:38:49] OK=0 FAIL=0 SKIP=0
[2026-04-03 16:38:49] RESULTS_TSV=/tmp/ptoas-board-monitor-a5/runs/20260403_163706_manual_pr426/remote_npu_validation_results.tsv
===== END STAGE board-validation rc=0 @ 2026-04-03 16:38:49 =====

===== INTERNAL ERROR =====
Traceback (most recent call last):
  File "/root/ptoas-board-monitor-a5/monitor.py", line 2071, in run_once
    summary = runner.run()
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1501, in run
    self.board_validate()
    ~~~~~~~~~~~~~~~~~~~^^
  File "/root/ptoas-board-monitor-a5/monitor.py", line 1490, in board_validate
    raise RuntimeError(
        "board validation produced zero testcase rows for RUN_ONLY_CASES: " + self.payload_run_only_cases
    )
RuntimeError: board validation produced zero testcase rows for RUN_ONLY_CASES: decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9

@HecreReed
Copy link
Copy Markdown
Collaborator Author

/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3

@reedhecre
Copy link
Copy Markdown

A5 板测失败

  • 触发方式:manual
  • 源码提交:fc6110570fca
  • 结果汇总:OK 10 / FAIL 3 / SKIP 0
  • 日志:/root/ptoas-board-monitor-a5/logs/20260403_170006_manual_pr426.log
  • 手动指令:/run a5 decode_attention_incore_0 decode_attention_incore_1 decode_attention_incore_2 decode_attention_incore_3 decode_attention_incore_4 decode_attention_incore_5 decode_attention_incore_6 decode_attention_incore_7 decode_attention_incore_8 decode_attention_incore_9 decode_attention_incore_10 decode_attention_incore_11 decode_attention_incore_12 --pto-level=level3
  • 触发人:HecreReed
  • 指定用例:decode_attention_incore_0,decode_attention_incore_1,decode_attention_incore_2,decode_attention_incore_3,decode_attention_incore_4,decode_attention_incore_5,decode_attention_incore_6,decode_attention_incore_7,decode_attention_incore_8,decode_attention_incore_9,decode_attention_incore_10,decode_attention_incore_11,decode_attention_incore_12
  • PTOAS 参数:--pto-level=level3
  • 触发评论:test: add qwen3 scope2 pto kernels #426 (comment)
  • 失败阶段:board-validation / exit=1

失败用例

  • decode_attention_incore_7 (run, exit=2)
  • decode_attention_incore_2 (run, exit=1)
  • decode_attention_incore_10 (run, exit=2)

@reedhecre
Copy link
Copy Markdown

A5 板测失败详情:PR #426

decode_attention_incore_7

stage=run info=exit=2

/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:97:23: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  set_flag(PIPE_MTE2, PIPE_MTE1, EVENT_ID0);
                      ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:100:24: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_MTE2, PIPE_MTE1, EVENT_ID0);
                       ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:105:12: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  set_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
           ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:105:23: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  set_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
                      ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:108:13: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
            ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:108:24: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
                       ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:110:12: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  set_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
           ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:110:20: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  set_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
                   ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:114:13: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
            ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_7/decode_attention_incore_7_kernel.cpp:114:21: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
                    ^
10 errors generated.
gmake[2]: *** [CMakeFiles/decode_attention_incore_7_kernel.dir/build.make:76: CMakeFiles/decode_attention_incore_7_kernel.dir/decode_attention_incore_7_kernel.cpp.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
gmake[1]: *** [CMakeFiles/Makefile2:85: CMakeFiles/decode_attention_incore_7_kernel.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2
[2026-04-03 17:05:25] ERROR: testcase failed (exit 2): decode_attention_incore_7
decode_attention_incore_2

stage=run info=exit=1

[ERROR] aclrtSynchronizeStream(stream) failed: 507035 (/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_2/main.cpp:109)
[ERROR] RecentErrMsg: EZ9999: Inner Error!
EZ9999[PID: 1977663] 2026-04-03-17:11:01.806.916 (EZ9999):  The error from device(chipId:0, dieId:0), serial number is 131, there is an aivec error exception, core id is 0, error code = 95, dump info: pc start: 0x100040800000, current: 0x100040800178, sc error info: 0xffffffffffff, su error info: 0xe7ffd23d1fdc0017,0x4240141410009bfd, mte error info: 0x2005d, vec error info: 0x4080031000310047, cube error info: 0, l1 error info: 0, aic error mask: 0x395856, para base: 0x100040200000, mte error: 0x80000000.[FUNC:ProcessDavidStarsCoreErrorInfo][FILE:device_error_proc_c.cc][LINE:580]
        TraceBack (most recent call last):
       The extend info: errcode:(95) errorStr: The DDR address of the MTE instruction is out of range. subErrType: 0x4.[FUNC:ProcessDavidStarsCoreErrorInfo][FILE:device_error_proc_c.cc][LINE:583]
       Kernel task happen error, retCode=0x31, [vector core exception].[FUNC:PreCheckTaskErr][FILE:davinci_kernel_task.cc][LINE:1728]
       AIV Kernel happen error, retCode=0x31.[FUNC:GetError][FILE:stream.cc][LINE:1478]
       [AIC_INFO] after execute:args print end[FUNC:GetError][FILE:stream.cc][LINE:1478]
       [DFX_INFO]Aicore kernel execute failed, device_id=1, stream_id=62, report_stream_id=62, task_id=0, flip_num=0, fault kernel_name=_Z25decode_attention_incore_2Pu6__bf16PfS_S_ii, fault kernel info ext=_Z25decode_attention_incore_2Pu6__bf16PfS_S_ii, program id=0, hash=1092065175157927996.[FUNC:GetError][FILE:stream.cc][LINE:1478]
       rtStreamSynchronize execution failed, reason=vector core exception[FUNC:FuncErrorReason][FILE:error_message_manage.cc][LINE:65]
       synchronize stream failed, runtime result = 507035[FUNC:ReportCallError][FILE:log_inner.cpp][LINE:148]
[2026-04-03 17:11:37] ERROR: testcase failed (exit 1): decode_attention_incore_2
decode_attention_incore_10

stage=run info=exit=2

/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:97:23: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  set_flag(PIPE_MTE2, PIPE_MTE1, EVENT_ID0);
                      ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:100:24: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_MTE2, PIPE_MTE1, EVENT_ID0);
                       ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:105:12: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  set_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
           ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:105:23: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  set_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
                      ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:108:13: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
            ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:108:24: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_MTE1, PIPE_M, EVENT_ID0);
                       ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:110:12: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  set_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
           ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:110:20: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  set_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
                   ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:114:13: error: the ranges of 1st parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
            ^
/tmp/ptoas-board-monitor-a5/runs/20260403_170006_manual_pr426/npu_validation/Qwen3Scope2/decode_attention_incore_10/decode_attention_incore_10_kernel.cpp:114:21: error: the ranges of 2nd parameter must be [0, 1], [4, 5]
  wait_flag(PIPE_M, PIPE_FIX, EVENT_ID0);
                    ^
10 errors generated.
gmake[2]: *** [CMakeFiles/decode_attention_incore_10_kernel.dir/build.make:76: CMakeFiles/decode_attention_incore_10_kernel.dir/decode_attention_incore_10_kernel.cpp.o] Error 1
gmake[2]: *** Waiting for unfinished jobs....
gmake[1]: *** [CMakeFiles/Makefile2:85: CMakeFiles/decode_attention_incore_10_kernel.dir/all] Error 2
gmake: *** [Makefile:91: all] Error 2
[2026-04-03 17:15:48] ERROR: testcase failed (exit 2): decode_attention_incore_10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants