public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug other/57219] New: __builtin_isinf_sign source comments more restrictive than documentation
@ 2013-05-08 19:31 jtaylor.debian at gmail dot com
  2013-05-08 19:48 ` [Bug middle-end/57219] " glisse at gcc dot gnu.org
  2013-08-27 12:43 ` glisse at gcc dot gnu.org
  0 siblings, 2 replies; 3+ messages in thread
From: jtaylor.debian at gmail dot com @ 2013-05-08 19:31 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57219

             Bug #: 57219
           Summary: __builtin_isinf_sign source comments more restrictive
                    than documentation
    Classification: Unclassified
           Product: gcc
           Version: 4.9.0
            Status: UNCONFIRMED
          Severity: trivial
          Priority: P3
         Component: other
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: jtaylor.debian@gmail.com


in glibc bug [0] it is discussed to use __builtin_isinf_sign for C99 isinf.

The source code and the patch mail [1] for __builtin_isinf_sign document that
it returns -1, 0 or 1 as glibc isinf does.

The gcc documentation on the other hand only says it returns the sign of the
infinity.

To avoid confusion it would be good if the source code comment or the
documentation could be matched up to say the exact same thing.
Either that the value of the return is undefined (but keeps sign) or that it is
strictly define.

[0] http://sourceware.org/bugzilla/show_bug.cgi?id=15367
[1] http://gcc.gnu.org/ml/gcc-patches/2008-05/msg01067.html


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug middle-end/57219] __builtin_isinf_sign source comments more restrictive than documentation
  2013-05-08 19:31 [Bug other/57219] New: __builtin_isinf_sign source comments more restrictive than documentation jtaylor.debian at gmail dot com
@ 2013-05-08 19:48 ` glisse at gcc dot gnu.org
  2013-08-27 12:43 ` glisse at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: glisse at gcc dot gnu.org @ 2013-05-08 19:48 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57219

Marc Glisse <glisse at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |NEW
           Keywords|                            |documentation
   Last reconfirmed|                            |2013-05-08
          Component|other                       |middle-end
     Ever Confirmed|0                           |1
           Severity|trivial                     |enhancement

--- Comment #1 from Marc Glisse <glisse at gcc dot gnu.org> 2013-05-08 19:48:33 UTC ---
I am in favor of documenting that the return value is always -1/0/+1.


^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Bug middle-end/57219] __builtin_isinf_sign source comments more restrictive than documentation
  2013-05-08 19:31 [Bug other/57219] New: __builtin_isinf_sign source comments more restrictive than documentation jtaylor.debian at gmail dot com
  2013-05-08 19:48 ` [Bug middle-end/57219] " glisse at gcc dot gnu.org
@ 2013-08-27 12:43 ` glisse at gcc dot gnu.org
  1 sibling, 0 replies; 3+ messages in thread
From: glisse at gcc dot gnu.org @ 2013-08-27 12:43 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57219

Marc Glisse <glisse at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |glisse at gcc dot gnu.org
         Resolution|---                         |FIXED

--- Comment #2 from Marc Glisse <glisse at gcc dot gnu.org> ---
r202021 | glisse | 2013-08-27 14:39:21 +0200 (Tue, 27 Aug 2013) | 7 lines

2013-08-27  Marc Glisse  <marc.glisse@inria.fr>

    PR middle-end/57219
    * doc/extend.texi (__builtin_isinf_sign): Restrict the return
    values to -1, 0 and 1.


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-08-27 12:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-05-08 19:31 [Bug other/57219] New: __builtin_isinf_sign source comments more restrictive than documentation jtaylor.debian at gmail dot com
2013-05-08 19:48 ` [Bug middle-end/57219] " glisse at gcc dot gnu.org
2013-08-27 12:43 ` glisse at gcc dot gnu.org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).