long long / long long
Florian Weimer
Florian.Weimer@RUS.Uni-Stuttgart.DE
Mon Sep 10 12:18:00 GMT 2001
Joe Buck <jbuck@synopsys.COM> writes:
> Well, the Linux kernel developers found that they couldn't let gcc
> do long long arithmetic because it did such a poor job, so they do
> it in assembly or in C on pairs of 32 bit values instead. So at
> least some folks probably wouldn't mind seeing an improvement.
Anything up to and including GCC 2.95 is probably quite broken with
regard to 64 bit support on x86, performancewise. For example, if you
pass a 64 bit constant in a function call, the constant is but into
some data segment and is copied to the stack from there. IIRC, the
generated code is not even shorter if the constant is used multiple
times.
The kernel folks still work with ancient GCC (even gcc) versions, and
it is not clear if their experience carries over to newer GCCs.
Of course, Frank's floating point implementation cannot be used in
kernel space at the moment. AFAIK, floating point is still not
possible there for technical reasons.
--
Florian Weimer Florian.Weimer@RUS.Uni-Stuttgart.DE
University of Stuttgart http://cert.uni-stuttgart.de/
RUS-CERT +49-711-685-5973/fax +49-711-685-5898
More information about the Gcc
mailing list