All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.32-0
@ 2004-12-06 15:59 Mark_H_Johnson
  2004-12-07 14:07 ` Ingo Molnar
  0 siblings, 1 reply; 17+ messages in thread
From: Mark_H_Johnson @ 2004-12-06 15:59 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: Amit Shah, Karsten Wiese, Bill Huey, Adam Heath, emann,
	Gunther Persoons, K.R. Foley, linux-kernel, Florian Schmidt,
	Fernando Pablo Lopez-Lezcano, Lee Revell, Rui Nuno Capela,
	Shane Shrybman, Esben Nielsen, Thomas Gleixner, Michal Schmidt

>> > on low RT load (the common case) the scheduler behaves like the
>> > stock scheduler - the new logic only kicks in if a CPU runqueue has
>> > 2 or more RT tasks running at once.
>
>'the common case' == ordinary (non-RT) Linux boxes! When i implement
>scheduler features i'm always trying to make them as generic as
>possible, i.e. this feature too is structured to be as upstream
>mergeable as possible. For that purpose the change had to be
>low-overhead in the common, non-RT case.
I truly appreciate that. However...

>It is easy to hack the
>scheduler to fix some RT issue but break the generic scheduler - this
>solution is not meant to be such a hack.
I agree but I see the big delay of running the RT task to be a symptom
that the current non RT scheduler is somehow broken. I've reported the
non RT starvation condition several times. Yes, the second CPU is busy,
but I really do want to bump cpu_burn (which is non RT & nice) to run my
(non RT and not nice) stress script / commands instead.

--Mark H Johnson
  <mailto:Mark_H_Johnson@raytheon.com>


^ permalink raw reply	[flat|nested] 17+ messages in thread
* Re: [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.32-0
@ 2004-12-06 14:40 Mark_H_Johnson
  2004-12-06 15:34 ` Ingo Molnar
  0 siblings, 1 reply; 17+ messages in thread
From: Mark_H_Johnson @ 2004-12-06 14:40 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: Amit Shah, Karsten Wiese, Bill Huey, Adam Heath, emann,
	Gunther Persoons, K.R. Foley, linux-kernel, Florian Schmidt,
	Fernando Pablo Lopez-Lezcano, Lee Revell, Rui Nuno Capela,
	Shane Shrybman, Esben Nielsen, Thomas Gleixner, Michal Schmidt

>* Esben Nielsen <simlo@phys.au.dk> wrote:
>
>> On Fri, 3 Dec 2004, Ingo Molnar wrote:
>>
>> >
>> > [...]
>> > on low RT load (the common case)
>>
>> In the system I deal with on my day job, 50% of the CPU load is from
>> RT tasks!
>
>i'm not sure what point you are trying to make, but 'low RT load' in
>this context means up to a load of 1.0. (i.e. one or less tasks running
>on average)
I am not quite so sure that is a good assumption with our real time
system either. We use RT priorities based on execution rate with a
single (highest priority) RT task that wakes up the others at the
appropriate times. So an 80 Hz task has a higher RT priority than a
40 Hz task, both are greater than 10 Hz, and all greater than 1 Hz.
We do have a few other tasks for signal handling and other purposes
but most fit the above pattern.

At periodic rate (e.g., once per second) we basically start ALL RT tasks
and let the kernel figure out which one (two actually) should run first.
At that point in time, I may have 10-20 RT tasks ready to run with only
two CPU's to run them on. As the high priority tasks get done, the load
starts to drop, but a one Hz task may get delayed for some time and
interrupted several times during execution (later cycles of higher rate
RT tasks). FYI - I just checked and on our cluster head node, we have
31 RT tasks on a two CPU system.

With the real time load up, the one minute load average on 2.4 systems
oscillates in an odd fashion. For example, looking at 1 hour chart of
load average on my cluster shows the head node oscillating between zero
and five, even though the CPU usage is constant at 17.4%. I assume this
is a sampling error.

If the algorithm is OK for "small numbers" where small is under ten
times the number of CPU's, that is probably OK. [I'll allow that
SOMEONE will try to run a big RT simulation on a 256 CPU SMP machine
and complain later]

>also, this only applies to SMP systems.
Yes.

>thirdly, even if the new balancing code kicks in, the overhead is not
>that bad, and it's for a purpose: we rather want an RT task to run on a
>free CPU.
I agree though I wish it was possible to determine if the interrupt
preemption was "short" or "long" to decide to switch or not [the switch
DOES have costs...]. I believe this is why the max latency of my CPU
task went down (by about 1 msec) but the number of short latencies
(> 100 usec) went up.

But I am still seeing starvation of the non RT tasks that was not
present in 2.4. It appears that cpu_burn (non RT, nice) is taking CPU
cycles that should be allocated to my (non RT, not nice) stress test
programs. This distorts the elapsed time of my tests and to some extent
the latency results (since less I/O stress is on the system) of the tests.

--Mark H Johnson
  <mailto:Mark_H_Johnson@raytheon.com>


^ permalink raw reply	[flat|nested] 17+ messages in thread
* Re: [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.32-0
@ 2004-12-03 22:33 Mark_H_Johnson
  0 siblings, 0 replies; 17+ messages in thread
From: Mark_H_Johnson @ 2004-12-03 22:33 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: Amit Shah, Karsten Wiese, Bill Huey, Adam Heath, emann,
	Gunther Persoons, K.R. Foley, linux-kernel, Florian Schmidt,
	Fernando Pablo Lopez-Lezcano, Lee Revell, Rui Nuno Capela,
	Shane Shrybman, Esben Nielsen, Thomas Gleixner, Michal Schmidt

Comparison of .32-0 and .31-15 results


      within 100 usec
       CPU loop (%)   Elapsed Time (sec)    2.4
Test   32-0  31-15     32-0   31-15  |   CPU  Elapsed
X     94.58  99.22      67      68   |  97.20   70
top   95.29  97.96      39      34   |  97.48   29
neto  94.24  99.98     360     360   |  96.23   36
neti  94.83  98.31     360     350   |  95.86   41
diskw 90.77  99.57     360     360 * |  77.64   29
diskc 93.47  97.49     360     360   |  84.12   77
diskr 93.49  98.35     320     180   |  90.66   86
total                 1866    1712   |         368
* wide variation in audio duration

Grr. This appears that .32-0 is MUCH WORSE than 31.15 at
keeping the relatively small (100 usec) latencies down.
Probably due to the CPU task switch that prevents the
longer ones from occurring. The MAX CPU latencies are down
in most cases (over 4 msec down to about 3 msec) which
is a good result.

The long elapsed times appear to indicate that we are
starving the "stress test" application (and likely
running the niced, non RT cpu_burn instead).

--Mark H Johnson
  <mailto:Mark_H_Johnson@raytheon.com>


^ permalink raw reply	[flat|nested] 17+ messages in thread
* [patch] Real-Time Preemption, -RT-2.6.10-rc1-mm3-V0.7.25-1
@ 2004-11-11 21:51 Ingo Molnar
  2004-11-16 12:54 ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.27-0 Ingo Molnar
  0 siblings, 1 reply; 17+ messages in thread
From: Ingo Molnar @ 2004-11-11 21:51 UTC (permalink / raw)
  To: linux-kernel
  Cc: Lee Revell, Rui Nuno Capela, Mark_H_Johnson, K.R. Foley,
	Bill Huey, Adam Heath, Florian Schmidt, Thomas Gleixner,
	Michal Schmidt, Fernando Pablo Lopez-Lezcano, Karsten Wiese,
	Gunther Persoons, emann, Shane Shrybman, Amit Shah


i have released the -V0.7.25-1 Real-Time Preemption patch, which can be
downloaded from the usual place:

    http://redhat.com/~mingo/realtime-preempt/

this is a fixes-only release that resolves a couple of bugs that slipped
into -V0.7.25-0:

 - lockup/deadlock fix: make debug_direct_keyboard default to 0. It is
   only a debug helper to be used for development, it was never intended
   to be enabled. This fix should resolve the bugs reported by Gunther
   Persoons and Mark H. Johnson.

 - fix symbol export problems in rtc.ko, reported by Remi Colinet, based
   on the patch from K.R. Foley.

 - make preempt_wakeup_timing default to 1 if enabled in the .config, as 
   originally intended.

to create a -V0.7.25-1 tree from scratch, the patching order is:

   http://kernel.org/pub/linux/kernel/v2.6/linux-2.6.9.tar.bz2
   http://kernel.org/pub/linux/kernel/v2.6/testing/patch-2.6.10-rc1.bz2
   http://kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.10-rc1/2.6.10-rc1-mm3/2.6.10-rc1-mm3.bz2
   http://redhat.com/~mingo/realtime-preempt/realtime-preempt-2.6.10-rc1-mm3-V0.7.25-1

	Ingo

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

end of thread, other threads:[~2004-12-07 14:08 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-06 15:59 [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.32-0 Mark_H_Johnson
2004-12-07 14:07 ` Ingo Molnar
  -- strict thread matches above, loose matches on Subject: below --
2004-12-06 14:40 Mark_H_Johnson
2004-12-06 15:34 ` Ingo Molnar
2004-12-03 22:33 Mark_H_Johnson
2004-11-11 21:51 [patch] Real-Time Preemption, -RT-2.6.10-rc1-mm3-V0.7.25-1 Ingo Molnar
2004-11-16 12:54 ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.27-0 Ingo Molnar
2004-11-16 13:09   ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.27-1 Ingo Molnar
2004-11-16 13:40     ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.27-3 Ingo Molnar
2004-11-17 12:42       ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.28-0 Ingo Molnar
2004-11-18 12:35         ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.28-1 Ingo Molnar
2004-11-18 16:46           ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.29-0 Ingo Molnar
2004-11-22  0:54             ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.30-2 Ingo Molnar
2004-11-23 17:58               ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.30-9 Ingo Molnar
2004-11-24 10:16                 ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.30-10 Ingo Molnar
2004-12-03 20:58                   ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm2-V0.7.32-0 Ingo Molnar
2004-12-03 21:04                     ` Ingo Molnar
2004-12-04 22:32                     ` Rui Nuno Capela
2004-12-04 22:46                       ` Ingo Molnar
2004-12-04 23:38                         ` Rui Nuno Capela
2004-12-04 23:55                         ` K.R. Foley
2004-12-05  3:10                           ` Gene Heskett
2004-12-05  3:05                       ` Gene Heskett
2004-12-05 23:14                     ` Esben Nielsen
2004-12-06 13:14                       ` Ingo Molnar
2004-12-06 15:01                         ` Esben Nielsen
2004-12-06 15:27                           ` Ingo Molnar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.