Swiftpack.co - Swift Packages by glessard

Swiftpack.co is a collection of thousands of indexed Swift packages. Search packages.

Packages published by glessard

glessard/swift-atomics 6.5.0
Atomic operations bridged from Clang to Swift
⭐️ 117
🕓 3 years ago
🔖 Release Notes

Releases

The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
Tweaks to compare-and-exchange functions
4 years ago
Move choice between weak and strong CAS out of the C parameter list in `CAtomics` - In the `CAtomics` module, all types have direct `CompareAndExchangeWeak` and `CompareAndExchangeStrong` functions rather than a single function with a parameter selecting between strong and weak. - The old version of `CompareAndExchange` with a `CASType` parameter still exists, but forwards to either of the other two, making it objectively worse. - `SwiftAtomics` internally adapts to the above, but is otherwise unchanged.
Fix for Windows
4 years ago
- use `intptr_t` in tagged pointer unions.
Simplifications, mostly.
4 years ago
- Changes the default memory ordering parameters in SwiftAtomics. The defaults are now `.acquire` for loading operations, `.release` for storing operations, and `.acqrel` for read-modify-write operations. - Removes the `load()` function on `AtomicReference`. `load` required locking, and it failed once every several million attempts (under contention), and that just wasn't good enough. (It fails seldom enough that what I thought had been extensive testing prior to version 4.2.0 was in fact insufficient.) There's been a fair bit of trying to fix it in the last year, but nothing has completely worked. The correct solution may require collaboration with Swift's ARC reference-counting runtime, and therefore will have to wait until a similar type appears in the standard library.
Version 5
4 years ago
This release has major changes to the `CAtomics` package, in that it no longer uses swift-style function names, but uses (once more) C-style names: it switches from using the `SWIFT_NAME` macro to `__attribute__((overloadable))`. This allows all the necessary changes to have a similar shape, as `AtomicInt.load(_ order: LoadMemoryOrder)` becomes `CAtomicsLoad(_ atomic: UnsafeMutablePointer<AtomicInt>, order: LoadMemoryOrder)`. The Swift-style module is renamed to `SwiftAtomics`, which is less presumptuous than just `Atomics`. (Still presumptuous, but the standard library is unlikely to ever have a module named `SwiftAtomics`.) Finally, tagged pointers are now usable from the `SwiftAtomics` module, after having been usable from `CAtomics` since `4.4.0`.
Fix for Swift 5 compiler
5 years ago
- The Swift 5 compiler no longer imports structs with large alignments. This defeats the approach I previously took to pad structs. - In order to get padded structs to mitigate false sharing effects, the package now inserts explicit padding rather than explicitly requesting a large alignment. This is not the ideal solution, but it's good enough for most cases. - The padded types are renamed from 4.4.0, with abject apologies to anyone who might be affected. I should have tried building with Swift 5 a tad earlier.
4.4.0
5 years ago
- Adds tagged pointers to the CAtomics package, taking advantage of 128-bit atomic instructions in x64 and ARM64 - Adds cache-aligned variants to various types from CAtomics. These types take an entire cache line to themselves, which can be useful in some cases. - Adds initializers, such as `AtomicInt32.init(_ value: Int32)` and `AtomicRawPointer.init(_ pointer: UnsafeRawPointer)`. Previously one had to use a default initializer followed by a call to the `initialize` method. - Adds a compare-and-swap operation to `AtomicReference` - Supports the Windows build of Swift
Improvements for Swift 4.2
5 years ago
Improvements for Swift 4.1
5 years ago
Improved CAtomics
6 years ago
The underlying C package has a nicer interface when used from Swift.
glessard/swift-reactive-streams 0.4.2
An interpretation of Reactive Streams in Swift
⭐️ 4
🕓 3 years ago
🔖 Release Notes

Releases

The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
tag it.
4 years ago
glessard/shuffle 2.3.0
Shuffle a Collection
⭐️ 3
🕓 3 years ago
glessard/deferred darwin-atomics
A lock-free, asynchronous Result: a future Result, a promised Result, a deferred Result.
⭐️ 3
🕓 3 years ago
🔖 Release Notes

Releases

The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
Improved queue handling
3 years ago
API improvements
4 years ago
- API improvements when the `Failure` type is `Never`: some accessors become non-Optional, while some functions become non-throwing. - Made the `cancel()` method available only when it is usable by repeating it in conditional extensions. - Added a customization point for cancellation for subclasses of `Deferred`. - Added versions of `recover()` for error types more specific than `Error`.
Typed Errors
4 years ago
Major update to `deferred`, adding typed errors as a generic parameter, using the same parameter names as the standard library's `Result`. Another major change involves execution scheduling: execution now starts only once a `Deferred`'s result has been explicitly requested in some way. The `notify` method is the primary way to accomplish this (along with `onValue` and `onError`), as well an explicit call to `beginExecution()`. Finally, the URLSessionTask wrapper has been moved to its own package, `DeferredHTTP`.
4 years ago
Encapsulation improvements and improved lock-freedom.
4 years ago
4 years ago
4.4.0
5 years ago
Improves performance by consolidating notifications and deallocations - fewer calls to dispatch_async - more work done in each dispatch_async Improvements to and full testing of `DeferredURLSessionTask`. Added a `split` method for any `Deferred` whose value type is a tuple of 2, 3 or 4 elements. The return value is a tuple of `Deferred`; if the original `Deferred`'s outcome is an `Error`, then every `Deferred` in the split is determined with the same `Error`.
more api tweaks
5 years ago
- added parameter labels to `determine()` methods (with fix-its.) The parameter-less versions didn't save anything much, while causing grief when `Value` has a type that implements `Error` - improved behaviour of `firstValue()`. Its outcome is now an error only when all the inputs are errors. - the old behaviour is still provided by `firstDetermined()`.
api tweaks
5 years ago
made `class Transferred: Deferred` public as a convenience. renamed `Determined<T>` to `Outcome<T>` (no changes necessary.) renamed some parameter labels for clarity (with deprecation/rename warnings.)
Swift 4.2 update
5 years ago
glessard/SwiftCompatibleAtomics 0.7.1
Swift atomics implementation, source compatible with Swift's (possible) future Atomics submodule
⭐️ 1
🕓 3 years ago
glessard/DeferredHTTP 1.2.0
URLSessionTask wrapped in Deferred.
⭐️ 0
🕓 3 years ago
glessard/timing 2.1.1
Easy timing and pretty-printed time intervals in Swift
⭐️ 0
🕓 3 years ago
glessard/digests 1.0.3
Swift wrapper for CommonCrypto's digest algorithms API
⭐️ 0
🕓 3 years ago
glessard/TFFSubscribers 0.3.0
Subscribers for use with Combine
⭐️ 0
🕓 3 years ago
iOS macOS watchOS
glessard/composition 2.1.3
Function composition operator
⭐️ 0
🕓 4 years ago
🔖 Release Notes

Releases

The markdown parsing is broken/disabled for release notes. Sorry about that, I'm chasing the source of a crash that's been bringing this website down for the last couple of days.
6 years ago
Package description updated for Swift 4
7 years ago
glessard/TFFPublishers 1.1.3
Publishers for use with Combine
⭐️ 0
🕓 3 years ago
iOS macOS watchOS

Swiftpack is being maintained by Petr Pavlik | @ptrpavlik | @swiftpackco | API | Analytics