AMD-64 optimizations, some (new) code
Torbjorn Granlund
tege at swox.com
Tue Sep 27 11:35:25 CEST 2005
Ashod Nakashian <saghmos at xter.net> writes:
If I had more disk space, I'd have compiled and installed gcc 4.0.1 (I
currently use 3.3.3 and I have hit more than one problem with the
generated code!)
I think you'll find that gcc 4.0.1 is a lot worse than 3.3.3. It
might be safer to upgrade to 3.3.6 (or whatever is the latest 3.3
release).
> 3.3 is definitely good performance. The GMP development code
> (scheduled for GMP 5) has similar speed (3.0). I haven't been
> able to get under 3.0, although I have tried hard.
So do you have all major functions ported/optimized for AMD-64, or is
there some missing stuff? I optimize for the fun of it, so I don't care
if the same work is already done or not. And no, I don't compete with
others on performance... I do it for the sheer joy of actually doing it.
I am working on writing AMD64 functions, one group for athlon64/opteron
and one group for Pentium.
Since I'm on the subject, I guess until GMP 5 is released, there will be
enough AMD-64 code around to undermine the value of GMP 5, to some
extent at least, since I see you have algorithmic improvements in your
list of TODO. But then again, one doesn't expect to find all new code
with the modified/improved algorithms optimized with assembly for most
cores all in one step. So while having new code with better big-O
complexity is always more than welcome, it is hard to imagine it be a
show stopper... not when you have this much effort in assembly-optimized
code. It will take some time until the new code is also optimized to the
same caliber as the current one. So, yes, the more you postpone the
release of the AMD-64 code, the less the value of your effort. Just my 2
cents.
I suppose that's true for any programming project, but since GMP
is a volunteer project, I cannot just speed up development.
But I don't agree that the main value of GMP 5 would be AMD64
assembly code. Most of the speedups will come from C code
improvements.
--
Torbjörn
More information about the gmp-discuss
mailing list