Physical vs AWS Virtual CPU Cores

Firstly a bit of an explanation on the central processing unit CPU and what it does. A single-core CPU can only perform one task at a time, which is where multiple CPUs, hyper-threading and multi-core CPUs come into play. Having multiple CPUs allows multiple programs to run at the same time ensuring your computer stays responsive, especially while multitasking.

Multiple CPUs

Most computers only have a single CPU. Before hyper-threading and multi-core CPUs came around, people attempted to add additional processing power to computers by adding additional CPUs. This requires a motherboard with more than one CPU socket — multiple CPUs are inserted into different sockets. This isn’t very common among home-user PCs today. Even a high-powered gaming desktop with multiple graphics cards will generally only have a single CPU. You’ll find multi-CPU systems among supercomputers, servers, and similar high-end systems that need as much number-crunching power as they can get.

Hyper-Threading Technology


Hyper-threading was Intel’s first attempt to bring parallel computation to consumer PCs. A single physical CPU core with hyper-threading appears as two logical CPUs to an operating system. The CPU is still a single CPU, so it’s “cheating” a bit — while the operating system sees two CPUs for each core, the actual CPU hardware only has a single set of execution resources for each core. The CPU pretends it has more cores than it does, and it uses its own logic to speed up program execution.

Multi-Core CPUs

A dual-core CPU has two central processing units, so it appears to the operating system as two CPUs. A different process can be using each core at the same time. This speeds up your system, because your computer can do multiple things at once.

Unlike hyper-threading, there are no tricks here — a dual-core CPU literally has two central processing units on the CPU chip. A quad-core CPU has four central processing units, an octa-core CPU has eight central processing units, and so on.

Windows 8’s task manager shows this fairly well — here we have a single processor with four cores and hyper-threading, so it appears to have eight logical CPUs.


Most computers now have multi-core CPUs, which is the most efficient option here. However, Intel CPUs also have hyper-threading as a bonus. Some computers that need a large amount of CPU power may have multiple CPUs, but it’s much less efficient than it sounds.

AWS Virtual CPUs (vCPU)

I've found it really hard to find any type of information on what Amazon Web Services considers a vCPU as part of the EC2 instances. The instance type page defines a vCPU as “a hyperthreaded core for M3, C3, R3, HS1, G2, and I2.” The description seems a bit confusing: is it a dedicated CPU core (which has two hyperthreads in the E5-2670 v2 CPU platform being used), or is it a half-core, single hyperthread?

After some testing (test results to come soon) using an m3.xlarge EC2 instance which is stated to have 4 vCPUs running an E5-2670 v2 processor at 2.5GHz on the Ivy Bridge-EP micro architecture I have found that a vCPU in an AWS environment actually represents only half a physical core. So if you’re looking for equivalent compute capacity to, say, an 8-core server, you would need a so-called 4xlarge EC2 instance with 16 vCPUs.

No comments:

Post a Comment