Design an Inference Runtime That Partitions Models Across CPU, GPU and NPU

Last updated: November 29, 2026

Quick Overview

Design an on-device inference runtime for Android phones with Cortex-A CPU clusters, a Mali GPU and an NPU that takes a model graph, partitions it across the available processors, and minimises latency and energy while staying correct when some operators are unsupported.

Arm
ML System Design
Machine Learning Engineer
Arm
November 29, 2026
Machine Learning Engineer
System Design Round
ML System Design
Hard

0

0

0 solved


Design an on-device inference runtime for Android phones with Cortex-A CPU clusters, a Mali GPU and an NPU that takes a model graph, partitions it across the available processors, and minimises latency and energy while staying correct when some operators are unsupported.

Arm builds Arm NN, the Arm Compute Library and KleidiAI kernels that sit underneath frameworks like TensorFlow Lite, ExecuTorch and llama.cpp on billions of phones. The interviewer checks graph partitioning, cost modelling, memory movement and the practical realities of heterogeneous mobile SoCs such as thermal limits and big.LITTLE scheduling.

What the Interviewer Expects
  • Define backends with capability queries and cost models
  • Partition the graph into subgraphs per backend while minimising transfers
  • Plan memory with zero-copy buffers where hardware allows
  • Pick CPU kernels per core type and data type (int8, fp16, bf16 with I8MM/SME)
  • Handle fallback, warm-up and compilation caching
  • Measure and adapt to thermal throttling and contention
Key Topics to Cover
graph partitioning
heterogeneous compute
cost models
memory planning
on-device inference
quantization
How to Approach This
  1. Start by mapping the business objective to a concrete ML objective and metric.
  2. Cover the full pipeline: data collection, feature engineering, model selection, training, serving.
  3. Discuss online vs offline evaluation. Plan an A/B test to validate real-world impact.
  4. Address the serving latency budget and whether batch or real-time inference is needed.
  5. Think about the data flywheel: how user feedback improves the model over time.
Possible Follow-up Questions
  • How would you handle a large language model where the KV cache dominates memory?
  • How would you decide between running a layer on two big cores versus the GPU?
  • How do you validate numerical correctness across backends with different rounding?
  • What changes for a real-time camera pipeline with a 33 ms frame budget?
Sharpen Your Skills on Codemia

Practice similar problems with our interactive workspace, get AI feedback, and track your progress.

Practice ML System Design Problems
Sample Answer
Requirements

Input: a model graph (TFLite or ExecuTorch) with int8, fp16 or fp32 ops. Output: an execution plan and a runtime that executes it. Targets: minimise p95 latency for interactive models and energy for b...

High-Level Design

Components: (1) Backend plugins for CPU (Compute Library and KleidiAI microkernels), GPU (OpenCL or Vulkan kernels on Mali) and NPU (vendor driver). Each exposes supports(op, dtype, shape) and `esti...


Submit Your Answer
Markdown supported

Related Questions