[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Just to be Sure
On Mon, 20 Jul 1998, guy keren wrote:
> > required only if you're a C programmer and use gprof et al.
>
> here i'm not completely sure (just cause i didn't try it), but as far as i
> know, there's no need for profiling information inside libc in order to
> profile one's program (please correct me if i'm wrong - i don't tend to
> use profiles. i never did use any profiler, shame on me).
Shame, shame. You're so proud of it, I think you're planning to join the
firm in Redmond soon, eh ? The guys who make programs that make any
computer, no matter how fast, look slow ? The next time when you write a C
program and compile using gcc and think it's great, compile with -pg and
after running type 'gprof <progname> | less'. Find out how good you are
;)
> > In fact, some packages under Linux come with the -g option used in the
> > makefiles for reasons that elude my (low) IQ, and these will fail to build
> > if you don't install the 3 extra libs (profile, devel and debug).
>
> NOT AT ALL. forgive me for shouting, but one does NOT need to have all the
> libraries with debug info, neither all the object files of a program with
> debug info. one only needs that in the part of the code they mean to
> actually debug... thus, no program will fail to compile, debug info or
> not.
One needs at least the #include debug header stubs to be present to be
able to compile some development and unfinished packages. The reason is,
the developers used gdb and left the flags in the Makefiles. If you don't
have the debug libs then these packages will not compile. I haven't
compiled libc for debugging but I know that there are small details that
can come from behind and bite you if you don't add all the libs, from
experience. The small details usually bite you when the machine is down
due to a human oops, and has no CD/network/{whatever you need most now}
access.
> > Since
> > you don't seem to know what the hell I'm talking about, install them too.
>
> or actually - don't. you don't need them at all, you will probably never
> miss them, unless you have intentions of developing or modifying the C
> library itself. and when you'll get to a stage you will want that - you'll
> always be able to install them. i'm sure they'll change many times before
> you get to this stage in your "programming life".
>
> peter - i do hope you wrote all this a ta late hour nigh, after not
> sleeping for a few days?
That is always the case with me, but I meant what I wrote. If he doesn't
start looking into these things now, when will he ? When he's 40 and
worried about his kid's college ?
> hope this helps avoid the evil corruption peter was trying to lay upon
> us ;),
Yeah, right. I tried to introduce a Linux user to the possibilities raised
by free access to the whole source and (beware !) the possibility to
profile and debug it (wow ! risky !) but I got caught by the guardian
angel at the door (list).
Shall I mention gets() as an interesting starting point for libc hacking
or is that going to earn me a flame too ?
Peter