InterviewStack.io LogoInterviewStack.io

GPU and Hardware Considerations Questions

Focuses on hardware choices and constraints for machine learning workloads, why accelerators are important, and how hardware characteristics influence model training and inference. Topics include GPU architecture and strengths versus CPU and other accelerators, memory capacity and bandwidth limits, batch size and memory tradeoffs, mixed precision and numerical format impacts, multi GPU setups and interconnects such as NVLink and PCIe, device profiling and monitoring, hardware driven optimization techniques, accelerator virtualization and cloud instance selection, inference accelerators and edge hardware, and how hardware decisions affect throughput, latency, cost, and algorithmic choices. Also covers practical tooling and diagnostics for hardware performance tuning.

HardSystem Design
54 practiced
Design a production inference solution for a conversational AI model targeting 20ms p95 latency on commodity GPUs. Include model-size considerations, GPU selection, batching/dynamic batching strategies, model optimizations (quantization, distillation), cold-start/warmup strategies, replica counts and autoscaling rules, and how you would measure and guarantee SLOs.
MediumTechnical
61 practiced
Write a Python function (no deep-learning imports required) that estimates GPU memory usage for training given: P (number of parameters), bytes_per_activation_per_sample, batch_size, optimizer_multiplier (e.g., Adam=2), bytes_per_param (4 or 2), and a scratch_multiplier for temporary buffers. Return estimated total memory in GB and a breakdown of components (weights, gradients, optimizer, activations, scratch).
HardTechnical
43 practiced
You observe GPUs at 20–30% utilization even though memory is nearly full. Describe a step-by-step profiling and remediation plan: list the tools and metrics you'd collect, how to distinguish between data-loading, host-device transfer, kernel compute, and synchronization issues, and propose concrete optimizations (e.g., async data loader, increase batch size, use fused kernels, mixed precision, overlap transfers) based on findings.
EasyTechnical
44 practiced
List practical tools and commands you would use to monitor and profile GPU usage and detect bottlenecks during model training on Linux (including host and container environments). For each tool, state what metrics it provides (e.g., utilization, memory usage, PCIe throughput, SM stats) and when you'd use it: nvidia-smi, nsys, nsight, nvprof (deprecated), nvtop, PyTorch profiler, TensorBoard, Prometheus exporters, or cloud monitoring dashboards.
HardTechnical
53 practiced
You need to implement a custom fused transformer-attention kernel to leverage Tensor Cores for better throughput. Explain design choices and implementation steps either using CUDA WMMA APIs or Triton: data layout, tile sizes, alignment constraints, memory staging (shared memory), avoiding bank conflicts, and validation for numerical correctness and performance regression testing.

Unlock Full Question Bank

Get access to hundreds of GPU and Hardware Considerations interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.