public inbox for linux-api@vger.kernel.org
 help / color / mirror / Atom feed
* [RFC PATCH v3 0/5] getcpu_cache system call
@ 2016-01-28 21:01 Mathieu Desnoyers
  2016-01-28 21:01 ` [RFC PATCH v3 1/5] getcpu_cache system call: cache CPU number of running thread Mathieu Desnoyers
                   ` (3 more replies)
  0 siblings, 4 replies; 10+ messages in thread
From: Mathieu Desnoyers @ 2016-01-28 21:01 UTC (permalink / raw)
  To: Thomas Gleixner, Paul Turner, Andrew Hunter, Peter Zijlstra
  Cc: linux-kernel-u79uwXL29TY76Z2rM5mHXA,
	linux-api-u79uwXL29TY76Z2rM5mHXA, Andy Lutomirski, Andi Kleen,
	Dave Watson, Chris Lameter, Ingo Molnar, Ben Maurer,
	Steven Rostedt, Paul E. McKenney, Josh Triplett, Linus Torvalds,
	Andrew Morton, Russell King, Catalin Marinas, Will Deacon,
	Michael Kerrisk, Mathieu Desnoyers

Hi,

Here is an update to the getcpu_cache system call following the v2 round
of review. It implements a cache for the CPU number of the currently
running thread in user-space.

Benchmarks comparing this approach to a getcpu based on system call on
ARM show a 44x speedup. They show a 14x speedup on x86-64 compared to
executing lsl from a vDSO through glibc.

This patchset is sent as RFC. It applies on Linux 4.4. It is submitted
for feedback. I'm targeting the 4.6 merge window.

Feedback is welcome,

Thanks!

Mathieu

Mathieu Desnoyers (5):
  getcpu_cache system call: cache CPU number of running thread
  getcpu_cache: ARM resume notifier
  getcpu_cache: wire up ARM system call
  getcpu_cache: x86 32/64 resume notifier
  getcpu_cache: wire up x86 32/64 system call

 MAINTAINERS                            |   7 ++
 arch/arm/include/uapi/asm/unistd.h     |   1 +
 arch/arm/kernel/calls.S                |   1 +
 arch/arm/kernel/signal.c               |   1 +
 arch/x86/entry/common.c                |   1 +
 arch/x86/entry/syscalls/syscall_32.tbl |   1 +
 arch/x86/entry/syscalls/syscall_64.tbl |   1 +
 fs/exec.c                              |   1 +
 include/linux/sched.h                  |  36 ++++++++
 include/uapi/linux/Kbuild              |   1 +
 include/uapi/linux/getcpu_cache.h      |  42 +++++++++
 init/Kconfig                           |  10 +++
 kernel/Makefile                        |   1 +
 kernel/fork.c                          |   4 +
 kernel/getcpu_cache.c                  | 150 +++++++++++++++++++++++++++++++++
 kernel/sched/sched.h                   |   1 +
 kernel/sys_ni.c                        |   3 +
 17 files changed, 262 insertions(+)
 create mode 100644 include/uapi/linux/getcpu_cache.h
 create mode 100644 kernel/getcpu_cache.c

-- 
2.1.4

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2016-01-29 16:28 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-28 21:01 [RFC PATCH v3 0/5] getcpu_cache system call Mathieu Desnoyers
2016-01-28 21:01 ` [RFC PATCH v3 1/5] getcpu_cache system call: cache CPU number of running thread Mathieu Desnoyers
     [not found]   ` <1454014885-29012-2-git-send-email-mathieu.desnoyers-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2016-01-28 21:52     ` Thomas Gleixner
2016-01-28 22:44       ` Mathieu Desnoyers
2016-01-29  8:39         ` Thomas Gleixner
2016-01-29 16:28           ` Mathieu Desnoyers
     [not found] ` <1454014885-29012-1-git-send-email-mathieu.desnoyers-vg+e7yoeK/dWk0Htik3J/w@public.gmane.org>
2016-01-28 21:01   ` [RFC PATCH v3 2/5] getcpu_cache: ARM resume notifier Mathieu Desnoyers
2016-01-28 21:01   ` [RFC PATCH v3 3/5] getcpu_cache: wire up ARM system call Mathieu Desnoyers
2016-01-28 21:01 ` [RFC PATCH v3 4/5] getcpu_cache: x86 32/64 resume notifier Mathieu Desnoyers
2016-01-28 21:01 ` [RFC PATCH v3 5/5] getcpu_cache: wire up x86 32/64 system call Mathieu Desnoyers

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox