Moore's Law has come to connote the proposition that, in terms of basic operations. , the processing power of a single processor will double approximately every two years. It can be useful to refer to Moore's law in thinking about computational complexity and parallel processing. To this end we will use the term Moore cycle to refer to:
The engineering time cycle required to develop a processor capable of doing
twice the number of basic operations per "clock tic" that can be done with
today's processors. Read
years for
Moore cycles.
The additional number of processors (measured in powers of
)
required to do twice the number of "basic operations" per "clock tic" that can
be done with a cluster of a given size. Read
processors for
Moore cycles, where
is
the number of processors presently in the cluster.
Informally, suppose I have a cluster with
processors and I want
times the performance. I need to spend
Moore cycles. Either wait
years and buy
new
processors, or wait
years and buy
new processors, or buy
of today's processors. (The extent that, in practice, the promise of this
calculation can be realized will be subjected to a good deal scrutiny a bit
later in the semester.)
Finally, again informally, it suffices to have table-lookup or a comparison in mind when thinking about the term "basic operation."
There are two related situations involving complexity that we want to consider:
We apply an algorithm to a small dataset. We would like to apply it to a larger dataset, but, at present, lack the computing resources to do it in a timely way. We want to know how many Moore cycles will be required to do the computation.
We do not want others to be able to apply an algorithm to a given data set (e.g. in cryptography). We need to estimate how many Moore cycles will be required before they will have the necessary compute-power.
Addition:
Consider the following template for addition
In the worst case, with carries, it requires approximately
addition table lookups to add two
digit numbers. That is, if I have the resources to add two
digit numbers today, one Moore cycle will be required to add two
digit
numbers. Note that whether it is
addition table lookups to add two
digit numbers or
addition table lookups to add two
digit numbers,
some other fixed constant, the conclusion that one Moore cycle will be
required to add two
digit
numbers, is the same .
Multiplication:
Consider the following template for multiplication
Taking into account some arithmetic considerations, worst case, there is a
constant
such
that
multiplication table lookups suffices to multiply to
digit numbers. If I have those resources today, two Moore cycles will be
required before it will be practical to multiply two
digit
numbers.
Suppose we have analyzed an algorithm
and
determined that for any
and any
digit
number
,
can
be computed in no more than
basic operations,
.
Using a little algebra, we can show that there is some
such
that for
,
Hence, for any
,
and
any
digit
number,
can
be computed in no more than
basic
operations.
Fixing
suppose we have the resources to compute
where
any
digit
number. In particular, we have the resources to do
basic operations in an acceptable amount of time. To compute
where
any
digit
number would, worst case, require
Restated, for any algorithm with such a polynomial bound, we can choose a
fixed
such that if we can compute
where
is any
digit
number today, in
Moore
cycles we would have the resources to compute
for
any
digit
number.
Fixing the base in which integers are represented as
,Suppose
we wanted to check if a given integer
is
a prime. We could simply divide
by
every integer
If
any of these numbers divide
evenly then
is not a prime, and if none divide evenly then
is a prime. Using this brute force method if
is any
digit
number we might have to do approximately
divisions.
Even if a division was a basic operation, doubling the number of digits would
require
divisions.
Thus, as opposed to the calculations above,
increases, the number of Moore cycles required to achieve acceptable
performance on
digit numbers also increases.
In fact one can do a lot better. Again, a little algebras show that it
suffices to try all
So rather than
divisions
we need only do
(floor
function)
However, the observation that as
increases, the number of Moore cycles required to achieve acceptable
performance on
digit numbers also increases, still holds.