site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com On Dec 14, 2007, at 2:50 AM, Stephane Sudre wrote: OK, I think I've found what happens. Here is what I'm seeing: => The application eats 12 MB of RAM. I kill the application and launch it again => It eats 3-4 MB of RAM I kill it and launch it again and again -> It eats 3-4 MB of RAM => It eats 12 MB of RAM I kill it and launch it again => It eats 3-4 MB of RAM. I hope the pattern is obvious now. On 27 nov. 07, at 19:12, Dave Zarzycki wrote: I'd start with the following tools: leaks heap vmmap Good luck, davez On Nov 27, 2007, at 8:14 AM, Stéphane wrote: Mac OS X 10.4.11: According to Activity Monitor: - The process launched by launchd takes 4 MB of Real Memory - The process launched by launchd takes 1.3 MB of Real Memory _______________________________________________ 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/zarzycki%40apple.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... launchd was rewritten a few times during the development of Leopard. Does this reproduce on Leopard? I don't know why but the first time you launch an executable on Mac OS X (10.4.11), it eats more memory than on further launches. I've built a Cocoa application (but I can see that with a Foundation tool too) I copy this application (this copy of the application has never been launched) to another location. I open this application through 'open' for instance (it could be done with a LaunchDaemon script for a Foundation tool). I delete the application and replace it with the never launched copy. I launch it I would be interesting to know why the first launch of an application takes more RAM. I though about prebinding but this doesn't sound reasonable. You'll need to run our various memory introspection tools on your program to understand what is going on. I have a process that is launched by launchd. It's set as RunAtLoad = true I have almost exactly the same version of this process launched by a StartupItem (the differences are in strings where a figure is replaced by another). If I kill the process launched by launchd, it's automatically restarted and it takes 1.3 MB of Real Memory. Of course since even startup items are launched via launchd - but later - it makes me wonder why a delayed launch claims less memory than an early one. This email sent to zarzycki@apple.com This email sent to site_archiver@lists.apple.com
participants (1)
-
Dave Zarzycki