public inbox for gcc@gcc.gnu.org
 help / color / mirror / Atom feed
From: Joern Rennecke <amylaar@cygnus.co.uk>
To: "Kaveh R. Ghazi" <ghazi@caip.rutgers.edu>
Cc: gdr@codesourcery.com, gcc@gcc.gnu.org
Subject: Re: Silently checking whether diagnostics would occur
Date: Wed, 13 Sep 2000 16:37:00 -0000	[thread overview]
Message-ID: <200009132338.AAA17109@phal.cygnus.co.uk> (raw)
In-Reply-To: <200009131550.LAA13911@caip.rutgers.edu>

> So rather than do a complete restructuring of the format checking
> function, I though it would be much easier and cleaner to be able to
> call the checks conceptually like this:
> 
>  > check_diagnostics_silently = 1;  /* new global vars */
>  > diagnostic_occurred = 0;

Simpler to implement the change, but cleaner?

I can see it now.  Somewhere down the line, someone uses this
format checking in another utility function.  That function gets
called by another utility function under certain circumstances.
That function is then used by some piece of format-checking code.

After a few month of debugging, someone figures out why certain programs
just won't show any format warnings beyond some point even if there are
more problems left, and invents a stack for these global variables in
a static array.

The array overflows for another set of programs.  It is replaced with
a linked list of malloced structures.

Some time later, other programs are seen to cause the compiler to gobble
up all available memory the memory while parsing, making the host grind
to a halt, because the mallocing of structures causes a memory leak
when doing error recovery.
So we sprinkle a few strategically garbage collector calls into the
parser.

However, now some other data structures that should be live throughout the
parsing stage will be freed prematurely...

  parent reply	other threads:[~2000-09-13 16:37 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-09-13  8:50 Kaveh R. Ghazi
2000-09-13 13:51 ` Michael Meissner
2000-09-13 16:37 ` Joern Rennecke [this message]
2000-09-13 14:33 Kaveh R. Ghazi
2000-09-13 20:37 ` Michael Meissner
2000-09-13 17:38 Mike Stump
2000-09-14  7:43 Kaveh R. Ghazi
2000-09-14  8:31 Kaveh R. Ghazi
2000-09-14  8:42 ` Michael Meissner
2000-09-14 10:47 ` Joseph S. Myers
2000-09-14 12:37 ` Joern Rennecke
2000-09-15 11:12 Kaveh R. Ghazi
2000-09-15 11:25 Kaveh R. Ghazi

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200009132338.AAA17109@phal.cygnus.co.uk \
    --to=amylaar@cygnus.co.uk \
    --cc=gcc@gcc.gnu.org \
    --cc=gdr@codesourcery.com \
    --cc=ghazi@caip.rutgers.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).