lkml.org 
[lkml]   [2012]   [Apr]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 11/16] sched: add latency tracing for -deadline tasks.
From
Hi,

On Wed, Apr 11, 2012 at 23:03, Steven Rostedt <rostedt@goodmis.org> wrote:
>> +     /*
>> +      * Semantic is like this:
>> +      *  - wakeup tracer handles all tasks in the system, independently
>> +      *    from their scheduling class;
>> +      *  - wakeup_rt tracer handles tasks belonging to sched_dl and
>> +      *    sched_rt class;
>> +      *  - wakeup_dl handles tasks belonging to sched_dl class only.
>> +      */
>> +     if ((wakeup_dl && !dl_task(p)) ||
>> +         (wakeup_rt && !dl_task(p) && !rt_task(p)) ||
>> +         (p->prio >= wakeup_prio || p->prio >= current->prio))
>>               return;
>
> Anyway, perhaps this should be broken up, as we don't want the double
> test, that is, wakeup_rt and wakeup_dl are both checked. Perhaps do:
>
>        if (wakeup_dl && !dl_task(p))
>                return;
>        else if (wakeup_rt && !dl_task(p) && !rt_task(p))
>                return;
>
>        if (p->prio >= wakeup_prio || p->prio >= current->prio)
>                return;
>
>
> -- Steve

sorry for the question, I'm obviously missing something here but what
is the logic behind this rewrite? In both cases my gcc generates the
same code for me.

nX
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2012-04-16 17:53    [W:0.121 / U:35.756 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site