8 Commits
Author SHA1 Message Date
Karoy Lorentey 040c295e86 Update copyrights 2025-06-04 11:31:02 -07:00
Karoy Lorentey 581fb9e875 Drop support for Swifts 5.7-5.9
As usual, we support just the three latest Swift releases: 5.10, 6.0 and 6.1.

Also delete obsolete C atomics. Dropping Swifts <5.9 allows us to make ATOMICS_NATIVE_BUILTINS the unconditional default behavior.
2025-06-03 19:23:53 -07:00
Karoy Lorentey fe0fc8b76c Avoid confusing Swift 5.7 with _pointerBitWidth conditionals
#if conditional parsing is evidently broken in 5.7, and it gets confused unless things are arranged just right. Things seem to work as long as the `compiler(>=5.9)` conditional is put on its own `#if` construct on the topmost level — so let’s do that for now.
2023-09-27 14:19:36 -07:00
Karoy Lorentey 48fad5a291 Let builtins & shims expose different primitive signatures
For builtins, we want to emulate the stdlib’s solution where all atomic primitive operations take and return a (sort of) opaque atomic representation value.

For C shims, we do not want to atomic primitives to take and return _Atomic(T) values, so let’s revert to the original 1.1.x solution.
2023-09-25 21:05:53 -07:00
Karoy Lorentey d976dd29ad Protect _pointerBitWidth conditionals from misparsing on older Swifts 2023-09-25 19:42:22 -07:00
Karoy Lorentey 8b703fe93c [native atomics] Fix alignment issues by reintroducing custom storage types
The SysV ABI defined uint64_t with 4 byte alignment on i386 — so we can’t just assume that the integer types will have the right alignment by default for atomics.

Emulate the original `_Atomic<Width>Storage` types in the C shims even in native atomics configuration, so that they can carry a custom `@_alignment` attribute.
2023-09-22 00:41:51 -07:00
Karoy Lorentey 4166cff711 Move definition of DoubleWord into DoubleWord.swift 2023-09-20 18:49:02 -07:00
Karoy Lorentey b1b74cb512 Reorganize source folder 2023-09-20 18:39:37 -07:00