Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Core Data Instruments for the iPhone

I'm trying to monitor my core data usage but all the Core Data instruments are greyed out in Instruments. It's also not available from the "Run with Performance Tool" in Xcode. It says that the Core Data instruments are for the Mac and it's not available on the iPhone, but I've heard people talking about using it, and it's mentioned in the Apple docs too.

How can I get them working?

Thanks!

like image 956
Michael Waterfall Avatar asked Nov 25 '09 21:11

Michael Waterfall


People also ask

What is Core Data on iPhone?

Core Data is a framework that you use to manage the model layer objects in your application. It provides generalized and automated solutions to common tasks associated with object life cycle and object graph management, including persistence.

What are iOS Instruments?

Instruments is a powerful performance analysis and testing tool that's part of Xcode toolset. Instruments can help you profile your apps on all platforms - iOS, macOS, watchOS, tvOS - in order to better understand and optimize their behavior and performance.

Should I use Core Data iOS?

The next time you need to store data, you should have a better idea of your options. Core Data is unnecessary for random pieces of unrelated data, but it's a perfect fit for a large, relational data set. The defaults system is ideal for small, random pieces of unrelated data, such as settings or the user's preferences.


1 Answers

You can run Core Data instruments against the simulator only, not the device.

Open Instruments and select the Core Data items you want, then use Instruments to launch the simulated iPhone app, instead of launching from Xcode.

Hopefully this support is better in future versions. Also, I believe it only works with 3.1, not 3.0.

like image 117
Hunter Avatar answered Oct 28 '22 07:10

Hunter