public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug web/46031] New: Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16
@ 2010-10-15  5:03 justin.lebar+bug at gmail dot com
  2010-10-15  5:08 ` [Bug web/46031] " pinskia at gcc dot gnu.org
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: justin.lebar+bug at gmail dot com @ 2010-10-15  5:03 UTC (permalink / raw)
  To: gcc-bugs

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

           Summary: Atomic Builtins page should indicate that 16-byte
                    compare-and-swap is available with -mcex16
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: web
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: justin.lebar+bug@gmail.com


The atomic builtins page doesn't indicate that gcc supports 16-byte
compare-and-swap instructions.  But gcc does in fact support this instruction,
so the page should indicate that the functionality can be enabled with -mcex16
(or, presumably, with the appropriate -march flag).

http://gcc.gnu.org/onlinedocs/gcc/Atomic-Builtins.html


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

* [Bug web/46031] Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16
  2010-10-15  5:03 [Bug web/46031] New: Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16 justin.lebar+bug at gmail dot com
@ 2010-10-15  5:08 ` pinskia at gcc dot gnu.org
  2010-10-15  5:30 ` justin.lebar+bug at gmail dot com
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2010-10-15  5:08 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> 2010-10-15 05:08:00 UTC ---
I don't think the atomics page should reference a target specific option. 

I think the following sentence makes that clear that the builtins are dependent
on target options as they can change what the target processor is:
Not all operations are supported by all target processors.


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

* [Bug web/46031] Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16
  2010-10-15  5:03 [Bug web/46031] New: Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16 justin.lebar+bug at gmail dot com
  2010-10-15  5:08 ` [Bug web/46031] " pinskia at gcc dot gnu.org
@ 2010-10-15  5:30 ` justin.lebar+bug at gmail dot com
  2010-10-15  5:40 ` pinskia at gcc dot gnu.org
  2010-10-15  5:54 ` justin.lebar+bug at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: justin.lebar+bug at gmail dot com @ 2010-10-15  5:30 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #2 from Justin Lebar <justin.lebar+bug at gmail dot com> 2010-10-15 05:30:20 UTC ---
"Not all operations are supported by all target processors" isn't the same as
"not all operations supported by target processors are listed here."

If you want to be vague and say "some target processors support other
operations or other operand sizes, not listed here", I guess that would be an
improvement.  But from a user's perspective, I'd like the manual to tell me
which builtins GCC supports, and under which circumstances those operations are
available.  In this case, the manual's omission of 16-bit cex suggested to me
that gcc didn't support it at all.


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

* [Bug web/46031] Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16
  2010-10-15  5:03 [Bug web/46031] New: Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16 justin.lebar+bug at gmail dot com
  2010-10-15  5:08 ` [Bug web/46031] " pinskia at gcc dot gnu.org
  2010-10-15  5:30 ` justin.lebar+bug at gmail dot com
@ 2010-10-15  5:40 ` pinskia at gcc dot gnu.org
  2010-10-15  5:54 ` justin.lebar+bug at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: pinskia at gcc dot gnu.org @ 2010-10-15  5:40 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> 2010-10-15 05:39:53 UTC ---
Actually it says the target processors might not include all of the builtins. 
What is a target processor is up to each target and likewise on how to change
the processor.

This should allow you to read the target options for how to change the
processor GCC is targeting.  This is the same issue as -march=i386 does not
support any of them vs -march=i686 supports the majority of them.

The x86 specific options explicitly references the atomic builtins.  Again I
don't think we should reference target specific options in the generic part of
the manual.  Doing that makes the manual even more confusing.  Maybe adding the
following sentence will help:
Each target defines how a specific processor is selected, see the target
options pages on how to select the specific processor.


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

* [Bug web/46031] Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16
  2010-10-15  5:03 [Bug web/46031] New: Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16 justin.lebar+bug at gmail dot com
                   ` (2 preceding siblings ...)
  2010-10-15  5:40 ` pinskia at gcc dot gnu.org
@ 2010-10-15  5:54 ` justin.lebar+bug at gmail dot com
  3 siblings, 0 replies; 5+ messages in thread
From: justin.lebar+bug at gmail dot com @ 2010-10-15  5:54 UTC (permalink / raw)
  To: gcc-bugs

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

--- Comment #4 from Justin Lebar <justin.lebar+bug at gmail dot com> 2010-10-15 05:54:28 UTC ---
> Actually it says the target processors might not include all of the builtins.

Maybe I'm not making sense.  My point is that there's a builtin (*) that is
supported by some target processors but is not listed in the manual.  So the
statement that some target processors might not include all the builtins isn't
helpful.

* The builtin is compare_and_swap with 16-byte operands.  The manual explicitly
says "GCC will allow any integral scalar or pointer type that is 1, 2, 4 or 8
bytes in length" but should indicate that 16-byte operands are supported for
compare_and_swap, at least under some circumstances.


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

end of thread, other threads:[~2010-10-15  5:54 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-10-15  5:03 [Bug web/46031] New: Atomic Builtins page should indicate that 16-byte compare-and-swap is available with -mcex16 justin.lebar+bug at gmail dot com
2010-10-15  5:08 ` [Bug web/46031] " pinskia at gcc dot gnu.org
2010-10-15  5:30 ` justin.lebar+bug at gmail dot com
2010-10-15  5:40 ` pinskia at gcc dot gnu.org
2010-10-15  5:54 ` justin.lebar+bug at gmail dot com

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).