New Breakthrough in China's AI Computing Ecosystem: Open-Source Practice of Full-Stack Programming Toolchain

    This article explores a newly open-sourced full-stack programming toolchain for AI computing, covering its three core components: advanced programming language, matrix computation library, and distributed communication library, along with their technical innovations and ecosystem-building strategies. The toolchain demonstrates significant performance improvements in heterogeneous computing scenarios while maintaining hardware compatibility.

    The co-evolution of hardware architectures and software ecosystems has become critical for overcoming performance bottlenecks in AI computing. A technical team recently open-sourced a full-stack programming toolchain for domestic AI computing, providing a comprehensive solution for heterogeneous computing ecosystems. This toolchain comprises three core components: an advanced programming language, matrix computation library, and distributed communication library, forming end-to-end support from algorithm design to hardware deployment.

    1. Advanced Programming Language: Balancing Performance and Usability
      TileLang, a next-gen AI programming language, addresses core pain points in CUDA ecosystems through hardware abstraction. Its parallel computing model is encapsulated in concise syntax structures, exemplified by matrix operation interfaces using declarative programming paradigms:

      1. # TileLang matrix multiplication example
      2. @tile_op
      3. def matrix_multiply(A: Tensor[M,K], B: Tensor[K,N]) -> Tensor[M,N]:
      4. return sum(A[i,k] * B[k,j] for k in range(K))

      This design delivers three key advantages: 1) 40%+ development efficiency improvement through automatic parallelization; 2) hardware adaptation layer decoupled from algorithm logic; 3) built-in auto-tuning engine for optimal computation path selection. Performance validation shows 92% theoretical peak utilization on domestic accelerators, with 27% efficiency gain in Transformer attention mechanisms through intelligent memory access optimization.

    2. Matrix Computation Library: Full-Precision Computing Engine
      DeepGEMM-Ascend implements multi-level optimization:

    • Computation Kernel Layer: Specialized units for BF16/FP8/FP4 with mixed-precision scheduling
    • Memory Management: Block matrix storage dividing 128GB matrices into 256x256MB sub-blocks (3x locality improvement)
    • Thread Scheduling: Dynamic task allocation across 128 accelerators with 0.8μs inter-card latency via ring topology

    In trillion-parameter model training, single matrix multiplication latency reduces by 31% vs industry benchmarks. The unified programming interface enables seamless hardware switching:

    1. # Unified interface example
    2. if hardware_type == "GPU":
    3. use_cuda_kernel()
    4. elif hardware_type == "NPU":
    5. use_npu_kernel() # Auto-mapped to DeepGEMM-Ascend
    1. Distributed Communication Library: Overcoming Super-Node Bottlenecks
      DeepEP-Ascend solves three technical challenges:
    • Topology-Aware Routing: Generates optimal paths through 3D grid analysis of 128-card super-nodes (91% AllReduce bandwidth utilization)
    • Computation-Communication Overlap: Double-buffering achieves 83% overlap in ResNet-152 training
    • Fault Recovery: Heartbeat detection enables 15-second recovery from single-card failures (12x faster than traditional methods)

    In 4,096-card cluster tests, model convergence time reduces to 18 minutes (22% improvement vs international solutions). Its gradient compression algorithm reduces communication volume to 1/8 while maintaining 99.97% model accuracy.

    1. Ecosystem Development: Open Collaboration Paradigm
      The toolchain adopts a layered architecture:
    • Foundation Layer: Hardware Abstraction Interface (HAI) for rapid architecture adaptation
    • Middle Layer: Open compiler optimization interfaces for community contributions
    • Application Layer: Integrated plugins for mainstream deep learning frameworks

    This design fosters active developer communities. An autonomous driving team completed algorithm migration to domestic hardware in 7 days with <5% performance loss. A university research team improved specific operator performance by 17% through compiler layer extensions.

    1. Evolution Path and Challenges
      Three challenges remain: 1) Dynamic load balancing for heterogeneous clusters; 2) Incomplete support for emerging operators (e.g., sparse computing); 3) Limited ecosystem compatibility testing coverage. Future directions include:
    • AI-driven auto-optimization engines
    • Cross-vendor hardware abstraction standards
    • Visual performance analysis toolchains

    The open-sourcing of this toolchain marks a milestone in building autonomous AI computing ecosystems. Beyond providing complete alternatives, its open collaboration model accelerates technical iteration. Developers gain cross-platform capabilities while enterprises reduce hardware lock-in risks and improve ROI. With continuous community contributions, China’s AI computing ecosystem is poised for more prosperous development.