[PATCH] libsanitizer: Fix GetPcSpBp determination of SP on 32-bit Solaris/x86

Rainer Orth ro@CeBiTec.Uni-Bielefeld.DE
Thu Jul 16 08:44:21 GMT 2020


Hi Jakub,

>> I may still be mistaken, but all this suggests that Linux might be
>> playing games with ESP and UESP, while Solaris and NetBSD (see below)
>> keep them separate, but in the end UESP is the register to use.
>
> I think what matters more is
> kernel/signal.c and ia32/ia32_signal.c doing:
>                 put_user_ex(regs->sp, &sc->sp);
> ...
>                 put_user_ex(regs->sp, &sc->sp_at_signal);
> i.e. both ESP and UESP ought to have the same value in the end on Linux.
>
> Your patch is ok for trunk and for 10.3 after a few weeks (10.2 is frozen
> ATM anyway) so that if there are some problems (like say some headers not
> defining REG_UESP or something similar), we'll find that out on trunk first.

fair enough.  What about the gcc-9 branch by then?  I expect there will
be at least one more release from that one, too?

Thanks.
        Rainer

-- 
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University


More information about the Gcc-patches mailing list