All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Zhang, Yanmin" <yanmin_zhang@linux.intel.com>
To: Ingo Molnar <mingo@elte.hu>
Cc: Nick Piggin <nickpiggin@yahoo.com.au>,
	Arjan van de Ven <arjan@infradead.org>,
	Andrew Morton <akpm@linux-foundation.org>,
	LKML <linux-kernel@vger.kernel.org>
Subject: Re: sched_yield: delete sysctl_sched_compat_yield
Date: Mon, 03 Dec 2007 17:29:30 +0800	[thread overview]
Message-ID: <1196674170.25646.121.camel@ymzhang> (raw)
In-Reply-To: <20071130100845.GB2201@elte.hu>

On Fri, 2007-11-30 at 11:08 +0100, Ingo Molnar wrote:
> * Nick Piggin <nickpiggin@yahoo.com.au> wrote:
> 
> > Haven't we been asking JVMs to use futexes or posix locking for years 
> > and years now? [...]
> 
> i'm curious, with what JVM was it tested and where's the source so i can 
> fix their locking for them? Can the problem be reproduced with:
> 
>   http://download.fedora.redhat.com/pub/fedora/linux/development/source/SRPMS/java-1.7.0-icedtea-1.7.0.0-0.20.b23.snapshot.fc9.src.rpm
I used BEA Jrockit to run volanoMark. Because of no Jrockit source codes, so
I retested volanoMark by jre-1.7.0-icedtea.x86_64 java of Fedora Core 8 on my stoakley (8-core)
machine with kernel 2.6.24-rc3.

1) Jrockit: sched_compat_yield=0's result is less than 15% of sched_compat_yield=1's.
2) jre-1.7.0-icedtea: sched_compat_yield=0's result is less than 89% of sched_compat_yield=1's.

So JVM really has much impact on the regression.

I checked the source codes of openjdk and found Thread.yield is implemented as native sched_yield.
If java applications call Thread.yield, it just calls sched_yield. garbage collection and other JVM
threads also calls Thread.yield. That's why 2 different JVM have different regression percentage.

Although no source codes of volanoMark, I suspect it calls Thread.sched. volanoMark is a kind
of chatroom benchmark. When a client sends out a message, server will send the message to all clients.
I suspect the client calls Thread.yield after sending out a couple of messages.

2 JVM all have regression if sched_compat_yield=0.

I ran some testing, such like iozone/specjbb/tbench/dbench/sysbench, and didn't see regression.

-yanmin


  parent reply	other threads:[~2007-12-03  9:30 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-27  9:33 sched_yield: delete sysctl_sched_compat_yield Zhang, Yanmin
2007-11-27 11:17 ` Ingo Molnar
2007-11-27 22:57 ` Arjan van de Ven
2007-11-30  2:46   ` Nick Piggin
2007-11-30  2:51     ` Arjan van de Ven
2007-11-30  3:02       ` Nick Piggin
2007-11-30  3:15     ` Zhang, Yanmin
2007-11-30  3:29       ` Nick Piggin
2007-11-30  4:32         ` Zhang, Yanmin
2007-11-30 10:08         ` Ingo Molnar
2007-12-03  4:27           ` Nick Piggin
2007-12-03  8:45             ` Ingo Molnar
2007-12-03  9:17               ` Nick Piggin
2007-12-03  9:35                 ` Zhang, Yanmin
2007-12-03  9:57                 ` Ingo Molnar
2007-12-03 10:15                   ` Nick Piggin
2007-12-03 10:33                     ` Ingo Molnar
2007-12-03 11:02                       ` Nick Piggin
2007-12-03 11:37                         ` Ingo Molnar
2007-12-03 17:04                           ` David Schwartz
2007-12-03 17:37                             ` Chris Friesen
2007-12-03 19:12                               ` David Schwartz
2007-12-03 19:56                                 ` Chris Friesen
2007-12-03 21:39                                   ` Mark Lord
2007-12-03 21:48                                     ` Ingo Molnar
2007-12-03 21:57                                       ` Mark Lord
2007-12-03 22:05                                         ` Ingo Molnar
2007-12-03 22:18                                           ` Mark Lord
2007-12-03 22:33                                             ` Ingo Molnar
2007-12-04  0:18                                               ` Nick Piggin
2007-12-04  0:30                                           ` David Schwartz
2007-12-04  2:09                                             ` Nick Piggin
2007-12-04  1:02                           ` Nick Piggin
2007-12-03  9:41               ` Zhang, Yanmin
2007-12-03 10:17                 ` Ingo Molnar
2007-12-03  9:29           ` Zhang, Yanmin [this message]
2007-12-03 10:05             ` Ingo Molnar
2007-12-04  6:40               ` Zhang, Yanmin

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=1196674170.25646.121.camel@ymzhang \
    --to=yanmin_zhang@linux.intel.com \
    --cc=akpm@linux-foundation.org \
    --cc=arjan@infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=nickpiggin@yahoo.com.au \
    /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 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.