atomic_fetch_xor, atomic_fetch_xor_explicit
De cppreference.com
|
|
This page has been machine-translated from the English version of the wiki using Google Translate.
The translation may contain errors and awkward wording. Hover over text to see the original version. You can help to fix errors and improve the translation. For instructions click here. |
| Defined in header <stdatomic.h>
|
||
| C atomic_fetch_xor( volatile A* obj, M arg ); |
(1) | (desde C11) |
| C atomic_fetch_xor_explicity( volatile A* obj, M arg, memory_order order ); |
(2) | (desde C11) |
Atómicamente reemplaza el valor apuntado por
obj con el resultado de XOR bit a bit entre el valor antiguo de obj y arg, y devuelve el valor que tenía antes obj. La operación es de lectura-modificación-escritura de la operación. La primera versión de memoria de acuerdo con las órdenes accede memory_order_seq_cst, la segunda versión de la memoria de órdenes de acceso de acuerdo con order .Original:
Atomically replaces the value pointed by
obj with the result of bitwise XOR between the old value of obj and arg, and returns the value obj held previously. The operation is read-modify-write operation. The first version orders memory accesses according to memory_order_seq_cst, the second version orders memory accesses according to order.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
Este es un función genérica definida para todos los tipos de objetos atómicos.
A es el tipo de un objeto atómico, M o es del tipo no-atómico correspondiente a A A si es de tipo atómico entero o ptrdiff_t A si es de tipo puntero atómica .Original:
This is a función genérica defined for all atomic object types.
A is the type of an atomic object, M is either the non-atomic type corresponding to A if A is atomic integer type, or ptrdiff_t if A is atomic pointer type.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[editar] Parámetros
| obj | - | puntero al objeto atómico modificar
Original: pointer to the atomic object to modify The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
| arg | - | el valor a XOR bit a bit con el valor almacenado en el objeto atómico
Original: the value to bitwise XOR to the value stored in the atomic object The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
| order | - | la sincronización de la memoria de ordenación para esta operación: todos los valores están permitidos
Original: the memory synchronization ordering for this operation: all values are permitted The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. |
[editar] Valor de retorno
El valor que tenía antes ser objeto atómica apuntada por
obj .Original:
The value held previously be the atomic object pointed to by
obj.The text has been machine-translated via Google Translate.
You can help to correct and verify the translation. Click here for instructions.
You can help to correct and verify the translation. Click here for instructions.
[editar] Ver también
| atómico lógico AND Original: atomic logical AND The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (función) | |
| atomic_fetch_xor atomic_fetch_xor_explicit (C11) |
atómico exclusivo lógico OR Original: atomic logical exclusive OR The text has been machine-translated via Google Translate. You can help to correct and verify the translation. Click here for instructions. (función) |
| C++ documentation for atomic_fetch_xor, atomic_fetch_xor_explicit
| |