Designing High-Performance Compute Environments
This lesson explains how the right instance family, placement and network adapter change the run time and cost of simulations, ML training, rendering and low-latency processing by an order of magnitude.
Learning outcomes
After completing this lesson, you will be able to:
- Choose an instance family from the limiting resource.
- Distinguish tightly and loosely coupled workloads.
- Explain when to use cluster placement groups and EFA.
- Describe ParallelCluster and Parallel Computing Service.
Instance families
The right instance family follows from the resource that limits performance. Compute-bound work runs on C instances, and tightly coupled HPC on Hpc instances. Memory-bound work, such as large in-memory databases, runs on R, X and High Memory instances. Work limited by storage I/O runs on I instances with local NVMe storage. GPU and machine learning work runs on P and G instances. Graviton instances, based on Arm, give the best price performance for supported workloads. The following table summarises the families.
| Bottleneck | Family |
|---|---|
| Compute | C, and Hpc instances for tightly coupled HPC |
| Memory | R, X, and High Memory instances |
| Storage I/O (NVMe) | I |
| GPU and ML | P and G instances |
| Price performance | Graviton (Arm) |
Larger sizes also give more network bandwidth and EBS throughput.
Tightly and loosely coupled workloads
High-performance computing (HPC) workloads fall into two groups that need opposite designs. Tightly coupled workloads, such as weather simulation and computational fluid dynamics, split one problem across many nodes that exchange data constantly through the Message Passing Interface (MPI), so network latency limits the whole job. They run in a cluster placement group with the Elastic Fabric Adapter (EFA), in one Availability Zone, on instances of one type. Loosely coupled workloads, such as rendering frames, Monte Carlo risk calculations or processing genomics samples, consist of independent tasks that barely communicate. They are spread across Availability Zones and instance types, often on Spot Instances and scheduled by a job scheduler such as AWS ParallelCluster's Slurm. The following table summarises the comparison.
Tightly or loosely coupled?
Networking and placement
Three tools provide the network performance that tightly coupled workloads need. A cluster placement group places instances physically close together in one Availability Zone, for the lowest latency and highest throughput between them. The Elastic Fabric Adapter (EFA) lets MPI and NCCL (the NVIDIA library for GPU communication) bypass the operating system's network stack, which cuts latency further. Enhanced networking with the Elastic Network Adapter (ENA) and jumbo frames raise bandwidth and packets per second within a VPC. The following table summarises the tools.
| Tool | Provides |
|---|---|
| Cluster placement groups | Instances close together in one AZ for low latency and high throughput |
| Elastic Fabric Adapter (EFA) | OS-bypass networking for MPI and NCCL |
| Enhanced networking (ENA), jumbo frames | Higher bandwidth and packets per second within a VPC |
Managing clusters
HPC clusters are created and operated with purpose-built services rather than by hand. AWS ParallelCluster creates clusters with schedulers such as Slurm from a configuration file, including compute queues, shared storage and EFA networking, and scales compute nodes with the job queue. AWS Parallel Computing Service provides managed Slurm clusters, so the scheduler itself is operated by AWS.
For GPU workloads, Capacity Blocks for ML reserve GPU instances for a defined future window, so a job can be scheduled with certainty that its accelerators will be available.
A computational fluid dynamics cluster
Engineers run MPI simulations across 64 nodes; performance is limited by inter-node latency. AWS ParallelCluster builds the environment from a configuration file:
Region: eu-west-1
Image:
Os: alinux2023
HeadNode:
InstanceType: c7i.xlarge
Networking: { SubnetId: subnet-0private1 }
Scheduling:
Scheduler: slurm
SlurmQueues:
- Name: cfd
ComputeResources:
- Name: hpc7g
InstanceType: hpc7g.16xlarge
MinCount: 0
MaxCount: 64
Efa: { Enabled: true }
Networking:
SubnetIds: [subnet-0private1]
PlacementGroup: { Enabled: true }Every element answers a specific bottleneck: Hpc instances provide high core counts and memory bandwidth, EFA provides OS-bypass networking for MPI, the cluster placement group keeps nodes physically close, and MinCount: 0 means compute nodes exist only while jobs run. The single-subnet, single-AZ layout is a deliberate trade of availability for performance, acceptable because a failed job can be rerun.
What does an Elastic Fabric Adapter provide for HPC workloads?
Show answer
Low-latency, OS-bypass networking for tightly coupled MPI workloads, used together with cluster placement groups.
Exam Tips
Remember for the exam
- Tightly coupled HPC calls for a cluster placement group and EFA.
- Loosely coupled batch work suits Spot capacity across many instance types.
- To create and manage HPC clusters with Slurm, use AWS ParallelCluster or Parallel Computing Service.
- For better price performance on general workloads, use Graviton.
- For GPU capacity for a fixed training window, use Capacity Blocks for ML.