Re: which gcc version?

From: Matti Aarnio (matti.aarnio@zmailer.org)
Date: Thu Apr 05 2001 - 07:02:19 EST


On Thu, Apr 05, 2001 at 07:37:03AM -0400, Bart Trojanowski wrote:
> On Thu, 5 Apr 2001, Manoj Sontakke wrote:
> gcc requires a function call to do a mul/div on a long long. There is no
> easy way to do a 64bit op of this type on a 32 bit CPU...

        Actually there is -- presuming your CPU has lots of registers,
        which i386 does not have...

        This rule -- "no -lgcc in kernel code" -- is to trap code which
        in fast-paths would call those slow routines.
        Fastpaths should either not grok such values, or at most use
        shifts.

        To think of it, there really should be explicitely callable
        versions of these with LinuxKernel names for them, not gcc
        builtins.  That way people would *know* they are doing
        something, which is potentially very slow.
        (And the API would not change from underneath them.)

> Cheers,
> Bart.
> --
> WebSig: http://www.jukie.net/~bart/sig/

/Matti Aarnio
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/



This archive was generated by hypermail 2b29 : Sat Apr 07 2001 - 21:00:16 EST