Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 02 Oct 2007 21:52:33 +0900
From:      NIIMI Satoshi <sa2c@sa2c.net>
To:        Jeff Roberson <jroberson@chesapeake.net>
Cc:        freebsd-current@freebsd.org, freebsd-threads@freebsd.org
Subject:   Re: sched_yield() is very slow when other threads are busy on FreeBSD-current
Message-ID:  <47023F11.7000604@sa2c.net>
In-Reply-To: <20071002011337.Q6669@10.0.0.1>
References:  <46FD4B09.20006@sa2c.net> <20071002011337.Q6669@10.0.0.1>

next in thread | previous in thread | raw e-mail | index | archive | help
Hi,

Jeff Roberson wrote:
> Can you please try the enclosed patch and tell me if it addresses your 
> problem?

I've tested with SCHED_4BSD and SCHED_ULE.

7-CURRENT, SCHED_4BSD, HZ=100:
      81.14 real        80.32 user         0.00 sys
      80.85 real        80.03 user         0.00 sys
      82.37 real        81.54 user         0.00 sys

7-CURRENT, SCHED_4BSD, HZ=1000:
       3.06 real         2.84 user         0.00 sys
       3.08 real         2.87 user         0.00 sys
       3.00 real         2.80 user         0.01 sys

7-CURRENT, SCHED_ULE, HZ=100:
       9.03 real         8.93 user         0.00 sys
       1.68 real         1.67 user         0.00 sys
       9.13 real         9.04 user         0.00 sys

7-CURRENT, SCHED_ULE, HZ=1000:
       4.49 real         4.38 user         0.00 sys
       4.57 real         4.48 user         0.00 sys
       4.78 real         4.67 user         0.01 sys

6.2-RELEASE, SCHED_4BSD, HZ=100:
       0.55 real         0.55 user         0.00 sys
       0.54 real         0.54 user         0.00 sys
       0.60 real         0.60 user         0.00 sys

6.2-RELEASE, SCHED_4BSD, HZ=1000:
       0.29 real         0.29 user         0.00 sys
       0.27 real         0.26 user         0.00 sys
       0.28 real         0.28 user         0.00 sys

I picked up 3 medians of 5 tests since durations are not stable on
SCHED_ULE.

SCHED_ULE is much faster than before, but still slower than 6.2-RELEASE.
SCHED_4BSD is still very slow with small HZ.

Thanks,
-- 
NIIMI Satoshi



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?47023F11.7000604>