All of lore.kernel.org
 help / color / mirror / Atom feed
* Re: [patch] Real-Time Preemption, -RT-2.6.10-rc3-mm1-V0.7.33-0
@ 2004-12-15  0:40 Sid Boyce
  0 siblings, 0 replies; 40+ messages in thread
From: Sid Boyce @ 2004-12-15  0:40 UTC (permalink / raw)
  To: linux-kernel

Same failure in previous RT V0.7-32 builds on x86_64, SuSE 9.2 gcc 
version 3.3.4 (pre 3.3.5 20040809)

   CC      arch/x86_64/kernel/../../i386/mach-default/topology.o
   LD      arch/x86_64/kernel/bootflag.o
   CC      arch/x86_64/kernel/e820.o
In file included from include/asm/dma.h:13,
                  from include/linux/bootmem.h:8,
                  from arch/x86_64/kernel/e820.c:10:
include/asm/io.h: In function `memset_io':
include/asm/io.h:265: warning: implicit declaration of function `memset'
include/asm/io.h:265: warning: return makes pointer from integer without 
a cast
   CC      arch/x86_64/kernel/reboot.o
   LD      arch/x86_64/kernel/quirks.o
   CC      arch/x86_64/kernel/semaphore.o
   CC      arch/x86_64/kernel/mce.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/main.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/if.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/generic.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/state.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/amd.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/cyrix.o
   CC      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/centaur.o
   LD      arch/x86_64/kernel/../../i386/kernel/cpu/mtrr/built-in.o
   CC      arch/x86_64/kernel/acpi/../../../i386/kernel/acpi/boot.o
In file included from arch/i386/kernel/acpi/boot.c:30:
include/linux/irq.h:80: error: parse error before "cycles_t"
include/linux/irq.h:80: warning: no semicolon at end of struct or union
include/linux/irq.h:82: error: parse error before '}' token
include/linux/irq.h:82: warning: type defaults to `int' in declaration 
of `irq_desc_t'
include/linux/irq.h:84: error: parse error before "irq_desc"
include/linux/irq.h:84: warning: type defaults to `int' in declaration 
of `irq_desc'
include/linux/irq.h:84: warning: data definition has no type or storage 
class
In file included from arch/i386/kernel/acpi/boot.c:30:
include/linux/irq.h:99: error: parse error before "irq_desc_t"
include/linux/irq.h:99: warning: function declaration isn't a prototype
include/linux/irq.h:100: error: parse error before "irq_desc_t"
include/linux/irq.h:100: warning: function declaration isn't a prototype
make[2]: *** [arch/x86_64/kernel/acpi/../../../i386/kernel/acpi/boot.o] 
Error 1
make[1]: *** [arch/x86_64/kernel/acpi] Error 2
make: *** [arch/x86_64/kernel] Error 2

Regards
Sid.
-- 
Sid Boyce .... Hamradio G3VBV and keen Flyer
=====LINUX ONLY USED HERE=====

^ permalink raw reply	[flat|nested] 40+ messages in thread
* Re: [patch] Real-Time Preemption, -RT-2.6.10-rc3-mm1-V0.7.33-0
@ 2004-12-16 15:50 Mark_H_Johnson
  0 siblings, 0 replies; 40+ messages in thread
From: Mark_H_Johnson @ 2004-12-16 15:50 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: linux-kernel, Lee Revell, Rui Nuno Capela, Mark_H_Johnson,
	K.R. Foley, Bill Huey, Adam Heath, Florian Schmidt,
	Thomas Gleixner, Fernando Pablo Lopez-Lezcano, Steven Rostedt

I was curious about what was causing some of my "extended delays" during
a network stress test & captured a trace I'll summarize here & forward
the complete trace separately. If I read this right, it appears I just
had "bad luck" (lots of interrupts on the CPU with the RT task) but I
would be glad to hear of a better interpretation (if it fits the data).

The test set up was my two CPU SMP system. The kernel was .33-03 with
PREEMPT_DESKTOP and non threaded IRQ's. The RT program was a slight
variation of latencytest - modified to capture traces if the CPU loop
(nominal 1160 usec) took more than 20% longer than nominal. The non
RT stress program running concurrently was my network output test
which basically uses rcp to copy a file to another system.

       times in usec
       CPU   Latency  Cause
[00]     50      14   Audio IRQ
[01]    154      69   Network IRQ / soft IRQ
[02]     53      92   SMP timer / Network IRQ / soft IRQ
[03]     25      62   Network IRQ / soft IRQ
[04]     60       6   Network IRQ
[05]    133      70   Network IRQ / soft IRQ
[06]     53     211   Network IRQ / soft IRQ / reschedule
[07]     35      76   Network IRQ / soft IRQ
[08]     75     210   Network IRQ / soft IRQ / reschedule / soft IRQ
[09]     58     105   Audio IRQ / soft IRQ / reschedule
[10]     19     103   Network IRQ / soft IRQ
[11]     86      86   Network IRQ / soft IRQ
[12]     34     102   Network IRQ / soft IRQ
[13]     53      63   Network IRQ / soft IRQ
[14]     56      52   Network IRQ / soft IRQ / reschedule
[15]     72      23   SMP timer / soft IRQ
[16]     59       2   End of trace
Total  1075    1346   (2421 grand total - check)

None of the individual latencies are all that bad - both #06 and #08
were the worst at 210 usec. It may be possible to fix the specific causes
of those two traces (though I know we've also broken the network code
as well...). but it is the cumulative effect of the number of
interrupts that appear to be the problem.

I am also not so sure that PREEMPT_RT would have done much better
but have not run that test for a comparison. I worry about the
cost of rescheduling / IRQ threading overhead - which may explain
why I see PREEMPT_DESKTOP doing better than PREEMPT_RT in some of
my tests.

I guess I should also note that this trace appears to indicate that
ALSA is buffering audio for output [see the two interrupts during the
trace]. I expect the audio output to be a blocking write in latencytest
(that was the 2.4 behavior). Is there some way to get the same behavior
I saw in 2.4 on a 2.6 / ALSA audio set up? If you don't know, who should
I direct that question to?

  --Mark

preemption latency trace v1.1.4 on 2.6.10-rc3-mm1-V0.7.33-03
--------------------------------------------------------------------
 latency: 2421 µs, #2259/2259, CPU#0 | (M:preempt VP:0, KP:1, SP:0 HP:0
#P:2)
    -----------------
    | task: latencytest-tra-14143 (uid:0 nice:0 policy:1 rt_prio:99)
    -----------------
 => started at: <00000000>
 => ended at:   restore_all+0x5/0x21 <c0104000>

                 _------=> CPU#
                / _-----=> irqs-off
               | / _----=> need-resched
               || / _---=> hardirq/softirq
               ||| / _--=> preempt-depth
               |||| /
               |||||     delay
   cmd     pid ||||| time  |   caller
      \   /    |||||   \   |   /
latencyt-14143 0...1    0µs : user_trace_start (sys_gettimeofday)
latencyt-14143 0d...    0µs+< (0)                    [00]
latencyt-14143 0d.h.   50µs : do_IRQ (8049af8 a 0)
... process audio interrupt ...
[I can argue - why did this come in here since the audio REALLY should
have finished during the write() call done later]
latencyt-14143 0d...   64µs!< (0)                    [01]
latencyt-14143 0d.h.  218µs : do_IRQ (8049af9 b 0)
... process network IRQ / soft IRQ ...
latencyt-14143 0d...  287µs+< (0)                    [02]
latencyt-14143 0d...  340µs : smp_apic_timer_interrupt (8049af9 0 0)
... timer / network IRQ / soft IRQ
latencyt-14143 0d...  432µs+< (0)                    [03]
latencyt-14143 0d.h.  457µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ ...
latencyt-14143 0d...  519µs+< (0)                    [04]
latencyt-14143 0d.h.  579µs : do_IRQ (8049af8 b 0)
... network IRQ  ...
latencyt-14143 0d...  585µs!< (0)                    [05]
latencyt-14143 0d.h.  718µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ ...
latencyt-14143 0d...  788µs+< (0)                    [06]
latencyt-14143 0d.h.  841µs : do_IRQ (8049af9 b 0)
... network IRQ / soft IRQ / reschedule
latencyt-14143 0d... 1052µs+< (0)                    [07]
latencyt-14143 0d.h. 1087µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ
latencyt-14143 0d... 1163µs+< (0)                    [08]
latencyt-14143 0d.h. 1238µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ / reschedule / timer / soft IRQ
latencyt-14143 0d... 1448µs+< (0)                    [09]
latencyt-14143 0d.h. 1506µs : do_IRQ (8049af8 a 0)
... audio IRQ / soft IRQ / reschedule
[this on the other hand is closer to the right duration for the
audio interrupt]
latencyt-14143 0d... 1611µs+< (0)                    [10]
latencyt-14143 0d.h. 1630µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ
latencyt-14143 0d... 1733µs+< (0)                    [11]
latencyt-14143 0d.h. 1819µs : do_IRQ (8049af9 b 0)
... network IRQ / soft IRQ
latencyt-14143 0d... 1905µs+< (0)                    [12]
latencyt-14143 0d.h. 1939µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ
latencyt-14143 0d... 2041µs+< (0)                    [13]
latencyt-14143 0d.h. 2094µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ
latencyt-14143 0d... 2157µs+< (0)                    [14]
latencyt-14143 0d.h. 2213µs : do_IRQ (8049af8 b 0)
... network IRQ / soft IRQ / reschedule
latencyt-14143 0d... 2265µs+< (0)                    [15]
latencyt-14143 0d... 2337µs : smp_apic_timer_interrupt (8049af8 0 0)
... SMP timer / soft IRQ
latencyt-14143 0d... 2360µs+< (0)                    [16]
latencyt-14143 0.... 2419µs > sys_gettimeofday (00000000 00000000 0000007b)
latencyt-14143 0.... 2419µs : sys_gettimeofday (sysenter_past_esp)
latencyt-14143 0.... 2420µs : user_trace_stop (sys_gettimeofday)
latencyt-14143 0...1 2421µs : user_trace_stop (sys_gettimeofday)


^ permalink raw reply	[flat|nested] 40+ messages in thread
* Re: [patch] Real-Time Preemption, -RT-2.6.10-rc3-mm1-V0.7.33-0
@ 2004-12-14 23:11 Mark_H_Johnson
  2004-12-15  9:17 ` Ingo Molnar
  0 siblings, 1 reply; 40+ messages in thread
From: Mark_H_Johnson @ 2004-12-14 23:11 UTC (permalink / raw)
  To: Ingo Molnar
  Cc: Bill Huey, Adam Heath, K.R. Foley, linux-kernel, Florian Schmidt,
	Fernando Pablo Lopez-Lezcano, Lee Revell, Rui Nuno Capela,
	Steven Rostedt, Thomas Gleixner

A comparison of PREEMPT_RT (with tracing) to PREEMPT_DESKTOP
(with tracing). Due to the tracing overheads (and the results
I measured in the last few days), I'll report on percentages
within 200 usec for RT and 100 usec on PK to make it "more fair".

Comparison of .33-00RT and .33-00PK results
00RT has PREEMPT_RT
00PK has PREEMPT_DESKTOP and no threaded IRQ's
2.4 has lowlat + preempt patches applied

  within 200/100 usec
       CPU loop (%)   Elapsed Time (sec)    2.4
Test   RT     PK        RT      PK   |   CPU  Elapsed
X     96.78  99.88      90 *    83+* |  97.20   70
top   93.87 100.00      36 *    31+  |  97.48   29
neto  99.17 100.00     340 *   193+  |  96.23   36
neti  99.13  98.39     340 *   280 * |  95.86   41
diskw 98.04 100.00?    350 *   310+  |  77.64   29
diskc 95.56  99.94     350 *   310+  |  84.12   77
diskr 90.77  99.94     220 *   310+  |  90.66   86
total                 1726    1517   |         368
 [higher is better]  [lower is better]
* wide variation in audio duration
+ long stretch of audio duration "too fast"
? I believe I had non RT starvation & this result is in error
[chart shows a typical results for about 20 seconds and then
gets "really smooth" like the top chart for the remainder of
the measured duration]

The percentages are all within a handful of a percent so these
results look pretty comparable.

Looking at ping response time:
  RT 0.226 / 0.486 / 2.475 / 0.083 msec
  PK 0.102 / 0.174 / 0.813 / 0.054 msec
for min / average / max / mdev values. Again, tracing penalizes
RT much more than PK so this is to be expected.

The maximum duration of the CPU loop (as measured by the
application) is in the range of 2.05 msec to 3.30 compared
to the nominal 1.16 msec duration for -00RT. The equivalent
numbers for -00PK are 1.21 to 2.61 msec. I would expect RT
to be better than PK on this measure, but it never seems to
be the result I measure.

Based on the number of latency_trace files, -00RT still
is far better than -00PK. In particular, I get some extended
delays in -00PK from:
 - network (I have an 2000 usec example!)
 - rcu_process_callbacks (around 250 usec)
 - clear_page_range (around 170 usec)
 - free_pages_and_swap_cache (around 140 usec)
 - do_no_page (around 170 usec)
 - ide [IRQ?] (around 200 usec)
 - journal_remove_journal_head (> 1000 usec)
 - do_wait / wait_task_zombie (around 200 usec)
A fix to the network & journaling latencies would be helpful.
The others are certainly less important. I'll send the traces
separately.

Also, if you get some odd trace results on an SMP system,
Ingo already has some fixes applied in response to some buglets
I found & reported separately.

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


^ permalink raw reply	[flat|nested] 40+ messages in thread
* [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.27-3
@ 2004-11-16 13:40 Ingo Molnar
  2004-11-17 12:42 ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm1-V0.7.28-0 Ingo Molnar
  0 siblings, 1 reply; 40+ messages in thread
From: Ingo Molnar @ 2004-11-16 13:40 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.27-3 Real-Time Preemption patch, which can be
downloaded from the usual place:

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

this is another quick update to fix a couple of bugs. Sorry about the
fast pace of updates but these fixes are worth having ASAP:

Changes since a -V0.7.27-1:

 - fix module-put BKL count bug - this could explain/fix the lockups
   reported by Rui Nuno Capela.

 - fixed a netfilter related networking deadlock reported by Mark H. 
   Johnson two weeks ago, it triggered on my testbox today. This (rare)
   bug could potentially explain some of the other lockup reports that
   are still open.

 - fix load average constant +1.0 offset when PREEMPT_RT is enabled. 
   This was an artifact of the IRQ-threading of the timer interrupt.

to create a -V0.7.27-3 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-rc2.bz2
  http://kernel.org/pub/linux/kernel/people/akpm/patches/2.6/2.6.10-rc2/2.6.10-rc2-mm1/2.6.10-rc2-mm1.bz2
  http://redhat.com/~mingo/realtime-preempt/realtime-preempt-2.6.10-rc2-mm1-V0.7.27-3

	Ingo

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

end of thread, other threads:[~2005-01-04  6:41 UTC | newest]

Thread overview: 40+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-15  0:40 [patch] Real-Time Preemption, -RT-2.6.10-rc3-mm1-V0.7.33-0 Sid Boyce
  -- strict thread matches above, loose matches on Subject: below --
2004-12-16 15:50 Mark_H_Johnson
2004-12-14 23:11 Mark_H_Johnson
2004-12-15  9:17 ` 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-07 13:29               ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm3-V0.7.32-4 Ingo Molnar
2004-12-07 14:11                 ` [patch] Real-Time Preemption, -RT-2.6.10-rc2-mm3-V0.7.32-6 Ingo Molnar
2004-12-14 13:28                   ` [patch] Real-Time Preemption, -RT-2.6.10-rc3-mm1-V0.7.33-0 Ingo Molnar
2004-12-14 19:34                     ` Steven Rostedt
2004-12-14 20:08                       ` Lee Revell
2004-12-14 20:45                         ` Steven Rostedt
2004-12-14 21:18                           ` Ingo Molnar
2004-12-14 21:47                             ` Lee Revell
2004-12-14 21:51                               ` Ingo Molnar
2004-12-14 21:57                                 ` Lee Revell
2004-12-14 21:52                             ` George Anzinger
2004-12-14 21:59                               ` Steven Rostedt
2004-12-14 22:28                               ` Ingo Molnar
2004-12-14 22:13                             ` Lee Revell
2004-12-14 22:31                               ` Ingo Molnar
2004-12-14 22:47                                 ` Lee Revell
2004-12-14 22:57                                   ` Paul Davis
2004-12-15  9:32                                     ` Ingo Molnar
2004-12-15 16:23                                       ` Lee Revell
2004-12-14 23:18                                   ` linux-os
2004-12-15  1:53                                     ` Paul Davis
2004-12-15  2:49                                     ` Gene Heskett
2004-12-15  2:38                                 ` Gene Heskett
2004-12-15 15:24                                   ` K.R. Foley
2004-12-15 16:34                                     ` Gene Heskett
2004-12-15 16:38                                       ` K.R. Foley
2004-12-14 20:07                     ` Fernando Lopez-Lezcano
2004-12-14 20:35                       ` Ingo Molnar
2004-12-14 23:21                     ` Fernando Lopez-Lezcano
2004-12-15  0:43                       ` Florian Schmidt
2004-12-15  1:09                       ` Lee Revell
2004-12-15  2:04                         ` Fernando Lopez-Lezcano
2004-12-15  9:09                           ` Ingo Molnar
2004-12-15 10:17                             ` Andrew Walrond
2004-12-15 16:51                             ` Lee Revell
2004-12-17  0:45                       ` Fernando Lopez-Lezcano
2004-12-15 20:52                     ` Magnus Määttä
2005-01-04  6:40                     ` Bill Huey

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.