Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1542878

[patch 0/3] x86/process: Optimize __switch_to_extra()

From Thomas Gleixner <tglx@linutronix.de>
Newsgroups linux.kernel
Subject [patch 0/3] x86/process: Optimize __switch_to_extra()
Date 2016-12-15 17:50 +0100
Message-ID <sOHoe-87a-13@gated-at.bofh.it> (permalink)
Organization linux.* mail to news gateway

Show all headers | View raw


GCC generates lousy code in __switch_to_extra(). Aside of that some of the
operations there are implemented suboptimal.

This series, inspired by a patch from Kyle, helps the compiler to be less
stupid by explicitely giving the hints to optimize and replaces the open
coded bit toggle mechanisms with proper helper functions.

The resulting change in text size:

	 64bit	    32bit
Before:	  3726	     9388
After:	  3646	     9324
Delta:	    80	      152	    

The number of conditional jumps is also reduced:

	 64bit	    32bit
Before:	     8	       13
After:	     5	       10

Thanks,

	tglx

---
 include/asm/processor.h |   12 ++++++++
 include/asm/tlbflush.h  |   10 ++++++
 kernel/process.c        |   70 +++++++++++++++++++-----------------------------
 3 files changed, 51 insertions(+), 41 deletions(-)

Back to linux.kernel | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

[patch 0/3] x86/process: Optimize __switch_to_extra() Thomas Gleixner <tglx@linutronix.de> - 2016-12-15 17:50 +0100
  [patch 2/3] x86/process: Optimize TIF_BLOCKSTEP switch Thomas Gleixner <tglx@linutronix.de> - 2016-12-15 17:50 +0100
    Re: [patch 2/3] x86/process: Optimize TIF_BLOCKSTEP switch Andy Lutomirski <luto@amacapital.net> - 2016-12-15 18:30 +0100
      Re: [patch 2/3] x86/process: Optimize TIF_BLOCKSTEP switch Thomas Gleixner <tglx@linutronix.de> - 2016-12-16 10:00 +0100
        Re: [patch 2/3] x86/process: Optimize TIF_BLOCKSTEP switch Andy Lutomirski <luto@amacapital.net> - 2016-12-16 20:30 +0100
  [patch 1/3] x86/process: Optimize TIF checks in switch_to_extra() Thomas Gleixner <tglx@linutronix.de> - 2016-12-15 17:50 +0100
    Re: [patch 1/3] x86/process: Optimize TIF checks in  switch_to_extra() Thomas Gleixner <tglx@linutronix.de> - 2016-12-15 18:30 +0100
      Re: [patch 1/3] x86/process: Optimize TIF checks in switch_to_extra() Peter Zijlstra <peterz@infradead.org> - 2016-12-15 18:40 +0100
    Re: [patch 1/3] x86/process: Optimize TIF checks in switch_to_extra() Andy Lutomirski <luto@amacapital.net> - 2016-12-15 18:30 +0100
    Re: [patch 1/3] x86/process: Optimize TIF checks in switch_to_extra() Peter Zijlstra <peterz@infradead.org> - 2016-12-15 18:30 +0100

csiph-web