3 ms·
Were these ALU primitives or were they like "load, increment, store"?The latter could easily be non-atomic.
by wyldfire 4y ago
Were these ALU primitives or were they like "load, increment, store"?The latter could easily be non-atomic.
- gpderetta 4y agoINC/DEC are internally decomposed into separate read-modify-write operations, but are still atomic with regards to interrupts; for multiprocessing you need the LOCK prefix, which in the past brute-force locked the memory bus, but these days make sure that the operations are scheduled in such a way that the core is guaranteed not to lose ownership of the cacheline.