1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Long standing ULE scheduler problem with CPU intensive tasks

Discussion in 'FreeBSD Development' started by hsn, Aug 20, 2011.

  1. hsn

    hsn New Member

    Messages:
    34
    Likes Received:
    0
    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
     
  2. fidaj

    fidaj New Member

    Messages:
    49
    Likes Received:
    0
    Which CPU in your system where you done the tests?
     
  3. hsn

    hsn New Member

    Messages:
    34
    Likes Received:
    0
    single Intel (in vmware) and dualcore intel on real hw.
     
  4. fidaj

    fidaj New Member

    Messages:
    49
    Likes Received:
    0
    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.
     
  5. hsn

    hsn New Member

    Messages:
    34
    Likes Received:
    0
    none of them supports HT. Did you tried my how-to repeat test?
     
  6. fidaj

    fidaj New Member

    Messages:
    49
    Likes Received:
    0
    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...
     
  7. fidaj

    fidaj New Member

    Messages:
    49
    Likes Received:
    0
    For ULE may have to do more and sysctl kern.sched.steal_htt=0 ...
     
  8. fidaj

    fidaj New Member

    Messages:
    49
    Likes Received:
    0
  9. hsn

    hsn New Member

    Messages:
    34
    Likes Received:
    0
    steal_htt to 0 didn't make any difference.

    I will try patch after it will get integrated in v10.