logo

AWS Graviton Processors

Learn about the price performance advantages of AWS Graviton processors

Published Dec 1, 2023
AWS offers EC2 instances powered by AWS Graviton processors. These processors are custom built by Amazon Web Services and feature 64-bit Arm Neoverse cores and deliver the best price performance for running workloads in AWS. Many companies are using EC2 instances powered by Graviton and getting great results after making the switch. If you have not tried Graviton or learned about what makes Graviton different compared to other EC2 instances, read on. I will provide some details about getting started with Graviton processors and why they are important to the future of computing.

AWS has introduced four generations of Graviton processors in the last 5 years.
The first generation instance type is A1, and was announced at re:Invent 2018. A1 instances provide up to 16 vCPUs. As the first Graviton instance type, A1 paved the way for the software ecosystem needed for the next generation, Graviton2.
Announced at re:Invent 2019, Graviton2 processors provide a significant performance uplift from A1. The Graviton2 instance types include M6g, C6g, R6g, and T4g. AWS advertises 40% better price performance over the same generation of x86 instances. Graviton2 instances include up to 64 vCPUs. Graviton2 uses Arm Neoverse N1 cores.
Graviton3 was announced at re:Invent 2021 and instance types include M7g, C7g, R7g. Graviton3 offers up to 2x better floating-point performance, up to 2x faster crypto performance, and up to 3x better ML performance compared to Graviton2. Graviton3 uses Arm Neoverse V1 cores.
This week, at re:Invent 2023, AWS announced Graviton4, based on Neoverse V2 cores. Graviton4 increases core count to 96 and will be first available in the R8g instance type. Graviton4 provides 30% better compute performance, 50% more cores, and 75% more memory bandwidth than Graviton3.
There are more than 150 instance types with Graviton processors. Performance has increased by about 4x per vCPU and core count has increased 6x since the A1 instance type was introduced.
In many ways Graviton instances are the same as other instance types you use in AWS. They have vCPUs, memory, storage, and are built on the AWS Nitro system. The key difference, which users may or may not notice, is Graviton processors use the Arm architecture, a completely different instruction set.

The Arm architecture is the basis for the world’s largest compute ecosystem. Arm does not create any silicon or systems, but instead licenses the architecture and designs to partners who create the silicon and systems. To date, approximately 250 billion chips containing Arm-based processors have been shipped. A significant number of the Arm devices are in the mobile and embedded markets. If you greatly simplify where computing happens, there are four general types of computing.
Computing typeDescription
Servers and cloud instancesComputing in the cloud, EC2 instances and other cloud and on-prem servers
Laptops and desktopsComputing on your desk, typically running Windows, macOS, or Linux
Mobile phones and tabletsComputing in your pocket, typically running Android or iOS
All other embedded computing, including IoTEverything else which performs specific functions (many invisibly) using hardware and software
The Arm ecosystem has been strong in mobile and embedded, but server and cloud usage is growing quickly, thanks to AWS Graviton processors. AWS has already built more than 2 million Graviton processors.
Low power is a key factor in the success of Arm. The diversity of the silicon ecosystem paved the way to wide adoption in embedded and IoT. The transition to raise performance and efficiency in the data center and on the desktop is happening now. There is also a transition from traditional embedded to IoT which is based on containers for application deployment.
The CPU architecture defines the instruction set, register file, exception model, memory model, and other things that an operating system relies on. There are many CPU architectures which rise and fall in popularity over time, but today Arm and x86 are the two most popular.
This week, Arm celebrated its 33-year anniversary. If you are interested in the history of computing and want to see the genesis of Arm, watch Micro Men.
Getting back to Graviton, there are two main cases for considering Graviton EC2 instances. The first case is instance replacement.

Many of the Graviton success stories summarize the process of taking an existing workload in EC2, moving it to Graviton, and comparing the price performance. Graviton looks and feels nearly identical, and often the transition is easy. If all the needed AWS services are supported on Graviton and the needed runtime environments are available, then the process is seamless.
The underlying processor architecture is irrelevant for many users, and price performance is the key metric. Better price performance is made possible by the work AWS has done to create a custom chip based on the Arm architecture and making the software transition as easy as possible.
Where things really get interesting is when the processor architecture starts to provide benefits to software developers because Arm is the common architecture across computing.
In addition to Graviton, there is momentum for the Arm architecture in laptops and desktops. Windows 11 on Arm laptops and other changes in the market mean that the future of computing will be different than it is today.

For the last 20+ years, software developers targeting embedded and mobile have been using x86 laptops, desktops, and servers to develop software that eventually lands on Arm. Graviton is exciting for all of those software developers who want to move to developing software in the cloud using the same architecture as the embedded product it lands on. As containers continue to gain popularity, efficiencies will be gained by seamlessly creating and deploying containers across all types of computing. As edge computing grows and interacts with the cloud, a common architecture can be used. The same transition is happening in automotive software development. Graviton is likely to have a more significant impact on software developers than many realize.
As a fun exercise, you can try the build once, deploy anywhere concept on Arm.

A hands-on example is always helpful to learn new things. You can try some examples using different programming languages which can be run on all kinds of Arm hardware, including EC2 instances with Graviton processors. The examples build and run containers which print the underlying platform information provided by the uname command.
It is fun to look at the output from these images and see the diversity of the Arm ecosystem. Many distributions of Linux are supported on AWS Graviton EC2 instances, and there are many other Arm-based systems running Linux, including the Raspberry Pi.
Visit GitHub to see the project details.
Start by cloning the repository:
1
git clone https://github.com/jasonrandrews/hello-arm.git
Pick a language to run, each example has a README to follow, but all are very simple with just a build and run script.
Use an account on Docker Hub to save the images and run on another Arm computer to demonstrate the build once, run anywhere benefit. You can also use Amazon Elastic Container Registry.
The Dockerfiles for each image are very simplistic, on purpose to show that Arm computing can be used for everything from cloud to laptop to IoT.
Refer to the Docker install guide if you need help installing Docker.
The output from c-hello-world is shown below on a variety of machines running the Arm architecture.

1
2
Hello, architecture from uname is Linux buildkitsandbox 5.14.21-150500.55.31-default #1 SMP PREEMPT_DYNAMIC Wed Oct 4 16:52:05 UTC 2023 (5dc23e0) aarch64 Linux
64-bit userspace

1
2
Hello, architecture from uname is Linux buildkitsandbox 5.15.123.1-microsoft-standard-WSL2 #1 SMP Mon Aug 7 18:29:33 UTC 2023 aarch64 Linux
64-bit userspace

1
2
Hello, architecture from uname is Linux buildkitsandbox 6.1.0-rpi6-rpi-2712 #1 SMP PREEMPT Debian 1:6.1.58-1+rpt2 (2023-10-27) aarch64 Linux
64-bit userspace

1
2
Hello, architecture from uname is Linux buildkitsandbox 6.4.16-linuxkit #1 SMP PREEMPT Thu Nov 16 10:49:20 UTC 2023 aarch64 Linux
64-bit userspace
Try the examples on Graviton processors or any other Arm system.

Arm Learning Paths and the AWS Graviton Technical Guide are great places to start learning more about migration topics such as how to recompile code for the Arm architecture.
Graviton is also available in AWS managed services. Amazon ECS, Amazon EKS, AWS Fargate, and AWS Lambda all offer Graviton options. Refer to managed services for a full list.
AWS is offering a free trial for EC2 tg4.small instances until December 31, 2023. The best way to get started is to create an EC2 instance and try out some of your software. Read Migrating applications to Arm servers to start learning about common migration scenarios.
Good luck with Graviton.