2
0
mirror of https://github.com/boostorg/atomic.git synced 2026-02-01 20:12:09 +00:00
Files
atomic/test/fallback_ref_api.cpp
Andrey Semashev 34a2bc134c Fixed compilation on 32-bit x86, reduced code duplication.
On 32-bit x86, 64-bit integers have 4-byte alignment, which resulted in
a non-integral type being selected for storage type in case of lock-based
atomic_ref. This broke arithmetic and bitwise operations on atomic_ref.

We now select an integral type based on its native alignment, not the storage
alignment we require for atomic operations. This is fine in case of lock-based
backend.

Also, extended buffer_storage with support for specifying alignment and removed
aligned_buffer_storage and storage128_t.
2020-03-01 03:11:33 +03:00

3.1 KiB