From mboxrd@z Thu Jan 1 00:00:00 1970 Received: (qmail 4762 invoked from network); 28 Jun 1998 16:42:30 -0000 Received: from gatecoms.gatecom.com (198.87.96.251) by mail2.redhat.com with SMTP; 28 Jun 1998 16:42:30 -0000 Received: (from jsturm@localhost) by gatecoms.gatecom.com (8.8.7/8.8.7) id MAA10679; Sun, 28 Jun 1998 12:41:02 -0400 (EDT) Date: Sun, 28 Jun 1998 12:41:02 -0400 (EDT) From: Jeff Sturm X-Sender: jsturm@gatecoms To: axp-list@redhat.com Subject: Re: Performance measurements In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Sat, 27 Jun 1998, Volker Barthelmann wrote: > On Wed, 24 Jun 1998, Christopher C Chimelis wrote: > > On Wed, 24 Jun 1998, Jeff Sturm wrote: > > > > > I'm aware of -mieee and have used it for many applications that would > > > otherwise die on SIGFPE. But it is hardly ideal--it seems to slow down > > > the benchmark code by a ratio of 3-4. I'm not exactly sure what it does, > > > but it seems to add a lot of fp value-checking code. I can do much the > > > same by inserting statements in my source code, all at the expense of > > > runtime performance. > > > > Yeah, runtime performance is killed by -mieee. My only guess would be to > > implement a kernel-level handler for this (is this covered in the new math > > code in later 2.1 kernels?). > > This should basically be a compiler-problem. AFAIK gcc currently just > inserts trap-barriers directly after every instruction that might cause an > exception therefore stalling the pipelines. > > By trying to avoid reusing of the registers involved for some time and > moving the trap-barrier or eliminating it, the speed-penalty could > probably be reduced for the most part. >From what I understand the real problem is parallel instruction issue, not register usage. The kernel cannot tell which instruction caused a trap if -mieee is not used. So -mieee must reduce floating-point to a single CPU pipeline, there's the performance penalty. So on Alpha we must live with not-quite-IEEE arithmetic at very fast speeds, or true IEEE at somewhat slower speeds. Jeff