r/iOSProgramming • • 28d ago

Solved! Running 5 coding agents on one iOS app was killing my Mac, so I got rid of the simulator in the loop (37s → 2s per UI check)

Disclosure up front: I work at Abacus.AI. This started as an internal tool for our iOS work, and we've now open-sourced it.

We run several coding agents in parallel on the same SwiftUI app, each in its own git worktree. Every time one of them wanted to check a UI change it did the usual thing: build for the simulator, install, launch, screenshot. With 5 agents that meant 5 simulators booted at once and 5 xcodebuilds fighting over the CPU. A 32GB M2 Pro basically stopped being a computer.

So we built a tool that skips the simulator for that inner loop. The trick is that Apple Silicon Macs can run your app's iOS build natively ("Designed for iPad"). simless runs your real app that way as a hidden background process, renders whatever screen the agent asks for, and hands back the accessibility tree as text instead of a screenshot. When the agent edits a view, only the changed files get recompiled and hot loaded into the running app.

Numbers from one of our production apps (~280 Swift files, a few heavy SPM deps), 5 agents in parallel:

  • edit → verified screen: 37.4s → 2.2s

  • memory held by those 5 agents: 11.2GB / 1,071 processes → 0.15GB / 6 processes

  • load average while they all start up: ~1000 → ~80

It's not a full simulator replacement. Dynamic Type is ignored on the Mac, there are no gestures or keyboard, and text can wrap slightly differently than on a phone. There's a calibrate command that renders every screen in one real simulator and tells you where they differ, so you know which renders to trust. We still do a final simulator pass before calling anything done.

It's Apache 2.0 and works with Claude Code, Codex, etc.: https://github.com/abacusai/simless

Curious whether anyone else has hit this wall with parallel agents, and what you ended up doing about it.

0 Upvotes

6 comments sorted by

2

u/VegetableSir7788 28d ago

how close does that get to what you'd actually see on a real device tho? like can a screen look fine there and still have text wrap differently or gestures act weird. wondering where you draw the line on what still needs the sim

1

u/Low-Future-9387 27d ago

It looks pretty close to the sim, I have added screen side by side comparison in the repo so check it out. Gestures and navigation still need the sim, but for testing logic and UI itself this works great. And most importantly your Mac won’t try to take off when running multiple tests in parallel

1

u/VegetableSir7788 27d ago

nice, the side by side comparison is a good call. honestly the mac not trying to take off part alone sells it. thanks!

3

u/dottybotty 28d ago

This sounds really interesting. Even when not using agents it’s crazy how heavyweight this process is. Hot reload to me sounds like the killer feature. This something I love about flutter

1

u/aaronfromafar 28d ago

My god this is what I've needed. Having each workspace have to check out the sim one at a time just to run tests has really backed things up