instruments

Detecting redundant function calls within call stack tree with DTrace

泄露秘密 提交于 2019-12-11 05:57:35
问题 I'm having a hard time tracking down unnecessary redundant calls within a rather complex algorithm. It looks like (some of my) my algorithm(s) is/are seriously slowed down by redundant calls (in several subroutines) of a non-cached and comparatively expensive function. To confirm this I'd like to utilize Dtrace to detect multiple calls of a single function within a given branch of the call stack tree. I'd like to be able to ask dtrace to: search the call stack tree within a given function

Is it possible to extend the Instruments profiler on Mac OS X for a new language?

前提是你 提交于 2019-12-11 05:06:42
问题 I'd like to use the Instruments profiler on the Mac to profile Haskell code. However, Haskell isn't a supported language by Xcode/Instruments. Is it possible to extend Instruments to support profiling in a new/unsupported language? What would be involved? 回答1: Instruments is a front-end to DTrace. You can use DTrace hooks with GHC. 来源: https://stackoverflow.com/questions/13778669/is-it-possible-to-extend-the-instruments-profiler-on-mac-os-x-for-a-new-language

App crashes only with (lldb)?

别说谁变了你拦得住时间么 提交于 2019-12-11 04:51:43
问题 I have an app with Cocos2D and some UIKit mixed in. I have recently been implementing some new features so maybe the memory management is wrong or something is getting over-released but whenever I exit the app by clicking the home button, the console just crashes only with the message (lldb). Even if I turn on NSZombiesEnabled nothing different happens. The only thing my app points to is a line that looks like this: libGPUSupportMercury.dylib`gpus_ReturnNotPermittedKillClient: 0x38101094:

Instruments: Leaks and Allocations (tvOS)

跟風遠走 提交于 2019-12-11 04:41:41
问题 I’m currently working on a tvOS app. This is my first native (Swift) app. The app will be a digital signage app, used during events or in offices of companies. One big difference compared to a typical app on iOS/tvOS is that it needs to run pretty much 24/7, so memory is a big topic for this app. The smallest leak will eventually cause the app to crash. The app is constantly looping through a set of fullscreen slides. At the bottom of the screen there is a ticker with 10 articles (refreshed

App crashes on certain actions when using instruments, how to find reason?

折月煮酒 提交于 2019-12-11 04:28:44
问题 I have an App with a Navigation Controller, several sub Controllers. With XCode Debug I can't find any errors. With iPhone running unplugged, I can't find any errors. With Instruments running the App on Simulator it doesn't crash. With Instruments running the App on iPhone it crashes when I click forth and back between certain ViewControllers. It's not happening everytime, but very often. My boss also reported that on his iPod it crashes sometimes, so I'm quite confused now. How should I

How to determine where this memory leak is coming from?

ぐ巨炮叔叔 提交于 2019-12-11 04:07:30
问题 How can I determine where this memory leak is coming from in my code? It doesn't reference anything but the "main" function in my application. 回答1: It looks like you're trying to use NSZombieEnabled and leaks at the same time. These two diagnostic techniques don't work together--NSZombieEnabled makes all deallocated objects just stick around, so they will appear as leaks. Simply turn off NSZombieEnabled and you should be set for this case. 回答2: As Joey said; you can't use Zombie Detection and

Resident memory vs live bytes

此生再无相见时 提交于 2019-12-11 04:05:30
问题 Assumption: I am working on an iPhone project using Cocos2d 2.0 with ARC (and use Instruments of XCode 4.5.2). Short question: Why resident memory is much higher than live bytes? I say this because: using instruments: I do get low memory warnings and I run my Allocation tool and see on avarage 3/5 MB of live bytes. Then I get a peak (18MB) and then back to 3/5MB. The problem is that, whenever I keep going back and forwards from one scene to the other I do get low memory warnings. Using

JavaScriptCore crash on iOS9

旧城冷巷雨未停 提交于 2019-12-11 03:34:01
问题 Encountering a crash for a iOS9 only. The crash is manifesting in JavaScriptCore though I'm not certain it has anything to do with JavaScriptCore. I'm more inclined to believe this is an issue with memory exhaustion more specifically and possible virtual memory exhaustion. As noted in the screenshot free RAM is exceptionally low so it's definitely not an ideal situation. I don't know enough about iOS internals to entirely what's going on here but wondering if there's others out there who have

Core Data: NSObjectID and NSTemporaryObjectID leaks

橙三吉。 提交于 2019-12-10 15:51:15
问题 Before I send my app to the App Store I like to check it for memory leaks and other fishy stuff with instruments. There is one Core Data issue that I can't seem to solve, so I've decided to create a small test app to illustrate the problem. What's the problem? When I save an entity in a (child) NSManagedObjectContext it is propagated to its parent NSManagedObjectContext. During this process Core Data creates internal instances of _NSObjectID and NSTemporaryObjectID . For some reason these

Is Core Animation color blended layers useful or say is it necessary?

元气小坏坏 提交于 2019-12-10 13:03:32
问题 Color Blended Layers Open Instruments and choose the Core Animation template located under iOS / Graphics. First, click in the Core Animation instrument's timeline to reveal the bottom pane and find the section labeled "Debug Options". Check the "Color Blended Layers" box, which will show a red overlay over layers that were blended and a green overlay over layers drawn without blending. Is Core Animation color blended layers useful or say is it necessary? I found that the system UI is red