instruments
How to find out what mach_msg_trap waits for?
Turn out my app is not actually spending 65% of it’s time in the mach_msg_trap function. It was a configuration error in Instruments on my part. The Sampler tool defaults to All Sample Counts, this will measure all threads regardless of their state. Instead switch to Running Sample Times that will reflect the current actual … Read more
What do “Dirty” and “Resident” mean in relation to Virtual Memory?
“Dirty memory” is memory which has been changed somehow – that’s memory which the garbage collector has to look at, and then decide what to do with it. Depending on how you build your data structures, you could cause the garbage collector to mark a lot of memory as dirty, having each garbage collection cycle … Read more
Why do I get instruments – “Target failed to run”?
I got the same issue when I switched to XCode 4 and I solved it by setting my release code-signing profile to my development profile instead of the app store profile that was previously set. Indeed, Xcode 4 profiles your app using the release build by default.
iOS Instruments – How to load dSYM file for Swift libraries such as libswift.foundation.dylib?
This answer is copied from https://github.com/Flash3001/iOSCharts.Xamarin/issues/17 by: Flash3001 but hope this will help you: The file is located in: /Library/Frameworks/Mono.framework/External/xbuild/Xamarin/iOS Before: <Target Name=”_CalculateCodesignAppBundleInputs” Condition=”‘$(_RequireCodeSigning)’ == ‘true'”> <ItemGroup> <_CodesignAppBundleInput Include=”$(_NativeExecutable)” /> <_CodesignAppBundleInput Include=”$(_AppBundlePath)Info.plist” /> <_CodesignAppBundleInput Include=”$(_AppBundlePath)embedded.mobileprovision” /> <_CodesignAppBundleInput Include=”$(DeviceSpecificIntermediateOutputPath)Entitlements.xcent” /> <_CodesignAppBundleInput Include=”@(_BundleResourceWithLogicalName)” /> <_CodesignAppBundleInput Include=”@(_NativeLibrary)” /> <_CodesignAppBundleInput Include=”@(_Frameworks)” /> <_CodesignAppBundleInput Include=”@(_ResolvedAppExtensionReferences -> ‘$(_AppBundlePath)PlugIns\%(FileName)%(Extension)\_CodeSignature\CodeResources’)” Condition=”‘$(IsAppExtension)’ == ‘false'” … Read more
Instruments > device grayed out
I only had to reboot my phone (not my Mac), and then the error went away (Xcode 9.2, iPhone X running 11.2.6).
How to log all methods used in iOS app
Inspired by tc’s answer to a similar question here, I put together a debug breakpoint action that will log out the class and method name for every time objc_msgSend() is triggered in your application. This works similarly to the DTrace script I described in this answer. To enable this breakpoint action, create a new symbolic … Read more
Problem running iPhone application on iPhone from Xcode (and in Instruments)
This happened to me as well (more than once). I ultimately had to restart Xcode to resolve the problem (after verifying the code signing settings were correct, the provisioning profile was installed, etc..).
Instruments 4.1 unresponsive to projects launched from Xcode 4.1 until pressing Cmd-Tab
Strange bug is fixed in XCode 4.2! The problem was the hidden password dialog, so sometime it works and sometimes not. One of possible solutions was: Run Instruments Cmd Tab to Xcode covering the instruments. Cycle and hide messages until password dialog is found. Close Xcode. PS: I know it is a few years to … Read more