[Cfp-interest 2191] Re: AI for feraiseexcept update

Jim Thomas jaswthomas at sbcglobal.net
Sun Oct 3 14:52:33 PDT 2021



> On Oct 3, 2021, at 11:19 AM, Damian McGuckin <damianm at esi.com.au> wrote:
> 
> On Sun, 3 Oct 2021, Jim Thomas wrote:
> 
>> Please review and send any comments ASAP:
>> https://wiki.edg.com/pub/CFP/WebHome/C23_proposal_-_feraiseexcept_update-20
>> 211003.pdf
> 
> It is very clear.
> 
> But, if I was raising say INEXACT and OVERFLOW, if would
> 
> 	a)	grab the exception flags from the FPU rgister
> 
> 	b)	update the in-core copy with both,
> 
> 	c)	send them back as a single operation to the FPU register,

Unless the implementation has non-default exception handling, this is fine because the program can’t detect the order the exceptions are raised.

I can’t tell from what you wrote whether you are just setting the bits in a status register or signaling (using the IEEE 754 term for raise) exceptions. The feraiseexcept function specifies the latter (though for default exception handling it doesn’t matter). An implementation might need to invoke arithmetic operations to cause the signals.The idea is that user code when effecting an overflow condition could provide the requisite exceptions by calling feraiseexcept with an argument representing overflow and inexact. On an implementation with alternate exception handling, signaling inexact first (or concurrently, if that is meaningful) would be incorrect. 

> Most implementations do this. Your words as they stand would render most of these non-compliant overnight. And if you wanted to force people to send 2 separate and consecutive updates to the FPU register, you would get push-back at the very least although I would anticipate much worse.

This is an editorial change. The current version has the same requirement.

- Jim Thomas

> 
> Could you write (my changes in CAPS as I have only a black a white mail
> program so I am not yelling),
> 
> 	.... then overflow is raised before OR CONCURRENTLY WITH
> 	"inexact". Similarly ....
> 
> 	.... then "underflow" is raised before OR CONCURRENTLY WITH
> 	"inexact".
> 
> I have avoided the word co-incident. Concurrently has an obvious and
> non-technical meaning.
> 
> If you do not like that, how about just changing the word
> 
> 	before
> to
> 	guaranteed to not be after
> 
> My 2c.
> 
> Stay safe - Damian
> 
> Pacific Engineering Systems International, 277-279 Broadway, Glebe NSW 2037
> Ph:+61-2-8571-0847 .. Fx:+61-2-9692-9623 | unsolicited email not wanted here
> Views & opinions here are mine and not those of any past or present employer




More information about the Cfp-interest mailing list