This is the mail archive of the
libc-alpha@sources.redhat.com
mailing list for the glibc project.
Re: 2 problems with sprof
On Sun, Sep 23, 2001 at 09:39:47AM -0700, Ulrich Drepper wrote:
> "H . J . Lu" <hjl@lucon.org> writes:
>
> > Did you mean the number of text segments in the program header is
> > different between DSO and executable? I don't think it is the case.
>
> No, the total number of text segments you have to profile.
>
> > I don't think they are the same problem.
>
> It's only not the same with regard to the data structures created and
> the dynamic nature of loading and unloading. The rest is the same.
Did you mean profiling executable plus a DSO doesn't work or just
profiling executable doesn't work? I agree profiling executable plus
a DSO is almost the same as profiling 2 DSOs. But I don't think it
is worth fixing profiling executable alone if we still can't profile
DSO at the same time. As I said, when I make the change, I will take
profiling executable into account.
>
> > May I suggest we do
> >
> > LD_PROFILE=dso1:dso2... # profile a list of DSOs
> > LD_PROFILE_EXEC= # profile executable
> > LD_PROFILE_ALL= # profile all, including executable
>
> I don't see why, and how. ld.so cannot profile the executable with
> the same mechanisms. And it's the wrong place to start.
Do we need a way to tell ld.so to profile executable? If yes, how?
Also does sprof support executable?
>
> I think what you want is profiling with dynamic linking just as I
> mentioned. Then leave ld.so out.
>
> > Can we change HZ in kernel to get high-resolution timer?
>
> No, that's no solution. What you need is POSIX timer support in the
> kernel. Anoter of these real-world things the kernel people ignore
> since they don't need it themselves.
Are there any patches for kernel POSIX timer?
H.J.