Does the new xcode crash due to running out of memory? - xcode4.5

I recently often get this:
Process: Xcode [30248]
Path: /Applications/Xcode.app/Contents/MacOS/Xcode
Identifier: com.apple.dt.Xcode
Version: 4.5 (1839)
Build Info: IDEApplication-1839000000000000~3
App Item ID: 497799835
App External ID: 10747437
Code Type: X86-64 (Native)
Parent Process: launchd [140]
User ID: 501
Date/Time: 2012-10-09 10:32:37.454 +0700
OS Version: Mac OS X 10.8.2 (12C60)
Report Version: 10
Interval Since Last Report: 136816 sec
Crashes Since Last Report: 2
Per-App Interval Since Last Report: 134365 sec
Per-App Crashes Since Last Report: 1
Anonymous UUID: 1CBC3344-3A0F-4006-F51E-8FF9902D7CC5
Crashed Thread: 0 Dispatch queue: com.apple.main-thread
Exception Type: EXC_CRASH (SIGABRT)
Exception Codes: 0x0000000000000000, 0x0000000000000000
Application Specific Information:
ProductBuildVersion: 4G182
UNCAUGHT EXCEPTION (NSMallocException): Out of memory. We suggest restarting the application. If you have an unsaved document, create a backup copy in Finder, then try to save.
UserInfo: (null)
Hints: None
Backtrace:
0 0x00007fff93d7308e __exceptionPreprocess (in CoreFoundation)
1 0x00007fff96bd13f0 objc_exception_throw (in libobjc.A.dylib)
2 0x00007fff8b3ff914 ___NSInitializePlatform_block_invoke_0 (in Foundation)
3 0x00007fff93ce7fe0 __CFStringChangeSizeMultiple (in CoreFoundation)
4 0x00007fff93d0d722 CFStringReplaceAll (in CoreFoundation)
5 0x00007fff93d0bd55 _CFBundleTryOnePreferredLprojNameInDirectory (in CoreFoundation)
6 0x00007fff93d0b3a0 _CFBundleAddPreferredLprojNamesInDirectory (in CoreFoundation)
7 0x00007fff93d0ba7e _CFBundleGetLanguageSearchList (in CoreFoundation)
8 0x00007fff93dbcf99 _CFBundleCreateQueryTableAtPath (in CoreFoundation)
9 0x00007fff93db9817 _CFBundleCopyQueryTable (in CoreFoundation)
10 0x00007fff93dbdeb9 _CFBundleCopyURLsOfKey (in CoreFoundation)
11 0x00007fff93dbb3ad _CFBundleCopyFindResources (in CoreFoundation)
12 0x00007fff93d1b757 CFBundleCopyResourceURL (in CoreFoundation)
13 0x00007fff907b4165 MTUOpenResourceFile (in SpeechSynthesis)
14 0x00007fff907b40a7 MTUReadResourceDataFile (in SpeechSynthesis)
15 0x00007fff907b3c1f ReadVoiceDescriptionFileFromBundle(__CFBundle*, VoiceDescription*) (in SpeechSynthesis)
16 0x00007fff907b3a41 RegisterVoiceBundle(VoiceListRec**, SpeechEngine*, __CFBundle*, int) (in SpeechSynthesis)
17 0x00007fff907b392f RegisterVoices(int, SpeechEngine*, VoiceListRec**) (in SpeechSynthesis)
18 0x00007fff907b355f RebuildVoiceList(SpeechEngine*, VoiceListRec**) (in SpeechSynthesis)
19 0x00007fff907afd4d RebuildVoiceListIfNecessary() (in SpeechSynthesis)
20 0x00007fff907b01e6 NewSpeechChannel (in SpeechSynthesis)
21 0x00007fff907b9e99 StartSpeakingNow (in SpeechSynthesis)
22 0x00007fff93d2fda4 __CFRUNLOOP_IS_CALLING_OUT_TO_A_TIMER_CALLBACK_FUNCTION__ (in CoreFoundation)
23 0x00007fff93d2f8bd __CFRunLoopDoTimer (in CoreFoundation)
24 0x00007fff93d15099 __CFRunLoopRun (in CoreFoundation)
25 0x00007fff93d146b2 CFRunLoopRunSpecific (in CoreFoundation)
26 0x00007fff924640a4 RunCurrentEventLoopInMode (in HIToolbox)
27 0x00007fff92463e42 ReceiveNextEventCommon (in HIToolbox)
28 0x00007fff92463cd3 BlockUntilNextEventMatchingListInMode (in HIToolbox)
29 0x00007fff94ea4613 _DPSNextEvent (in AppKit)
30 0x00007fff94ea3ed2 -[NSApplication nextEventMatchingMask:untilDate:inMode:dequeue:] (in AppKit)
31 0x00007fff94e9b283 -[NSApplication run] (in AppKit)
32 0x00007fff94e3fcb6 NSApplicationMain (in AppKit)
33 0x000000010080bd17 (in Xcode)
34 0x000000010080bca8 (in Xcode)
The amount of memory is abundant. 8GB and there are still plenty left. Not to mention virtual memory. I am not sure if I should ask this to superuser.
The xcode version is Version 4.5 (4G182)
Did I set things up incorrectly or is this just a bug in xcode 4.5?
Should this be asked at superuser.com instead (but most of the crowd there probably do not use xcode).
Quite often when I change tabs, xcode will slow down.

Related

iOS 12-only Crash on -[GAIAnalyticsPropertiesStore upsertPropertyRecord:]

Unable to reproduce but getting lots of crashes reported via crashlytics.
See crash log below. If more info is needed please let me know...
Crashing only on devices running iOS 12.0/12.1
Using GoogleAnalytics 3.17.0 (latest)
Crash occurs at:
8 ----- 0x10148534c -[GAIAnalyticsPropertiesStore upsertPropertyRecord:] + 4383150924
Help and suggestions are greatly appreciated. Thanks!
Crashed: GAIThread
0 libsystem_platform.dylib 0x1bf912f3c
_os_unfair_lock_unowned_abort + 36
1 libsystem_platform.dylib 0x1bf914524
_os_unfair_lock_unlock_slow + 144
2 libsqlite3.dylib 0x1c017e18c sqlite3_randomness +
4368
3 libsqlite3.dylib 0x1c015d878 sqlite3_value_text +
26356
4 libsqlite3.dylib 0x1c015d250 sqlite3_value_text +
24780
5 libsqlite3.dylib 0x1c0128434 sqlite3_finalize + 3732
6 libsqlite3.dylib 0x1c01557d0 sqlite3_step + 66844
7 libsqlite3.dylib 0x1c0145464 sqlite3_step + 432
8 ----- 0x10148534c
-[GAIAnalyticsPropertiesStore upsertPropertyRecord:] + 4383150924
9 ----- 0x101484ddc
-[GAIAnalyticsPropertiesStore nextHitNumberForTrackingId:clientId:] + 4383149532
10 ----- 0x10147eb00 -[GAIBatchingDispatcher
queueDispatch:] + 4383124224
11 ----- 0x10147e91c -[GAIBatchingDispatcher
queueModel:] + 4383123740
12 Foundation 0x1c07bb5a0 __NSThreadPerformPerform
+ 336
13 CoreFoundation 0x1bfc9a5b8
CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION + 24
14 CoreFoundation 0x1bfc9a538 __CFRunLoopDoSource0 +
88
15 CoreFoundation 0x1bfc99e1c __CFRunLoopDoSources0 +
176
16 CoreFoundation 0x1bfc94ce8 __CFRunLoopRun + 1040
17 CoreFoundation 0x1bfc945b8 CFRunLoopRunSpecific +
436
18 Foundation 0x1c06886a4 -[NSRunLoop(NSRunLoop)
runMode:beforeDate:] + 300
19 Foundation 0x1c06c4094 -[NSRunLoop(NSRunLoop)
run] + 88
20 ----- 0x10146bf14 +[GAI threadMain:] +
4383047444
21 Foundation 0x1c07bb3b0 NSThread__start +
1040
22 libsystem_pthread.dylib 0x1bf9252fc _pthread_body + 128
23 libsystem_pthread.dylib 0x1bf92525c _pthread_start + 48
24 libsystem_pthread.dylib 0x1bf928d08 thread_start + 4
--
Update:
I made a couple of changes that seemed to have helped. The app is still crashing but less frequently. Also I added log statements to help pinpoint where and when it is crashing.
The change I made that seemed to help was increasing the value for dispatchInterval (previous set to 20)...
[GAI sharedInstance].dispatchInterval = 60;
Also, the crash only seems to occur when the app is launched and/or becomes active while trying to track an event in the app delegate method...
- (void)applicationDidBecomeActive:(UIApplication *)application {
...
GA_EVENT(#"App Launch", #"", #"App Launched", 0);
// NOTE: GA_EVENT defines a custom method that creates the event (GAIDictionaryBuilder)
// and invokes the GAITracker's send method with the event per usual.
// This approach is used throughout the app and was working fine prior
// to iOS 12, but is now causing a crash here for some reason
...
}
Lastly, in the event that this is a bug with GA SDK, I created an issue in their bug tracker. From my research, the last time this crash was reported it seemed to have required an update to their SDK. So, perhaps that's the case here as well. We'll see if I hear anything back from the Google gods...
https://issuetracker.google.com/issues/117476933
We have found the solution to this problem after spending sleepless days and nights. The issue was occurring because of the Apsalar SDK in our case. If you are using Apsalar SDK in your project, I highly recommend you to move from Apsalar to Singular SDK. Singular SDK covers all the functionality provided by Apsalar. So you need not worry about missing any functionality or changing a hell lot of code.
You can download the Singular SDK from the following link: https://support.singular.net/hc/en-us/articles/115000497903-Integrating-the-Singular-SDK

Editmask Powerbuilder 12.6 Build 4121

I have a problem : I have an EditMask Control that contains 18 numeric values and when I am digiting the value 16th, this control changes the value of the number.
My current version of Powerbuilder is 12.6 and the build is 4121 released on November 2016.
I inserted numbers 1 , so it changed by 0 at the end
this is the editmask detail
Thank you for your soon answer

Running into DVTAssertions: ASSERTION FAILURE error with ios-sim

I'm trying get ionic up and running using my mac by following the simple instructions on the website (http://ionicframework.com/getting-started/)
Everything is working until i need to emulate
$ ionic emulate ios
I did a little deeper and I realized the same error lies in when I tried to run ios-sim
Here is what I see
$ ios-sim start
2015-02-27 14:01:57.361 ios-sim[1810:208272] [MT] DVTAssertions: ASSERTION FAILURE in /SourceCache/DVTiOSFrameworks/DVTiOSFrameworks-6274/DVTiPhoneSimulatorRemoteClient/DTiPhoneSimulatorSessionConfig.m:143
Details: (runtime) should not be nil.
Object: <DTiPhoneSimulatorSystemRoot>
Method: +rootWithSimRuntime:
Thread: <NSThread: 0x7ff44a5105f0>{number = 1, name = main}
Hints: None
Backtrace:
0 0x0000000110abe24a -[DVTAssertionHandler handleFailureInMethod:object:fileName:lineNumber:assertionSignature:messageFormat:arguments:] (in DVTFoundation)
1 0x0000000110abdc9f _DVTAssertionHandler (in DVTFoundation)
2 0x0000000110abdf8e _DVTAssertionFailureHandler (in DVTFoundation)
3 0x0000000111062614 +[DTiPhoneSimulatorSystemRoot rootWithSimRuntime:] (in DVTiPhoneSimulatorRemoteClient)
4 0x0000000111061897 -[DTiPhoneSimulatorSessionConfig simulatedSystemRoot] (in DVTiPhoneSimulatorRemoteClient)
5 0x000000010ebadab0 -[iPhoneSimulator launchApp:withFamily:uuid:environment:stdoutPath:stderrPath:timeout:args:] (in ios-sim)
6 0x000000010ebaecfd -[iPhoneSimulator runWithArgc:argv:] (in ios-sim)
7 0x000000010ebaefbb main (in ios-sim)
8 0x000000010ebac37c start (in ios-sim)
9 0x0000000000000002
Abort trap: 6
Please advice

QStringList of quazip::getFileNameList casts error by destruction

in Qt Creator (qt 4.8, winxp) I wrote
QuaZip* zipfile = new QuaZip;
zipfile->setZipName("myzipfile.zip");
zipfile->open(QuaZip::mdUnzip);
if(zipfile->isOpen()){
QStringList files = zipfile->getFileNameList();
} // here the error occurs
when files is destroyed, a messagebox says
Debug Assertion Failed!
Expression: _CrtIsValidHeapPointer(pUserData)
In the debugger I have the following function stack:
0 DbgBreakPoint ntdll 0x7c90120e
1 RtlpBreakPointHeap ntdll 0x7c96c201
2 RtlpValidateHeapEntry ntdll 0x7c96c63e
3 RtlValidateHeap ntdll 0x7c9603b0
4 HeapValidate kernel32 0x7c85f8d7
5 _CrtIsValidHeapPointer dbgheap.c 2103 0x102d1ac9
6 _free_dbg_nolock dbgheap.c 1317 0x102d0b3a
7 _free_dbg dbgheap.c 1258 0x102d09e0
8 free dbgfree.c 49 0x102d8990
9 qFree qmalloc.cpp 60 0x5e2f1d
10 QString::free qstring.cpp 1235 0x65dd22
11 QString::~QString qstring.h 880 0x5ac0d3
12 QString::`scalar deleting destructor' QuizSet 0x4120e0
13 QList<QString>::node_destruct qlist.h 433 0x412180
14 QList<QString>::free qlist.h 759 0x4115fb
15 QList<QString>::~QList<QString> qlist.h 733 0x410967
16 QStringList::~QStringList MyApp 0x414d9f
17 MyApp::myFunction myapp.cpp 561 0x420e1c
...
line 433 in qlist.h is where the debugger stops:
while (from != to) --to, reinterpret_cast<T*>(to)->~T();
the error occurs only if I call ::getFileNameList(), if I fill the list manual it works fine.
Other operations with quazip work, I can unzip and zip data, only the getFileNameList makes trouble.
EDIT: I found the cause: the quazip1.dll I used was the release version of it, only in debug-running this problem arised. So if I use the debug quazip.dll, it works fine. Annoying they're called the same, so I have to rename everytime I switch from debug to release. Anybody knows a workaround to this?
This means that you are mixing release mode Qt DLLs with Debug ones. You have to create 2 sets of Quazip DLLs one for Release mode and one for Debug mode. You cannot mix Qt Debug DLLs with Release DLLs.

ASP.NET Memory Leak - OracleCommand Object

I have a memory leak and I am having a really hard time trying to figure out where the problem is. The ASP.NET process is raising to 1GB every now and then. I have followed the instructions on this page (http://humblecoder.co.uk/tag/windbg) and the !gcroot command returns the following (last x lines). I have looked at all my OracleConnections and OracleCommands and they appear to be closed and disposed correctly:
6523dfd4 282 28200 System.Data.SqlClient.SqlParameter
0e90d850 548 28496 System.IO.MemoryStream
67b71a0c 1461 29220 System.Transactions.SafeIUnknown
7a5ee588 1924 30784 System.Collections.Specialized.ListDictionary+NodeKeyValueCollection
648c91f4 665 31920 System.Configuration.ConfigurationValues
7a5e5d04 1342 32208 System.Threading.Semaphore
652410f8 670 34840 System.Data.ProviderBase.DbConnectionPool+PoolWaitHandles
6613228c 1319 36932 System.Web.Security.FileSecurityDescriptorWrapper
66106948 2449 39184 System.Web.UI.AttributeCollection
0e8ff780 2021 40420 Microsoft.Win32.SafeHandles.SafeLsaPolicyHandle
01e34730 336 43008 Oracle.DataAccess.Client.OracleDataReader
648c9434 2218 44360 System.Configuration.ConfigurationValue
7a5ea0e4 1918 46032 System.Collections.Specialized.ListDictionary+NodeKeyValueCollection+NodeKeyValueEnumerator
7a5eaaa8 3088 49408 System.Collections.Specialized.NameObjectCollectionBase+NameObjectEntry
652435c4 1138 59176 System.Data.SqlClient.SqlBuffer
0e912c9c 2491 59784 System.Collections.ArrayList
0e9132c0 1236 69216 System.Collections.Hashtable
6614bf64 45 69660 System.Web.Caching.ExpiresEntry[]
0e8ff7d8 4042 80840 Microsoft.Win32.SafeHandles.SafeLsaMemoryHandle
66105ff4 5434 86944 System.Web.UI.StateBag
01e364c8 5686 90976 Oracle.DataAccess.Client.OpoSqlValTimeoutCtx
0e912e08 1007 91556 System.Int32[]
7a5ee300 3942 94608 System.Collections.Specialized.ListDictionary+NodeEnumerator
01e35ef8 7918 95016 Oracle.DataAccess.Client.OpoSqlRefCtx
01e353bc 6043 96688 Oracle.DataAccess.Client.MetaData
0e8f83e8 5017 100340 Microsoft.Win32.SafeHandles.SafeLocalAllocHandle
7a5ef738 6284 125680 System.Collections.Specialized.HybridDictionary
7a5ef7f4 5143 144004 System.Collections.Specialized.ListDictionary
661060d0 10908 174528 System.Web.UI.StateItem
0e91189c 533 184492 System.Char[]
6610d15c 2426 203784 System.Web.UI.WebControls.TableCell
01e362ec 7918 221704 Oracle.DataAccess.Client.OracleXmlQueryProperties
7a5ef8b4 11231 224620 System.Collections.Specialized.ListDictionary+DictionaryNode
65242390 1814 232192 System.Data.SqlClient._SqlMetaData
0e8f832c 12124 242480 Microsoft.Win32.SafeHandles.SafeTokenHandle
01e36444 7918 253376 Oracle.DataAccess.Client.OracleXmlSaveProperties
0e8f7ca8 13394 267880 Microsoft.Win32.SafeHandles.SafeWaitHandle
0e9133bc 1255 267912 System.Collections.Hashtable+bucket[]
0e8f7a98 12048 289152 System.Threading.ManualResetEvent
0e8e443c 7886 385508 System.Object[]
01e34b60 6456 387360 Oracle.DataAccess.Client.OpoConRefCtx
01e33860 6432 668928 Oracle.DataAccess.Client.OracleConnection
01e34f9c 6439 824192 Oracle.DataAccess.Client.OpoConCtx
01e34038 7918 1171864 Oracle.DataAccess.Client.OracleCommand
000dfbe0 70 5839608 Free
0e9136dc 2622 17492932 System.Byte[]
0e910c6c 56049 19472876 System.String
Total 283875 objects
If mem usage drops to 200 MB after a time, this shows your memory is beeing collected, but you still might have a memory missuse issue.
this dump doesn't show alot, but if it was taken when the process is 1GB as you said, you can still use it:
1) use !gcroot on several objects, to see how they are attached to the memory (i would check the DB usage, it seems you have a large amount of oracle connections (6432), and alot of other DB stuff floating around.)
like this:
!dumpheap -MT <mt = the left most number>
objects will show with memory addresses
!gcroot <address>
an object stack will show displaying how the object is attached to the memory tree.
a sample of this process
2) check performance counters (start->run->perfmon) add these counters:
- .Net Clr Memory-> #bytes all heaps
- Process->private bytes
calculate the difference between them - this is the memory consumed by unmanaged resources (like DB client objects)
check this in low memory and in high memory scenarios, and you will see if the memory consumption is mostly due to Managed memory (all heaps) or unmanaged.
3) if the memory is unmanaged, it's still likely to be held by managed objects, as the main application is managed, so making sure you free unmanaged resources after you are done with them is key. (close DBConnections, dispose DBCommands, close file handles, free COMObjects etc.)
Hope this helps,
Amit.

Resources