Re: [PATCH] sched/core: make "Preemption disabled at" message more useful

From: Vegard Nossum
Date: Wed Jul 27 2016 - 08:26:46 EST


This is a multi-part message in MIME format. On 07/27/2016 12:38 PM, Ingo Molnar wrote:
* Vegard Nossum <vegard.nossum@xxxxxxxxx> wrote:
I'm assuming you want to declare and initialise preempt_disable_ip at
once here, but it generates slightly worse code since it dereferences
current->preempt_disable_ip in the "fast path" (i.e. a sleeping
function is NOT called from an invalid context).

Could you please add a likely() branch to see whether GCC will delay the
initialization?

The 4 #ifdefs were really ugly, so yes, it would be nice to at least reduce them
to 2.

How about this?


Vegard