This is the mail archive of the
mailing list for the glibc project.
Re: [PATCH] mips/o32: fix internal_syscall5/6/7
- From: Aurelien Jarno <aurelien at aurel32 dot net>
- To: Andreas Schwab <schwab at suse dot de>
- Cc: libc-alpha at sourceware dot org
- Date: Tue, 15 Aug 2017 18:14:57 +0200
- Subject: Re: [PATCH] mips/o32: fix internal_syscall5/6/7
- Authentication-results: sourceware.org; auth=none
- References: <email@example.com> <firstname.lastname@example.org>
On 2017-08-15 14:00, Andreas Schwab wrote:
> On Aug 15 2017, Aurelien Jarno <email@example.com> wrote:
> > The internal_syscall5/6/7 functions use the stack pointer to store
> > the 5th and following arguments on the stack. In some cases GCC optimize
> > out the stack pointer, and thus storing the data to the stack causes a
> > segmentation fault.
> FORCE_FRAME_POINTER does not work any more?
From what I understand of the generated code, it seems to work at the
function level, but not at the asm code level. The pthread_rwlock_rdlock
adds a loop around the syscall, and it seems that's the code path causing
the issue. Adding $sp as clobbered changes the code to reload the $sp
from the saved value at each loop.
Aurelien Jarno GPG: 4096R/1DDD8C9B