Sorry about that, Andreas, but I think the replacement of quot with a
shorter implementation goes in the wrong direction. With this change we
replace quot with an identical copy of *quo. *quo has been implemented
to handle two arguments. quot has more functionality which of course
seems to be not in use. But quot is used at a lot of places and I have
counted 2,679,086 calls from the test_suite.
I had a further look at the replacements of *quo in simp.lisp. I have
checked, that we do not get changed results. My point is, that e. g. in
addk *quo was replaced with '/'. This does not change the result, but it
changes the algorithm. If we analyze the algorithm carefully we can see
that in the routine addk the function *quo always had called the Lisp
function truncate and never the Lisp function '/'. Therefore, if we can
definitely exclude a call of *quo with floating point numbers from the
function addk, a correct replacement of *quo is a call of truncate and
not '/', when it is the intention to replace *quo without changing the
algorithm.
I had no look at the other files, where *quo has been replaced, but it
seems to me that we have three possibilities:
*quo has been called always with two integers -> truncate
*quo has been called at least with one floating point number -> '/'
*quo has been called with Lisp numbers -> *quo should not be replaced.
Of course it is possible to replace *quo for the last case with a call
of the more general function quot, which has some more overhead (the
function has gone away too).
My conclusion is, that these changes should be done only with a
knowledge about the details of the algorithm. A general replacement at a
lot of places at the same time might cause more trouble then it is
worth.
By the way, some time ago I have thought about a replacement of *quo in
addk and *red with truncate. I have tried to measure the efficiency
gain, but with SBCL the gain was too small to justify a change. But of
course a change might be justified with a better readability. But for
this case I think nothing else should change.
Dieter Kaiser