lkml.org 
[lkml]   [2015]   [Jul]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [RFC PATCH] thread_local_abi system call: caching current CPU number (x86)
Date
Mathieu Desnoyers wrote:
> Expose a new system call allowing threads to register a userspace memory
> area where to store the current CPU number. Scheduler migration sets the

I really like that this approach makes it easier to add a per-thread interaction between userspace and the kernel in the future.

>+ if (!tlap || t->thread_local_abi_len <
>+ offsetof(struct thread_local_abi, cpu)
>+ + sizeof(tlap->cpu))

Could you save a branch here by enforcing that thread_local_abi_len = 0 if thread_local_abi = null?

-b

\
 
 \ /
  Last update: 2015-07-17 13:01    [W:0.104 / U:0.052 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site