앱 스토어에 첫 번째 앱을 제출할 준비가되었습니다. 장치에서 테스트 한 누출, 작동 여부를 확인했습니다. 나는 내 기억이 통제하에 있는지 확인하여 할당을했고, 아, 통제 할 수있는 것이 아무것도 없었다.아이폰 앱 메모리가 계속 성장합니다
나는 내 응용 프로그램의 테스트 여러 영역을했습니다,하지만 사용자가 계속 사용 메모리가 매우 쉽게 통제 할 수 있도록 할 수있는 몇 가지 큰 영역에 초점을 맞추었다. 나에게 Allocations/Heapshots의 정보는 읽기가 힘들다. 그래서 나는 Rosetta Stone이 나에게 이런 결과를 줄 수 있기를 바란다.
나는 가능한 한 많은 세부 사항을 제공하기 위해 노력하고, 충분하지 경우, 단지 소리, 내가 더 쓸 것이다 것입니다.
앱은 메뉴에서 시작한다. 버튼을 클릭하면 presentModalViewController를 통해 뷰가 표시됩니다. 뷰가 나타나고 백그라운드에서 데이터베이스가 열리고 임의의 행이 선택되어 저장됩니다. 따라서주기 : 메인 메뉴 ->보기 열기 ->보기 닫기를 클릭하면 매번 10KB-25KB의 속도로 메모리가 커집니다.
일부의 생각 : 내보기의
- 일부 부품은 사용자 정의 .PNG 파일 인 버튼 의 일부, IB를 통해 만들어집니다. 이전 빌드에서 메모리 누수의 원인이 된 이러한 리소스를 해제하고 다시 할당하는 데 문제가 있음을 읽었습니다.
- 나는 원래 IB에서 만든 나의 버튼의 일부 button.layer.borderWidth /의 borderColor/CornerRadius를 /의 backgroundColor를 사용했습니다. 이건 아니야? (그들을 제거하면 조금 도움이되지만 문제는 여전히 나타납니다). 당신이 코드의 비트가 도움이 될 것입니다 생각하는 경우
0 libSystem.B.dylib calloc 1 CoreGraphics CGGlyphBitmapCreate 2 CoreGraphics CGFontCreateGlyphBitmap8 3 CoreGraphics CGFontCreateGlyphBitmap 4 CoreGraphics CGGlyphLockLockGlyphBitmaps 5 libRIP.A.dylib ripc_DrawGlyphs 6 CoreGraphics draw_glyphs 7 CoreGraphics CGContextShowGlyphsWithAdvances 8 WebCore WebCore::showGlyphsWithAdvances(WebCore::FloatPoint const&, WebCore::SimpleFontData const*, CGContext*, unsigned short const*, CGSize const*, unsigned long) 9 WebCore WebCore::Font::drawGlyphs(WebCore::GraphicsContext*, WebCore::SimpleFontData const*, WebCore::GlyphBuffer const&, int, int, WebCore::FloatPoint const&, bool) const 10 WebCore WebCore::Font::drawSimpleText(WebCore::GraphicsContext*, WebCore::TextRun const&, WebCore::FloatPoint const&, int, int) const 11 WebCore WebCore::Font::drawText(WebCore::GraphicsContext*, WebCore::TextRun const&, WebCore::FloatPoint const&, int, int) const 12 WebKit drawAtPoint(unsigned short const*, int, WebCore::FloatPoint const&, WebCore::Font const&, WebCore::GraphicsContext*, bool, WebCore::BidiStatus*, int) 13 WebKit -[NSString(WebStringDrawing) __web_drawAtPoint:forWidth:withFont:ellipsis:letterSpacing:includeEmoji:measureOnly:renderedStringOut:drawUnderline:] 14 WebKit -[NSString(WebStringDrawing) __web_drawAtPoint:forWidth:withFont:ellipsis:letterSpacing:includeEmoji:measureOnly:renderedStringOut:] 15 WebKit -[NSString(WebStringDrawing) __web_drawAtPoint:forWidth:withFont:ellipsis:letterSpacing:includeEmoji:measureOnly:] 16 WebKit -[NSString(WebStringDrawing) _web_drawAtPoint:forWidth:withFont:ellipsis:letterSpacing:includeEmoji:] 17 UIKit -[NSString(UIStringDrawing) drawAtPoint:forWidth:withFont:lineBreakMode:letterSpacing:includeEmoji:] 18 UIKit -[NSString(UIStringDrawing) drawAtPoint:forWidth:withFont:fontSize:lineBreakMode:baselineAdjustment:includeEmoji:] 19 UIKit -[NSString(UIStringDrawing) drawAtPoint:forWidth:withFont:fontSize:lineBreakMode:baselineAdjustment:] 20 UIKit -[UILabel _drawTextInRect:baselineCalculationOnly:] 21 UIKit -[UILabel drawTextInRect:] 22 UIKit -[UILabel drawRect:] 23 UIKit -[UIView(CALayerDelegate) drawLayer:inContext:] 24 QuartzCore -[CALayer drawInContext:] 25 QuartzCore backing_callback(CGContext*, void*) 26 QuartzCore CABackingStoreUpdate_ 27 QuartzCore CA::Layer::display_() 28 QuartzCore -[CALayer _display] 29 QuartzCore CA::Layer::display() 30 QuartzCore -[CALayer display] 31 QuartzCore CA::Layer::display_if_needed(CA::Transaction*) 32 QuartzCore CA::Context::commit_transaction(CA::Transaction*) 33 QuartzCore CA::Transaction::commit() 34 QuartzCore CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*) 35 CoreFoundation __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ 36 CoreFoundation __CFRunLoopDoObservers 37 CoreFoundation __CFRunLoopRun 38 CoreFoundation CFRunLoopRunSpecific 39 CoreFoundation CFRunLoopRunInMode 40 GraphicsServices GSEventRunModal 41 GraphicsServices GSEventRun 42 UIKit UIApplicationMain 43 GRE Words main /Users/admin/Dropbox/GRE Words/main.m:14 44 GRE Words start
은 알려 주시기 바랍니다 : 그 호기심에 대한
,이 힙 성장의 가장 큰 호출 스택입니다. 나는 앞으로 나아가고있는 것처럼 느꼈다. 그리고 이것은 꽤 낙담했다.
감사합니다.
오른쪽, 즉 (내가 위에서 언급 번호와 함께 온 방법이다) 내가 무슨 짓을했는지.나는 그것의 무엇이든을 암호문을 해독 할 수 없다, 모두는 내적으로이고 나의 방법의 무엇이든을 직접 가르키 지 않는 것을 보인다. – ballofpopculture
여기에서 같은 문제가 발생합니다. – dan