* [PATCH] Document atomic fetch and nand
@ 2019-01-09 6:35 Sebastian Huber
2019-01-11 20:26 ` Jeff Law
0 siblings, 1 reply; 2+ messages in thread
From: Sebastian Huber @ 2019-01-09 6:35 UTC (permalink / raw)
To: gcc-patches
Copy code example for fetch and nand from "Legacy __sync Built-in
Functions for Atomic Memory Access" to "Built-in Functions for Memory
Model Aware Atomic Operations".
gcc/
* doc/extend.texi (Built-in Functions for Memory Model Aware
Atomic Operations): Document atomic fetch and nand.
---
gcc/doc/extend.texi | 2 ++
1 file changed, 2 insertions(+)
diff --git a/gcc/doc/extend.texi b/gcc/doc/extend.texi
index 7f33be4f29c..f2a61e4c4f8 100644
--- a/gcc/doc/extend.texi
+++ b/gcc/doc/extend.texi
@@ -11008,6 +11008,7 @@ they are not scaled by the size of the type to which the pointer points.
@smallexample
@{ *ptr @var{op}= val; return *ptr; @}
+@{ *ptr = ~(*ptr & val); return *ptr; @} // nand
@end smallexample
The object pointed to by the first argument must be of integer or pointer
@@ -11029,6 +11030,7 @@ the type to which the pointer points.
@smallexample
@{ tmp = *ptr; *ptr @var{op}= val; return tmp; @}
+@{ tmp = *ptr; *ptr = ~(*ptr & val); return tmp; @} // nand
@end smallexample
The same constraints on arguments apply as for the corresponding
--
2.16.4
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Document atomic fetch and nand
2019-01-09 6:35 [PATCH] Document atomic fetch and nand Sebastian Huber
@ 2019-01-11 20:26 ` Jeff Law
0 siblings, 0 replies; 2+ messages in thread
From: Jeff Law @ 2019-01-11 20:26 UTC (permalink / raw)
To: Sebastian Huber, gcc-patches
On 1/8/19 11:35 PM, Sebastian Huber wrote:
> Copy code example for fetch and nand from "Legacy __sync Built-in
> Functions for Atomic Memory Access" to "Built-in Functions for Memory
> Model Aware Atomic Operations".
>
> gcc/
>
> * doc/extend.texi (Built-in Functions for Memory Model Aware
> Atomic Operations): Document atomic fetch and nand.
OK
jeff
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2019-01-11 20:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-01-09 6:35 [PATCH] Document atomic fetch and nand Sebastian Huber
2019-01-11 20:26 ` Jeff Law
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).