mirror of
https://github.com/software-mansion/argent.git
synced 2026-09-14 19:27:14 +08:00
f47481ae84
On Xcode 26.x / Instruments 16, xctrace can no longer package a `--device <udid> --attach <app>` simulator trace (coreprofilesessiontap fails), which breaks native profiling on the simulator entirely. When device-attach fails on a simulator, transparently fall back to a host `--all-processes` Time Profiler recording and scope the results to the app's host PID. This path is CPU-only by construction — Leaks and Allocations cannot target "All Processes" — so hangs/leaks export is skipped and their absence is no longer reported as a failure. - start: detect the app's host PID, retry device-attach, then fall back to a host-wide Time Profiler scoped to that PID. Clears stale .trace bundles between attempts. Only falls back on simulators. - pipeline: filterSamplesByPid scopes a host-wide trace to the app via the `(AppName, pid: N)` thread fmt tag. - analyze: emit an "Analysis Inconclusive" report (never "All clear") when the only data source produced no readable/app-matching samples. - metadata sidecar: persist mode/pid/appProcess next to the trace so a different tool-server process can reconstruct app-scoped analysis on profiler-load. - export: ExportOptions.keys to restrict export to CPU in fallback mode. - tests: host-fallback PID scoping + inconclusive reporting; update stop-recovery for the new export signature.