Re: where does initialization time go?
site_archiver@lists.apple.com Delivered-To: darwin-dev@lists.apple.com [... very complex multi-dtrace script setup ...] I don't understand why you'd have to go through all this trouble. mozilla$target:::main-entry { exit(0); } -------------------------------- provider mozilla { probe main__entry(void) : (void); }; proc:::exec-success / execname == "firefox-bin" && mpid == 0 / { mstart = timestamp; mpid = pid; } mozilla*:::main-entry / pid == mpid / { mend = timestamp; printf("Total: %u ms\n", (mend - mstart)/1000000); exit(0); } -------------------------------- sudo dtrace -s ... & sleep 5 open .../Minefield.app Eric Thanks, Joel --- fastest mac firefox! http://wagerlabs.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... On Aug 28, 2009, at 3:05 PM, Joel Reymont wrote: On Aug 28, 2009, at 7:22 PM, Eric Gouriou wrote: I'd recommend reworking your script to watch the exec-success of firefox-bin and use a static probe (no need for $target then) to mark the end time. Then you can use a more normal launch method, for example open .../Minefiled.app . ./cold.sh firefox-bin startup.d stop-main.d dtrace -Zqw -x dynvarsize=64m -x evaltime=exec -p 35209 -s sigcont.d -s startup.d -s stop-main.d kill -CONT 35209 Total: 2000.401494ms Note that stop-main.d does not work without $target, even though main-entry is a USDT probe. mozilla*:::main-entry ? I am not very familiar with creating USDT probes. This might help if you haven't seen it: <http://blogs.sun.com/dap/entry/writing_a_dtrace_usdt_provider
This could just be an issue of making sure that dtrace has learned about your provider by the time it parses the probe definition. This email sent to site_archiver@lists.apple.com
participants (1)
-
Eric Gouriou