www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/06/28/21:15:11

From: Sinan_Unur AT mail DOT com (A. Sinan Unur)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Peculiar behavior of program.
Date: 28 Jun 2001 18:04:55 -0700
Organization: http://groups.google.com/
Lines: 57
Message-ID: <426926da.0106281704.4b1e7c53@posting.google.com>
References: <Pine DOT SUN DOT 3 DOT 91 DOT 1010626161205 DOT 17201C-100000 AT is> <3b3b4662 DOT 211401101 AT news DOT primus DOT ca>
NNTP-Posting-Host: 32.102.40.165
X-Trace: posting.google.com 993776696 14157 127.0.0.1 (29 Jun 2001 01:04:56 GMT)
X-Complaints-To: groups-support AT google DOT com
NNTP-Posting-Date: 29 Jun 2001 01:04:56 GMT
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

invalid AT erehwon DOT invalid (Graaagh the Mighty) wrote in message news:<3b3b4662 DOT 211401101 AT news DOT primus DOT ca>...
> On Tue, 26 Jun 2001 16:12:23 +0300 (IDT), Eli Zaretskii
> <eliz AT is DOT elta DOT co DOT il> sat on a tribble, which squeaked:
> 
> >> That suggests to make such a scheme be used when code is compiled with
> >> -g and not -fomit-frame-pointer.
> >
> >The problem is, -fomit-frame-pointer is a compiler switch, while the
> >setup of the runtime environment is done in the library.  How will the
> >library startup code know that -fomit-frame-pointer was used or not?
> 
> That's easy. What decides what file to use to link in the standard
> library? I don't see anyone having to link with -libc. So the tools
> are doing it automagically.
> 
> Now imagine that the startup code is isolated into a separate module,
> say -lcrt, instead of included in libc. (Maybe this is already the
> case.) There are, in fact, *two* versions of libcrt.a, one for a
> certain debugging scenario, the other for general usage. The decision
> as to which one to link is made based on a flag passed from the
> compiling stage, possibly hidden inside one or more of the .o files.
> 
> Doesn't look so impossible now, does it?

<snip>

> You guys are supposed to be pretty wizardly hackers. Here I have at
> least one viable idea, while you stubbornly claim it's impossible. 

<snip>

The whole point is if you really think something is needed, you do it,
and contribute it to the general effort.

The really viable idea is to sit down and actually debug your program.
Try to come up with a minimal version that still exhibits the problem,
then you will find the cause.

Which features get implemented, if they are feasible at all, depend on
both the cost and benefit from implementing them. The possibility that
the benefit from a feature may be positive does not necessarily imply
the feature should be implmented. The benefit must be greater than the
cost of implementing it. (The cost being the time and energy of the
people whom you are asking to implement).

Clearly, a majority has decided that their time is better served
debugging their programs so as not to trash everything in sight. Now,
if, to you, the benefit from implementing a feature that would allow
cwsdpmi to divine the contents of memory locations that may have been
overwritten is greater than the cost of implementing that feature,
then you know where to get the sources and fix it.

Sinan

--
A. Sinan Unur
http://www.unur.com/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019