1036a Long standing ULE scheduler problem with CPU intensive tasks - The FreeBSD Forums
The FreeBSD Forums  

Go Back   The FreeBSD Forums > Development > FreeBSD Development

FreeBSD Development Kernel development, writing drivers, coding, and questions regarding FreeBSD internals.

Reply
 
Thread Tools Display Modes
  #1  
Old August 20th, 2011, 11:02
hsn hsn is offline
Junior Member
 
Join Date: Mar 2011
Posts: 24
Thanks: 1
Thanked 0 Times in 0 Posts
Default Long standing ULE scheduler problem with CPU intensive tasks

ULE scheduler in 7.X and 8.X (maybe in 6 too) has one scenario where it performs really bad. I remember that oldest release of ULE worked in this scenario well (better than 4bsd) but all following ULE versions are really bad in this.

How to reproduce:
  1. run some CPU eating task on lowest priority (best for testing is distributed.net client, because it is included in ports)
  2. then compile something which is using autoconf ./configure script

You will notice huge performance drop due to background dnetc client. Compile (especially ./configure stuff) runs really slow. It should run on the same speed as without dnetc because intelligent scheduler will steal CPU time from dnetc in favor of compiling. Dnetc is running at nice level 20 after all.

ULE scheduler can be tuned via sysctl a bit but i was not able to do any significant improvement

Last edited by phoenix; August 22nd, 2011 at 17:31. Reason: Please format your posts!
Reply With Quote
  #2  
Old September 26th, 2011, 00:04
fidaj fidaj is offline
Junior Member
 
Join Date: Nov 2008
Posts: 49
Thanks: 9
Thanked 4 Times in 4 Posts
Default

Which CPU in your system where you done the tests?
Reply With Quote
  #3  
Old September 26th, 2011, 08:02
hsn hsn is offline
Junior Member
 
Join Date: Mar 2011
Posts: 24
Thanks: 1
Thanked 0 Times in 0 Posts
Default

single Intel (in vmware) and dualcore intel on real hw.
Reply With Quote
  #4  
Old September 26th, 2011, 08:16
fidaj fidaj is offline
Junior Member
 
Join Date: Nov 2008
Posts: 49
Thanks: 9
Thanked 4 Times in 4 Posts
Default

Quote:
Originally Posted by hsn View Post
single Intel (in vmware) and dualcore intel on real hw.
May cause performance degradation when the hyper-threading?
Try to disable hyper-threading and look at the changes ...
Code:
echo "machdep.hyperthreading_allowed=0" >> /boot/loader.conf
At one-core and dual-core processors performance on the ULE scheduler does not suit me too...
I had to use the scheduler for Core2Duo - 4BSD.
Reply With Quote
  #5  
Old September 26th, 2011, 08:17
hsn hsn is offline
Junior Member
 
Join Date: Mar 2011
Posts: 24
Thanks: 1
Thanked 0 Times in 0 Posts
Default

none of them supports HT. Did you tried my how-to repeat test?
Reply With Quote
  #6  
Old September 26th, 2011, 08:26
fidaj fidaj is offline
Junior Member
 
Join Date: Nov 2008
Posts: 49
Thanks: 9
Thanked 4 Times in 4 Posts
Default

Quote:
Originally Posted by hsn View Post
none of them supports HT. Did you tried my how-to repeat test?
I have a Core2Duo processor - it also does NOT support hyper-threading, but disabling hyper-threading allows the kernel to properly use the topology of my CPU...

I do not repeat your test, but I noticed the same problem with ULE on other tasks running on my laptop...
Reply With Quote
  #7  
Old September 26th, 2011, 09:25
fidaj fidaj is offline
Junior Member
 
Join Date: Nov 2008
Posts: 49
Thanks: 9
Thanked 4 Times in 4 Posts
Default

For ULE may have to do more and sysctl kern.sched.steal_htt=0 ...
Reply With Quote
  #8  
Old October 31st, 2011, 12:07
fidaj fidaj is offline
Junior Member
 
Join Date: Nov 2008
Posts: 49
Thanks: 9
Thanked 4 Times in 4 Posts
Default

Will it help in your case?
http://docs.freebsd.org/cgi/mid.cgi?...32817.35db5ccd
Reply With Quote
  #9  
Old October 31st, 2011, 13:40
hsn hsn is offline
Junior Member
 
Join Date: Mar 2011
Posts: 24
Thanks: 1
Thanked 0 Times in 0 Posts
Default

steal_htt to 0 didn't make any difference.

I will try patch after it will get integrated in v10.
Reply With Quote
Reply

Tags
ule

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[Solved] "CPU doesn't support long mode"? omgbsd Installing & Upgrading 8 July 12th, 2011 11:54
ULE in 8.1-STABLE and CPU topology jkcarrol General 9 November 6th, 2010 04:12
[Solved] cpu doesn't support long mode (8.1-RC2 in Linux/KVM) cmeerw Installing & Upgrading 3 July 19th, 2010 22:07
[Solved] Is routing 1000Mbs CPU intensive task? graudeejs Networking 18 July 3rd, 2010 15:16
CPU limit for jails under ULE scheduler kostjn FreeBSD Development 7 May 30th, 2009 09:59


All times are GMT +1. The time now is 02:23.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2013, vBulletin Solutions, Inc.
The mark FreeBSD is a registered trademark of The FreeBSD Foundation and is used by The FreeBSD Project with the permission of The FreeBSD Foundation.
Web protection and acceleration provided by CloudFlare
0