iPhone Simulator takes several minutes to boot-up so I am tracing the elapses time of the system calls to aim speed up the booting time:
sudo dtruss -a -f "sudo -u flopez \"/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/Applications/iPhone\ Simulator.app/Contents/MacOS/iPhone\ Simulator\"" 3>&1 1>trace.txt 2>trace.txt
And I found two specially slow system calls:
awk '{ if ($2 >= 50000000 ) print }' trace.txt
PID/THRD ELAPSD SYSCALL(args) = return
1614/0x4dfd: 156374511 select(0x4, 0x7FFCE8404C90, 0x7FFCE84071E0, 0x0, 0x0) = -1 Err#4
1645/0x4fbf: 104751284 kevent64(0x3, 0x0, 0x0) = -1 Err#4
Note that the select()
system call took 104 seg and finally fails, so it would be helpful to discover the file path associated with this call.
How can I find this file?