Re: ULE vs. 4BSD in RELENG_7



On Tue, 6 Nov 2007, Josh Carroll wrote:

That's expected due to the fuzzy rounding of 128 / 10, etc. Can you set
slice_min and slice both equal to 7 and see if the numbers come out
better than without the patch but with a slice value of 7? Basically I'm
trying to isolate the effects of the different slice handling in this
patch from the other changes.

Here are the results. Looks like setting slice_min and slice to 7
degraded performance for all work loads. Should I try any other
settings for slice and slice_min?

Josh, I had an interesting thought today. What if the reason 4BSD is faster is because it distributes load more evenly across all packages because it distributes randomly? ULE distributed across cores evenly but not packages. Can you try the attached patch? This also turns the default slice size down but does not contain the other context switch performance improvements.

Thanks,
Jeff


ffmpeg: 1:39.91

sysbench (4, 8, 12, 16 threads respectively):

2013.78
2157.6
2175.91
2184.16

And buildworld time: 14m7.517s

Thanks!
Josh
_______________________________________________
freebsd-performance@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-performance
To unsubscribe, send any mail to "freebsd-performance-unsubscribe@xxxxxxxxxxx"
Index: sched_ule.c
===================================================================
RCS file: /home/ncvs/src/sys/kern/sched_ule.c,v
retrieving revision 1.216
diff -u -r1.216 sched_ule.c
--- sched_ule.c 23 Oct 2007 00:52:24 -0000 1.216
+++ sched_ule.c 9 Nov 2007 23:01:21 -0000
@@ -1105,6 +1105,9 @@
* Look for an idle group.
*/
CTR1(KTR_ULE, "tdq_idle %X", tdq_idle);
+ cpu = ffs(tdq_idle & 0x5a5a5a5a);
+ if (cpu)
+ return (--cpu);
cpu = ffs(tdq_idle);
if (cpu)
return (--cpu);
@@ -1324,7 +1327,7 @@
* in case which sched_clock() called before sched_initticks().
*/
realstathz = hz;
- sched_slice = (realstathz/10); /* ~100ms */
+ sched_slice = (realstathz/15);
tickincr = 1 << SCHED_TICK_SHIFT;

/* Add thread0's load since it's running. */
_______________________________________________
freebsd-performance@xxxxxxxxxxx mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-performance
To unsubscribe, send any mail to "freebsd-performance-unsubscribe@xxxxxxxxxxx"

Relevant Pages

  • Re: ULE vs. 4BSD in RELENG_7
    ... fixes that and changes the min/max slice values to something more ... Slice min should be around 4 with a max of 12. ... Looks like things got a little worse with this patch. ... Basically I'm trying to isolate the effects of the different slice handling in this patch from the other changes. ...
    (freebsd-performance)
  • [PATCH 5/5 V2] [PPC] Setup stack memory segment for hugetlb pages
    ... Currently the memory slice that holds the process stack is always initialized ... This patch defines the weak function that is declared ... in the previos patch to convert the stack slice to hugetlb pages. ...
    (Linux-Kernel)
  • Re: ULE vs. 4BSD in RELENG_7
    ... slice_min and slice both equal to 7 and see if the numbers come out ... patch from the other changes. ... slice_min and slice set to 7 as I was seeing without the patch with ... those settings, and report back soon. ...
    (freebsd-performance)
  • Re: ULE vs. 4BSD in RELENG_7
    ... sysbench:: ... And buildworld: 13m47.052s ... I ran these after changing the slice value to 7 as well with this patch. ...
    (freebsd-performance)
  • Re: [PATCH] O17int
    ... >like shiploads of schedule() from the get time of day. ... cpu off to non-gui task who's going to use his full 100 ms slice, ... is to periodically check the head of all queues ...
    (Linux-Kernel)