
There's No Such Thing as a General-Purpose Processor - canpoturn
http://queue.acm.org/detail.cfm?id=2687011
======
sliverstorm
This is almost axiomatic of modern processors, because the truth is there is
no market for truly general-purpose processors. Chip designers produce heavily
optimized & targeted silicon to squeeze out significantly more performance in
real-life workloads at the expense of code that might- but doesn't- exist, and
given the choice between a slow GP-PU and a fast modern CPU, you'd take the
latter 99 times out of 100.

Belief in a truly GP-PU probably would lead to some very bad design decisions-
either in software or hardware- but I don't think many people actually believe
in it beyond the theory, the model. Just as hardware engineers adapt their
ideal model to the "real software", software engineers adapt their software to
"real hardware".

 _Because processors optimized for these cases have been the cheapest
processing elements that consumers can buy, many algorithms have been coerced
into exhibiting some of these properties._

I would additionally argue that aside from cost, because of the _speed_
exhibited by such processors, many algorithms that do not _naturally_ fit in
the current model are in fact faster on the modern CPU than the hypothetical
GP-PU _anyway_. Caches, for example, are such a tremendous lever on
performance that a low-performance but cacheable version of algorithm X
running on an i7 will almost certainly be dramatically faster than a high-
performance but noncacheable version running on our hypothetical GP-PU...

If there is a low-level OS whiz around, they might be able to figure out how
to set the noncacheable flag on your program's memory space, and you could
prove to yourself just how much speed the cache is worth... unfortunately I am
not that wizard.

~~~
cbsmith
> I would additionally argue that aside from cost, because of the speed
> exhibited by such processors, many algorithms that do not naturally fit in
> the current model are in fact faster on the modern CPU than the hypothetical
> GP-PU anyway.

Yup. I think the article's initial assumption of what a general purpose
processor looks like ignores history. We've tried to build those kinds of
processors... and what we've converged on is processors that are good at these
particular specialized operations, because that actually tends to work better
for most jobs. Not that there aren't exceptions... you can look at FPGA's to
get an idea of what they are, and the fact that FPGA's are only used in a
bunch of very specialized areas suggest that modern CPU's aren't THAT far off
on being reasonable optimal for a truly varied set of tasks.

~~~
im3w1l
My take is that due to the exponential speed increase we have had in
processors, general purpose of year n+2 has run faster than special purpose of
year n. Thus, there was little point in building special purpose processors.

But those times are coming to an end now.

------
thomasjudge
Does anyone else find this article, while interesting, a little odd? In that
I'm not sure that his argument succeeds. Especially in that while he portends
to show that "there is no such thing as a general purpose processor", the
first line of his conclusion starts "The general purpose processors of
today.."

It reminds me a little of philosophical arguments which attempt to disprove
the existence of something common-sensical. If you define a general purpose
processor as one which would be able to execute any algorithm comparably
performant as a purpose-defined processor, then yes, that processor does not
exist. But that's like saying processors with infinite cores, speed, and heat-
dissipation capacity don't exist. It's true, but not all that interesting.

"General purpose processors don't exist" is certainly an eyeball grabbing
headline, but I think his "real" conclusion is more measured and in a way less
controversial: "Efficient designs will require admitting that there is no one-
size-fits-all processor design and that there is a large spectrum, with
different trade-offs at different points." Despite his not defining
"efficiency", that point seems true, but not that controversial.

Does he show that "General-purpose processor" is not a useful distinction? I
don't think so.

(Apologies: recovering philosopher, not a CS PhD.)

~~~
Chinjut
I think the point is that what we think of as an archetypal "general-purpose
processor" is a somewhat arbitrary point in the space of possible
architectures, and to think of other designs as in some sense secondary simply
for failure to match this particular model is to lose sight of the true scope
of general computation.

Is it uncontroversial? Perhaps no one would disagree after hearing it spelt
out, but I think it certainly is the case that people often naively think of
"general-purpose processor" in just the way the author worries about, and that
reading something like this can bring about a helpful shift in perspective.

~~~
kazinator
That would be an argument against someone who claims that the general purpose
processor, to be general purpose, has to look like those familiar ones which
we have.

Put another way: a particular point in a large space of "general purpose"
doesn't indicate special purpose.

You have to choose a point to implement something.

------
arielby
Run-time code generation being faster than static code generation isn't
fundamentally weird: as an example, take a program that takes (pure) C code as
input, evaluates it, and returns its exit status – compiling the code and
running it could be much faster than interpreting it. In fact, variants of
this _are_ significant features of general-purpose processors.

The fact that many programs written in dynamic languages can be sped-up in
this way is slightly surprising, as they are a different family of examples,
but isn't much different on a fundamental level.

On a different note, if dark silicon becomes cheap, then general-purpose
processors would become less important, as one could have a computer system
consist of thousands of independent systems, each for a different purpose. If
dark RAM would also be cheap, then giving each such processor its own memory
could eliminate the need for MMU-s.

~~~
bryanbuckley
>If dark RAM would also be cheap, then giving each such processor its own
memory could eliminate the need for MMU-s.

Could you explain a bit further? I don't follow.

Wouldn't MMUs be needed just to support (performant) programs with very large
address spaces (i.e. need virtual addresses)?

------
notacoward
Extrapolate on this reasoning a bit, and you might end up at something like
Convey.

[http://www.conveycomputer.com/](http://www.conveycomputer.com/)

Disclaimer: I have nothing to do with them, I know there are other projects
that have taken FPGA-oriented programming much further, but Convey seems to
have done the best so far _commercializing_ the idea.

------
kazinator
Of course there is "general purpose". It the complement of "special purpose".
A processor not made for a wide range of applications, rather than for a
"special purpose" is general purpose (and this is distinct from "all purpose":
general purpose doesn't necessarily mean equally well adapted for any use
whatsoever: two different general purpose processors can have quite different
strengths.)

> _The general-purpose processors of today are highly specialized and designed
> for running applications compiled from low-level C-like languages._

And those applications differ from each other like night and day. One C
application is Ruby virtual machine. Another one a text editor. Another one a
window manager, ...

The idea that processors are special-purpose hardware blocks because they are
designed for running compiled C is a laughable form of reductionism. Why not
make the ultimate argument and say that they are specialized devices for
handling 0's and 1's. Or maybe the specific voltage levels of the majority of
the signals of a chip it specialized. This chip is specialized to 5V; this
more modern one to 3V, ...

------
nkurz
_The existence of accelerators (including GPUs) indicates that all attempts
thus far at building a general-purpose processor have failed. If they had
succeeded, then they would be efficient at running the algorithms delegated to
accelerators, and there would be no market for accelerators._

This is nonsense. I started writing several examples mocking this logic, but
erased them because I think the original quote sufficiently proves the point.

~~~
cjg
I thought that was one of the more insightful lines in the piece.

Perhaps you should take the time to refute the logic.

I was surprised to see a comment like yours. If you can't be bothered to make
a reasoned comment, then don't write anything.

~~~
harry8
I also thought it a ridiculous statement fwiw. "The existence of a specialised
thing means that attempts at building a general purpose thing is not viable"
Apply that logic to anything specialised to see it. I'm really not trying to
be rude or belittle you, I'm just trying to get a stark example that shows the
thinking in the spirit of sensible discourse. You may read it differently and
explain why and I'll learn something. So...

The existence of nascar shows that attempts to build a family saloon has
failed, if it had succeeded you could race your family saloon competitively on
a banked oval track.

A general purpose thing involves a trade off such that it can do most things
but can't do any one thing as well as something that is designed to do that
and nothing else. Yes stupid car analogies to describe computing indeed.
Totally. I'm sorry.

~~~
cjg
Please see my reply to the sibling post (which made roughly the same points as
yours).

[https://news.ycombinator.com/item?id=8580643](https://news.ycombinator.com/item?id=8580643)

~~~
harry8
Yeah after a couple of days wait, a couple of hours after me the same points.
Murphy's law of timing...

