This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Merging calls to `abort'


Richard Kenner <kenner@vlsi1.ultra.nyu.edu> wrote:

>     However, the idea that users could search for previous bug
>     reports is new to me.  That might be an additional reason for
> using fancy_abort.
>
> It's not just users, but first level tech-support.  There, it can help
> in suggesting a workaround to the user and knowing which file the
> abort is in may help assign the bug to the appropriate developer.

Absolutely true. As a GCC bugmaster, I can confirm that receiving bug reports
with clear indication of the file name and the function name is incredibly
useful. Not only it lets us find duplicates in seconds, or assign recent
regressions to the responsible in a shot, but it also provides an immediate
indication of which kind of bug it is. Otherwise, we would be forced to run GDB
on the testcases just to categorize a bug.

The abuse of abort() in GNU software is unfortunate. I agree with Mark when he
says that a naked abort should be used only after useful information has
already been printed to the user. In fact, we are in the middle of a conversion
of the whole GCC codebase from abort() to assert() (even if our abort() is a
fancy_abort() in disguise!).

Giovanni Bajo


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]