Skip to content

Move ARCH specific fpu_counter out of task_struct

Vineet Gupta linux-arch linux-sh lkml 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest3 patches 4 repliesIn review
  2. v1 RFC3 patches 10 repliesSuperseded

Changes in v2 from the cover letter

- Rabased to 3.12-rc4
- Added ACK from Ingo on patch 2/3

Patches in v2 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/3sh: Move fpu_counter into ARCH specific thread_structarch/sh/include/asm/fpu.h arch/sh/include/asm/processor_32.h arch/sh/include/asm/processor_64.h +2 more+25 -50 replies
2/3x86: Move fpu_counter into ARCH specific thread_structarch/x86/include/asm/fpu-internal.h arch/x86/include/asm/processor.h arch/x86/kernel/i387.c +3 more+19 -100 replies
3/3sched: Remove ARCH specific fpu_counter from task_structinclude/linux/sched.h+0 -91 reply

Reviews trailers per patch

2 of 3 patches have a Reviewed-by or Acked-by.

PatchIngo Molnar
1/3
2/3A-b
3/3A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH v2 0/3] Move ARCH specific fpu_counter out of task_struct

Hi,

When debugging a ARC SMP 3.11 build failure due to a ST insn dealing with task_struct.thread going out of range, I spotted @fpu_counter in task_struct which only SH/x86 happen to use, and can be easily moved out into corresponding ARCH specific thread_struct. This saves 4 bytes per task_struct instantiated, for all the other 18 arches.

While the change is relatively strightforward, I've failed to connect with SH arch folks / Paul Mundt, latter's SH email keeps bouncing back. Hence I'm taking the liberty to use his alternate email (as listed on his github page) and I appologize in advance if this causes any inconvenience.

Changes in v2:
- Rabased to 3.12-rc4
- Added ACK from Ingo on patch 2/3

Version 1 can be found here:
https://lkml.org/lkml/2013/9/17/49

Thx,
-Vineet

Vineet Gupta (3):
sh: Move fpu_counter into ARCH specific thread_struct
x86: Move fpu_counter into ARCH specific thread_struct
sched: Remove ARCH specific fpu_counter from task_struct

 arch/sh/include/asm/fpu.h           |  2 +-
 arch/sh/include/asm/processor_32.h  | 10 ++++++++++
 arch/sh/include/asm/processor_64.h  | 10 ++++++++++
 arch/sh/kernel/cpu/fpu.c            |  2 +-
 arch/sh/kernel/process_32.c         |  6 +++---
 arch/x86/include/asm/fpu-internal.h | 10 +++++-----
 arch/x86/include/asm/processor.h    |  9 +++++++++
 arch/x86/kernel/i387.c              |  2 +-
 arch/x86/kernel/process_32.c        |  4 ++--
 arch/x86/kernel/process_64.c        |  2 +-
 arch/x86/kernel/traps.c             |  2 +-
 include/linux/sched.h               |  9 ---------
 12 files changed, 44 insertions(+), 24 deletions(-)
Signature · 1 line
1.8.1.2