[Cfp-interest] F10 cleanup

Jim Thomas jaswthomas at sbcglobal.net
Thu Nov 8 15:00:49 PST 2012


Let me say more about the problem mentioned at the end of the message below. The old IEC 60559 standard specifies only two of the <math.h> functions in C11 as required operations: sqrt and remainder. Thus Annex F says sqrt and remainder are "fully specified as a basic arithmetic operation in IEC 60559" and does not provide the details about special cases as it does for other math functions. But in IEC 60559-2011 several of the <math.h> functions are fully specified as required operations (e.g., round, nextup, fmin, scalbn, to name just a few). It would be good to document all these functions in a consistent way. To be consistent with the current sqrt and remainder we would remove the details from their specification in Annex F and just refer to IEC 60559. Would it be better for implementors to see the details in Annex F? We could achieve consistency by adding the details to the sqrt and remainder sections in Annex F. What do you think?

-JIm

On Nov 7, 2012, at 12:12 PM, Jim Thomas wrote:

> I'm preparing Part 1 for an attachment to the request to make our TS an official Work Item for WG 14. The work is mostly formatting, but I'm finding a few other things that need fixing. Please give me a quick response on this proposed rewording in F.10:
> 
> 
> [4a] The functions bound to operations in IEC 60559 (see Table 1) are fully specified by IEC 60559, including rounding behaviors and floating-point exceptions.
> 
> [5] The ‘‘invalid’’ and ‘‘divide-by-zero’’ floating-point exceptions are raised as specified in IEC 60559 or in subsequent subclauses of this annex.
> 
>> 
> [8] Whether or when library functions not bound to operations in IEC 60559 raise the ‘‘inexact’’ floating-point exception is unspecified, unless explicitly specified otherwise.
> 
> [9] Whether or when library functions not bound to operations in IEC 60559 raise an undeserved ‘‘underflow’’ floating-point exception is unspecified.372) Otherwise, as implied by F.8.6, these functions do not raise spurious floating-point exceptions (detectable by the user), other than the ‘‘inexact’’ floating-point exception.
> 
> [10] Whether the functions not bound to operations in IEC 60559 honor the rounding direction mode is implementation-defined, unless explicitly specified otherwise.
> 
> 
> A general problem here is we haven't made all the changes needed to account for the fact that IEC 60559 now fully specifies more functions. I think we'll want to make some more changes in Annex F to clean this up, but I don't have a complete proposal yet.
> 
> -Jim
> 
> 
> 




More information about the Cfp-interest mailing list