Abstract
Deep Recommender Models (DLRMs) are critical for personalized services but face significant memory-bound bottlenecks during inference. This paper introduces an automated framework for DLRM inference optimization on multi-core AI accelerators. By implementing asymmetric data flow strategies—partitioning embedding tables across cores to utilize distributed on-chip memory—the framework achieves up to 6.5x speedup over standard compilers on real-world workloads.
Introduction
Personalization algorithms, particularly Deep Recommender Models (DLRMs), account for nearly 80% of AI workloads in some data centers. Unlike typical deep learning models that are compute-bound, DLRMs are primarily memory-bound. The bottleneck lies in the embedding layers, which map categorical data to dense vectors via lookups in massive tables. These lookups involve small, random memory accesses that often waste bandwidth and leave compute units idling. Furthermore, production environments must satisfy strict Service-Level Agreements (SLAs) focused on 99th-percentile (P99) latency, where worst-case delays are more critical than average speeds.
Methods: Asymmetric Data Flow Optimization
The proposed framework optimizes these lookups on domain-specific multi-core architectures (specifically the Huawei Ascend 910) using a two-pronged approach:
1. Single-Core Data Flow Strategies
Researchers designed specialized kernels to maximize on-chip resource utilization. Key techniques include Persistent Preloading, which pins small, frequently used tables in the core's local L1 buffer, and Vectorized Lookups, which use the chip's vector unit to retrieve multiple rows in parallel, reducing the impact of irregular access patterns.
2. Asymmetric Workload Partitioning
Standard compilers often use symmetric partitioning, where every core handles the same set of tables for different parts of a batch. This paper proposes asymmetric sharding, where different tables (or chunks of large tables) are assigned to different cores. This effectively turns the collective L1 buffers of all cores into one large, distributed cache, allowing more tables to stay on-chip.
3. Automated Optimization
A greedy optimization algorithm, guided by a linear performance model, automatically decides which data flow strategy and core assignment to use for each table to minimize P99 latency.
Evaluation and Key Results
The framework was evaluated using several industry-standard benchmarks, including Criteo-1TB, Avazu-CTR, Taobao, and KuaiRec-big, alongside a proprietary production workload (Huawei-25MB).
Significant Speedups
On real-world query distributions, the proposed method achieved speedups ranging from 1.5x to 6.5x compared to the default Ascend compiler. In extreme cases with highly skewed "hot" indices, the method was over 20x faster than the baseline by avoiding severe cache bank conflicts.
Superior Pareto Efficiency
The asymmetric strategy consistently provided a better Pareto front between throughput (queries per second) and P99 latency. As shown in the Taobao and KuaiRec-big evaluations, the asymmetric approach allows for much higher capacity within the same SLA constraints compared to symmetric or baseline methods.
Conclusion and Future Work
By treating individual core L1 buffers as a single large pool of fast memory, this framework significantly improves the efficiency of DLRM inference. While currently focused on tables that fit within accelerator memory (e.g., 32GB), future work aims to extend this to multi-device setups and host-side lookup optimizations for tables exceeding local memory capacity.
Summary updated