[CRIU] [PATCH 1/4] pie/x86_64: syscall clobbers rcx and r11

Cyrill Gorcunov gorcunov at gmail.com
Tue Jun 16 12:29:00 PDT 2015


On Tue, Jun 16, 2015 at 10:10:53PM +0300, Cyrill Gorcunov wrote:
> On Tue, Jun 16, 2015 at 07:34:55AM -0600, Tycho Andersen wrote:
> > On Tue, Jun 16, 2015 at 04:31:50PM +0300, Cyrill Gorcunov wrote:
> > > On Tue, Jun 16, 2015 at 07:20:56AM -0600, Tycho Andersen wrote:
> > > > 
> > > > Ok, I just added rcx because the above link said it could be clobbered
> > > > too, but I can send a patch to remove it if you want.
> > > 
> > > no need to, i'm fine with as is.
> > 
> > Ok. I think the reason we've never seen a seg fault here is that the
> > code path hasn't changed in a while (and neither has gcc's register
> > allocator apparently, yay reaload.c). When I changed it for this
> > patchset, gcc decided to use r11 for something (viz. the dissasembly
> > in the commit message), which is what caused the fault.
> 
> I still wonder why it's happened ;) Look, the kernel saves all the data
> it going to modify inside syscall

Not needed. The patch is correct, thanks for fixin!


More information about the CRIU mailing list