boblq wrote:
At least one serious contributor seems on the surface of things to
disagree with you about the relevance of machine language.
Well, he argues for the stability of machine language, not importance.
And I would argue with him about even that. C has been far more stable
over that period while assembly language has evolved dramatically.
Fortran has been even more stable.
Furthermore, an assembly language disconnected from hardware
implementation *always* does weird things that it should not. The
original 6809 and Alpha assembly languages were probably about as good
as it gets. Why people just don't steal those when they need one is
beyond me.
One of the principal goals of my books is to show how high-level constructions
are actually implemented in machines, not simply to show how they are applied.
I explain coroutine linkage, tree structures, random number generation, high-precision
arithmetic, radix conversion, packing of data, combinatorial searching, recursion, etc.,
from the ground up.
Hmmm, I don't remember Knuth being quite that low-level, but it's been a
while since I pulled out one of his books.
Of course, this may be part of the reason why I don't find his books
particularly useful. If I'm looking for concepts, I don't want to have
to inload an assembly language as well.
Moreover, if I did use a high-level language, what language should it be? In the
1960s I would probably have chosen Algol W; in the 1970s, I would then have had
to rewrite my books using Pascal; in the 1980s, I would surely have changed
everything to C; in the 1990s, I would have had to switch to C++ and then
probably to Java. In the 2000s, yet another language will no doubt be de rigueur.
I cannot afford the time to rewrite my books as languages go in and out of fashion;
languages aren't the point of my books, the point is rather what you can do in your
favorite language. My books focus on timeless truths.
I find this to be a red herring. I also note that he conveniently
forgets about Fortran. If his programs are really that small, then
Fortran is more than high enough level. C also easily spans 1980's to
now with practically no change. He has rearranged his assembly language
from his original one in the 1960's, so that time frame certainly was
unstable anyhow. Scheme/Lisp was also stable over that same time frame.
It has a a few unexpected, but important, instructions, e.g.
Hey I was just thinking. Does anyone know of any Instruction Sets
> that have an extra bit in the branch instruction to be used as a
> "hint" for the branch prediction logic?
Donald Knuth redefined his MIX assembly language:
In his opcode matrix he mentions these instructions which do
exactly what you are looking for:
5E PBEV probable branch if even (3)
5F PBEVB probable branch if even, backward (3)
50 PBN probable branch if negative (3)
Architectural analysis shows that these instructions are a waste of time
and circuitry. These are equivalent to a dynamic "branch the same way
as last time" but not as flexible.
In addition, these are classic CISC-type instructions that waste
circuitry and opcode space. Why should Bit 0 get special treatment?
The sequence "LOAD R0, #01; AND R1, R0; BZERO R1,<somewhere>" will
generally execute equivalently fast and has more flexibility.
-a
--
[email protected]
http://www.kernel-panic.org/cgi-bin/mailman/listinfo/kplug-list