Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoints for worklet lifecycle tracing

Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
From: Frederic Weisbecker
Date: Friday, April 24, 2009 - 5:37 pm

On Fri, Apr 24, 2009 at 04:20:56PM -0700, Andrew Morton wrote:


If you don't recall problems revealed by this tracer or patches
motivated by its results, I have examples.

Soon after writing the first version of th workqueue tracer, I saw
this incredible rate of unused workqueue on my box.
Note that's still the case today (I've cut the worklet informations):

# cat trace_stat/workqueues 
# CPU  INSERTED  EXECUTED   TASKNAME:PID
# |      |         |        `-WORKFUNC
# |      |         |          |
  0   9587       9650       events/0:9
  0      0          0       cpuset:11
  0   1384       1384       khelper:12
  0      0          0       kintegrityd/0:178
  0    385        385       kblockd/0:184
  0      0          0       kacpid:190
  0      0          0       kacpi_notify:191
  0      0          0       tifm:498
  0  24061      24061       ata/0:507
  0      0          0       ata_aux:511
  0      0          0       aio/0:871
  0      0          0       crypto/0:897
  0      0          0       scsi_tgtd/0:2368
  0      0          0       iscsi_eh:2387
  0      0          0       kpsmoused:2521
  0      0          0       hd-audio0:2660
  0      0          0       krxrpcd/0:2745
  0    147        147       reiserfs/0:2895
  1  11023      11046       events/1:10
  1      0          0       kintegrityd/1:181
  1    293        293       kblockd/1:185
  1  33783      33783       ata/1:509
  1      0          0       aio/1:878
  1      0          0       crypto/1:898
  1      0          0       scsi_tgtd/1:2370
  1      0          0       krxrpcd/1:2746
  1     99         99       reiserfs/1:2896


27 threads. 15 are unused, 12 are used.

And still, I've only two CPUS.
More than half of my workqueues are unused.
I also have a small config. I can't imagine the result
with a distro config which enables a lot of options
by default.

I discovered it with this tracer. Then it brought me to
write this patch:

http://lkml.org/lkml/2009/1/31/184

Btw, if one day I can see something like async but which is able
to accept work that _must_ be ran async in any case, then I'm still willing
to rework this patch.

Still with these same observations, I wrote this another one:

http://lkml.org/lkml/2009/1/26/363

Without this tracer, I wouldn't have had the informations which
motivated me to write these patches. And although they weren't accepted
(the first is more about pending than refused, my bad), which is
justified, they reveal a real problem.


Who knows what kind of other things we can discover with worklet tracing?

Frederic.


--
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH 0/1] tracing, workqueuetrace: Make workqueue tr ..., Frederic Weisbecker, (Mon Apr 13, 6:57 am)
Re: [PATCH 1/1] tracing, workqueuetrace: Make workqueue tr ..., Frederic Weisbecker, (Mon Apr 13, 7:13 am)
Re: [PATCH 1/1] tracing, workqueuetrace: Make workqueue tr ..., Frederic Weisbecker, (Mon Apr 13, 7:34 am)
Re: [PATCH v2 1/4] ftrace, workqueuetrace: Make workqueue ..., Frederic Weisbecker, (Mon Apr 13, 8:24 am)
Re: [PATCH v2 3/4] ftrace: add max execution time mesureme ..., Frederic Weisbecker, (Mon Apr 13, 9:16 am)
Re: [PATCH v2 2/4] ftrace: introduce workqueue_handler_exi ..., Frederic Weisbecker, (Mon Apr 13, 9:25 am)
[PATCH v2 5/4] ftrace, workqueuetrace: display work name, KOSAKI Motohiro, (Mon Apr 13, 9:03 pm)
Re: [PATCH v2 3/4] ftrace: add max execution time mesureme ..., Frederic Weisbecker, (Tue Apr 14, 4:40 am)
Re: [PATCH v2 5/4] ftrace, workqueuetrace: display work name, Frederic Weisbecker, (Tue Apr 14, 2:16 pm)
Re: [PATCH v2 5/4] ftrace, workqueuetrace: display work name, KOSAKI Motohiro, (Tue Apr 14, 4:55 pm)
Re: [PATCH v2 5/4] ftrace, workqueuetrace: display work name, Frederic Weisbecker, (Tue Apr 14, 6:15 pm)
Re: [PATCH v2 5/4] ftrace, workqueuetrace: display work name, KOSAKI Motohiro, (Tue Apr 14, 11:13 pm)
Re: [PATCH v2 5/4] ftrace, workqueuetrace: display work name, Frederic Weisbecker, (Wed Apr 15, 9:23 am)
Re: [PATCH 0/4] ftrace, workqueuetrace: Add worklet inform ..., Frederic Weisbecker, (Mon Apr 20, 12:23 am)
Re: [PATCH 1/4] trace_workqueue: use list_for_each_entry() ..., Frederic Weisbecker, (Mon Apr 20, 12:26 am)
Re: [PATCH 4/4] trace_workqueue: Add worklet information, Frederic Weisbecker, (Mon Apr 20, 4:36 am)
Re: [PATCH v3 1/1] ftrace, workqueuetrace: Make workqueue ..., Frederic Weisbecker, (Mon Apr 20, 10:11 am)
Re: [PATCH v3 1/1] ftrace, workqueuetrace: Make workqueuet ..., Frederic Weisbecker, (Mon Apr 20, 4:48 pm)
Re: [PATCH v3 1/1] ftrace, workqueuetrace: Make workqueuet ..., Frederic Weisbecker, (Tue Apr 21, 11:28 am)
Re: [PATCH v3 1/1] ftrace, workqueuetrace: Make workqueuet ..., Frederic Weisbecker, (Tue Apr 21, 11:33 am)
Re: Re: [PATCH 4/4] trace_workqueue: Add worklet information, Frederic Weisbecker, (Tue Apr 21, 4:39 pm)
Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoi ..., Frederic Weisbecker, (Fri Apr 24, 3:59 pm)
Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoi ..., Frederic Weisbecker, (Fri Apr 24, 4:27 pm)
Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoi ..., Frederic Weisbecker, (Fri Apr 24, 5:37 pm)
Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoi ..., Frederic Weisbecker, (Tue Apr 28, 6:42 am)
Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoi ..., Frank Ch. Eigler, (Tue Apr 28, 10:24 am)
Re: [PATCH 0/4] workqueue_tracepoint: Add worklet tracepoi ..., Frederic Weisbecker, (Tue Apr 28, 10:49 am)