Repository navigation
chore(shared-core): bump the SharedCore SPM pin to 0.7.0 - #803
Merged
Merged
Conversation
0.7.0 carries the bulk byte-array bridge: SharedBytes converts NSData and ByteArray with usePinned + memcpy, so Data+KotlinByteArray makes one bridge call per direction instead of one per byte. The two 3.4 MB bonding-curve tables were costing ~1.9 s of Objective-C message sends on the main thread during session construction; the round trip is 1.013 s -> 0.002 s in SharedCoreKitTests. Move the version floor in the three package manifests and the Xcode project's package reference together, then re-resolve. The manifests and the project resolve as one graph, and upToNextMinor makes 0.6.x and 0.7.x disjoint, so a site left behind fails to resolve rather than quietly pinning low.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Picks up
flipcash-shared-core-spm0.7.0, published fromcode-payments/code-android-app#1503.
SharedCoreKit'sData.kotlinByteArraycopied one byte per Objective-C message sendinto the Kotlin/Native runtime.
DiscreteBondingCurvepasses two 3,360,016-byte tablesthrough it, so
SharedBondingCurve.initializemade roughly 6.7M bridge calls — 1915.9 mson the main thread, inside session construction, before
state = .loggedIn. 0.7.0 addsSharedBytes, which convertsNSDataandByteArraywithusePinned+memcpy; the6,720,032-byte round trip in
SharedCoreKitTestsgoes 1.013 s to 0.002 s.Every other caller of that bridge passes 32–64 bytes, which is why it stayed invisible
until the curve tables went through it.
The version floor moves at four sites —
FlipcashCore,FlipcashUIandCrossPlatformVectorsmanifests plus the Xcode project's package reference — becausethey resolve as one graph and
upToNextMinormakes 0.6.x and 0.7.x disjoint. A site leftat 0.6.0 fails resolution outright rather than quietly pinning low.