addition, each of these units has different properties that we can use to understand them.
The computational unit has the property of how many computations it can do per
second, the memory unit has the properties of how much data it can hold and how fast
we can read from and write to it, and finally the connections have the property of how
fast they can move data from one place to another.
Using these building blocks, we can talk about a standard workstation at multiple levels
of sophistication. For example, the standard workstation can be thought of as having a
central processing unit (CPU) as the computational unit, connected to both the random
access memory (RAM) and the hard drive as two separate memory units (each having
different capacities and read/write speeds), and finally a bus that provides the connec‐
tions between all of these parts. However, we can also go into more detail and see that
the CPU itself has several memory units in it: the L1, L2, and sometimes even the L3
and L4 cache, which have small capacities but very fast speeds (from several kilobytes
to a dozen megabytes). These extra memory units are connected to the CPU with a
special bus called the backside bus. Furthermore, new computer architectures generally
come with new configurations (for example, Intel’s Nehalem CPUs replaced the front‐
side bus with the Intel QuickPath Interconnect and restructured many connections).
Finally, in both of these approximations of a workstation we have neglected the network
connection, which is effectively a very slow connection to potentially many other com‐
puting and memory units!
To help untangle these various intricacies, let’s go over a brief description of these fun‐
damental blocks.
Computing Units
The computing unit of a computer is the centerpiece of its usefulness—it provides the
ability to transform any bits it receives into other bits or to change the state of the current
process. CPUs are the most commonly used computing unit; however, graphics
processing units (GPUs), which were originally typically used to speed up computer
graphics but are becoming more applicable for numerical applications, are gaining
popularity due to their intrinsically parallel nature, which allows many calculations to
happen simultaneously. Regardless of its type, a computing unit takes in a series of bits
(for example, bits representing numbers) and outputs another set of bits (for example,
representing the sum of those numbers). In addition to the basic arithmetic operations
on integers and real numbers and bitwise operations on binary numbers, some com‐
puting units also provide very specialized operations, such as the “fused multiply add”
operation, which takes in three numbers, A,B,C, and returns the value A * B + C.
The main properties of interest in a computing unit are the number of operations it can
do in one cycle and how many cycles it can do in one second. The first value is measured
2 | Chapter 1: Understanding Performant Python
www.it-ebooks.info