From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.3 required=5.0 tests=BAYES_00,INVALID_MSGID autolearn=no autolearn_force=no version=3.4.4 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 103376,17506301c0751a38 X-Google-Attributes: gid103376,public From: dewarr@my-dejanews.com Subject: Re: Need exception despite Machine_Overflows is false Date: 1998/12/19 Message-ID: <75guuf$gl7$1@nnrp1.dejanews.com>#1/1 X-Deja-AN: 423992761 References: <36796140.62B2788C@magic.fr> <367AA93A.3F8F1506@magic.fr> X-Http-Proxy: 1.0 x2.dejanews.com:80 (Squid/1.1.22) for client 205.232.38.14 Organization: Deja News - The Leader in Internet Discussion X-Article-Creation-Date: Sat Dec 19 19:31:26 1998 GMT Newsgroups: comp.lang.ada X-Http-User-Agent: Mozilla/4.04 [en] (OS/2; I) Date: 1998-12-19T00:00:00+00:00 List-Id: In article <367AA93A.3F8F1506@magic.fr>, Pascal MALAISE wrote: > > > As long as your limits are tighter than the machine > > limits, the > > compiler will insert explicit checks. > > >The detection is done now! > > > Of course, this will slow things down, > > it is not significant The slow down will vary from machine to machine, but it is a very big effect with properly programmed code, probably a factor of 3-4 slowdown at least. If you do not see such a slowdown, it is likely that you have programmed poorly with respect to cache. For example a naive matrix multiplication of matrices larger than the cache is of course completely disastrous from an efficiency point of view, and there are well known algorithms for doing this properly. The moral as usual with fpt is that unless you *really* know what you are doing, you are better off using existing library routines for such purposes. > Oh, I was not looking for a bug. > The program makes pure mattrix multiplications and all I > need is raising > then > handling the exception. You should not need to rely on exceptions for this purpose. The IEEE standard does not require that exceptions be implemented (they are optional), and properly written numerical algorithms should not need to rely on getting such exceptions. -----------== Posted via Deja News, The Discussion Network ==---------- http://www.dejanews.com/ Search, Read, Discuss, or Start Your Own