This is the mail archive of the gdb@sourceware.cygnus.com mailing list for the GDB project.


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

Re: Restructuring i386_extract_return_value



>    In my experience, about 5 minutes after you release a product based on
>    the assumption that this switch is not used enough to care about,
>    somebody posts a bug report for a program which does use that
>    switch...
> 
> I'm pretty confident that this isn't going to happen.  the
> `-mno-fp-ret-in-i387' switch changes the ABI.  You'd have to compile
> all your code (including libraries) with that switch in order to make
> it work, and I really fail to see the benefits of doing that.  Anybody
> who's clueless enough about that switch to fail to understand that it
> might lead to undebuggable code will probably also fail to notice the
> switch in GDB.

The problem is that GCC doesn't warn about these consequences.  Since
recompiling everything, including libraries, is not a big deal these
days, given the motivation, I can easily imagine someone who builds
some weirdo project around this switch.  The GCC docs doesn't say
anything about the impact of this switch on debugging (in fact, it
doesn't even say that the libraries must be recompiled), so such users
will have no way of knowing what they are in for, until it's too late.

There are many other GCC switches that change the ABI, but most of
them don't break debugging.

I think we should at least document the switches which break
debugging, preferably in the GCC manual as well.  But if supporting
this switch is not too hard, I suggest we at least have a todo item to
include it at some point.

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