Repository navigation
Upgrade LUI to 93b2097 and adapt native event forwarding - #144
Merged
Merged
Conversation
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
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.
Upgrade LUI from
4fdb9136026af7863a8d025133871e34864eace1to93b209713acd852094af085737762e59161e2265, the latest main resolved when this task began.Journal keeps its native Timeline, fixed resident graph hosts and existing UI/UX. The new
virtualWindowevent uses typed Swift → C → OCaml forwarding with full-width IDs, validated ranges/pins, GC roots and owned patch delivery after releasing the runtime. The app explicitly negotiates the existing host-code-2 eager capability; this does not adopt LUI virtual_rows. Thirteen required transitive dependencies are added, with all previously locked package versions retained. The link-only build stub is aligned with the new symbol.Validation
fb64304e13ec6ee75bf87140abb0e0b75efdfcd1; clean diff, independent read-only review of all ten changed files found no evidenced issue.dune build @all app/native_embed.exe.oanddune runtest --force: pass at final head.Repeated performance comparison
Same M4 Max/64 GiB, macOS 26.6.2, Xcode 26.1.1, Swift 6.2.1, OCaml 5.5.0 and iOS 26.1 Simulator. Same optimized Release fixture configuration, synthetic data and operations. Normal binaries have no added timing/display probes. No local builds or recording overlap timed samples.
The following rows are five iterations per version within one XCTest session, not five independent processes. Memory is XCTest physical memory in decimal kB, converted to MiB. CPU is whole app CPU during the actions, including in-process AX handling, not pure main-thread rendering time.
Five additional independent fresh-data process pairs alternate old/new order. These title/image observations include the XCTest drag and AX polling overhead and are not first-pixel timing:
Standard fixture: 114 roots per graph, with three fixed canonical transactions already present before every standard comparison (Today page creation plus two Capture entries on A; A has 116 roots). Large fixture: an independent zero-cursor peer with 2,000 added roots per graph, 2,114 total. Each run starts from an independent checkpoint copy.
Separate diagnostic binaries
Three independent no-recording process pairs are the primary diagnostic sample; the separately recorded first pair is excluded. There are six cold preparations and fifteen warm commits per version. Synchronous emission wall time is distinct from full handoff latency. CADisplayLink callback gaps are not hardware presented FPS. The 608 pooled warm callback intervals per version are correlated frames, not 608 independent runs.
Small tail increases are retained: instrumented runtime-start max +1.342 ms, cold snapshot max +0.335 ms and warm display interval p95 +0.030 ms. With small event counts, nearest-rank p95 often equals max; no significance claim is made.
Extended memory comparison
Short five-iteration memory deltas were higher after upgrading (standard median 491.520 → 917.504 kB; large median 655.360 → 1163.264 kB), despite lower absolute/peak memory. We therefore repeated the identical 2,114-root scroll operation twenty times per version, 160 native scrolls each, with no probe or recording:
Twenty-iteration follow-up: app CPU median 3.708279 → 2.6154075 s (−29.47%); peak physical memory median 142.324 → 131.949 MiB (−7.29%), with maxima 143.722 → 134.378 MiB. Every observed candidate absolute/peak sample remains below its baseline counterpart.
The per-iteration physical-memory delta median is 188.416 → 139.264 kB (−26.09%); its p95 rises 638.976 → 1114.112 kB (+475.136 kB), while its maximum falls 5374.000 → 1687.552 kB. Both versions gain exactly 1,228.8 kB (1.171875 MiB) across the last ten ordered absolute-memory observations. This does not establish a complete plateau: first-to-last growth is 2,162.688 → 3,440.688 kB, and last-ten fitted slopes are 126.703 → 169.003 kB/iteration. We retain this higher fitted slope and the early-session growth difference rather than calling the candidate leak-free. One long session per version cannot settle very long-term memory behavior.
The cumulative signpost duration for eight scrolling gestures (not a single-frame hitch) median is essentially unchanged, 2.566040 → 2.5660275 s. Its maximum rises 2.599369 → 2.632817 s (+33.448 ms, +1.287%). This tail observation is retained; the sample does not justify claiming that every latency metric improves, nor does it identify a repeatable latency regression by itself. The bounded Simulator tests show lower CPU and absolute/peak memory, while hardware frame-rate and indefinite-memory guarantees remain unproven.
Evidence and practical limits
The task-local report, CSV and raw evidence retain ordered samples, min/max, standard deviation, absolute/relative differences, traces, historical driver snapshots, producer records and SHA-256 manifests. The delivered recordings show actual native operations at original speed; the two swipe clips exclude a Simulator startup PTS discontinuity using unchanged contiguous video packets with a constant timestamp offset, and full sources remain locally preserved; diagnostic videos are not used for the no-recording performance comparison.
The apps retain production Journal UI/reducers with identical existing synthetic fixture hooks and memory-only authentication/key storage. JournalApp is Release-optimized with the existing DEBUG fixture storage hook; LUI is Release. Experimental host-restamped OCaml inputs retain
cross_abi_validated=false. This is not physical-device ABI, real-account or hardware FPS proof. XCTest returned no usable hitch/FPS metric, so none is fabricated.spec-dev-tool check --allis unavailable (exit 127). No merge or TestFlight publication is included.Production app binaries were built at
b0c0440; subsequent commits change only the existing pin test constant and the link-only stub. Final runtime source is equivalent to the measured app, and final source checks bindfb64304.Final-head CI: Journal CI run 41020389775 completed successfully. The PR is open, non-Draft and not merged. UI/video/raw evidence is retained locally; attachments are omitted.