Re: Problem with (Saturn) Profiler
Re: Problem with (Saturn) Profiler
- Subject: Re: Problem with (Saturn) Profiler
- From: Rick Altherr <email@hidden>
- Date: Mon, 26 Jan 2009 08:58:43 -0800
On Jan 25, 2009, at 8:56 AM, Dieter Oberkofler wrote:
I have been trying to profile a i386 application and ended up in
using Saturn as "the" only traditional (each function is actually
reported) profiler according to the documentation.
After quite a few hours of recompiling, linking and guessing (it
seems as if when running an application bundle in Saturn, the
LSEnvironment is not evaluated) I finally have a fully instrumented
application that can be executed in Saturn. This is what I did and I
after my run, I wanted to load the generated Saturn data file and
end up with the following error message: "The document "..." could
not be opened. The file is to large". Checking the file shows that
the fine is less then 2GB. A few questions that might help:
1) Is Saturn the proper tool to do some simple function profiling?
That all depends on what type of "simple function profiling" you want
to do. Saturn is an exact function tracer meaning it has high
overheard and knows the precise duration of every function call on
every thread. It requires recompilation of your program and will
cause your program to run at less than half its non-instrumented speed.
If you don't need to know precise information, you want to use Shark's
Time Profile. It provides a statistical sampling of your programs
execution. It can't tell you the amount of execution time for every
function in your program or how often it is called, but it can tell
you what portions of your program are taking the most execution time.
It has very low overhead (less than 1% typically) and requires no
modifications to your program.
2) Is it possible (and intentional) that the environment set in in
the LSEnvironment of the bundle is not observed?
Saturn does not use LaunchServices to launch the binary. At the
moment, there is no way to force it to evaluate the LSEnvironment
setting.
3) Can it really be that Saturn is unable to process a 2GB File?
Yes, it runs out of VM space when it tries. Remember that that is
only 2GB of raw callstacks (addresses). By the time you load the
symbol information and aggregate the data in meaningful ways for
presentation, the remaining 2GB of VM space is gone.
4) If this is a known (hard to believe) restriction what ere the
workarounds?
Saturn includes an option to limit the output file size to a specific
value. It can also be set to limit based on time and set a delay from
the start of the program's execution. Between those options, you can
generally restrict the tracing to the action you are interested in
while keeping the file size small enough that we can analyze it.
Thank you,
Dieter
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
@apple.com
This email sent to email@hidden
--
Rick Altherr
Architecture and Performance Group
email@hidden
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden