Karim BELABAS on Fri, 07 Nov 2003 12:11:40 +0100


[Date Prev] [Date Next] [Thread Prev] [Thread Next] [Date Index] [Thread Index]

Re: Experimenting with the Alpha build.


On Thu, 6 Nov 2003, Phil Carmody wrote:
> --- Karim BELABAS <Karim.Belabas@math.u-psud.fr> wrote:
>> On Thu, 6 Nov 2003, Phil Carmody wrote:
>>> I was wondering if -ffast-math would do to Pari/GP/GMP on the alpha.
>>> The speed-ups weren't significant on the whole (I should have tried
>>> -mno-ieee too perhaps)
>>
>> This is expected: there's almost no floating point code in PARI (everything
>> is emulated using 'unsigned long' arithmetic). Might be considered a
>> shortcoming.
>>
>> There are lots of variables of type 'double', but they are used in parts of
>> the code which is negligible timewise. And never where stability / accuracy
>> is important. I.e --fast-math should be a no-op with respect to performances
>> or results.
>
> I also recompiled GMP with -ffast-math too for the test. In theory GMP might
> perform some FP maths (FFT multiplication? or is it NTT?).

NTT from a quick glance at the code. I don't think GMP uses doubles much,
either. mp_limb_t is always a variant of some unsigned integer (int, long,
long long).

Cheers,

    Karim.
-- 
Karim Belabas                     Tel: (+33) (0)1 69 15 57 48
Dép. de Mathématiques, Bât. 425   Fax: (+33) (0)1 69 15 60 19
Université Paris-Sud              http://www.math.u-psud.fr/~belabas/
F-91405 Orsay (France)            http://pari.math.u-bordeaux.fr/  [PARI/GP]