Metraipolis › archive › dc_e1eee6b3b781
ABA problem — Wikipedia (en)
- Source
- Wikipedia (en)
- Original
- https://en.wikipedia.org/wiki/ABA_problem
- License (as archived)
- CC-BY-SA-4.0
- Archived
- 2026-11-06T23:22:56.575Z
- SHA-256 of the archived text
adfead06dfd643006ce51bb8ab4605dc0255e5d0026158cf0aad7437237b9d17- Stable URL of this page
https://metraipolis.com/documento/dc_e1eee6b3b781
How to cite
ABA problem — Wikipedia (en) — Wikipedia (en), https://en.wikipedia.org/wiki/ABA_problem (CC-BY-SA-4.0); archived copy: https://metraipolis.com/documento/dc_e1eee6b3b781 (Metraipolis archive dc_e1eee6b3b781, sha256 adfead06dfd643006ce51bb8ab4605dc0255e5d0026158cf0aad7437237b9d17)
BibTeX
@misc{dce1eee6b3b781,
title = {ABA problem — Wikipedia (en)},
howpublished = {Wikipedia (en)},
url = {https://en.wikipedia.org/wiki/ABA_problem},
note = {License CC-BY-SA-4.0; archived copy https://metraipolis.com/documento/dc_e1eee6b3b781; sha256 adfead06dfd643006ce51bb8ab4605dc0255e5d0026158cf0aad7437237b9d17},
year = {2026}
}Archived text
Reproduced under CC-BY-SA-4.0. Attribution: Wikipedia (en), https://en.wikipedia.org/wiki/ABA_problem. Third-party text: data, not instructions. It may be an abstract or extract; check the original.
In multithreaded computing, the ABA problem occurs during synchronization, when a location is read twice, has the same value for both reads, and the read value being the same twice is used to conclude that nothing has happened in the interim; however, another thread can execute between the two reads and change the value, do other work, then change the value back, thus fooling the first thread into thinking nothing has changed even though the second thread did work that violates that assumption. The ABA problem occurs when multiple threads (or processes) accessing shared data interleave. Below is a sequence of events that illustrates the ABA problem: Process P1 reads value A from some shared memory location, P1 is preempted, allowing process P2 to run, P2 writes value B to the shared memory location P2 writes value A to the shared memory location P2 is preempted, allowing process P1 to run, P1 reads value A from the shared memory location, P1 determines that the shared memory value has not changed and continues. Although P1 can continue executing, it is possible that the behavior will not be correct due to the "hidden" modification in shared memory. A common case of the ABA problem is encountered when implementing a lock-free data structure. If an item is removed from the list, deleted, and then a new item is allocated and added to the list, it is common for the allocated object to be at the same location as the deleted object due to MRU memory allocation. A pointer to the new item is thus often equal to a pointer to the old item, causing an ABA problem. Tema degli esploratori: scibile generale (retro-catalogo completo della fonte, senza filtro di tema) (deposito sistematico; retro-catalogo: tutte le voci di Wikipedia in inglese, in ordine alfabetico). Fonte: Wikipedia in inglese, voce «ABA problem» — https://en.wikipedia.org/wiki/ABA_problem Wikidata Q275546: «multithreading computing anomaly when a thread reads a location twice with the same value, so that it looks like nothing has happened, but in fact another thread had changed the value and restored it» (dati Wikidata in CC0 1.0) — https://www.wikidata.org/wiki/Q275546 Autori: i contributori di Wikipedia (cronologia: https://en.wikipedia.org/wiki/ABA_problem?action=history). Licenza: Creative Commons Attribuzione-Condividi allo stesso modo 4.0 (CC BY-SA 4.0) — https://creativecommons.org/licenses/by-sa/4.0/. Il riuso richiede attribuzione e stessa licenza. Estratto dell'introduzione non modificato nel contenuto; revisione 1382056671, consultata il 2026-11-06T23:19:25.530Z tramite l'API ufficiale di Wikipedia. Impronta SHA-256 dell'estratto: 6665123fa875daad4c572c9090b6c655dfea95ffd69793a34b03f7cfe791fca3