AI Compute Software-Hardware Co-Design: The Evolution of Domestic AI Accelerators

    This article breaks down the shift in domestic AI compute from single-chip peak performance to end-to-end software-hardware co-design. It explains the three layers of co-design (operators, graph scheduling, and cluster interconnect), why inference adaptation is evolving toward native pretraining, the engineering requirements for fine-grained expert parallelism, and a practical checklist for evaluating migration in terms of functionality, performance, stability, and cost.

    1. Background: The Core Challenge Has Shifted from Availability to Usability

    In recent years, discussions around domestic AI compute have mostly focused on single-card peak throughput and fabrication process. However, as large model parameter counts scale into the trillions, and as training and inference workloads become far more sensitive to memory bandwidth and interconnect topology than to isolated floating-point performance, the industry consensus is changing. What determines usable compute is the coordination efficiency across chips, servers, interconnects, frameworks, operator libraries, and model architectures.

    Two technical signals in the source material stand out. First, a new generation of an open-source large model completed its initial adaptation on domestic accelerator cards, with the full series of rack-scale supernodes passing validation. Its technical documentation shows that a fine-grained expert parallelism scheme passed correctness validation on two accelerator platforms with different architectures. Second, the same open-source community further open-sourced infrastructure components targeting domestic chips, signaling a shift in collaboration from “passive adaptation” to “jointly building the software stack.”

    Abstracting these two signals leads to one conclusion: competition in domestic compute has entered its second phase, moving from point replacement to end-to-end engineering capability. This article does not evaluate any specific vendor or product; instead, it dissects the common technical problems and engineering methods of this phase.

    2. Three Layers of Software-Hardware Co-Design

    2.1 Operator Layer: From “It Runs” to “It Runs Fast”

    In the early stage of migration, most frameworks rely on operator mapping and automatic fallback to ensure functional correctness, but performance is often only around 60% of the native platform. Real optimization requires rewriting hot operators for the domestic architecture’s memory hierarchy, vector width, and data movement instructions, especially attention mechanisms, normalization, and the grouped matrix multiplications in expert routing.

    2.2 Graph and Scheduling Layer: Static Graphs Fit Domestic Hardware Better

    Dynamic graph execution introduces significant overhead from dispatching large numbers of small operators. Lowering the entire computation graph, performing operator fusion and constant folding, and orchestrating communication operators and computation operators into the same execution stream are key prerequisites for achieving linear speedup.

    2.3 Cluster Layer: Interconnect Topology Sets the Ceiling

    The supernode form factor uses high-bandwidth intra-domain interconnects to scale a single machine with multiple cards into a logical “single large card.” This allows tensor parallelism to complete within the domain, leaving cross-domain communication to data parallelism and pipeline parallelism, which are less sensitive to bandwidth.

    3. Why “Inference Adaptation” Moves Toward “Native Pretraining”

    Inference has relatively relaxed requirements for numerical precision and operator coverage, so quantization and graph optimization can yield clear gains. Pretraining, however, requires thousands of cards to run stably for weeks; any numerical instability, communication jitter, or missing checkpoint mechanism causes an overall rollback. Native pretraining therefore depends on three prerequisites:

    • Numerical consistency: mixed-precision policies, reduction order, and random number generation must be reproducible on the target architecture;
    • Fault tolerance: tiered checkpointing, automatic isolation of faulty cards, and automatic task rescheduling;
    • Composable parallelism: data, tensor, pipeline, expert, and sequence parallelism must support arbitrary orthogonal combinations.

    An illustrative parallel configuration (pseudocode, expressing configuration structure only):

    1. parallel_plan = {
    2. "tensor_parallel": 8, # confined within the high-bandwidth domain
    3. "pipeline_parallel": 4,
    4. "expert_parallel": 16, # fine-grained expert partitioning
    5. "sequence_parallel": True,
    6. "data_parallel": "auto", # derived from the remaining cards
    7. "checkpoint": {"interval_steps": 200, "tiered": True},
    8. }

    4. Engineering Essentials of Fine-Grained Expert Parallelism

    Load imbalance in mixture-of-experts models is a major killer of training efficiency. Fine-grained partitioning splits a single expert into smaller compute units; combined with capacity factors and dropping strategies, it can significantly alleviate hotspots. Engineering efforts should focus on:

    1. Real-time collection and visualization of routing statistics to locate long-tail experts;
    2. Pipeline overlap between all-to-all communication and computation to avoid communication bubbles;
    3. Placing frequently activated expert shards preferentially within the domain to reduce cross-domain traffic;
    4. Sharing the same parallelism description between training and inference to reduce the cost of maintaining two versions.

    5. A Checklist for Evaluating Migration

    • Functionality: operator coverage, precision alignment error, and boundary-case regression;
    • Performance: single-card throughput, scaling efficiency curves, communication ratio, and memory watermark;
    • Stability: long-run test duration, fault-injection recovery time, and checkpoint-resume success rate;
    • Cost: training cost per token and inference latency percentiles.

    When implementing on the cloud, a container platform can handle environment delivery, object storage can hold checkpoints and datasets, a message queue can decouple data preprocessing, and logging and monitoring with alerting can cover long-run observation. This turns a one-off adaptation into a repeatable engineering pipeline.

    6. Conclusion

    Raising the ceiling of domestic AI compute is essentially not a breakthrough in any single metric, but the compounding effect of the “chip-server-framework-model architecture” four layers maturing simultaneously. The ecosystem flywheel truly starts turning when native pretraining of open-source models begins targeting domestic architectures first. For developers, the most worthwhile investment now is turning parallelism strategies, fault-tolerance mechanisms, and performance evaluation into reusable assets.