Path: utzoo!utgpu!news-server.csri.toronto.edu!dgp.toronto.edu!jonah Newsgroups: comp.arch From: jonah@dgp.toronto.edu (Jeff Lee) Subject: Re: 386 Clones [really: IEEE floating point & various approaches; long] Message-ID: <1990Nov1.232508.18287@jarvis.csri.toronto.edu> References: <1990Oct26.015244.586@amd.com> <8464@scolex.sco.COM> <42597@mips.mips.COM> <4174@goanna.cs.rmit.oz.au> <42618@mips.mips.COM> Date: 2 Nov 90 04:25:09 GMT Lines: 13 mash@mips.COM (John Mashey) writes: >Now, how about input from people who actually develop FP programs: >a) Do you use traps for SIGFPE, or not? I'm not a numerical analyst, but I did recently take a graduate course on numerical software and the advice given by the professor was to avoid traps and make explicit tests for +INF, -INF, NaN, and 0 where appropriate. Usually only one or two are appropriate in any given case and explicitly checking makes sure that you *think* about the possibilities for overflow/underflow, how to avoid it (if possible), and how to retain accuracy. The opinion on traps was that they were generally more trouble than they were worth, especially if the trap handler overhead was any significant amount.