Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753981AbbFITBf (ORCPT ); Tue, 9 Jun 2015 15:01:35 -0400 Received: from mail-la0-f48.google.com ([209.85.215.48]:34498 "EHLO mail-la0-f48.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752088AbbFITB0 (ORCPT ); Tue, 9 Jun 2015 15:01:26 -0400 MIME-Version: 1.0 In-Reply-To: <1433876051-26604-4-git-send-email-dvlasenk@redhat.com> References: <1433876051-26604-1-git-send-email-dvlasenk@redhat.com> <1433876051-26604-4-git-send-email-dvlasenk@redhat.com> From: Andy Lutomirski Date: Tue, 9 Jun 2015 12:01:03 -0700 Message-ID: Subject: Re: [PATCH 4/5] x86/asm/entry/32: Replace RESTORE_RSI_RDI[_RDX] with open-coded 32-bit reads To: Denys Vlasenko Cc: Ingo Molnar , Linus Torvalds , Steven Rostedt , Borislav Petkov , "H. Peter Anvin" , Oleg Nesterov , Frederic Weisbecker , Alexei Starovoitov , Will Drewry , Kees Cook , X86 ML , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1016 Lines: 23 On Tue, Jun 9, 2015 at 11:54 AM, Denys Vlasenko wrote: > This doesn't change much, but this uses shorter 32-bit insns: > > -48 8b 74 24 68 mov 0x68(%rsp),%rsi > -48 8b 7c 24 70 mov 0x70(%rsp),%rdi > -48 8b 54 24 60 mov 0x60(%rsp),%rdx > +8b 74 24 68 mov 0x68(%rsp),%esi > +8b 7c 24 70 mov 0x70(%rsp),%edi > +8b 54 24 60 mov 0x60(%rsp),%edx > > Since these are the only uses of RESTORE_RSI_RDI[_RDX], drop these macros. > It probably doesn't matter for these fast paths, but, for the full slow path return, we really do need to restore the full pt_regs. After all, the syscall we're returning from might be sigreturn. --Andy -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/