From: "Zhang, Yanmin" <yanmin_zhang@linux.intel.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Matthew Wilcox <matthew@wil.cx>,
LKML <linux-kernel@vger.kernel.org>,
Alexander Viro <viro@ftp.linux.org.uk>,
Linus Torvalds <torvalds@linux-foundation.org>,
Andrew Morton <akpm@linux-foundation.org>
Subject: Re: AIM7 40% regression with 2.6.26-rc1
Date: Wed, 07 May 2008 11:41:52 +0800 [thread overview]
Message-ID: <1210131712.3453.43.camel@ymzhang> (raw)
In-Reply-To: <1210126286.3453.37.camel@ymzhang>
On Wed, 2008-05-07 at 10:11 +0800, Zhang, Yanmin wrote:
> On Tue, 2008-05-06 at 13:44 +0200, Ingo Molnar wrote:
> > * Zhang, Yanmin <yanmin_zhang@linux.intel.com> wrote:
> >
> > > Comparing with kernel 2.6.25, AIM7 (use tmpfs) has more than 40% with
> > > 2.6.26-rc1 on my 8-core stoakley, 16-core tigerton, and Itanium
> > > Montecito. Bisect located below patch.
> > >
> > > 64ac24e738823161693bf791f87adc802cf529ff is first bad commit
> > > commit 64ac24e738823161693bf791f87adc802cf529ff
> > > Author: Matthew Wilcox <matthew@wil.cx>
> > > Date: Fri Mar 7 21:55:58 2008 -0500
> > >
> > > Generic semaphore implementation
> > >
> > > After I manually reverted the patch against 2.6.26-rc1 while fixing
> > > lots of conflictions/errors, aim7 regression became less than 2%.
> >
> > hm, which exact semaphore would that be due to?
> >
> > My first blind guess would be the BKL - there's not much other semaphore
> > use left in the core kernel otherwise that would affect AIM7 normally.
> > The VFS still makes frequent use of the BKL and AIM7 is very VFS
> > intense. Getting rid of that BKL use from the VFS might be useful to
> > performance anyway.
> >
> > Could you try to check that it's indeed the BKL?
> >
> > Easiest way to check it would be to run AIM7 it on
> > sched-devel.git/latest and do scheduler tracing via:
> >
> > http://people.redhat.com/mingo/sched-devel.git/readme-tracer.txt
> One clear weird behavior of aim7 is cpu idle is 0% with 2.6.25, but is more than 50% with
> 2.6.26-rc1. I have a patch to collect schedule info.
With my patch+gprof, I collected some data. Below was outputed by gprof.
index % time self children called name
0.00 0.00 2/223305376 __down_write_nested [22749]
0.00 0.00 3/223305376 journal_commit_transaction [10526]
0.00 0.00 6/223305376 __down_read [22745]
0.00 0.00 8/223305376 start_this_handle [19167]
0.00 0.00 15/223305376 sys_pause [19808]
0.00 0.00 17/223305376 log_wait_commit [11047]
0.00 0.00 20/223305376 futex_wait [8122]
0.00 0.00 64/223305376 pdflush [14335]
0.00 0.00 71/223305376 do_get_write_access [5367]
0.00 0.00 84/223305376 pipe_wait [14460]
0.00 0.00 111/223305376 kjournald [10726]
0.00 0.00 116/223305376 int_careful [9634]
0.00 0.00 224/223305376 do_nanosleep [5418]
0.00 0.00 1152/223305376 watchdog [22065]
0.00 0.00 4087/223305376 worker_thread [22076]
0.00 0.00 5003/223305376 __mutex_lock_killable_slowpath [23305]
0.00 0.00 7810/223305376 ksoftirqd [10831]
0.00 0.00 9389/223305376 __mutex_lock_slowpath [23306]
0.00 0.00 10642/223305376 io_schedule [9813]
0.00 0.00 23544/223305376 migration_thread [11495]
0.00 0.00 35319/223305376 __cond_resched [22673]
0.00 0.00 49065/223305376 retint_careful [16146]
0.00 0.00 119757/223305376 sysret_careful [20074]
0.00 0.00 151717/223305376 do_wait [5545]
0.00 0.00 250221/223305376 do_exit [5356]
0.00 0.00 303836/223305376 cpu_idle [4350]
0.00 0.00 222333093/223305376 schedule_timeout [2]
[1] 0.0 0.00 0.00 223305376 schedule [1]
-----------------------------------------------
0.00 0.00 2/222333093 io_schedule_timeout [9814]
0.00 0.00 4/222333093 journal_stop [10588]
0.00 0.00 8/222333093 cifs_oplock_thread [3760]
0.00 0.00 14/222333093 do_sys_poll [5513]
0.00 0.00 20/222333093 cifs_dnotify_thread [3733]
0.00 0.00 32/222333093 read_chan [15648]
0.00 0.00 47/222333093 wait_for_common [22017]
0.00 0.00 658/222333093 do_select [5479]
0.00 0.00 2000/222333093 inet_stream_connect [9324]
0.00 0.00 222330308/222333093 __down [22577]
[2] 0.0 0.00 0.00 222333093 schedule_timeout [2]
0.00 0.00 222333093/223305376 schedule [1]
-----------------------------------------------
0.00 0.00 1/165565 flock_lock_file_wait [7735]
0.00 0.00 7/165565 __posix_lock_file [23371]
0.00 0.00 203/165565 de_put [4665]
0.00 0.00 243/165565 opost [13633]
0.00 0.00 333/165565 proc_root_readdir [14982]
0.00 0.00 358/165565 write_chan [22090]
0.00 0.00 6222/165565 proc_lookup_de [14908]
0.00 0.00 32081/165565 sys_fcntl [19687]
0.00 0.00 36045/165565 vfs_ioctl [21822]
0.00 0.00 42025/165565 tty_release [20818]
0.00 0.00 48047/165565 chrdev_open [3702]
[3] 0.0 0.00 0.00 165565 lock_kernel [3]
0.00 0.00 152987/153190 down [4]
-----------------------------------------------
0.00 0.00 203/153190 __reacquire_kernel_lock [23420]
0.00 0.00 152987/153190 lock_kernel [3]
[4] 0.0 0.00 0.00 153190 down [4]
0.00 0.00 153190/153190 __down [22577]
-----------------------------------------------
0.00 0.00 153190/153190 down [4]
[22577 0.0 0.00 0.00 153190 __down [22577]
0.00 0.00 222330308/222333093 schedule_timeout [2]
As system idle is more than 50%, so the schedule/schedule_timeout caller is important
information.
1) lock_kernel causes most schedule/schedule_timeout;
2) When lock_kernel calls down, then __down, __down calls schedule_timeout for
lots of times in a loop;
3) Caller of lcok_kernel are sys_fcntl/vfs_ioctl/tty_release/chrdev_open.
-yanmin
next prev parent reply other threads:[~2008-05-07 3:43 UTC|newest]
Thread overview: 140+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-05-06 5:48 AIM7 40% regression with 2.6.26-rc1 Zhang, Yanmin
2008-05-06 11:18 ` Matthew Wilcox
2008-05-06 11:44 ` Ingo Molnar
2008-05-06 12:09 ` Matthew Wilcox
2008-05-06 16:23 ` Matthew Wilcox
2008-05-06 16:36 ` Linus Torvalds
2008-05-06 16:42 ` Matthew Wilcox
2008-05-06 16:39 ` Alan Cox
2008-05-06 16:51 ` Matthew Wilcox
2008-05-06 16:45 ` Alan Cox
2008-05-06 17:42 ` Linus Torvalds
2008-05-06 20:28 ` Linus Torvalds
2008-05-06 16:44 ` J. Bruce Fields
2008-05-06 17:21 ` Andrew Morton
2008-05-06 17:31 ` Matthew Wilcox
2008-05-06 17:49 ` Ingo Molnar
2008-05-06 18:07 ` Andrew Morton
2008-05-11 11:11 ` Matthew Wilcox
2008-05-06 17:39 ` Ingo Molnar
2008-05-07 6:49 ` Zhang, Yanmin
2008-05-06 17:45 ` Linus Torvalds
2008-05-07 16:38 ` Matthew Wilcox
2008-05-07 16:55 ` Linus Torvalds
2008-05-07 17:08 ` Linus Torvalds
2008-05-07 17:16 ` Andrew Morton
2008-05-07 17:27 ` Linus Torvalds
2008-05-07 17:22 ` Ingo Molnar
2008-05-07 17:25 ` Ingo Molnar
2008-05-07 17:31 ` Linus Torvalds
2008-05-07 17:47 ` Linus Torvalds
2008-05-07 17:49 ` Ingo Molnar
2008-05-07 18:02 ` Linus Torvalds
2008-05-07 18:17 ` Ingo Molnar
2008-05-07 18:27 ` Linus Torvalds
2008-05-07 18:43 ` Ingo Molnar
2008-05-07 19:01 ` Linus Torvalds
2008-05-07 19:09 ` Ingo Molnar
2008-05-07 19:24 ` Matthew Wilcox
2008-05-07 19:44 ` Linus Torvalds
2008-05-07 20:00 ` Oi. NFS people. Read this Matthew Wilcox
2008-05-07 22:10 ` Trond Myklebust
2008-05-09 1:43 ` J. Bruce Fields
2008-05-08 3:24 ` AIM7 40% regression with 2.6.26-rc1 Zhang, Yanmin
2008-05-08 3:34 ` Linus Torvalds
2008-05-08 4:37 ` Zhang, Yanmin
2008-05-08 14:58 ` Linus Torvalds
2008-05-07 2:11 ` Zhang, Yanmin
2008-05-07 3:41 ` Zhang, Yanmin [this message]
2008-05-07 3:59 ` Andrew Morton
2008-05-07 4:46 ` Zhang, Yanmin
2008-05-07 6:26 ` Ingo Molnar
2008-05-07 6:28 ` Ingo Molnar
2008-05-07 7:05 ` Zhang, Yanmin
2008-05-07 11:00 ` Andi Kleen
2008-05-07 11:46 ` Matthew Wilcox
2008-05-07 12:21 ` Andi Kleen
2008-05-07 14:36 ` Linus Torvalds
2008-05-07 14:35 ` Alan Cox
2008-05-07 15:00 ` Linus Torvalds
2008-05-07 15:02 ` Linus Torvalds
2008-05-07 14:57 ` Andi Kleen
2008-05-07 15:31 ` Andrew Morton
2008-05-07 16:22 ` Matthew Wilcox
2008-05-07 15:19 ` Linus Torvalds
2008-05-07 17:14 ` Ingo Molnar
2008-05-08 2:44 ` Zhang, Yanmin
2008-05-08 3:29 ` Linus Torvalds
2008-05-08 4:08 ` Zhang, Yanmin
2008-05-08 4:17 ` Linus Torvalds
2008-05-08 12:01 ` [patch] speed up / fix the new generic semaphore code (fix AIM7 40% regression with 2.6.26-rc1) Ingo Molnar
2008-05-08 12:28 ` Ingo Molnar
2008-05-08 14:43 ` Ingo Molnar
2008-05-08 15:10 ` [git pull] scheduler fixes Ingo Molnar
2008-05-08 15:33 ` Adrian Bunk
2008-05-08 15:41 ` Ingo Molnar
2008-05-08 19:42 ` Adrian Bunk
2008-05-11 11:03 ` Matthew Wilcox
2008-05-11 11:14 ` Matthew Wilcox
2008-05-11 11:48 ` Matthew Wilcox
2008-05-11 12:50 ` Ingo Molnar
2008-05-11 12:52 ` Ingo Molnar
2008-05-11 13:02 ` Matthew Wilcox
2008-05-11 13:26 ` Matthew Wilcox
2008-05-11 14:00 ` Ingo Molnar
2008-05-11 14:18 ` Matthew Wilcox
2008-05-11 14:42 ` Ingo Molnar
2008-05-11 14:48 ` Matthew Wilcox
2008-05-11 15:19 ` Ingo Molnar
2008-05-11 15:29 ` Matthew Wilcox
2008-05-13 14:11 ` Ingo Molnar
2008-05-13 14:21 ` Matthew Wilcox
2008-05-13 14:42 ` Ingo Molnar
2008-05-13 15:28 ` Matthew Wilcox
2008-05-13 17:13 ` Ingo Molnar
2008-05-13 17:22 ` Linus Torvalds
2008-05-13 21:05 ` Ingo Molnar
2008-05-11 13:54 ` Ingo Molnar
2008-05-11 14:22 ` Matthew Wilcox
2008-05-11 14:32 ` Ingo Molnar
2008-05-11 14:46 ` Matthew Wilcox
2008-05-11 16:47 ` Linus Torvalds
2008-05-11 13:01 ` Ingo Molnar
2008-05-11 13:06 ` Matthew Wilcox
2008-05-11 13:45 ` Ingo Molnar
2008-05-11 14:10 ` Sven Wegener
2008-05-08 16:02 ` [patch] speed up / fix the new generic semaphore code (fix AIM7 40% regression with 2.6.26-rc1) Linus Torvalds
2008-05-08 18:30 ` Linus Torvalds
2008-05-08 20:19 ` Ingo Molnar
2008-05-08 20:27 ` Linus Torvalds
2008-05-08 21:45 ` Ingo Molnar
2008-05-08 22:02 ` Ingo Molnar
2008-05-08 22:55 ` Linus Torvalds
2008-05-08 23:07 ` Linus Torvalds
2008-05-08 23:14 ` Linus Torvalds
2008-05-08 23:16 ` Alan Cox
2008-05-08 23:33 ` Linus Torvalds
2008-05-08 23:27 ` Alan Cox
2008-05-09 6:50 ` Ingo Molnar
2008-05-09 8:29 ` Andi Kleen
2008-05-08 13:20 ` Matthew Wilcox
2008-05-08 15:01 ` Ingo Molnar
2008-05-08 13:56 ` Arjan van de Ven
2008-05-08 6:43 ` AIM7 40% regression with 2.6.26-rc1 Ingo Molnar
2008-05-08 6:48 ` Andrew Morton
2008-05-08 7:14 ` Zhang, Yanmin
2008-05-08 7:39 ` Ingo Molnar
2008-05-08 8:44 ` Zhang, Yanmin
2008-05-08 9:21 ` Ingo Molnar
2008-05-08 9:29 ` Ingo Molnar
2008-05-08 9:30 ` Zhang, Yanmin
2008-05-07 16:20 ` Ingo Molnar
2008-05-07 16:35 ` Linus Torvalds
2008-05-07 17:05 ` Ingo Molnar
2008-05-07 17:24 ` Linus Torvalds
2008-05-07 17:36 ` Ingo Molnar
2008-05-07 17:55 ` Linus Torvalds
2008-05-07 17:59 ` Matthew Wilcox
2008-05-07 18:17 ` Linus Torvalds
2008-05-07 18:49 ` Ingo Molnar
2008-05-07 13:59 ` Alan Cox
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1210131712.3453.43.camel@ymzhang \
--to=yanmin_zhang@linux.intel.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kernel@vger.kernel.org \
--cc=matthew@wil.cx \
--cc=mingo@elte.hu \
--cc=torvalds@linux-foundation.org \
--cc=viro@ftp.linux.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).