[Zlib-devel] [PATCH Take 2] 1.2.3 makefile.msc usability & rc fix (too late)
William A. Rowe, Jr.
wrowe at rowe-clan.net
Mon May 15 23:13:17 EDT 2006
Cosmin Truta wrote:
> Sorry, William, for not being able to reply earier.
NP
>>>and why are you slowing the DLL down in order to enable stack
>>>backtrace?
>>
>>Because I personally believe in sound stackframes, strongly object to
>>bastardizing the architecture to get at the last ounce of performance,
>>and because, programs crash :)
>
> I thought that Visual C++ can backtrace through optimized stack frames.
> (AFAIK gcc+gdb can!)
To clarify; *with* a .pdb the dbg tools -can- plough through optimized
stack frames. Looking at the user.dmp or Dr Watson output on a machine
without the necessary .pdb - and it's not possible to backtrace. Simply
put, without a stackframe and without a .pdb, there's no context to unwind
the stack.
>>With zlib/openssl/httpd, in one case, I uncover nested bugs in one lib
>>that are apropos of nothing in those sources, it's garbage in-garbage
>>out, and need to get back to the source which sent up the garbage.
>>Not in debug/development time, but in the real world.
>
> I didn't know that, sorry.
> It seems to me that you are using zlib1.dll for real, and you know well
> enough what's good and what's not. Is httpd compiled with stack frames,
> too?
Yes, for Apache 2.2 we build the dll as zlib1.dll using that script, with
modifications, see
http://www.apache.org/dist/httpd/binaries/win32/patches_applied/zlib-1.2.3-vc32-2005-rcver.patch
For the older Apache 2.0 we included specific sources, which wasn't working
out as well, but compensated for issues/variations of the build schema in
zlib 1.1.
>>I've removed -Oy- based on Cosmin's strong negative reaction
>
> Oh no! I only asked "why generate pdb's" and "why not optimize stack
> frames"! Check my quotes above ;-)
Well, this is two fold, as I say. One, with stack frames you don't need the
pdb installed to read the Dr Watson log. And sans stack frames, al la -Oy
you must have the corresponding pdb or Dr Watson reports nonsense. So they
are somewhat indepedent issues.
httpd binaries choose to obtain both debugging aids at the cost, in the -Oy
case, of a small performance hit. The performance hit is irrelevant compared
to the cost of supporting a user who's hit a GP fault -somewhere-.
Bill
More information about the Zlib-devel
mailing list