Memory fragmentation in a 32-bit application
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com Dkim-signature: v=1; a=rsa-sha1; c=relaxed; d=rynosoft.com; h=message-id :from:to:content-type:content-transfer-encoding:mime-version :subject:date; s=rynosoft.com; bh=HJRZv7AJ4wUYrEMBCzZpVFGkbRw=; b=DJSXKitv/pA6ZNFmjIK8r14qlcDPwOtrRGNaU6k0Qxjkvx8xSXybpNuPwUlxS lcBblLdG/BQKh/03uo8qzj2m5gy9duFrywFGAAQwpjF8+kF7eoC1QPbdICZYCP/7 txPOQ5TnSlHSfmuQdiFlzQKVNnsv6zrZR0S6n6ji+ROuQ4= Domainkey-signature: a=rsa-sha1; c=nofws; d=rynosoft.com; h=message-id:from :to:content-type:content-transfer-encoding:mime-version:subject: date; q=dns; s=rynosoft.com; b=OyBtkw8eKano0PCwrb7DOmwiCvyXyY2pu 1S3heZP5W0Li3Y7f7O4/JRV7nV9s2+9jiomvV85yYuzuRPIXL3yHJzRXSNWKePXR KqLMekBmljUf24rSi1Lm6Gv93H91C4mLPo7122HHIgBs6wdaSx2pxK7LhY4ZhKvd /rdA6uI4IM= Hello: -Mick ------ Mitchell J Laurren-Ring lists@rynosoft.com _______________________________________________ Do not post admin requests to the list. They will be ignored. Darwin-dev mailing list (Darwin-dev@lists.apple.com) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/darwin-dev/site_archiver%40lists.appl... I have a 32-bit application that can convert PDF files into Postscript files. We have a customer that processes large batches (100+) of large PDF files (10Mb+). That customer will often experience a crash when our application attempts to allocate memory using malloc which fails and returns nil. The crash occurs because we assert the nil but I'm trying to understand why the failure is occurring. First, I have debugged the problem at the customer site and noted that when the crash occurred our application was not out of VM (we still have around 3Gb available) and there was still tons (over 4Gb of the 8Gb installed) of physical memory available. The OS reports "malloc: *** mmap(size=nnnnnnnn) failed (error code=12)" on the console and presumably returns a nil for the malloc. I cannot confirm this because the code that is being executed at the time is in a library for which I do not have source. The failed allocations can range from 10Mb to 50Mb. I have concluded that the failure is probably happening as result of fragmentation in our VM space but I'm not sure how to confirm that. Are there any tools that can be used to visualize an application's VM space? I've used Instruments quite extensively but it has problems with apps that use a lot of resources and I don't think it has the ability that I seek. This email sent to site_archiver@lists.apple.com
participants (1)
-
Mitchell J Laurren-Ring