[CentOS] Kernel ELsmp vs EL

Fri Sep 8 02:59:10 UTC 2006
John Summerfield <debian at herakles.homelinux.org>

Jim Perrin wrote:
>>
>> Awesome... Next server has HT.. So I'll give that a try!
> 
> 
> Keep in mind that HT is its own special brand of hell, and isn't
> really *true* SMP. The kernel will work fine, and you'll see 2x the
> processors, but at most you'll get about a 3% performance boost, and
> at worst, it'll actually hurt performance. Some motherboards have
> buggy HT implementations and may cause some locking or slowness.
> Sometimes this can be resolved by appending apci=ht to your kernel
> boot line. With HT you also have the possibility of cache thrashing,
> which can/will impact performance. Make sure you know what you're
> getting into.
> 
> 

It's not all loss. I have a small benchmark written in Perl to exercise 
the CPU a little.
I have here two muts (machines under test),
Mopoke's a Dell Pentium IV 3.00 with HT enabled, running Suse 10.1.
Bilby's a Sempron 2500+, so it's a bit slower. Also, it's running 
roughly Nahant, so compiled with older (slower?) gcc and different perl.

What I'm illustrating here is the difference HT can make:


summer at Mopoke:~> time bm.perl&time bm.perl&wait
[1] 3480
[2] 3481

real    0m23.935s
user    0m23.689s
sys     0m0.004s

real    0m25.906s
user    0m24.746s
sys     0m0.004s
[1]-  Done                    time bm.perl
[2]+  Done                    time bm.perl
summer at Mopoke:~>
[summer at bilby ~]$ time bm.perl&time bm.perl&wait
[1] 10099
[2] 10100

real    0m49.343s
user    0m24.287s
sys     0m0.011s

real    0m49.371s
user    0m24.405s
sys     0m0.013s
[1]-  Done                    time bm.perl
[2]+  Done                    time bm.perl
[summer at bilby ~]$


Note that on mopoke, user for each is about equal to elapsed, about what 
one wout expect with dual-core or SMP.

On Bilby, user for each is about half elapsed, just as one would expect.

For those who like to play by themselves, here's the code:

[summer at bilby ~]$ cat bin/bm.perl
#!/usr/bin/perl
use integer;
$i = 0;
while ($i < 10000)
         {
                 $j = 0;
                 while ($j < 10000)
                         {
                                 ++$j;
                         }
                 ++$i;
         }

[summer at bilby ~]$







-- 

Cheers
John

-- spambait
1aaaaaaa at coco.merseine.nu  Z1aaaaaaa at coco.merseine.nu
Tourist pics http://portgeographe.environmentaldisasters.cds.merseine.nu/

Please do not reply off-list