ascendc-simt-tiling-design

Designs SIMT operator tiling strategies for Ascend NPU kernels.

Updated Sep 15, 2026
One-click install
npx skills add https://github.com/WangWindow/CANN-BatchMatMulMaxsum --skill ascendc-simt-tiling-design-wangwindow
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: ascendc-simt-tiling-design
Source: https://github.com/WangWindow/CANN-BatchMatMulMaxsum/tree/main/.agents/skills/ascendc-simt-tiling-design
Command: npx skills add https://github.com/WangWindow/CANN-BatchMatMulMaxsum --skill ascendc-simt-tiling-design-wangwindow

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Designing tiling for AscendC SIMT operators differs fundamentally from SIMD operators, and applying SIMD-style UB partitioning to SIMT kernels leads to incorrect block counts, thread misconfiguration, and wasted memory. This Skill provides the correct SIMT-specific methodology for core count splitting, thread count setting, and DCache/UB space allocation. ## Core Features & Use Cases - Core Count Splitting: Computes total blocks as ceil(total output elements / minimum elements per core), with warp (32) alignment and SetBlockDim configuration. - Thread Count Configuration: Enforces constexpr compile-time thread counts (default 1024, max 2048) shared between LAUNCH_BOUND and Simt::Dim3, with guidance by operator type (memory-bound vs compute-bound). - DCache and UB Allocation: Reserves at least 32KB DCache and computes usable UB as 216KB via SetLocalMemorySize. - Use Case: When implementing a SIMT operator on Ascend A2 hardware, use this Skill to determine how many cores to launch, how many threads per core to declare, and how much local memory to reserve. ## Quick Start Ask the AI to design a SIMT tiling strategy for your AscendC operator, including core count, thread count, and DCache allocation.

Frequently Asked Questions about ascendc-simt-tiling-design

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I design tiling for an AscendC SIMT operator?

SIMT tiling centers on core count splitting and thread count setting rather than UB partitioning. Compute total cores as ceil(total output elements / minimum elements per core), set threads as a constexpr compile-time constant, and reserve at least 32KB for DCache.

What is the difference between SIMT and SIMD tiling on Ascend?

SIMD tiling partitions UB space with buffer planning and vector instructions, while SIMT tiling partitions by element count across cores with thread-level parallelism. SIMT operators can read and write GM directly and only use UB for intra-core sharing scenarios.

How many threads should an AscendC SIMT kernel use?

The default thread count is 1024 and the maximum is 2048, declared as a constexpr compile-time constant. Memory-bound operators benefit from 2048 or 1024 threads to hide latency, while compute-bound operators use 512 or 1024 to balance register pressure.

Can SIMT thread count come from tiling data at runtime?

No, thread count must be a constexpr compile-time constant shared by LAUNCH_BOUND and Simt::Dim3. If small data causes idle threads, adjust the core count via SetBlockDim instead of reducing the thread count.

How much UB memory is available for SIMT operators on Ascend?

SIMT operators must reserve at least 32KB for DCache, leaving 216KB of usable UB from the 256KB total after an 8KB reservation. Configure this on the tiling side using SetLocalMemorySize.