This is the mail archive of the gdb-patches@sourceware.org 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]
Other format: [Raw text]

Re: [i386/stabs] Arguments of main on gcc >= 4.1


Joel Brobecker wrote:

I wonder how this all works if GCC < 4.1 is being used.

Gcc 3.4.4-cygwin works ok and doesn't need this patch.

My concern at this point is whether GDB still works in this case after you applied your patch. Unless GCC 3.4.4 doesn't emit the stack-alignment code, it should no longer work... The questions at this point are: Can we support both conventions? Do we even want to?


gcc 3.4.4 doesn't emit the stack-alignment code. Unless the comments in i386-tdep.c are wrong, any gcc < 4.1 doesn't emit the stack-alignment code, which makes them immune to the patch. I did regtest the patch on Cygwin.

The fact that this has nobody before you reported that this is
broken since 4.1 shows that this is probably not an extremely
important issue.

I've seen this reported at the mingw-users@ list with the new gcc4.2 binaries. As you know, mingw support wasn't in the FSF tree, so problems seen on mingw weren't being reported here.

But sure, this isn't certainly my priority ;-)

I see some movement at gcc@/gcc-patches@ about changing the stack
alignment scheme on i386.  That may be perfect.  If we get the debug
output fixed in the same release the prologue code changes, all will
be fine.

OK, so I will consider that this thread is currently on hold, pending discussions in GCC.


Even if gcc debug info isn't fixed, there will be several gcc releases with the problem and (pending confirmation), no release with stack alignment without the problem.

I'll try to break the patch further -- the setup for the
workaround is mostly bugfixing, and I'll come back to the
workaround later on if I'm still using a stabs outputting
compiler by then :-)

--
Pedro Alves


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