We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents df9f811 + 09ddcdd commit 3e95ba3Copy full SHA for 3e95ba3
Sources/Atomics/AtomicStrongReference.swift
@@ -79,11 +79,9 @@ extension DoubleWord {
79
80
@inline(__always)
81
fileprivate static var _readersBitWidth: Int {
82
- #if arch(i386) || arch(arm) || arch(arm64_32)
83
- return 8
84
- #else
85
- return 16
86
- #endif
+ // This reserves 8 bits for the accesses-in-flight counter on 32-bit
+ // systems, and 16 bits on 64-bit systems.
+ Int.bitWidth / 4
87
}
88
89
0 commit comments