HyperThreading

2009-05-05 Thread APseudoUtopia
Hello,

I'm running FreeBSD 7.2-RELEASE on a dual-core Xeon. It has a custom
compiled SMP kernel, ACPI enabled, with the ULE scheduler.

I've been looking into HyperThreading, and I've come to the conclusion
that I should not use it. I've been told that HTT is disabled by
default, however sysctl and dmesg seems to contradict that:

CPU: Intel(R) Xeon(TM) CPU 2.40GHz (2395.93-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf29  Stepping = 9
  
Features=0xbfebfbff
  Features2=0x4400
  Logical CPUs per core: 2
FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP/HT): APIC ID:  1
 cpu2 (AP): APIC ID:  2
 cpu3 (AP/HT): APIC ID:  3
cpu0:  on acpi0
cpu1:  on acpi0
cpu2:  on acpi0
cpu3:  on acpi0
SMP: AP CPU #2 Launched!
SMP: AP CPU #3 Launched!
SMP: AP CPU #1 Launched!



machdep.hyperthreading_allowed: 1
hw.ncpu: 4
kern.smp.disabled: 0
kern.smp.active: 1


Am I correct to assume that the above means that HTT is enabled?
There is nothing in my loader.conf, sysctl.conf, or kernel config file
related to hyperthreading.

Thanks.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Hyperthreading question

2004-06-08 Thread Dwayne MacKinnon
Hi all,
I'm upgrading some machines from 4.8-RELEASE to 4.10-RELEASE. The 
machines in question are dual-processor xeon boxes. Now, my boss is 
adamant in that he doesn't want hyperthreading enabled on the machines.

In 4.8-RELEASE things were simple... I just didn't add the "options HTT" 
line to my kernel config file. In 4.10-RELEASE though, HTT is enabled by
default.

So, is there any way to shut off the hyperthreading? I've tried 
disabling it in the BIOS, and had no luck whatsoever.

Thanks,
DMK
PS: A direct reply would be welcome. I'm not subscribed to the mailing list.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Disabling Hyperthreading...

2005-10-16 Thread Deepak Naidu
Hi,
I have installed FreeBSD 5.4 on Dell PowerEdge
1750, which has Xeon processors.

I have recompiled the kernel with SMP support(should I
add any option in Kernelconf file to disable it)

When using top command I c 0123, processor it seems
hyper threading is enabled.

How do I disable it, or is it diabled 


Thanx for any advise.

Cheers,
Deepak Naidu.



___ 
To help you stay safe and secure online, we've developed the all new Yahoo! 
Security Centre. http://uk.security.yahoo.com
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Hyperthreading Issues

2007-05-19 Thread Dantavious
Hi.
It seems to me (From the limited knowledge that I have!) that my machine is 
not hyperthreading. I have done the following.

1. Ensured that the capability is enabled in the BIOS.

2.  FreeBSD recongizes the capaiblity
CPU: Intel(R) Pentium(R) 4 CPU 2.80GHz (1866.74-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf29  Stepping = 9
Features=0xbfebfbff
  Features2=0x4400>
 Logical CPUs per core: 2
real memory  = 1073676288 (1023 MB)
avail memory = 1033097216 (985 MB)
ACPI APIC Table: 
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1

3. The kernel is built for SMP

# SMP -- Generic kernel configuration file for FreeBSD/i386 SMP
#Use this for multi-processor machines
#
# $FreeBSD: src/sys/i386/conf/SMP,v 1.5.6.1 2005/09/18 03:37:58 scottl Exp $

include GENERIC1

ident   SMP-CUSTOM

# To make an SMP kernel, the next line is needed
options SMP # Symmetric MultiProcessor Kernel
device  atapicam

4. In the past top would show the 2 different logical CPUs working however, 
this is not the case anymore. 

Can anyone help we with this issue. I am using 6.2 release.
Thanks in advance.
Derrick
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: HyperThreading

2009-05-08 Thread Brian A. Seklecki
On Wed, 2009-05-06 at 02:20 -0400, APseudoUtopia wrote:
> Am I correct to assume that the above means that HTT is enabled?
> There is nothing in my loader.conf, sysctl.conf, or kernel config file
> related to hyperthreading.

Yes, you are correct.  Try:

% sudo ps gauxww 

Or 

% sudo top

You can see the currently assigned CPU for each proc/thread.

~BAS

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Hyperthreading hurts 5.3?

2005-01-11 Thread Timothy J. Luoma

summary: should I disable hypertheading in the  BIOS when running 5.3?

Background info:

I have a new Dell Dimension 3000 running 5.3.

I noticed some huge pauses when copying a large # of files across the 
network.  Googling around found some information about earlier versions of 
5.x and Hyperthreading being detrimenatl for performance. 

Whether or not it was the source of the network copy problem, I am trying 
to decide if I should disable Hyperthreading.

Iif YES, I wasn't clear if people meant "disable in BIOS" or just some 
configuration setting in a *.conf file.

(disabling HT will apparently mean I have to reinstall XP on the other 
drive.  Not necessarily a bad thing, as it is supposedly also the way to 
solve the problem of my modem causing a BSOD in XP)

thanks

TjL


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading question

2004-06-08 Thread Eugene Lee
On Tue, Jun 08, 2004 at 03:36:28PM -0400, Dwayne MacKinnon wrote:
: 
: I'm upgrading some machines from 4.8-RELEASE to 4.10-RELEASE. The 
: machines in question are dual-processor xeon boxes. Now, my boss is 
: adamant in that he doesn't want hyperthreading enabled on the machines.
: 
: In 4.8-RELEASE things were simple... I just didn't add the "options HTT" 
: line to my kernel config file. In 4.10-RELEASE though, HTT is enabled by
: default.
: 
: So, is there any way to shut off the hyperthreading? I've tried 
: disabling it in the BIOS, and had no luck whatsoever.

Hyperthreading is built into the kernel by default starting with
FreeBSD-4.9.  However, it is not enabled by default.  To do so,
do a "sysctl machdep.hlt_logical_cpus=0"

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


SMP vs. Hyperthreading?

2004-03-13 Thread a
Hi,

I've got a machine with a P4 that supports HTT (Hyperthreading) so I
thought about setting up a SMP-kernel.

Under 4.9 it seems to work (see excerpts from /var/log/messages
below), whereas on the same exact hardware under 5.2.1 I don't see two
virtual CPUs working. 

For a first check I've run "cpuburn" (i.e. burnP6). Under 4.9 with one
"cpuburn" process active "top" etc. show a cpu-load of about 50% which
for me means SMP/HTT is active.

Under 5.2.1 it's a different story though: /var/log/messages shows
that there are 2 CPUs but the message indicating the second CPU has
been launched is missing ("/kernel: SMP: AP CPU #1 Launched!"). When I
run a "cpuburn"-Test under 5.2.1 CPU load indicated by "top" shows
100% so I assume SMP/HTT is not active.


So my primary question is - how do I get SMP running under 5.2.1 with
a hyperthreading-capable P4??

Thanks much in advance for any clue,
-ewald

-- < Cut here > --

Excerpt from /var/log/messages - 4.9:


Mar 12 15:00:30 mybox /kernel: CPU: Intel(R) Pentium(R) 4 CPU 2.60GHz (2593.68-MHz 
686-class CPU)
Mar 12 15:00:30 mybox /kernel: Origin = "GenuineIntel"  Id = 0xf29  Stepping = 9
Mar 12 15:00:30 mybox /kernel: 
Features=0xbfebfbff
Mar 12 15:00:30 mybox /kernel: Hyperthreading: 2 logical CPUs
Mar 12 15:00:30 mybox /kernel: real memory  = 394264576 (385024K bytes)
Mar 12 15:00:30 mybox /kernel: avail memory = 377823232 (368968K bytes)
Mar 12 15:00:30 mybox /kernel: Changing APIC ID for IO APIC #0 from 1 to 2 in MP table
Mar 12 15:00:30 mybox /kernel: APIC_IO: MP table broken: 8259->APIC entry missing!
Mar 12 15:00:30 mybox /kernel: Changing APIC ID for IO APIC #0 from 0 to 2 on chip
Mar 12 15:00:30 mybox /kernel: Programming 24 pins in IOAPIC #0  
Mar 12 15:00:30 mybox /kernel: FreeBSD/SMP: Multiprocessor motherboard: 2 CPUs
Mar 12 15:00:30 mybox /kernel: cpu0 (BSP): apic id:  0, version: 0x00050014, at 
0xfee0
Mar 12 15:00:30 mybox /kernel: cpu1 (AP):  apic id:  1, version: 0x00050014, at 
0xfee0
...
Mar 12 15:00:30 mybox /kernel: SMP: AP CPU #1 Launched!

-- < Cut here > --

Excerpt from /var/log/messages - 5.2.1:

Mar 13 08:49:22 mybox kernel: CPU: Intel(R) Pentium(R) 4 CPU 2.60GHz (2593.68-MHz 
686-class CPU)
Mar 13 08:49:22 mybox kernel: Origin = "GenuineIntel"  Id = 0xf29  Stepping = 9
Mar 13 08:49:22 mybox kernel: 
Features=0xbfebfbff
Mar 13 08:49:22 mybox kernel: Hyperthreading: 2 logical CPUs
Mar 13 08:49:22 mybox kernel: real memory  = 394264576 (376 MB)
Mar 13 08:49:22 mybox kernel: avail memory = 376074240 (358 MB)
Mar 13 08:49:22 mybox kernel: MPTable:
Mar 13 08:49:22 mybox kernel: ioapic0: Changing APIC ID to 1
Mar 13 08:49:22 mybox kernel: ioapic0: Assuming intbase of 0
Mar 13 08:49:22 mybox kernel: ioapic0  irqs 0-23 on motherboard
Mar 13 08:49:22 mybox kernel: Pentium Pro MTRR support enabled
Mar 13 08:49:22 mybox kernel: cpu0 on motherboard
Mar 13 08:49:22 mybox kernel: npx0: [FAST]





___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Hyperthreading FreeBSD 4.9

2003-10-29 Thread John Palmer
I currently have FreeBSD 4.8 with hyperthreading enabled.  I just cvsup to 
the latest version of FreeBSD to 4.9.  When I do make buildkernel 
KERNCONF=FOO, I get an error of "unknown option "HTT""  Has hyperthreading 
been disabled in FreeBSD 4.9?

Thanks

JP

_
Enjoy MSN 8 patented spam control and more with MSN 8 Dial-up Internet 
Service.  Try it FREE for one month!   http://join.msn.com/?page=dept/dialup

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Disabling Hyperthreading...

2005-10-17 Thread Lowell Gilbert
Deepak Naidu <[EMAIL PROTECTED]> writes:

> I have installed FreeBSD 5.4 on Dell PowerEdge
> 1750, which has Xeon processors.
> 
> I have recompiled the kernel with SMP support(should I
> add any option in Kernelconf file to disable it)
> 
> When using top command I c 0123, processor it seems
> hyper threading is enabled.
> 
> How do I disable it, or is it diabled 

ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:09.htt.asc
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


enable smp / hyperthreading

2005-11-07 Thread jwl
Hi

I've just installed 6.0-RELASE and am trying to get SMP to work (I have af
Pentium 4 with HT). So I've compiled the kernel with 'options SMP' and
according to dmesg the two CPUs are found:

FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1

But I'm not sure that both are enabled, because at this is at the end of
dmesg and I dont see the other CPU being enabled somewhere:

SMP: AP CPU #1 Launched!

According to 'sysctl -a' there are 2 CPUs, but only 1 active and SMP
doesnt seem to be disabled:

kern.smp.cpus: 2
kern.smp.disabled: 0
kern.smp.active: 1

So I thought that it might help to but 'kern.smp.active=2' in
/boot/loader.conf, but after a reboot it is back to 1 again.

What am I missing here?

regards, Jeppe Larsen
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading Issues

2007-05-19 Thread JD Bronson

At 12:19 PM 5/19/2007 -0400, Dantavious wrote:

Hi.
It seems to me (From the limited knowledge that I have!) that my machine is
not hyperthreading. I have done the following.



maybe /etc/sysctl.conf:

machdep.hyperthreading_allowed=1


?

-JD 


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading Issues

2007-05-19 Thread Dantavious
On Saturday 19 May 2007 12:31:50 JD Bronson wrote:
> machdep.hyperthreading_allowed=1

That did it thanks.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Giorgos Keramidas
On 2005-01-11 19:52, "Timothy J. Luoma" <[EMAIL PROTECTED]> wrote:
>
> summary: should I disable hypertheading in the  BIOS when running 5.3?
> [...]
> If YES, I wasn't clear if people meant "disable in BIOS" or just some
> configuration setting in a *.conf file.

FWIW, that should be enough, as far as FreeBSD is concerned.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread David Kelly
On Jan 11, 2005, at 6:52 PM, Timothy J. Luoma wrote:
summary: should I disable hypertheading in the  BIOS when running 5.3?
Background info:
I have a new Dell Dimension 3000 running 5.3.
I noticed some huge pauses when copying a large # of files across the
network.  Googling around found some information about earlier 
versions of
5.x and Hyperthreading being detrimenatl for performance.

Whether or not it was the source of the network copy problem, I am 
trying
to decide if I should disable Hyperthreading.
IMO there are times where 5.3 doesn't schedule the CPU as fairly as one 
would like. Times I've suspected this were during aggressive file 
activity on a few large files. I have HT disabled due to earlier 
problems with the combination of SATA and vinum resulting in a trashed 
fs with a late version of 5.2.1. The benefits of HT are too few for me 
to risk trashing the fs now its full.

If you can reproduce your situation then I suggest disabling HT and see 
what happens. That's the only way anybody would know if HT is part of 
the problem or part of the solution.

Iif YES, I wasn't clear if people meant "disable in BIOS" or just some
configuration setting in a *.conf file.
In the BIOS.
(disabling HT will apparently mean I have to reinstall XP on the other
drive.
What does XP have to do with it? IIRC on Dell its F2 during the 
power-on diagnostics to reach the built-in BIOS config. That is where 
HT is to be disabled. Works exactly that way on my PowerEdge 400SC 2.8G 
P4. The only question is whether the key is F2 to get there or not. Was 
F2 this afternoon on my ancient Dell Optiplex 450 MHz P2 when I had to 
boot a DOS floppy to remap some bad blocks.

--
David Kelly N4HHE, [EMAIL PROTECTED]

Whom computers would destroy, they must first drive mad.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Chuck Swiger
Timothy J. Luoma wrote:
summary: should I disable hypertheading in the  BIOS when running 5.3?
It would certainly be worth trying this and seeing whether running as a purely 
single-proc system performs better for you.

It's not exactly as if HyperThreading evolved out of a sensible plan like 
"let's design a multi-core CPU intended for parallel execution, or something 
like a m56k DSP with VLIW", the situation is more like "Intel created the P4 
such a monsterously long pipeline that breaks x86 instructions into tiny u-ops 
which require a lot of functional units to be available, only the CPU still 
can't schedule things to use all of the available units much of the time, 
anyway, so hey, maybe we could run another processing thread on 'em and hope 
the additional work it can do outweighs the additional CPU resource contention 
and the additional overhead of doing SMP..."

[ I have a non-HT P4 (a [EMAIL PROTECTED] Northwood) around, but I doubt I'd turn 
HT on with it even if it could.  I'd rather use an AMD-64, or a G5, or even a 
recent P3 (Tualatin/Pentium-M) than another hyperthermal P4 spaceheater. ]

Bah, I'm rambling, time to stop... :-)
--
-Chuck
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Chuck Swiger
David Kelly wrote:
(disabling HT will apparently mean I have to reinstall XP on the other
drive.
What does XP have to do with it? IIRC on Dell its F2 during the power-on 
diagnostics to reach the built-in BIOS config. That is where HT is to be 
disabled.
If you install and configure many flavors of Windows on a SMP system, that 
installation will not work if you move that image to a uni-proc system by 
swapping disks or otherwise removing CPU's (ie, by turning off HT'ing).  I 
last saw this with a Win2K system, which immediately blue-screened with an 
"invalid SMP HAL" error very early in the boot.

[ It doesn't surprise me that one would want or have to reinstall XP after 
disabling HyperThreading.  There exist even less comprehensible reasons which 
oblige people to reinstall Windows ]

--
-Chuck
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread David Kelly
On Jan 11, 2005, at 9:18 PM, Chuck Swiger wrote:
David Kelly wrote:
(disabling HT will apparently mean I have to reinstall XP on the 
other
drive.
What does XP have to do with it? IIRC on Dell its F2 during the 
power-on diagnostics to reach the built-in BIOS config. That is where 
HT is to be disabled.
If you install and configure many flavors of Windows on a SMP system, 
that installation will not work if you move that image to a uni-proc 
system by swapping disks or otherwise removing CPU's (ie, by turning 
off HT'ing).  I last saw this with a Win2K system, which immediately 
blue-screened with an "invalid SMP HAL" error very early in the boot.
OK, that makes Microsoft-logic sense. Had it in my head that he was 
saying the need to reinstall XP on a HD was to have a utility to toggle 
the HT bit in BIOS.

OTOH I've heard of others toggling the HT bit but don't remember 
anything about having to reinstall XP. Last I had a similar dealing was 
with NT4SP4, possibly with the "upgrade" to NT4SP6 when I somehow lost 
one of my 450 MHz CPU's. Found instructions on how to revive the 2nd 
CPU but left it alone as it was far better for the company server to be 
running on one CPU than the risk of damaging the install worse than it 
already was.

Last time I had to reinstall NT4SP6 it took 3 days of patch, reboot, 
repeat, before the OS install was complete.

Decided it was time for a clean wipe installation on my laptop when 
Panther was released. Believe it took 15 minutes. About the same for a 
text-only installation of FreeBSD on my Dell Optiplex.

--
David Kelly N4HHE, [EMAIL PROTECTED]

Whom computers would destroy, they must first drive mad.


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Timothy Luoma
On Jan 11, 2005, at 8:43 PM, Giorgos Keramidas wrote:
On 2005-01-11 19:52, "Timothy J. Luoma" <[EMAIL PROTECTED]> wrote:
summary: should I disable hypertheading in the  BIOS when running 5.3?
[...]
If YES, I wasn't clear if people meant "disable in BIOS" or just some
configuration setting in a *.conf file.
FWIW, that should be enough, as far as FreeBSD is concerned.
sorry to be dense, but which should be enough, BIOS or conf file?
is the default to use or not use hyperthreading in the kernel/conf?
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Bryan Fullerton
On Tue, 11 Jan 2005 23:52:11 -0500, Timothy Luoma <[EMAIL PROTECTED]> wrote:
> 
> sorry to be dense, but which should be enough, BIOS or conf file?
> 
> is the default to use or not use hyperthreading in the kernel/conf?

By default the system will detect a HTT processor, but can only launch
the second 'virtual' CPU core if you recompile the kernel with the SMP
option enabled.

I'm personally unclear why it'd be necessary to disable HTT in the
BIOS if you're using a non-SMP kernel on a uniproc box.

I'm experiencing some strangeness with a uniproc HTT-capable machine
and SATA with either SMP or non-SMP kernels, so I'll try turning off
HTT in the BIOS later this week and see if that helps.

Bryan
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Olivier Nicole
> I'm personally unclear why it'd be necessary to disable HTT in the
> BIOS if you're using a non-SMP kernel on a uniproc box.

Maybe for the same reason you should better not use a non-SMP kernel
if you have 2 CPU in your box.

Try to keep hardware (BIOS) and OS consistent, even if they are
supposed to know how to deal with inconsistencies.

Olkivier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Anthony Atkielski
Olivier Nicole writes:

ON> Maybe for the same reason you should better not use a non-SMP kernel
ON> if you have 2 CPU in your box.

Is a hyperthreading CPU identical to a second CPU from the software's
standpoint?  If not, what are the differences?

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Olivier Nicole
> Is a hyperthreading CPU identical to a second CPU from the software's
> standpoint?  If not, what are the differences?

I am not sure, but it is some how detected as 2 CPUs

FreeBSD/SMP: Multiprocessor System Detected: 4 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
 cpu2 (AP): APIC ID:  6
 cpu3 (AP): APIC ID:  7
 

Olivier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Jonathan Chen
On Wed, Jan 12, 2005 at 12:02:37AM -0500, Bryan Fullerton wrote:
> On Tue, 11 Jan 2005 23:52:11 -0500, Timothy Luoma <[EMAIL PROTECTED]> wrote:
> > 
> > sorry to be dense, but which should be enough, BIOS or conf file?
> > 
> > is the default to use or not use hyperthreading in the kernel/conf?
> 
> By default the system will detect a HTT processor, but can only launch
> the second 'virtual' CPU core if you recompile the kernel with the SMP
> option enabled.

Not true on 5.3+ GENERIC systems. If you look at dmesg, you'll see the
second virtual CPU launched as well as the extra column in top(1) if
you enable HTT in the BIOS.
-- 
Jonathan Chen <[EMAIL PROTECTED]>
--
  Jesus saves.
   Allah forgives.
 Cthulu thinks you'd make a nice sandwich.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Timothy Luoma
On Jan 11, 2005, at 9:09 PM, David Kelly wrote:
The benefits of HT are too few for me to risk trashing the fs now its 
full.
That's a good enough reason for me.
Iif YES, I wasn't clear if people meant "disable in BIOS" or just some
configuration setting in a *.conf file.
In the BIOS.
Thanks...
(disabling HT will apparently mean I have to reinstall XP on the other
drive.
What does XP have to do with it?
Sorry to be unclear, XP is on the other drive.  I called Creative Tech 
Support today to inquire why XP might die (BSOD) immediately on driver 
install for the serial port modem I bought from them.  He immediately 
diagnosed this as a machine with HT enabled, and said that the way that 
IRQs are assigned is "different".  (Someone else told me that Creative 
released new drivers but they hadn't helped.)

He said the only way to use the modem would be to a) get a USB version 
[which I assumed wouldn't work well with FreeBSD] or b) disable HT, but 
because XP installs itself "differently" if it senses a 
"multiprocessor" I would have to reinstall.

IIRC on Dell its F2 during the power-on diagnostics to reach the 
built-in BIOS config. That is where HT is to be disabled. Works 
exactly that way on my PowerEdge 400SC 2.8G P4. The only question is 
whether the key is F2 to get there or not. Was F2 this afternoon on my 
ancient Dell Optiplex 450 MHz P2 when I had to boot a DOS floppy to 
remap some bad blocks.
Yup, mine is the same way.  Shows "Setup F2" in initial flash screen 
(and F12 for 'boot menu' which, among other things, will let you 
manually boot from a 2nd hard drive, which is nice in case the OS on 
your 1st hard drive overwrites the MBR on reinstall (*cough like 
Windows cough*).

[just arrived]
On Jan 11, 2005, at 10:18 PM, Chuck Swiger wrote:
[ It doesn't surprise me that one would want or have to reinstall XP 
after disabling HyperThreading.  There exist even less comprehensible 
reasons which oblige people to reinstall Windows ]
Well I may reinstall Windows for other reasons, including setting up a 
FAT32 partition that I can access r/w from FreeBSD and to fix the modem 
problem... not to mention the fact that Dell installs all this crap by 
default such as McAfee Virus Scanner (which is basically just an 
attempt to get people to buy it when it "expires").

Reinstalling Windows is so common I can now pretty much time the few 
steps I have to go interactive with it without it a) sitting idle or b) 
taking me away from getting real work done.

TjL
ps - thanks to all who responded.  I'm going to disable HT, boot to 
FreeBSD and try another large file transfer and see if I see the large 
delays.  If no, I'll copy the files I need off the XP drive and 
reinstall XP.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-11 Thread Anthony Atkielski
Jonathan Chen writes:

JC> Not true on 5.3+ GENERIC systems. If you look at dmesg, you'll see the
JC> second virtual CPU launched as well as the extra column in top(1) if
JC> you enable HTT in the BIOS.

Well, now I'm confusing.  I have an Asus P4P800-E Deluxe MB with an
Intel P4 processor mounted on it, and dmesg looks like this:

FreeBSD 5.3-RELEASE #1: Mon Dec 27 05:52:34 CET 2004
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/FREEBIE
ACPI APIC Table: 
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: Intel(R) Pentium(R) 4 CPU 3.00GHz (2998.57-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf34  Stepping = 4
  
Features=0xbfebfbff
  Hyperthreading: 2 logical CPUs
real memory  = 1073414144 (1023 MB)
avail memory = 1045057536 (996 MB)
ioapic0: Changing APIC ID to 2
ioapic0  irqs 0-23 on motherboard
npx0: [FAST]
npx0:  on motherboard
npx0: INT 16 interface
acpi0:  on motherboard
acpi0: Power Button (fixed)
Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x808-0x80b on acpi0
cpu0:  on acpi0
pcib0:  port 0xcf8-0xcff on acpi0
pci0:  on pcib0
agp0:  mem 0xf800-0xfbff at device 0.0 
on pci0
pcib1:  at device 1.0 on pci0
pcib1: could not get PCI interrupt routing table for \\_SB_.PCI0.P0P1 - 
AE_NOT_FOUND
pci1:  on pcib1
pci1:  at device 0.0 (no driver attached)
[...]

Do I have two processors or not?  The BIOS says that hyperthreading is
enabled (and it wouldn't say anything at all if the processor were not
HT-capable, according to the manual).

Where's the second logical processor?  I recompiled my own kernel but I
didn't modify any of the CPU stuff (I don't think).

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Giorgos Keramidas
On 2005-01-11 23:52, Timothy Luoma <[EMAIL PROTECTED]> wrote:
>On Jan 11, 2005, at 8:43 PM, Giorgos Keramidas wrote:
>>On 2005-01-11 19:52, "Timothy J. Luoma" <[EMAIL PROTECTED]> wrote:
>>>
>>> summary: should I disable hypertheading in the  BIOS when running 5.3?
>>> [...]
>>> If YES, I wasn't clear if people meant "disable in BIOS" or just some
>>> configuration setting in a *.conf file.
>>
>> FWIW, that should be enough, as far as FreeBSD is concerned.
>
> sorry to be dense, but which should be enough, BIOS or conf file?

Oh, sorry about that.  I must have beel sleepy when I replied and missed
that there were two questions there.  I meant that disabling HT from the
BIOS setup should be enough for FreeBSD too.

> is the default to use or not use hyperthreading in the kernel/conf?

AFAICT from reading /usr/src/sys/i386/i386/mp_machdep.c, hyper-threading
support is always enabled in FreeBSD if it is also enabled in the BIOS.

The mp_topology() function contains, among other stuff:

   222  void
   223  mp_topology(void)
   224  {
   225  struct cpu_group *group;
   226  int logical_cpus;
   227  int apic_id;
   228  int groups;
   229  int cpu;
   230
   231  /* Build the smp_topology map. */
   232  /* Nothing to do if there is no HTT support. */
   233  if ((cpu_feature & CPUID_HTT) == 0)
   234  return;
   235  logical_cpus = (cpu_procinfo & CPUID_HTT_CORES) >> 16;
   236  if (logical_cpus <= 1)
   237  return;

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Scott Bennett
 On Wed, 12 Jan 2005 06:21:18 +0100 Anthony Atkielski
<[EMAIL PROTECTED]> wrote:

>Olivier Nicole writes:
>
>ON> Maybe for the same reason you should better not use a non-SMP kernel
>ON> if you have 2 CPU in your box.
>
>Is a hyperthreading CPU identical to a second CPU from the software's
>standpoint?  If not, what are the differences?
>
 Well, no, not exactly.  The dual-cored CPUs share certain resources
on the chip that are not shared in a multi-CPU situation, and that sharing
means certain operations have to be handled differently.  An MP setup has
separate cache and TLB managment in each CPU, whereas P4 w/HT logical
processors share this memory management circuitry.  Alteration of a cache
line requires notification of the other processor(s) in an MP situation to
mark any corresponding line in its(their) cache(s) because multiple separate
caches are involved, but notification is not necessary in the P4 w/HT situation
because it's the same cache being seen by both logical processors.
 Alteration/invalidation of TLB entries requires notification to
invalidate in an MP, so that the other CPU(s) can purge any corresponding TLB
entries it(they) may have, but notification is not required in the P4 w/HT
situation because both logical processors are refering to the same TLB.  Again,
unnecessary purging would be a performance hit.
 There must be some special handling of TLB entries in the P4 w/HT that
I haven't seen documented.  (There almost certainly is documentation; I just
haven't seen it yet.)  There must be some way to distinguish between TLB
entries filled per orders of one logical processor from those filled per
orders of the other logical processor.  If there weren't, then one logical
processor would use TLB entries for the address space running on the other
logical processor, which would, of course, be Very Bad.  But, to improve
performance, there should be some way to share TLBs for the case of two
threads running concurrently in the same address space.  If anyone reading
this knows the details of how this is handled in these chips, please post them
here.


  Scott Bennett, Comm. ASMELG, CFIAG
**
* Internet:   bennett at cs.niu.edu  *
**
* "A well regulated and disciplined militia, is at all times a good  *
* objection to the introduction of that bane of all free governments *
* -- a standing army."   *
*-- Gov. John Hancock, New York Journal, 28 January 1790 *
**
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Giorgos Keramidas
On 2005-01-12 07:20, Anthony Atkielski <[EMAIL PROTECTED]> wrote:
> Jonathan Chen writes:
> JC> Not true on 5.3+ GENERIC systems. If you look at dmesg, you'll see the
> JC> second virtual CPU launched as well as the extra column in top(1) if
> JC> you enable HTT in the BIOS.
>
> Well, now I'm confusing.  I have an Asus P4P800-E Deluxe MB with an
> Intel P4 processor mounted on it, and dmesg looks like this:
>
> FreeBSD 5.3-RELEASE #1: Mon Dec 27 05:52:34 CET 2004
> [EMAIL PROTECTED]:/usr/obj/usr/src/sys/FREEBIE
> ACPI APIC Table: 
> Timecounter "i8254" frequency 1193182 Hz quality 0
> CPU: Intel(R) Pentium(R) 4 CPU 3.00GHz (2998.57-MHz 686-class CPU)
>   Origin = "GenuineIntel"  Id = 0xf34  Stepping = 4
>   
> Features=0xbfebfbff
>   Hyperthreading: 2 logical CPUs
> real memory  = 1073414144 (1023 MB)
> avail memory = 1045057536 (996 MB)
> ioapic0: Changing APIC ID to 2
> ioapic0  irqs 0-23 on motherboard
> npx0: [FAST]
> npx0:  on motherboard
> npx0: INT 16 interface
> acpi0:  on motherboard
> acpi0: Power Button (fixed)
> Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
> acpi_timer0: <24-bit timer at 3.579545MHz> port 0x808-0x80b on acpi0
> cpu0:  on acpi0
> pcib0:  port 0xcf8-0xcff on acpi0
> pci0:  on pcib0
> agp0:  mem 0xf800-0xfbff at device 
> 0.0 on pci0
> pcib1:  at device 1.0 on pci0
> pcib1: could not get PCI interrupt routing table for \\_SB_.PCI0.P0P1 - 
> AE_NOT_FOUND
> pci1:  on pcib1
> pci1:  at device 0.0 (no driver attached)
> [...]
>
> Do I have two processors or not?  The BIOS says that hyperthreading is
> enabled (and it wouldn't say anything at all if the processor were not
> HT-capable, according to the manual).
>
> Where's the second logical processor?  I recompiled my own kernel but I
> didn't modify any of the CPU stuff (I don't think).

You need to enable SMP too, to allow the FreeBSD kernel to use the
second (hyper-threaded) CPU.

My workstation is a P4 @ 2800, which does support HTT, but I haven't
enabled SMP in my kernel configuration, so it is not used:

% # grep 'options[[:space:]]*SMP' /usr/src/sys/conf/NOTES
% options SMP # Symmetric MultiProcessor Kernel
% # grep 'options[[:space:]]*SMP' \
%   /usr/src/sys/`uname -m`/conf/`uname -v | sed -e 's:.*/::' `
% # dmesg
% Copyright (c) 1992-2005 The FreeBSD Project.
% Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
% The Regents of the University of California. All rights reserved.
% FreeBSD 6.0-CURRENT #0: Tue Jan 11 17:03:06 EET 2005
% [EMAIL PROTECTED]:/usr/obj/usr/src/sys/ORION
% WARNING: WITNESS option enabled, expect reduced performance.
% Timecounter "i8254" frequency 1193182 Hz quality 0
% CPU: Intel(R) Pentium(R) 4 CPU 2.80GHz (2806.37-MHz 686-class CPU)
%   Origin = "GenuineIntel"  Id = 0xf33  Stepping = 3
%   Features=0xbfebfbff
%   Hyperthreading: 2 logical CPUs
% real memory  = 468647936 (446 MB)
% avail memory = 449392640 (428 MB)
% npx0: [FAST]
% npx0:  on motherboard
% npx0: INT 16 interface
% acpi0:  on motherboard
% acpi0: Power Button (fixed)
% Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
% acpi_timer0: <32-bit timer at 3.579545MHz> port 0x4008-0x400b on acpi0
% cpu0:  on acpi0
% acpi_button0:  on acpi0
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Giorgos Keramidas
On 2005-01-11 22:18, Chuck Swiger <[EMAIL PROTECTED]> wrote:
>David Kelly wrote:

>>> (disabling HT will apparently mean I have to reinstall XP on the
>>> other drive.
>>
>> What does XP have to do with it? IIRC on Dell its F2 during the
>> power-on diagnostics to reach the built-in BIOS config. That is where
>> HT is to be disabled.
>
> If you install and configure many flavors of Windows on a SMP system,
> that installation will not work if you move that image to a uni-proc
> system by swapping disks or otherwise removing CPU's (ie, by turning
> off HT'ing).  I last saw this with a Win2K system, which immediately
> blue-screened with an "invalid SMP HAL" error very early in the boot.

Moving a disk with Windows installed on it to another system has other
problems too, although they are not (in general) as serious.

Since the user doesn't have the source, many options are 'tuned by the
installation process' to the system Windows is installed on.  So it
doesn't sound as surprising that it would require a reinstall when HTT
is toggled :-)

> [ It doesn't surprise me that one would want or have to reinstall XP after
> disabling HyperThreading.  There exist even less comprehensible reasons
> which oblige people to reinstall Windows ]

True.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Giorgos Keramidas writes:

GK> You need to enable SMP too, to allow the FreeBSD kernel to use the
GK> second (hyper-threaded) CPU.

I found it, in a file called SMP.  Why is the SMP option tucked away in
a separate file?

I stuck this into the config and rebuilt the kernel. Seems to run fine.
I see that top has a C column now, and running a program in a continuous
loop takes up exactly 50% of the machine (and two such programs take up
exactly 100%), according to top.

Boot messages looked a bit different:

The Regents of the University of California. All rights reserved.
FreeBSD 5.3-RELEASE #0: Wed Jan 12 17:55:18 CET 2005


   
[EMAIL PROTECTED]:/usr/obj/usr/src/sys/FREEBIE-SMP  


  
Timecounter "i8254" frequency 1193182 Hz quality 0  


   
CPU: Intel(R) Pentium(R) 4 CPU 3.00GHz (2998.57-MHz 686-class CPU)  


   
Origin = "GenuineIntel"  Id = 0xf34  Stepping = 4   


   
Features=0xbfebfbff

    
  
Hyperthreading: 2 logical CPUs  


   
real memory  = 1073414144 (1023 MB) 


   
avail memory = 1045061632 (996 MB)  


   
ACPI APIC Table:   


   
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs 


   
cpu0 (BSP): APIC ID:  0 


   
cpu1 (AP): APIC ID:  1  


   
[...]
cpu0:  on acpi0
cpu1:  on acpi0 
[...]
SMP: AP CPU #1 Launched!

So I guess it's all working now.  That was easy.

I imagine this will give me a bit more horsepower for the buck,
although--with only 0.2% of the machine busy under normal load even with
a single processor--I guess I wasn't exactly processor-bound to begin
with (I'd run out of I/O capacity long before running out of processor).
But why not profit from what's there, eh?

-- 
Anthony


___

Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Scott Bennett writes:

SB>  Well, no, not exactly.  The dual-cored CPUs share certain resources
SB> on the chip that are not shared in a multi-CPU situation, and that sharing
SB> means certain operations have to be handled differently.  An MP setup has
SB> separate cache and TLB managment in each CPU ...

What's TLB?

SB> ... whereas P4 w/HT logical processors share this memory management
SB> circuitry. Alteration of a cache line requires notification of the
SB> other processor(s) in an MP situation to mark any corresponding line
SB> in its(their) cache(s) because multiple separate caches are
SB> involved, but notification is not necessary in the P4 w/HT situation
SB> because it's the same cache being seen by both logical processors.
SB>  Alteration/invalidation of TLB entries requires notification to
SB> invalidate in an MP, so that the other CPU(s) can purge any corresponding 
TLB
SB> entries it(they) may have, but notification is not required in the P4 w/HT
SB> situation because both logical processors are refering to the same TLB.  
Again,
SB> unnecessary purging would be a performance hit.
SB>  There must be some special handling of TLB entries in the P4 w/HT that
SB> I haven't seen documented.  (There almost certainly is documentation; I just
SB> haven't seen it yet.)  There must be some way to distinguish between TLB
SB> entries filled per orders of one logical processor from those filled per
SB> orders of the other logical processor.  If there weren't, then one logical
SB> processor would use TLB entries for the address space running on the other
SB> logical processor, which would, of course, be Very Bad.  But, to improve
SB> performance, there should be some way to share TLBs for the case of two
SB> threads running concurrently in the same address space.  If anyone reading
SB> this knows the details of how this is handled in these chips, please post 
them
SB> here.

From what you say and from what I've read today, it sounds like
hyperthreading comes close to providing two separate processors for
heterogenous system loads (where each hyperthread is using slightly
different processor resources at any given instant), but it may not buy
much of anything for massively parallel compute-bound work, since both
threads may want nearly the same things at the same time and will thus
effectively be forced to spend a lot of time waiting for each other.

Fortunately, my server has a very mixed load, as one would expect for a
generic domain server, so hopefully it will profit from hyperthreading.

And hopefully no weird stuff will happen because I've turned on HT
(although offhand I'm not sure what would happen, unless there are
hidden hardware conflicts or something specific and software-visible
about HT in normal operation that might expose a bug).  I'm not sure
that I see how HT could affect Serial ATA disks, for example, any more
than having two separate physical processors would.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Giorgos Keramidas
On 2005-01-12 18:41, Anthony Atkielski <[EMAIL PROTECTED]> wrote:
> Giorgos Keramidas writes:
>
> GK> You need to enable SMP too, to allow the FreeBSD kernel to use the
> GK> second (hyper-threaded) CPU.
>
> I found it, in a file called SMP.  Why is the SMP option tucked away in
> a separate file? [...]

The 'separate file' is NOTES.  This file is actually the complete
reference of options that the kernel supports, so it's not like the SMP
option is hidden or something.

> I imagine this will give me a bit more horsepower for the buck,
> although--with only 0.2% of the machine busy under normal load even with
> a single processor--I guess I wasn't exactly processor-bound to begin
> with (I'd run out of I/O capacity long before running out of processor).
> But why not profit from what's there, eh?

Because it's not always a 'profit'.

The locking and synchronization overhead is not always negligible.
Please, read the rest of the thread too :-)

- Giorgos

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Giorgos Keramidas writes:

GK> The 'separate file' is NOTES.  This file is actually the complete
GK> reference of options that the kernel supports, so it's not like the SMP
GK> option is hidden or something.

I must have a magic special version of FreeBSD:

# cd /usr/src/sys/i386/conf
# grep SMP *
NOTES:# SMP OPTIONS:
NOTES:# The apic device can be used in both UP and SMP kernels, but is required
NOTES:# for SMP kernels.  Thus, the apic device is not strictly an SMP option,
NOTES:# but it is a prerequisite for SMP.
NOTES:# Be sure to disable 'cpu I386_CPU' for SMP kernels.
NOTES:# Enabling this with an SMP kernel will cause the kernel to be unusable.
NOTES:options   I4B_SMP_WORKAROUND
SMP:# SMP -- Generic kernel configuration file for FreeBSD/i386 SMP
SMP:# $FreeBSD: src/sys/i386/conf/SMP,v 1.5.4.1 2004/10/23 20:04:00 kensmith 
Exp $
SMP:options SMP
#

The "options SMP" appears only in a file called SMP on my system.

GK> Because it's not always a 'profit'.
GK>
GK> The locking and synchronization overhead is not always negligible.

My experience with multiprocessing on other systems is that this
overhead is rarely an issue.  For single-threaded compute-bound user
processes and occasionally for some similarly-designed OS processes it
sometimes makes a difference; usually there's a net gain, though.

At some specific number of processors (often 5 or more, but it depends
on many things), the additional overhead associated with managing yet
another processor (including hardware and software contention) causes
global performance to diminish rather than increase.  But I'd be very
surprised to see that on any OS or platform with only two processors.

There are also some key advantages to having more than one processor,
such as the fact that the system is much more likely to remain
responsive if a (typical single-threaded) process gets stuck in a loop.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Bryan Fullerton
On Wed, 12 Jan 2005 18:29:01 +1300, Jonathan Chen <[EMAIL PROTECTED]> wrote:
> On Wed, Jan 12, 2005 at 12:02:37AM -0500, Bryan Fullerton wrote:
> > By default the system will detect a HTT processor, but can only launch
> > the second 'virtual' CPU core if you recompile the kernel with the SMP
> > option enabled.
> 
> Not true on 5.3+ GENERIC systems. If you look at dmesg, you'll see the
> second virtual CPU launched as well as the extra column in top(1) if
> you enable HTT in the BIOS.

You are incorrect. There is no SMP option in the 5.3-R i386 GENERIC
config file as distributed.

Other platforms (sparc64 and alpha) do ship with SMP enabled by
default. They're not using HTT, though, so are irrelevant to this
discussion.

Bryan
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Bryan Fullerton
On Wed, 12 Jan 2005 00:02:37 -0500, Bryan Fullerton <[EMAIL PROTECTED]> wrote:
 > I'm experiencing some strangeness with a uniproc HTT-capable machine
> and SATA with either SMP or non-SMP kernels, so I'll try turning off
> HTT in the BIOS later this week and see if that helps.

Well, this is interesting. I disabled HTT in the BIOS and rebooted
with a SMP kernel. As expected, there is only one CPU available after
boot. However, FreeBSD still detects that the CPU is HTT-capable and
prints the following in dmesg output:

CPU: Intel(R) Pentium(R) 4 CPU 2.80GHz (2793.01-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf33  Stepping = 3
Features=0xbfebfbff
  Hyperthreading: 2 logical CPUs

If my sig11 issue doesn't recur now that HTT is off I'll go back to a
non-SMP kernel and confirm there are no issues there too.

Bryan
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Giorgos Keramidas
On 2005-01-12 19:23, Anthony Atkielski <[EMAIL PROTECTED]> wrote:
> Giorgos Keramidas writes:
>
> GK> The 'separate file' is NOTES.  This file is actually the complete
> GK> reference of options that the kernel supports, so it's not like the SMP
> GK> option is hidden or something.
>
> I must have a magic special version of FreeBSD:
>
> # cd /usr/src/sys/i386/conf
> # grep SMP *
> NOTES:# SMP OPTIONS:

Look in /usr/src/sys/conf/NOTES too.  The machine independent kernel
options are listed there, instead of the machine-dependent NOTES file.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Andrea Venturoli
Anthony Atkielski wrote:
From what you say and from what I've read today, it sounds like
hyperthreading comes close to providing two separate processors for
heterogenous system loads (where each hyperthread is using slightly
different processor resources at any given instant), but it may not buy
much of anything for massively parallel compute-bound work,
FWIW I tried numerical computations on a P4 with HT enabled: I expected 
using 2 threads might give *at least slightly* better results, but I 
could come to the conclusion that with 1, 2 or 4 threads the performance 
gain (or loss) was exactly zero.
(BTW, an old AMD 2000 XP+ would in any case almost outperform a P4 3GHz, 
but that's another story).

Obviously your use (as a server) is very different, and probably the one 
test I have done can't expect to achieve 100% coverage even in this 
field... but, anyway, just my 2 cents...

 bye
av.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Scott Bennett
 On Wed, 12 Jan 2005 18:45:56 +0100 Anthony Atkielski
<[EMAIL PROTECTED]> wrote:

>Scott Bennett writes:
>
>SB>  Well, no, not exactly.  The dual-cored CPUs share certain resources
>SB> on the chip that are not shared in a multi-CPU situation, and that sharing
>SB> means certain operations have to be handled differently.  An MP setup has
>SB> separate cache and TLB managment in each CPU ...
>
>What's TLB?

 Translation Lookaside Buffer.  (I know.  It's a weird name.  I think
its origin was at IBM, which would explain the weirdness completely.)  Its
a collection of registers that contains the results of the most recent
address translations.  These results are kept around in order to avoid
going through the full address translation process for addresses in pages
for which address translation has already occurred.  It's a big time-saver.
When a virtual address is encountered that isn't in the TLB, then address
translation proceeds from scratch, and the result replaces the least recently
used entry in the TLB.
>
>SB> ... whereas P4 w/HT logical processors share this memory management
>SB> circuitry. Alteration of a cache line requires notification of the
>SB> other processor(s) in an MP situation to mark any corresponding line
>SB> in its(their) cache(s) because multiple separate caches are
>SB> involved, but notification is not necessary in the P4 w/HT situation
>SB> because it's the same cache being seen by both logical processors.
>SB>  Alteration/invalidation of TLB entries requires notification to
>SB> invalidate in an MP, so that the other CPU(s) can purge any corresponding 
>TLB
>SB> entries it(they) may have, but notification is not required in the P4 w/HT
>SB> situation because both logical processors are refering to the same TLB.  
>Again,
>SB> unnecessary purging would be a performance hit.
>SB>  There must be some special handling of TLB entries in the P4 w/HT that
>SB> I haven't seen documented.  (There almost certainly is documentation; I 
>just
>SB> haven't seen it yet.)  There must be some way to distinguish between TLB
>SB> entries filled per orders of one logical processor from those filled per
>SB> orders of the other logical processor.  If there weren't, then one logical
>SB> processor would use TLB entries for the address space running on the other
>SB> logical processor, which would, of course, be Very Bad.  But, to improve
>SB> performance, there should be some way to share TLBs for the case of two
>SB> threads running concurrently in the same address space.  If anyone reading
>SB> this knows the details of how this is handled in these chips, please post 
>them
>SB> here.
>
>>From what you say and from what I've read today, it sounds like
>hyperthreading comes close to providing two separate processors for
>heterogenous system loads (where each hyperthread is using slightly
>different processor resources at any given instant), but it may not buy
>much of anything for massively parallel compute-bound work, since both
>threads may want nearly the same things at the same time and will thus
>effectively be forced to spend a lot of time waiting for each other.

 I think that's probably close to the truth.  For logic and number
crunching, the two logical processors can proceed in parallel.  But they
will compete for any non-register memory access, for address translation
time, and possibly other resources.  I notice that the 5.2.1 boot messages
refer to the second core as an AP, which I'm guessing stands for "attached
processor".  If that guess is correct, then it means that only the first
core is able to perform certain functions, and the AP core has to get the
first core to do those things for it when it needs them done.  Typically,
such restricted functions include things like starting I/O operations,
handling I/O interrupts, setting the system clock, etc.  Whether these
restrictions are the actual ones, if there are any at all, in this
situation, I do not know.
>
>Fortunately, my server has a very mixed load, as one would expect for a
>generic domain server, so hopefully it will profit from hyperthreading.
>
 What Intel claims is essentially that the HT-enabled CPUs allow
snappier responses in interactive processes when a CPU-bound process is
running.

>And hopefully no weird stuff will happen because I've turned on HT
>(although offhand I'm not sure what would happen, unless there are
>hidden hardware conflicts or something specific and software-visible
>about HT in normal operation that might expose a bug).  I'm not sure
>that I see how HT could affect Serial ATA disks, for example, any more
>than having two separate physical processors wo

Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Andrea Venturoli writes:

AV> FWIW I tried numerical computations on a P4 with HT enabled: I expected
AV> using 2 threads might give *at least slightly* better results, but I
AV> could come to the conclusion that with 1, 2 or 4 threads the performance
AV> gain (or loss) was exactly zero.

Where these computations in which all threads were doing pretty much the
same thing?  And was it floating-point?  (Doesn't the processor have
just one FPU, or something like that?)

AV> BTW, an old AMD 2000 XP+ would in any case almost outperform a P4 3GHz,
AV> but that's another story.

An AMD processor will also melt or catch fire if the CPU fan fails,
whereas an Intel processor won't. I found this out the hard way, and so
henceforth I'll be installing Intel processors. The cost savings one
gets from buying AMD isn't enough to pay for a new motherboard or PC.

AV> Obviously your use (as a server) is very different, and probably the
AV> one test I have done can't expect to achieve 100% coverage even in
AV> this field... but, anyway, just my 2 cents...

I have no easy way to measure the performance on my system, so I'm
mostly just speculating--but it seems logical.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Timothy Luoma
On Jan 12, 2005, at 12:34 AM, Timothy Luoma wrote:
ps - thanks to all who responded.  I'm going to disable HT, boot to 
FreeBSD and try another large file transfer and see if I see the large 
delays.  If no, I'll copy the files I need off the XP drive and 
reinstall XP.
Ok, well I disabled HT and still saw the delays.  Then I figured out 
that it wasn't FreeBSD, it was Apple's ftpd.

I started ftpd on the FreeBSD machine and used 'put' instead of 'get' 
and that worked just fine.

Still, given all that's been said, I disabled HT and reinstalled XP.
Thanks to all who shared their insight.
TjL
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Scott Bennett writes:

SB> I notice that the 5.2.1 boot messages refer to the second core as an
SB> AP, which I'm guessing stands for "attached processor". If that
SB> guess is correct, then it means that only the first core is able to
SB> perform certain functions, and the AP core has to get the first core
SB> to do those things for it when it needs them done.

AP just stands for "application processor," from what I've seen. My
impression from snooping in the code and looking elsewhere is that an AP
is just a processor that is halted during system boot. The processor
that executes the boot sequence is the bootstrap processor (BSP). Once
the boot proceeds far enough to allow synchronization of multiple
processors, the other processors (APs all) are started by the BSP.

This doesn't necessarily mean that the BSP is special in any other way
outside of startup or shutdown, and hopefully it is not, as that would
defeat much of the conceptual purpose behind SMP. I know that on
operating systems that insist on keeping one processor special for
certain tasks, the speed of this processor often becomes a bottleneck on
heavily loaded systems, as it tops out trying to handle all the
"restricted" stuff for the other processors and itself.

SB> What Intel claims is essentially that the HT-enabled CPUs allow
SB> snappier responses in interactive processes when a CPU-bound process
SB> is running.

That I can believe.  One of the great advantages to a multiple-processor
system is that it's much less likely to bog down if a process decides to
hog a processor (unless the process runs multiple threads).  I think MP
is more interesting for its ability to run completely independent
processes or threads than it is for its ability to run multiple
threads doing the same thing.  Few applications require multiple
high-speed processors churning through code all at once.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Olivier Nicole
> An AMD processor will also melt or catch fire if the CPU fan fails,
> whereas an Intel processor won't. I found this out the hard way, and so

Not always true, I had a P4 1.5 die on me for lack of fan.

Now what was tha company selling a new box with no fan on the CPU is
another story...

Olivier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Olivier Nicole writes:

ON> Not always true, I had a P4 1.5 die on me for lack of fan.

I understood that all recent Intel processors will first slow the clock
and then halt completely if the die temperature rises too much, but
there may be exceptions (or perhaps some processors run so hot that they
will overheat without a fan even in the stopped state).

Did it start up when you replaced the fan, or was it gone for good?

In the case of my AMD processor, it reached a temperature of at least
110° C and still ran, but shortly thereafter a problem with memory
management developed and worsened rapidly until the processor was
completely dead.

ON> Now what was tha company selling a new box with no fan on the CPU is
ON> another story...

I thought all the boxed P4 processors came with their own fan, so there
should never be a case in which a PC is sold with a P4 but no CPU fan.

In any case, now that I've decided to build my own servers from now on,
there should be far fewer unpleasant surprises.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


RE: Hyperthreading hurts 5.3?

2005-01-12 Thread Subhro




> -Original Message-
> From: [EMAIL PROTECTED] [mailto:owner-freebsd-
> [EMAIL PROTECTED] On Behalf Of Anthony Atkielski
> Sent: Thursday, January 13, 2005 6:14
> To: freebsd-questions@freebsd.org
> Subject: Re: Hyperthreading hurts 5.3?
> 
> Andrea Venturoli writes:
> 
> Where these computations in which all threads were doing pretty much the
> same thing?  And was it floating-point?  (Doesn't the processor have
> just one FPU, or something like that?)

Yes Dual cored CPUs have a single FPU.

> 
> An AMD processor will also melt or catch fire if the CPU fan fails,
> whereas an Intel processor won't. I found this out the hard way, and so
> henceforth I'll be installing Intel processors. The cost savings one
> gets from buying AMD isn't enough to pay for a new motherboard or PC.

This *used* to be true. I am using a AMD64 3000+ and the idle temperature is
28C. The room temp is around 12-14C. After asking this kid to crunch FPs for
over 16 hrs, the processor temperature rose to only 38C. I am not using any
special cooling gears, just the stock heatsink fan combo that came with the
box pack.



Indian Institute of Information Technology
Subhro Sankha Kar
Block AQ-13/1, Sector V
Salt Lake City
PIN 700091
India


smime.p7s
Description: S/MIME cryptographic signature


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Anthony Atkielski
Subhro writes:

S> This *used* to be true. I am using a AMD64 3000+ and the idle
S> temperature is 28C. The room temp is around 12-14C. After asking this
S> kid to crunch FPs for over 16 hrs, the processor temperature rose to
S> only 38C. I am not using any special cooling gears, just the stock
S> heatsink fan combo that came with the box pack.

The case temperature on my FreeBSD server runs at about 36° C with a
room temperature of 25° C, and the 3.0 GHz Intel P4 processor is at
about 44° and very nearly idle (0.5% busy). After running the processor
at 100% for a few minutes, it gets up to 51° (I haven't tried the
experiment beyond that, and the system is never 100% under normal
conditions). There are seven fans (I'm not taking any chances): two that
blow into the case over the disk drives, one that blows down onto the
motherboard (directly over the CPU), and three that blow through and out
of the power supply--plus the P4 CPU fan. They draw air through filters
so they don't create that much movement, but I like the redundancy.

My desktop running WinXP has an AMD Athlon 1800-something.  The
processor runs at about 59° and the case is at 29°; this case has only
three fans, one in the PS, on inward fan on the case, and a tiny CPU fan
over the processor.  The arrangement of the MB is such that the CPU
doesn't have a very clear airflow over it.  The CPU fan has been
replaced twice, as the first fans were sleeve bearings that failed
almost immediately (I installed my own ball-bearing fan after that).
The case fan was my own addition.  On one occasion the CPU froze after
the fan failed, but it did not seem to break.  I don't know if this
model of processor includes any protections.

It would be nice if someone would design processors that did not require
active cooling, as the need for a CPU fan to keep the system from
self-destructing is a major weak point for the hardware.

Thank goodness modern operating systems idle the processor when it's not
in use.  I shudder to think what it would be like under old versions of
Windows (including Win9x) that just looped when idle.  FreeBSD runs cool
as a cucumber, even though it handles all my Web and mail and DNS and
NTP traffic.

Which reminds me: I'm still looking for a way to monitor system
temperature at securelevel=3 on my FreeBSD system, so suggestions are
welcome.  Healthd is fine but it won't work at securelevel=3.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-12 Thread Stijn Hoop
off-topic, but...

On Thu, Jan 13, 2005 at 01:43:54AM +0100, Anthony Atkielski wrote:
> AV> BTW, an old AMD 2000 XP+ would in any case almost outperform a P4 3GHz,
> AV> but that's another story.
> 
> An AMD processor will also melt or catch fire if the CPU fan fails,
> whereas an Intel processor won't. I found this out the hard way, and so
> henceforth I'll be installing Intel processors. The cost savings one
> gets from buying AMD isn't enough to pay for a new motherboard or PC.

This also depends on your motherboard having overheat protection (ie shuts
itself down when the CPU temperature goes too high). My ASUS A7N8X calls
this feature 'C.O.P.' -- CPU overheating protection.

Choose your motherboard wisely and you'll avoid this problem.

--Stijn

-- 
It's harder to read code than to write it.
-- Joel Spolsky,
   http://www.joelonsoftware.com/articles/fog69.html


pgpSvKCBPHFu7.pgp
Description: PGP signature


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Scott Bennett
 On Thu, 13 Jan 2005 02:11:27 +0100 Anthony Atkielski
<[EMAIL PROTECTED]> wrote:

>Scott Bennett writes:
>
>SB> I notice that the 5.2.1 boot messages refer to the second core as an
>SB> AP, which I'm guessing stands for "attached processor". If that
>SB> guess is correct, then it means that only the first core is able to
>SB> perform certain functions, and the AP core has to get the first core
>SB> to do those things for it when it needs them done.
>
>AP just stands for "application processor," from what I've seen. My
>impression from snooping in the code and looking elsewhere is that an AP
>is just a processor that is halted during system boot. The processor
>that executes the boot sequence is the bootstrap processor (BSP). Once
>the boot proceeds far enough to allow synchronization of multiple
>processors, the other processors (APs all) are started by the BSP.

 Oh, good.  That sounds much better than what I was thinking.
>
>This doesn't necessarily mean that the BSP is special in any other way
>outside of startup or shutdown, and hopefully it is not, as that would
>defeat much of the conceptual purpose behind SMP. I know that on
>operating systems that insist on keeping one processor special for
>certain tasks, the speed of this processor often becomes a bottleneck on
>heavily loaded systems, as it tops out trying to handle all the
>"restricted" stuff for the other processors and itself.

 Usually that sort of restriction has a basis in hardware.  For example,
IBM's MP mainframes *used to* require that the same processor that started
an I/O operation be the one that fielded the interrupt(s) upon completion
of the operation.  Some machines also had the main processor/attached
processor configuration, in which the attached processor had no access to
the I/O hardware at all, so all I/O handling had to be done by the main
processor because the AP had no way to do it.
>
>SB> What Intel claims is essentially that the HT-enabled CPUs allow
>SB> snappier responses in interactive processes when a CPU-bound process
>SB> is running.
>
>That I can believe.  One of the great advantages to a multiple-processor
>system is that it's much less likely to bog down if a process decides to
>hog a processor (unless the process runs multiple threads).  I think MP
>is more interesting for its ability to run completely independent
>processes or threads than it is for its ability to run multiple
>threads doing the same thing.  Few applications require multiple
>high-speed processors churning through code all at once.
>
 My main interest in such things at present is for dividing the workload
in fluid dynamics and, most especially, geophysical fluid dynamics models.
Those, of course, do immense amounts of number-crunching with occasional,
massive bouts of I/O.  I want to play around with making a two-threaded
version of a GFD model (either atmospheric or oceanic) to see what, if any,
savings there may be in elapsed time by running on both cores vs. just one.
Such a model would have both threads doing essentially the same things,
though operating upon different parts of the arrays involved.
 But first, I still have to get a usable FreeBSD system going. :-(


  Scott Bennett, Comm. ASMELG, CFIAG
**
* Internet:   bennett at cs.niu.edu  *
**
* "A well regulated and disciplined militia, is at all times a good  *
* objection to the introduction of that bane of all free governments *
* -- a standing army."   *
*-- Gov. John Hancock, New York Journal, 28 January 1790 *
**
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Andrea Venturoli
Anthony Atkielski wrote:
Where these computations in which all threads were doing pretty much the
same thing?
Not exactly the same algorithm and on different set of data.

And was it floating-point?
Yes.

(Doesn't the processor have just one FPU, or something like that?)
I don't really know (I made this test almost for fun and curiosity), but 
I really supposed this must be true. Anyway I saw both CPU at 100%.



An AMD processor will also melt or catch fire if the CPU fan fails,
whereas an Intel processor won't.
In the past.
Nowadays they have some sort of protection.
BTW I've already seen a couple of (old) Athlons with a failing fan; they 
run overheated probably for months with occasional system lockups, but 
they are now working good with a new fan.
I'll stop here, we are going OT (and flaming :)...

 bye
av.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Olivier Nicole
> Did it start up when you replaced the fan, or was it gone for good?

It was dead for good, well it is still dead as a matter of fact :)

> I thought all the boxed P4 processors came with their own fan, so there
> should never be a case in which a PC is sold with a P4 but no CPU fan.

So did I, so did I, but one sees strange things when buying a machine
from a cheap assembly shop (I was not the first buyer, I just got the
machine when it became unusable and then I was curious so I opened it,
what the first owner never did).

Olivier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Anthony Atkielski
Andrea Venturoli writes:

AV> Not exactly the same algorithm and on different set of data.

But similar machine instructions, perhaps?

AV> Yes.

Just the contention for the FPU alone might have had the effect of
single-threading the workload.  That plus the SMP overhead might give
you a zero or negative gain with HT.

AV> In the past.
AV> Nowadays they have some sort of protection.

Unfortunately, AMD lost my business when the first processor nearly
burst into flames.  I try not to make the same mistake twice.  And I've
seen examples of AMD processors that _have_ burst into flames, so why
take a chance?

For me the weakest parts of any machine are the fans and the disk
drives, because they have to move.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Anthony Atkielski
Olivier Nicole writes:

ON> It was dead for good, well it is still dead as a matter of fact :)

The AMD processor on my XP system overheated and stalled a few times, before
I realized that the (brand-new) fan had failed.  It still runs okay now,
though, with a reliable fan.

The other AMD processor, on my server, dramatically overheated for 8-12
hours at a time (process stuck in a loop--I never found out why).  It
damaged something that failed intermittently at first (segment
violations in the kernel and in daemons that should never have such
problems), then got worse and worse over a few days, until it failed
completely.

ON> So did I, so did I, but one sees strange things when buying a machine
ON> from a cheap assembly shop (I was not the first buyer, I just got the
ON> machine when it became unusable and then I was curious so I opened it,
ON> what the first owner never did).

I decided to build my own.  I was tired of not knowing what was inside
the machine, and finding out the hard and expensive way that many
corners had been cut.  I also got tired of having stacks and stacks of
unused stereo mini-speakers, ultra-cheap keyboards, and equally cheap
mice.  Not to mention paying for Windows and a boatload of absolutely
useless garbage software that I was just going to wipe away immediately
in favor of FreeBSD (and I configure my FreeBSD systems to run FreeBSD
exclusively--none of this dual-boot stuff).  It gives me strange
pleasure to think that the current server has never gotten anywhere near
Windows.  FreeBSD was the first OS to deflower the virgin disk drives.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Andrea Venturoli
Anthony Atkielski wrote:
Andrea Venturoli writes:
AV> Not exactly the same algorithm and on different set of data.
But similar machine instructions, perhaps?
Yes, both numerical computations.
Basically one thread would model geometry and the other would mesh it.
Frequent stall would arise, as the two process would only by chance 
require the same time, even so the two CPUs were always at full load 
(!?!?!?). I also tried different combinations, e.g. three modelling 
threads and one mesher with, again, equal timings.

BTW, it's worth to mention, I *have* to use a compiler that knows 
nothing about SSE or the like, so all is done with FPU instructions as 
in the old 387s...



Just the contention for the FPU alone might have had the effect of
single-threading the workload.
I've come to the same conclusion. Still I can't put this together with 
100% load on both processors. If, as someone said, there is only one 
FPU, *how* are these figures coming out??? I would have expected 
something like 50%-50% (instead of 100%-0% of the single threaded 
version). *If* there is only one FPU, I'd expect both virtual processors 
being frequently idle waiting for each other.


That plus the SMP overhead might give
you a zero or negative gain with HT.
I tried a multithreaded version on a UP machine (nonsense, I know): the 
locking overhead is there, but very minimal: a process which takes 16 
minutes will require, maybe, 3 seconds more.

 bye
av.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Anthony Atkielski
Andrea Venturoli writes:

AV> I've come to the same conclusion. Still I can't put this together with
AV> 100% load on both processors. If, as someone said, there is only one
AV> FPU, *how* are these figures coming out???

The operating system tracks a dispatch of a processor into a process
thread.  After that, it has no idea whether the processor is actually
doing anything or not--from the OS' standpoint, the processor is
"running."  So if one thread in one logical processor is actually
executing instructions, and the other is stalled while waiting for a
shared resource in the processor, the OS will still consider both
threads to be "running" and will charge all of the elapsed time as
processor time ... giving you a figure of 100% busy.

AV> I would have expected something like 50%-50% (instead of 100%-0% of
AV> the single threaded version). *If* there is only one FPU, I'd expect
AV> both virtual processors being frequently idle waiting for each
AV> other.

Yes ... but the OS can't see that, and so OS monitoring tools can't
report it.

-- 
Anthony


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-13 Thread Olivier Nicole
> The other AMD processor, on my server, dramatically overheated for 8-12
> hours at a time (process stuck in a loop--I never found out why).  It
> damaged something that failed intermittently at first (segment
> violations in the kernel and in daemons that should never have such
> problems), then got worse and worse over a few days, until it failed
> completely.

It was not my machine, maybe it had been giving some warnings, but the
one in charge failed to notice them.
 
> I decided to build my own.  I was tired of not knowing what was inside
> the machine, and finding out the hard and expensive way that many
> corners had been cut.  I also got tired of having stacks and stacks of

I rely on a shop that I trust, and for servers, I give the exact
requirements :)

And of course I always open a new box before I power it on...

> unused stereo mini-speakers, ultra-cheap keyboards, and equally cheap
> mice.  Not to mention paying for Windows and a boatload of absolutely

At least we do not pay for Windows, that is Thailand :) (partial BS as
we have a site licence for Windows, shame!)

Olivier
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading hurts 5.3?

2005-01-14 Thread Scott Bennett
 On Thu, 13 Jan 2005 21:38:08 +0100 Andrea Venturoli
<[EMAIL PROTECTED]> wrote:

>Anthony Atkielski wrote:
>> Andrea Venturoli writes:
>> 
>> AV> Not exactly the same algorithm and on different set of data.
>> 
>> But similar machine instructions, perhaps?
>
>Yes, both numerical computations.
>Basically one thread would model geometry and the other would mesh it.
>Frequent stall would arise, as the two process would only by chance 
>require the same time, even so the two CPUs were always at full load 
>(!?!?!?). I also tried different combinations, e.g. three modelling 

 Makes sense.

>threads and one mesher with, again, equal timings.
>
>BTW, it's worth to mention, I *have* to use a compiler that knows 
>nothing about SSE or the like, so all is done with FPU instructions as 
>in the old 387s...
>
 That may make each thread take longer than if it could use the SSE
instructions, but is unrelated to your other issue.
>
>> Just the contention for the FPU alone might have had the effect of
>> single-threading the workload.
>
>I've come to the same conclusion. Still I can't put this together with 
>100% load on both processors. If, as someone said, there is only one 
>FPU, *how* are these figures coming out??? I would have expected 
>something like 50%-50% (instead of 100%-0% of the single threaded 
>version). *If* there is only one FPU, I'd expect both virtual processors 
>being frequently idle waiting for each other.
>
 They most likely are.  You seem to be forgetting that the "idling" in
question is handled within the CPU, not by the kernel.  In other words, it
happens effectively *during* an instruction on the "idled" core, not by kernel
processing between thread switches, so the instruction just takes longer than
it otherwise would, sort of like waiting for a memory access to complete.  No
interrupt occurs.  The core just sits and twiddles its electrons until the
resource it's queued upon becomes available to it, and then it proceeds to
complete the "idled" instruction.
>
>> That plus the SMP overhead might give
>> you a zero or negative gain with HT.
>
>I tried a multithreaded version on a UP machine (nonsense, I know): the 
>locking overhead is there, but very minimal: a process which takes 16 
>minutes will require, maybe, 3 seconds more.
>
 Was that using MPI?  Or some other thread management package?


  Scott Bennett, Comm. ASMELG, CFIAG
  836 Greenbrier Road, Apt. 4
  DeKalb, Illinois 60115
**
* Internet:   bennett at cs.niu.edu  *
**
* "A well regulated and disciplined militia, is at all times a good  *
* objection to the introduction of that bane of all free governments *
* -- a standing army."   *
*-- Gov. John Hancock, New York Journal, 28 January 1790 *
**
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: SMP vs. Hyperthreading?

2004-03-13 Thread Alex de Kruijff
On Sat, Mar 13, 2004 at 02:37:37PM +0100, [EMAIL PROTECTED] wrote:
> Hi,
> 
> I've got a machine with a P4 that supports HTT (Hyperthreading) so I
> thought about setting up a SMP-kernel.
> 
> Under 4.9 it seems to work (see excerpts from /var/log/messages
> below), whereas on the same exact hardware under 5.2.1 I don't see two
> virtual CPUs working. 
> 
> For a first check I've run "cpuburn" (i.e. burnP6). Under 4.9 with one
> "cpuburn" process active "top" etc. show a cpu-load of about 50% which
> for me means SMP/HTT is active.
> 
> Under 5.2.1 it's a different story though: /var/log/messages shows
> that there are 2 CPUs but the message indicating the second CPU has
> been launched is missing ("/kernel: SMP: AP CPU #1 Launched!"). When I
> run a "cpuburn"-Test under 5.2.1 CPU load indicated by "top" shows
> 100% so I assume SMP/HTT is not active.
> 
> 
> So my primary question is - how do I get SMP running under 5.2.1 with
> a hyperthreading-capable P4??

I installed 5.2 and that came ready to run afther the install. I didn't
have to do anything for it.

-- 
Alex

Articles based on solutions that I use:
http://www.kruijff.org/alex/index.php?dir=docs/FreeBSD/
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


RE: SMP vs. Hyperthreading?

2004-03-17 Thread Brent Wiese
> Hi,
> 
> I've got a machine with a P4 that supports HTT (Hyperthreading) so I
> thought about setting up a SMP-kernel.

SMP <> HT. I'm not an expert on this, but when I went to an Intel conference
a couple years ago which discussed hyperthreading, it was made pretty clear
it wasn't the same as SMP. But, like I said, I'm not an expert so I don't
know what exactly its doing at the very low levels.

> Under 5.2.1 it's a different story though: /var/log/messages shows
> that there are 2 CPUs but the message indicating the second CPU has
> been launched is missing ("/kernel: SMP: AP CPU #1 Launched!"). When I
> run a "cpuburn"-Test under 5.2.1 CPU load indicated by "top" shows
> 100% so I assume SMP/HTT is not active.

That is the message for the second CPU. The first is CPU #0 and is always
active. Every dual-cpu machine I've installed SMP kernel on only shows the
second CPU launching.

> So my primary question is - how do I get SMP running under 5.2.1 with
> a hyperthreading-capable P4??

I haven't used 5.x, but in 4.9, there is a specific line in the kernel
config for hyperthreading support (to which I've read mixed reviews on this
list).

Good luck
Brent


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Hyperthreading FreeBSD 4.9

2003-10-29 Thread Kris Kennaway
On Wed, Oct 29, 2003 at 01:51:32PM -0800, John Palmer wrote:
> I currently have FreeBSD 4.8 with hyperthreading enabled.  I just cvsup to 
> the latest version of FreeBSD to 4.9.  When I do make buildkernel 
> KERNCONF=FOO, I get an error of "unknown option "HTT""  Has hyperthreading 
> been disabled in FreeBSD 4.9?

It's controlled by sysctl, as long as you have a SMP kernel.

Kris


pgp0.pgp
Description: PGP signature


Re: Hyperthreading FreeBSD 4.9

2003-10-29 Thread Larry Rosenman


--On Wednesday, October 29, 2003 13:51:32 -0800 John Palmer 
<[EMAIL PROTECTED]> wrote:

I currently have FreeBSD 4.8 with hyperthreading enabled.  I just cvsup
to the latest version of FreeBSD to 4.9.  When I do make buildkernel
KERNCONF=FOO, I get an error of "unknown option "HTT""  Has
hyperthreading been disabled in FreeBSD 4.9?
Read /usr/src/UPDATING.


Thanks

JP

_
Enjoy MSN 8 patented spam control and more with MSN 8 Dial-up Internet
Service.  Try it FREE for one month!
http://join.msn.com/?page=dept/dialup
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to
"[EMAIL PROTECTED]"


--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED]
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749


pgp0.pgp
Description: PGP signature


Re: Hyperthreading FreeBSD 4.9

2003-10-29 Thread Matthew Seaman
On Wed, Oct 29, 2003 at 01:51:32PM -0800, John Palmer wrote:
> I currently have FreeBSD 4.8 with hyperthreading enabled.  I just cvsup to 
> the latest version of FreeBSD to 4.9.  When I do make buildkernel 
> KERNCONF=FOO, I get an error of "unknown option "HTT""  Has hyperthreading 
> been disabled in FreeBSD 4.9?

The answer to your question is cunningly hidden at the top of the
/usr/src/UPDATING file -- you know, the one the instructions are
always telling you to read -- and it's hidden there because it's a
secret, and that's the one place no-one would ever look for it.

Cheers,

Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.   26 The Paddocks
  Savill Way
PGP: http://www.infracaninophile.co.uk/pgpkey Marlow
Tel: +44 1628 476614  Bucks., SL7 1TH UK


pgp0.pgp
Description: PGP signature


Re: Hyperthreading FreeBSD 4.9

2003-10-29 Thread John Palmer
Thanks


From: Larry Rosenman <[EMAIL PROTECTED]>
To: John Palmer <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
Subject: Re: Hyperthreading FreeBSD 4.9
Date: Wed, 29 Oct 2003 15:59:08 -0600


--On Wednesday, October 29, 2003 13:51:32 -0800 John Palmer 
<[EMAIL PROTECTED]> wrote:

I currently have FreeBSD 4.8 with hyperthreading enabled.  I just cvsup
to the latest version of FreeBSD to 4.9.  When I do make buildkernel
KERNCONF=FOO, I get an error of "unknown option "HTT""  Has
hyperthreading been disabled in FreeBSD 4.9?
Read /usr/src/UPDATING.


Thanks

JP

_
Enjoy MSN 8 patented spam control and more with MSN 8 Dial-up Internet
Service.  Try it FREE for one month!
http://join.msn.com/?page=dept/dialup
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to
"[EMAIL PROTECTED]"


--
Larry Rosenman http://www.lerctr.org/~ler
Phone: +1 972-414-9812 E-Mail: [EMAIL PROTECTED]
US Mail: 1905 Steamboat Springs Drive, Garland, TX 75044-6749
<< attach3 >>
_
Send instant messages to anyone on your contact list with  MSN Messenger 
6.0.  Try it now FREE!  http://msnmessenger-download.com

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Missing machdep.hlt_logical_cpus on hyperthreading..

2003-11-26 Thread Stefan Cars
Hi!

I'm having a problem, sysctl can't find machdep.hlt_logical_cpus. My machine
is a dual xeon with hyperthreading enabled, running 4.9. I also would like
to know what that "Warning: Pentium 4 CPU: PSE disabled" means.

See below:

sysctl: unknown oid 'machdep.hlt_logical_cpus'

FreeBSD guldivar.globalwire.se 4.9-RELEASE FreeBSD 4.9-RELEASE #1: Mon Nov
24 14:59:32 CET 2003
[EMAIL PROTECTED]:/usr/src/sys/compile/FLASHZGI  i386

Copyright (c) 1992-2003 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD 4.9-RELEASE #1: Mon Nov 24 14:59:32 CET 2003
[EMAIL PROTECTED]:/usr/src/sys/compile/FLASHZGI
Timecounter "i8254"  frequency 1193182 Hz
CPU: Intel(R) XEON(TM) CPU 1.80GHz (1799.80-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf24  Stepping = 4
 
Features=0x3febfbff
  Hyperthreading: 2 logical CPUs
real memory  = 1073676288 (1048512K bytes)
config> di sn0
No such device: sn0
Invalid command or syntax.  Type `?' for help.
config> di lnc0
No such device: lnc0
Invalid command or syntax.  Type `?' for help.
config> di ie0
No such device: ie0
Invalid command or syntax.  Type `?' for help.
config> di fe0
No such device: fe0
Invalid command or syntax.  Type `?' for help.
config> di cs0
No such device: cs0
Invalid command or syntax.  Type `?' for help.
config> di bt0
No such device: bt0
Invalid command or syntax.  Type `?' for help.
config> di adv0
No such device: adv0
Invalid command or syntax.  Type `?' for help.
config> q
avail memory = 1041534976 (1017124K bytes)
Programming 24 pins in IOAPIC #0
IOAPIC #0 intpin 2 -> irq 0
Programming 24 pins in IOAPIC #1
Programming 24 pins in IOAPIC #2
FreeBSD/SMP: Multiprocessor motherboard: 4 CPUs
 cpu0 (BSP): apic id:  0, version: 0x00050014, at 0xfee0
 cpu1 (AP):  apic id:  1, version: 0x00050014, at 0xfee0
 cpu2 (AP):  apic id:  6, version: 0x00050014, at 0xfee0
 cpu3 (AP):  apic id:  7, version: 0x00050014, at 0xfee0
 io0 (APIC): apic id:  8, version: 0x00178020, at 0xfec0
 io1 (APIC): apic id:  9, version: 0x00178020, at 0xfec8
 io2 (APIC): apic id: 10, version: 0x00178020, at 0xfec80400
Preloaded elf kernel "kernel" at 0xc0414000.
Preloaded userconfig_script "/boot/kernel.conf" at 0xc041409c.
Warning: Pentium 4 CPU: PSE disabled
Pentium Pro MTRR support enabled
md0: Malloc disk
Using $PIR table, 14 entries at 0xc00f3f20
npx0:  on motherboard
npx0: INT 16 interface
pcib0:  on motherboard
IOAPIC #0 intpin 16 -> irq 2
IOAPIC #0 intpin 18 -> irq 9
IOAPIC #0 intpin 17 -> irq 10
pci0:  on pcib0
pcib1:  at device 2.0 on pci0
pci2:  on pcib1
pci2:  (vendor=0x8086, dev=0x1461) at 28.0
pcib2:  at device 29.0 on pci2
IOAPIC #2 intpin 0 -> irq 11
pci4:  on pcib2
pci4:  (vendor=0x8086, dev=0x1008) at 1.0 irq 11
pcib3:  at device 3.0 on pci4
pci5:  on pcib3
asr0:  mem 0xf800-0xfbff irq 11 at device
3.1
 on pci4
asr0: major=154
asr0: ADAPTEC 3410S FW Rev. 370F, 4 channel, 256 CCBs, Protocol I2O
pci2:  (vendor=0x8086, dev=0x1461) at 30.0
pcib4:  at device 31.0 on pci2
pci3:  on pcib4
pci0:  at 29.0 irq 2
pcib5:  at device 30.0 on pci0
pci1:  on pcib5
pci1:  at 2.0 irq 9
fxp0:  port 0xc880-0xc8bf mem
0xfe6a-0xfe6bfff
f,0xfe6fe000-0xfe6fefff irq 10 at device 3.0 on pci1
fxp0: Ethernet address 00:e0:81:20:f7:7c
inphy0:  on miibus0
inphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
isab0:  at device 31.0 on pci0
isa0:  on isab0
atapci0:  port
0xffa0-0xffaf,0-0x3,0-0x7,0-0x3,0-0
x7 irq 9 at device 31.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
ata1: at 0x170 irq 15 on atapci0
pci0:  (vendor=0x8086, dev=0x2483) at 31.3 irq 10
orm0:  at iomem
0xc-0xc7fff,0xc8000-0xc97ff,0xc9800-0xcf7ff,0xc
f800-0xd0fff on isa0
pmtimer0 on isa0
fdc0:  at port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on isa0
atkbdc0:  at port 0x60,0x64 on isa0
atkbd0:  flags 0x1 irq 1 on atkbdc0
kbd0 at atkbd0
vga0:  at port 0x3c0-0x3df iomem 0xa-0xb on isa0
sc0:  at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
sio0: configured irq 4 not in bitmap of probed irqs 0
sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
sio0: type 8250
sio1: configured irq 3 not in bitmap of probed irqs 0
ppc0: parallel port not found.
APIC_IO: Testing 8254 interrupt delivery
APIC_IO: routing 8254 via IOAPIC #0 intpin 2
IP packet filtering initialized, divert disabled, rule-based forwarding
enabled,
 default to accept, unlimited logging
SMP: AP CPU #3 Launched!
SMP: AP CPU #1 Launched!
SMP: AP CPU #2 Launched!
acd0: CDROM  at ata0-master PIO4
Mounting root from ufs:/dev/da0s1a
da0 at asr0 bus 0 target 1 lun 0
da0:  Fixed Direct Access SCSI-2 device
da0: Tagged Queueing Enabled
da0: 70004MB (143368192 512 byte sectors: 255H 63S/T 8924C)

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Missing machdep.hlt_logical_cpus on hyperthreading..

2003-12-02 Thread Stefan Cars
Hi, i'm reposting this since I didn't get any answer at all...

I'm having a problem, sysctl can't find machdep.hlt_logical_cpus. My machine
is a dual xeon with hyperthreading enabled, running 4.9. I also would like
to know what that "Warning: Pentium 4 CPU: PSE disabled" means.

See below:

sysctl: unknown oid 'machdep.hlt_logical_cpus'

FreeBSD guldivar.globalwire.se 4.9-RELEASE FreeBSD 4.9-RELEASE #1: Mon Nov
24 14:59:32 CET 2003
[EMAIL PROTECTED]:/usr/src/sys/compile/FLASHZGI  i386

Copyright (c) 1992-2003 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
The Regents of the University of California. All rights reserved.
FreeBSD 4.9-RELEASE #1: Mon Nov 24 14:59:32 CET 2003
[EMAIL PROTECTED]:/usr/src/sys/compile/FLASHZGI
Timecounter "i8254"  frequency 1193182 Hz
CPU: Intel(R) XEON(TM) CPU 1.80GHz (1799.80-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf24  Stepping = 4
 
Features=0x3febfbff
  Hyperthreading: 2 logical CPUs
real memory  = 1073676288 (1048512K bytes)
config> di sn0
No such device: sn0
Invalid command or syntax.  Type `?' for help.
config> di lnc0
No such device: lnc0
Invalid command or syntax.  Type `?' for help.
config> di ie0
No such device: ie0
Invalid command or syntax.  Type `?' for help.
config> di fe0
No such device: fe0
Invalid command or syntax.  Type `?' for help.
config> di cs0
No such device: cs0
Invalid command or syntax.  Type `?' for help.
config> di bt0
No such device: bt0
Invalid command or syntax.  Type `?' for help.
config> di adv0
No such device: adv0
Invalid command or syntax.  Type `?' for help.
config> q
avail memory = 1041534976 (1017124K bytes)
Programming 24 pins in IOAPIC #0
IOAPIC #0 intpin 2 -> irq 0
Programming 24 pins in IOAPIC #1
Programming 24 pins in IOAPIC #2
FreeBSD/SMP: Multiprocessor motherboard: 4 CPUs
 cpu0 (BSP): apic id:  0, version: 0x00050014, at 0xfee0
 cpu1 (AP):  apic id:  1, version: 0x00050014, at 0xfee0
 cpu2 (AP):  apic id:  6, version: 0x00050014, at 0xfee0
 cpu3 (AP):  apic id:  7, version: 0x00050014, at 0xfee0
 io0 (APIC): apic id:  8, version: 0x00178020, at 0xfec0
 io1 (APIC): apic id:  9, version: 0x00178020, at 0xfec8
 io2 (APIC): apic id: 10, version: 0x00178020, at 0xfec80400
Preloaded elf kernel "kernel" at 0xc0414000.
Preloaded userconfig_script "/boot/kernel.conf" at 0xc041409c.
Warning: Pentium 4 CPU: PSE disabled
Pentium Pro MTRR support enabled
md0: Malloc disk
Using $PIR table, 14 entries at 0xc00f3f20
npx0:  on motherboard
npx0: INT 16 interface
pcib0:  on motherboard
IOAPIC #0 intpin 16 -> irq 2
IOAPIC #0 intpin 18 -> irq 9
IOAPIC #0 intpin 17 -> irq 10
pci0:  on pcib0
pcib1:  at device 2.0 on pci0
pci2:  on pcib1
pci2:  (vendor=0x8086, dev=0x1461) at 28.0
pcib2:  at device 29.0 on pci2
IOAPIC #2 intpin 0 -> irq 11
pci4:  on pcib2
pci4:  (vendor=0x8086, dev=0x1008) at 1.0 irq 11
pcib3:  at device 3.0 on pci4
pci5:  on pcib3
asr0:  mem 0xf800-0xfbff irq 11 at device
3.1
 on pci4
asr0: major=154
asr0: ADAPTEC 3410S FW Rev. 370F, 4 channel, 256 CCBs, Protocol I2O
pci2:  (vendor=0x8086, dev=0x1461) at 30.0
pcib4:  at device 31.0 on pci2
pci3:  on pcib4
pci0:  at 29.0 irq 2
pcib5:  at device 30.0 on pci0
pci1:  on pcib5
pci1:  at 2.0 irq 9
fxp0:  port 0xc880-0xc8bf mem
0xfe6a-0xfe6bfff
f,0xfe6fe000-0xfe6fefff irq 10 at device 3.0 on pci1
fxp0: Ethernet address 00:e0:81:20:f7:7c
inphy0:  on miibus0
inphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto
isab0:  at device 31.0 on pci0
isa0:  on isab0
atapci0:  port
0xffa0-0xffaf,0-0x3,0-0x7,0-0x3,0-0
x7 irq 9 at device 31.1 on pci0
ata0: at 0x1f0 irq 14 on atapci0
ata1: at 0x170 irq 15 on atapci0
pci0:  (vendor=0x8086, dev=0x2483) at 31.3 irq 10
orm0:  at iomem
0xc-0xc7fff,0xc8000-0xc97ff,0xc9800-0xcf7ff,0xc
f800-0xd0fff on isa0
pmtimer0 on isa0
fdc0:  at port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on isa0
atkbdc0:  at port 0x60,0x64 on isa0
atkbd0:  flags 0x1 irq 1 on atkbdc0
kbd0 at atkbd0
vga0:  at port 0x3c0-0x3df iomem 0xa-0xb on isa0
sc0:  at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
sio0: configured irq 4 not in bitmap of probed irqs 0
sio0 at port 0x3f8-0x3ff irq 4 flags 0x10 on isa0
sio0: type 8250
sio1: configured irq 3 not in bitmap of probed irqs 0
ppc0: parallel port not found.
APIC_IO: Testing 8254 interrupt delivery
APIC_IO: routing 8254 via IOAPIC #0 intpin 2
IP packet filtering initialized, divert disabled, rule-based forwarding
enabled,
 default to accept, unlimited logging
SMP: AP CPU #3 Launched!
SMP: AP CPU #1 Launched!
SMP: AP CPU #2 Launched!
acd0: CDROM  at ata0-master PIO4
Mounting root from ufs:/dev/da0s1a
da0 at asr0 bus 0 target 1 lun 0
da0:  Fixed Direct Access SCSI-2 device
da0: Tagged Queueing Enabled
da0: 70004MB (143368192 512 byte sectors: 255H 63S/T 8924C)

Re: enable smp / hyperthreading

2005-11-07 Thread Roland Smith
On Mon, Nov 07, 2005 at 07:53:20PM +0100, [EMAIL PROTECTED] wrote:
> Hi
> 
> I've just installed 6.0-RELASE and am trying to get SMP to work (I have af
> Pentium 4 with HT). So I've compiled the kernel with 'options SMP' and
> according to dmesg the two CPUs are found:
> 
> FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
>  cpu0 (BSP): APIC ID:  0
>  cpu1 (AP): APIC ID:  1
> 
> But I'm not sure that both are enabled, because at this is at the end of
> dmesg and I dont see the other CPU being enabled somewhere:
> 
> SMP: AP CPU #1 Launched!

I think it is referring to the Auxiliary Processor (AP), because the BSP
(don't know what that stands for, though) is obviously already active.
 
> According to 'sysctl -a' there are 2 CPUs, but only 1 active and SMP
> doesnt seem to be disabled:
> 
> kern.smp.cpus: 2
> kern.smp.disabled: 0
> kern.smp.active: 1

  sysctl -d kern.smp.active
  kern.smp.active: Number of Auxillary Processors (APs) that were
  successfully started

This is the number of _extra_ CPUs, which chould be 1.
 
Roland
-- 
R.F.Smith (http://www.xs4all.nl/~rsmith/) Please send e-mail as plain text.
public key: http://www.xs4all.nl/~rsmith/pubkey.txt


pgpnrnQu316T8.pgp
Description: PGP signature


Re: enable smp / hyperthreading

2005-11-07 Thread Robert Marella
On Mon, 7 Nov 2005 20:05:24 +0100
Roland Smith <[EMAIL PROTECTED]> wrote:

> On Mon, Nov 07, 2005 at 07:53:20PM +0100, [EMAIL PROTECTED] wrote:
> > Hi
> > 
> > I've just installed 6.0-RELASE and am trying to get SMP to work (I
> > have af Pentium 4 with HT). So I've compiled the kernel with
> > 'options SMP' and according to dmesg the two CPUs are found:
> > 
> > FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
> >  cpu0 (BSP): APIC ID:  0
> >  cpu1 (AP): APIC ID:  1
> > 
> > But I'm not sure that both are enabled, because at this is at the
> > end of dmesg and I dont see the other CPU being enabled somewhere:
> > 
> > SMP: AP CPU #1 Launched!
> 
> I think it is referring to the Auxiliary Processor (AP), because the
> BSP (don't know what that stands for, though) is obviously already
> active. 
> > According to 'sysctl -a' there are 2 CPUs, but only 1 active and SMP
> > doesnt seem to be disabled:
> > 
> > kern.smp.cpus: 2
> > kern.smp.disabled: 0
> > kern.smp.active: 1
> 
>   sysctl -d kern.smp.active
>   kern.smp.active: Number of Auxillary Processors (APs) that were
>   successfully started
> 
> This is the number of _extra_ CPUs, which chould be 1.
>  
> Roland

If hyperthreading is working the ouput of 'top' should have a C column
and will show either a 0 or a 1.

AFAIK HTT is still disabled because of a security risk. See:

ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:09.htt.asc

If you do not believe you are at risk, there is a work around included
in the above site.

YMMV. I have been known to be wrong before. :-)

Robert
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: enable smp / hyperthreading

2005-11-07 Thread Robert Marella
On Mon, 7 Nov 2005 11:16:19 -1000
Robert Marella <[EMAIL PROTECTED]> wrote:

> On Mon, 7 Nov 2005 20:05:24 +0100
> Roland Smith <[EMAIL PROTECTED]> wrote:
> 
> > On Mon, Nov 07, 2005 at 07:53:20PM +0100, [EMAIL PROTECTED] wrote:
> > > Hi
> > > 
> > > I've just installed 6.0-RELASE and am trying to get SMP to work (I
> > > have af Pentium 4 with HT). So I've compiled the kernel with
> > > 'options SMP' and according to dmesg the two CPUs are found:
> > > 
> > > FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
> > >  cpu0 (BSP): APIC ID:  0
> > >  cpu1 (AP): APIC ID:  1
> > > 
> > > But I'm not sure that both are enabled, because at this is at the
> > > end of dmesg and I dont see the other CPU being enabled somewhere:
> > > 
> > > SMP: AP CPU #1 Launched!
> > 
> > I think it is referring to the Auxiliary Processor (AP), because the
> > BSP (don't know what that stands for, though) is obviously already
> > active. 
> > > According to 'sysctl -a' there are 2 CPUs, but only 1 active and
> > > SMP doesnt seem to be disabled:
> > > 
> > > kern.smp.cpus: 2
> > > kern.smp.disabled: 0
> > > kern.smp.active: 1
> > 
> >   sysctl -d kern.smp.active
> >   kern.smp.active: Number of Auxillary Processors (APs) that were
> >   successfully started
> > 
> > This is the number of _extra_ CPUs, which chould be 1.
> >  
> > Roland
> 
> If hyperthreading is working the ouput of 'top' should have a C column
> and will show either a 0 or a 1.
> 
> AFAIK HTT is still disabled because of a security risk. See:
> 
> ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:09.htt.asc
> 
> If you do not believe you are at risk, there is a work around included
> in the above site.
> 
> YMMV. I have been known to be wrong before. :-)
> 
> Robert
>

Replying to myself. It seems that once again I am wrong. 

I commented out the  machdep.hyperthreading_allowed=1
in /boot/loader.conf on my 6.0 system and I still have the C column and
showing 2 processors.

Sorry about the noise.

Robert
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: enable smp / hyperthreading

2005-11-08 Thread Jeppe Larsen
On Mon, 07 Nov 2005 11:16:19 -1000, Robert Marella wrote:

> ftp://ftp.freebsd.org/pub/FreeBSD/CERT/advisories/FreeBSD-SA-05:09.htt.asc
> 

That did the trick, I think :)

-- 
regards,
Jeppe W. Larsen

"Logic is the beginning of wisdom; not the end."


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: enable smp / hyperthreading

2005-11-17 Thread dgmm
On Monday 07 November 2005 18:53, [EMAIL PROTECTED] wrote:
> Hi
>
> I've just installed 6.0-RELASE and am trying to get SMP to work (I have af
> Pentium 4 with HT). So I've compiled the kernel with 'options SMP' and
> according to dmesg the two CPUs are found:
>
> FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
>  cpu0 (BSP): APIC ID:  0
>  cpu1 (AP): APIC ID:  1
>
> But I'm not sure that both are enabled, because at this is at the end of
> dmesg and I dont see the other CPU being enabled somewhere:
>
> SMP: AP CPU #1 Launched!
>
> According to 'sysctl -a' there are 2 CPUs, but only 1 active and SMP
> doesnt seem to be disabled:
>
> kern.smp.cpus: 2
> kern.smp.disabled: 0
> kern.smp.active: 1
>
> So I thought that it might help to but 'kern.smp.active=2' in
> /boot/loader.conf, but after a reboot it is back to 1 again.
>
> What am I missing here?

I'm sure people more knowledgeable than me will be able to confirm or comment 
further on the following but here goes anyway.

From my point of view, using SMP with a single HT processor is a waste of time 
unless you routinely run multiple programmes which require an approximately 
equal amount of CPU time or you need to keep about half of your CPU time free 
for other programs.

For example, encoding video with mplayer on a P4 with SMP enabled only used 
one virtual CPU.  It encodes approx. twice as fast with SMP switched off (and 
HT switched off in BIOS)  There does appear to be some lost CPU cycles due to 
HT switching too.

Note that I've not done any serious testing or looked deeply into this 
subject.  This is simply my limited experience.

-- 
Dave
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: enable smp / hyperthreading

2005-11-21 Thread Jeppe Larsen
On Thu, 17 Nov 2005 23:02:39 +, dgmm wrote:

> From my point of view, using SMP with a single HT processor is a waste of 
> time 
> unless you routinely run multiple programmes which require an approximately 
> equal amount of CPU time or you need to keep about half of your CPU time free 
> for other programs.

What about running 'make' with some -j options? Wouldnt that take
advantage of the "two" CPUs better than if running without HT? And 'make'
is used quite often ;)

-- 
vh
Jeppe W. Larsen

"Logic is the beginning of wisdom; not the end."


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


SMP with hyperthreading CPU (5.3)?

2004-10-30 Thread Ewald Jenisch
Hi,

I've got a 3GHz P4 system with hyperthreading enabled in the BIOS. For
this system I've built a SMP-kernel (kernel config-file "SMP" that
comes with 5.3).

However SMP doesn't seem to be enabled - at least I don't seen the
usual messages like "CPU ... launched" that's common with SMP
configurations.

The only thing I'm seeing are the following entries during boot:

CPU: Intel(R) Pentium(R) 4 CPU 3.00GHz (2992.71-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf34  Stepping = 4
  Features=0xbfebfbff
  Hyperthreading: 2 logical CPUs


Neither does "top" show anything about a second (logical) cpu being
active, nor does ps.

So do I have two logical CPUs active on this system?

If not - what should I do besides enabling "SMP" in the kernel config
file (sure enough "cpu I386_CPU" which effectively disables SMP is
commented out)

Thanks much in advance for any hints,
-ewald


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: Missing machdep.hlt_logical_cpus on hyperthreading..

2003-12-12 Thread Rob
Stefan Cars wrote:
Hi, i'm reposting this since I didn't get any answer at all...

I'm having a problem, sysctl can't find machdep.hlt_logical_cpus. My machine
is a dual xeon with hyperthreading enabled, running 4.9. I also would like
to know what that "Warning: Pentium 4 CPU: PSE disabled" means.
Stefan,

In your kernel configuration file, you need following:

  optionsSMP# Symmetric MultiProcessor Kernel
  optionsAPIC_IO# Symmetric (APIC) I/O
Then machdep.hlt_logical_cpus is in your sysctl.

Can't help you with the "PSE disabled" thing.

Cheers,
Rob.
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


no hyperthreading in FreeBSD 9?

2012-01-13 Thread Marco Beishuizen

Hi,

I just upgraded from 8-STABLE to 9-STABLE on my dual Xeon (nocona). Now I 
have in my boot messages:

...
root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hlt_logical_cpus does not 
exist.
root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hyperthreading_allowed 
does not exist.

...

So isn't hyperthreading not available anymore in FreeBSD 9?

Regards,
Marco

--
If you want me to be a good little bunny
just dangle some carats in front of my nose.
-- Lauren Bacall
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


FreeBSD and Intel Hyperthreading technology.

2005-10-05 Thread Pranav Peshwe
Hello,
I have an Intel P4 2.8Ghz processor with Hyperthreading (HT).
The dmesg displays a message saying HT is present and 2 logical
CPUs present.I tried toggling the setting in BIOS but no difference.
How does the FBSD(v5.4 stable) kernel deal with HT ? Do the internal
workings( maybe locking, per processor data or other things) change as 
compared to a simple non-HT processor ? or does it use employ SMP
methods to deal with the 2 logical CPUs presented by a HT processor ?

I want to do kernel programming on FBSD and my project partners have
non-HT CPUs.How much difference will HT make ? can it be avoided ?

TIA.

Regards,
Pranav Peshwe

---
One of the greatest victories you can gain over someone is to beat him
at politeness.
 - Josh Billings

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


hyperthreading CPU and broken scheduling?

2007-11-18 Thread Wojciech Puchar

i have machune with intel's CPU with hyperthreading.

it is detected right, but only first thread is ever used.

top shows at least 50% idle no matter what i run!

what's wrong?


root@:/usr62/src/sys/amd64/compile/serwer.tensor.gdynia.pl
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: Intel(R) Pentium(R) 4 CPU 3.00GHz (3000.13-MHz K8-class CPU)
  Origin = "GenuineIntel"  Id = 0xf62  Stepping = 2

Features=0xbfebfbff
  Features2=0xe41d,>
  AMD Features=0x20100800
  AMD Features2=0x1
  Logical CPUs per core: 2
real memory  = 1072562176 (1022 MB)
avail memory = 1021456384 (974 MB)
ACPI APIC Table: 
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
ioapic0  irqs 0-23 on motherboard
acpi0:  on motherboard
acpi0: Power Button (fixed)
Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x1008-0x100b on acpi0
cpu0:  on acpi0
acpi_throttle0:  on cpu0
cpu1:  on acpi0
acpi_throttle1:  on cpu1
acpi_throttle1: failed to attach P_CNT
device_attach: acpi_throttle1 attach returned 6


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Status of hyperthreading in FreeBSD

2008-12-20 Thread Brett Glass
"Netbooks" based on Intel's "Atom" microprocessor are turning into 
big hits this Christmas season. The Atom, a super-low-power x86 
processor, is an "in-order" machine, which means that except for a 
few special cases it can spend a lot of time waiting for data to 
arrive when it encounters a cache miss. So, hyperthreading may make 
sense on this kind of processor as compared to one with out-of-order execution.


Which raises a question: What's the status of FreeBSD's support for 
hyperthreading? As far as I know, after it was revealed that some 
processes on a machine with hyperthreading could "spy" on others, 
and also that hyperthreading didn't always improve performance on 
high end processors, the feature was turned off by default. But on 
single-user machines, or on servers where the CPU was likely to be 
shared by two processes that were both privileged anyway, it might 
make sense to re-enable it. But has this feature of the scheduler 
been maintained well enough for this to be a good idea? If not, 
would it worth looking into updating it so that FreeBSD runs well on the Atom?


--Brett Glass

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: SMP with hyperthreading CPU (5.3)?

2004-10-30 Thread Luke

If not - what should I do besides enabling "SMP" in the kernel config
file (sure enough "cpu I386_CPU" which effectively disables SMP is
commented out)
I haven't updated my system since August, but back then the "apic" device 
was also required.  5.3 may be different.
This is the relevant section from my 5.2-CURRENT hyperthreading kernel 
from last August.

# To make an SMP kernel, the next two are needed
options SMP # Symmetric MultiProcessor Kernel
device  apic# I/O APIC
___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: SMP with hyperthreading CPU (5.3)?

2004-11-02 Thread Ewald Jenisch
On Sat, Oct 30, 2004 at 01:43:09PM -0700, Luke wrote:
> I haven't updated my system since August, but back then the "apic" device 
> was also required.  5.3 may be different.
> This is the relevant section from my 5.2-CURRENT hyperthreading kernel 
> from last August.
> 
> # To make an SMP kernel, the next two are needed
> options SMP # Symmetric MultiProcessor Kernel
> device  apic# I/O APIC
> 

Sorry, forgot to say, that I've got both of them in my kernel config
file, i.e. "SMP" and "apic" - however I don't get the characteristic
"CPU... launched" messages upon boot.

This brings me to another point: What's the best way (besides checking
/var/log/messages) to tell whether SMP is active?

Does "top" display cpu load for hyperthreading (as opposed to
multiprocessor) systems too?

-ewald


___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: SMP with hyperthreading CPU (5.3)?

2004-11-02 Thread Hugo Silva
[EMAIL PROTECTED]:/home/killer/] sysctl kern.smp.active
kern.smp.active: 0


> On Sat, Oct 30, 2004 at 01:43:09PM -0700, Luke wrote:
>> I haven't updated my system since August, but back then the "apic"
>> device
>> was also required.  5.3 may be different.
>> This is the relevant section from my 5.2-CURRENT hyperthreading kernel
>> from last August.
>>
>> # To make an SMP kernel, the next two are needed
>> options SMP # Symmetric MultiProcessor Kernel
>> device  apic# I/O APIC
>>
>
> Sorry, forgot to say, that I've got both of them in my kernel config
> file, i.e. "SMP" and "apic" - however I don't get the characteristic
> "CPU... launched" messages upon boot.
>
> This brings me to another point: What's the best way (besides checking
> /var/log/messages) to tell whether SMP is active?
>
> Does "top" display cpu load for hyperthreading (as opposed to
> multiprocessor) systems too?
>
> -ewald
>
>
> ___
> [EMAIL PROTECTED] mailing list
> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
> To unsubscribe, send any mail to
> "[EMAIL PROTECTED]"
>


-- 
www.6s-gaming.com

___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: no hyperthreading in FreeBSD 9?

2012-01-13 Thread Mark Blackman

On 13 Jan 2012, at 16:30, Marco Beishuizen wrote:

> Hi,
> 
> I just upgraded from 8-STABLE to 9-STABLE on my dual Xeon (nocona). Now I 
> have in my boot messages:
> ...
> root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hlt_logical_cpus does not 
> exist.
> root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hyperthreading_allowed does 
> not exist.
> ...
> 
> So isn't hyperthreading not available anymore in FreeBSD 9?

http://svnweb.freebsd.org/base/release/9.0.0/UPDATING?r1=222852&r2=222853&;

Seems to imply HT is enabled by default and new sysctls are used to take 
logical CPUs offline.

How many CPUs does your boot message suggest FreeBSD 9 is reporting?

- Mark___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: no hyperthreading in FreeBSD 9?

2012-01-13 Thread b. f.
>
> > Hi,
> >
> > I just upgraded from 8-STABLE to 9-STABLE on my dual Xeon (nocona). Now I 
> > have in my boot messages:
> > ...
> > root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hlt_logical_cpus does not 
> > exist.
> > root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hyperthreading_allowed does 
> > not exist.
> > ...
> >
> > So isn't hyperthreading not available anymore in FreeBSD 9?

I'm not sure what you mean by this double negative.  If you mean "Is
hyperthreading still available on FreeBSD?", the answer is yes.  If
you mean "Can hyperthreading still be disabled on FreeBSD?" the answer
is still yes-- only some problematic and redundant means of disabling
it that were present in earlier versions of FreeBSD have been removed.
 (The primary commit is:

http://svnweb.freebsd.org/base?view=revision&revision=222853

.)  You can still use machdep.hyperthreading_allowed, but it is now
only a (loader) tunable, and not also a sysctl, so you can only set it
at boot time (via loader.conf(5), or by using "set ..." on the
loader(8) command line), and you cannot change it on the fly after the
system is up and running.

>
> http://svnweb.freebsd.org/base/release/9.0.0/UPDATING?r1=222852&r2=222853&;
>
> Seems to imply HT is enabled by default and new sysctls are used to take
> logical CPUs offline.
>

Yes -- although that has been the case for a while, and the OIDs are
not all sysctls (some are (loader) tunables or device hints (cf.
device.hints(5)), and they are not new.

b.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: no hyperthreading in FreeBSD 9?

2012-01-14 Thread Marco Beishuizen

On Fri, 13 Jan 2012, the wise Mark Blackman wrote:


On 13 Jan 2012, at 16:30, Marco Beishuizen wrote:


Hi,

I just upgraded from 8-STABLE to 9-STABLE on my dual Xeon (nocona). Now I have 
in my boot messages:
...
root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hlt_logical_cpus does not exist.
root: /etc/rc.d/sysctl: WARNING: sysctl machdep.hyperthreading_allowed does not 
exist.
...

So isn't hyperthreading not available anymore in FreeBSD 9?


http://svnweb.freebsd.org/base/release/9.0.0/UPDATING?r1=222852&r2=222853&;

Seems to imply HT is enabled by default and new sysctls are used to take
logical CPUs offline.

How many CPUs does your boot message suggest FreeBSD 9 is reporting?


Yeah, I just deleted the lines from sysctl.conf and it doesn't seem to 
make a difference at all (2 cpu's x 2 threads).


Sorry,
Marco
--
Who on earth would eat a charred caterpillar!?
No, no, you SINGE 'em!  You SINGE 'em and eat 'em!
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Can I disable HyperThreading in OS?

2005-10-01 Thread hshh
Hi,

I have a dual XEON smp box. There is option about disable HTT in bios, but
it can't work. It's still display 4 cpu in my OS.
Can I disablt HTT in OS directly? I am running FreeBSD 4.11.

Regards.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: FreeBSD and Intel Hyperthreading technology.

2005-10-05 Thread Chad Leigh -- Shire.Net LLC


On Oct 5, 2005, at 11:48 AM, Pranav Peshwe wrote:


Hello,
I have an Intel P4 2.8Ghz processor with Hyperthreading  
(HT).

The dmesg displays a message saying HT is present and 2 logical
CPUs present.I tried toggling the setting in BIOS but no difference.
How does the FBSD(v5.4 stable) kernel deal with HT ? Do the  
internal

workings( maybe locking, per processor data or other things) change as
compared to a simple non-HT processor ? or does it use employ SMP
methods to deal with the 2 logical CPUs presented by a HT processor ?

I want to do kernel programming on FBSD and my project partners have
non-HT CPUs.How much difference will HT make ? can it be avoided ?


I would suspect that if you do not run an SMP kernel it won't matter

Chad

---
Chad Leigh -- Shire.Net LLC
Your Web App and Email hosting provider
[EMAIL PROTECTED]


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: hyperthreading CPU and broken scheduling?

2007-11-18 Thread Manolis Kiagias

Wojciech Puchar wrote:

i have machune with intel's CPU with hyperthreading.

it is detected right, but only first thread is ever used.

top shows at least 50% idle no matter what i run!

what's wrong?


root@:/usr62/src/sys/amd64/compile/serwer.tensor.gdynia.pl
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: Intel(R) Pentium(R) 4 CPU 3.00GHz (3000.13-MHz K8-class CPU)
  Origin = "GenuineIntel"  Id = 0xf62  Stepping = 2

Features=0xbfebfbff

DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
  Features2=0xe41d,>
  AMD Features=0x20100800
  AMD Features2=0x1
  Logical CPUs per core: 2
real memory  = 1072562176 (1022 MB)
avail memory = 1021456384 (974 MB)
ACPI APIC Table: 
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP): APIC ID:  1
ioapic0  irqs 0-23 on motherboard
acpi0:  on motherboard
acpi0: Power Button (fixed)
Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
acpi_timer0: <24-bit timer at 3.579545MHz> port 0x1008-0x100b on acpi0
cpu0:  on acpi0
acpi_throttle0:  on cpu0
cpu1:  on acpi0
acpi_throttle1:  on cpu1
acpi_throttle1: failed to attach P_CNT
device_attach: acpi_throttle1 attach returned 6


___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
"[EMAIL PROTECTED]"




To enable hyperthreading, try setting the following in /etc/sysctl.conf:

machdep.hyperthreading_allowed=1

and reboot (or execute sysctl machdep.hyperthreading_allowed=1 by hand).

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: hyperthreading CPU and broken scheduling?

2007-11-18 Thread Manolis Kiagias

Wojciech Puchar wrote:

http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
"[EMAIL PROTECTED]"




To enable hyperthreading, try setting the following in /etc/sysctl.conf:

machdep.hyperthreading_allowed=1

and reboot (or execute sysctl machdep.hyperthreading_allowed=1 by hand).

did /etc/rc.d/sysctl start  and works.

quite strange that FreeBSD disables hyperthreading at start.


IIRC there has been some discussion about possible vulnerabilities when 
hyperthreading is enabled. If you google around you will find it.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: hyperthreading CPU and broken scheduling?

2007-11-18 Thread Wojciech Puchar

http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
"[EMAIL PROTECTED]"




To enable hyperthreading, try setting the following in /etc/sysctl.conf:

machdep.hyperthreading_allowed=1

and reboot (or execute sysctl machdep.hyperthreading_allowed=1 by hand).

did /etc/rc.d/sysctl start  and works.

quite strange that FreeBSD disables hyperthreading at start.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: hyperthreading CPU and broken scheduling?

2007-11-18 Thread Giorgos Keramidas
On 2007-11-18 11:43, Wojciech Puchar <[EMAIL PROTECTED]> wrote:
>>> http://lists.freebsd.org/mailman/listinfo/freebsd-questions
>>> To unsubscribe, send any mail to 
>>> "[EMAIL PROTECTED]"
>> To enable hyperthreading, try setting the following in /etc/sysctl.conf:
>>
>> machdep.hyperthreading_allowed=1
>>
>> and reboot (or execute sysctl machdep.hyperthreading_allowed=1 by hand).
>
> did /etc/rc.d/sysctl start  and works.

Please, use loader.conf to change `machdep.hyperthreading_allowed'.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: hyperthreading CPU and broken scheduling?

2007-11-18 Thread Dinesh Nair
On Sun, 18 Nov 2007 12:29:32 +0200, Manolis Kiagias wrote:

> Wojciech Puchar wrote:
> > i have machune with intel's CPU with hyperthreading.
> >
> > it is detected right, but only first thread is ever used.
> >
> > top shows at least 50% idle no matter what i run!
> >
> > what's wrong?
> To enable hyperthreading, try setting the following in /etc/sysctl.conf:
> 
> machdep.hyperthreading_allowed=1
> 
> and reboot (or execute sysctl machdep.hyperthreading_allowed=1 by hand).

would an SMP kernel be required to properly use hyperthreading, or would
just the above sysctl setting be enough ?

-- 
Regards,   /\_/\   "All dogs go to heaven."
[EMAIL PROTECTED](0 0)   http://www.openmalaysiablog.com/
+==oOO--(_)--OOo==+
| for a in past present future; do|
|   for b in clients employers associates relatives neighbours pets; do   |
|   echo "The opinions here in no way reflect the opinions of my $a $b."  |
| done; done  |
+=+
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


Re: hyperthreading CPU and broken scheduling?

2007-11-19 Thread Bill Moran
In response to Dinesh Nair <[EMAIL PROTECTED]>:

> On Sun, 18 Nov 2007 12:29:32 +0200, Manolis Kiagias wrote:
> 
> > Wojciech Puchar wrote:
> > > i have machune with intel's CPU with hyperthreading.
> > >
> > > it is detected right, but only first thread is ever used.
> > >
> > > top shows at least 50% idle no matter what i run!
> > >
> > > what's wrong?
> > To enable hyperthreading, try setting the following in /etc/sysctl.conf:
> > 
> > machdep.hyperthreading_allowed=1
> > 
> > and reboot (or execute sysctl machdep.hyperthreading_allowed=1 by hand).
> 
> would an SMP kernel be required to properly use hyperthreading, or would
> just the above sysctl setting be enough ?

The SMP kernel is required as well.

-- 
Bill Moran
http://www.potentialtech.com
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


When is it worth enabling hyperthreading?

2009-10-07 Thread Pierre-Luc Drouin

Hi,

Could someone explain me in which cases it is useful to enable 
hyperthreading on a machine running FreeBSD 8.0 and in which other cases 
it is not a good idea? Is that possible that hyperthreading is 
disadvantageous unless the number of active (non-sleeping) threads is 
really high?


For example, if I have an i7 CPU with 4 physical cores and that I run 
some multi-threaded code that has only 4 threads, it will run almost 
always (twice) slower with hyperthreading enabled than when I disable it 
in the BIOS. If I understand correctly, hyperthreading has the advantage 
of being able to do CPU context switching faster than the OS, but it 
does this context switching systematically instead of only when 
requested, so it slows things down unless the number of running 
(non-sleeping) threads is greater or equal to let say the number of 
physical threads x 1.5-1.75.


Thanks!
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


When is it worth enabling hyperthreading?

2009-10-09 Thread Scott Bennett
 On Wed, 07 Oct 2009 23:24:48 -0400 Pierre-Luc Drouin
 wrote:
>Could someone explain me in which cases it is useful to enable 
>hyperthreading on a machine running FreeBSD 8.0 and in which other cases 
>it is not a good idea? Is that possible that hyperthreading is 
>disadvantageous unless the number of active (non-sleeping) threads is 
>really high?
>
>For example, if I have an i7 CPU with 4 physical cores and that I run 
>some multi-threaded code that has only 4 threads, it will run almost 
>always (twice) slower with hyperthreading enabled than when I disable it 
>in the BIOS. If I understand correctly, hyperthreading has the advantage 
>of being able to do CPU context switching faster than the OS, but it 

 No.  Both context execute simultaneously.  Each logical CPU of the
two logical CPUs in a core has its own set of registers, LDT and GDT
pointer registers, and instruction counter.  Both compete for the same
remaining set of resources:  DAT, TLB, FPU, cache (all levels for a given
core), busses to off-chip resources, and--most critically--pipeline slots
per clock cycle.  Any time a resource shared by the two logical CPUs (what
the logical CPUs execute are called "CPU threads" or "hyperthreads") is
in use by one logical CPU, it is unavailable for use by the other logical
CPU.  If a logical CPU needs a resource unavailable due to its being in
use by the other logical CPU, the late-comer's processing is suspended
until the resource is released by the other logical CPU.  Such a lockout
situation is not directly detectable in software because the locked-out
instruction is still in execution; it's just taking more than the usual
number of cycles to complete.
 On a P4 Prescott chip or the late models of single-cored Xeons,
the pipeline structure is apparently less than ideal for sustained
simultaneous execution; i.e., there are frequent pairings of instructions
that require more than the available pipeline slots of the types required
by the two parallel instructions, which causes one of them to spin until
the other moves on, opening the next cycle's set of pipeline slots.  A
simple case can demonstrate the problem, although on most systems this
example would likely be infrequent.  There is only one FPU pipeline on
these chips, so two floating-point instructions executing simultaneously
will result in one getting the FPU pipeline slot for the current cycle,
while the other one spins until the next cycle, whereupon the other side
will spin, etc.  What is actually the more common occurrence is that
other types of instruction pairs will require, for example, four slots
of a type that only has three pipelines.
 The Core i7 chips (don't know about the other Core iN series) are
alleged to have an improved assortment of pipelines w.r.t. typical
instruction mixes, although I think there is still only one FPU per core,
so the parallelism is supposed to be rather more effective on these chips
than on their forerunners in the Pentium/Xeon series.  It has been quite
a while since I last tried measuring it, but IIRC, a "make buildworld"
on my 3.4 GHz P4 Prescott takes about one to two minutes longer elapsed
time in non-hyperthreading mode with MAKEFLAGS set to "-j3" than it does
with hyperthreading enabled and MAKEFLAGS set to "-j5" (i.e., something
like 52 - 53 minutes instead of 51 minutes and a few seconds).
 Your quad-core Core i7 chips ought to provide a much greater benefit
with hyperthreading enabled, relatively speaking.  The traditional
recommendation for the -j flag for make(1) is 3*nCPUs, but hyperthreading
doesn't give you a full CPU's worth of extra processing, so your quad-core
chips won't give you a full 8 CPUs' worth.  In other words, a single,
large, parallel make job probably should have -j set to something under
24 yet still greater than 12, as a guess perhaps 20ish. :-)  But do try it
yourself at different -j values, and let us know how your timings turn out
on that chip, along with the model number of the chip.

>does this context switching systematically instead of only when 
>requested, so it slows things down unless the number of running 
>(non-sleeping) threads is greater or equal to let say the number of 
>physical threads x 1.5-1.75.
>
 In general, there is a slight gain, although running parallel
floating-point activities is a break-even situation and not worth the
bother unless you're just trying to learn OpenMP or some such.  When I've
disabled hyperthreading, interactive response has often seemed a tad less
snappy when running some CPU-bound process at the same time.  OTOH, with
hyperthreading enabled, I sometimes notice a bit more jerkiness in things
like scrolling in firefox, but it's not easy to tell what's really happening
there because firefox typically has at least 7 threads itself. :-)  Like
Bill Moran 

Re: Status of hyperthreading in FreeBSD

2008-12-20 Thread michael



Brett Glass wrote:
"Netbooks" based on Intel's "Atom" microprocessor are turning into big 
hits this Christmas season. The Atom, a super-low-power x86 processor, 
is an "in-order" machine, which means that except for a few special 
cases it can spend a lot of time waiting for data to arrive when it 
encounters a cache miss. So, hyperthreading may make sense on this 
kind of processor as compared to one with out-of-order execution.


Which raises a question: What's the status of FreeBSD's support for 
hyperthreading? As far as I know, after it was revealed that some 
processes on a machine with hyperthreading could "spy" on others, and 
also that hyperthreading didn't always improve performance on high end 
processors, the feature was turned off by default. But on single-user 
machines, or on servers where the CPU was likely to be shared by two 
processes that were both privileged anyway, it might make sense to 
re-enable it. But has this feature of the scheduler been maintained 
well enough for this to be a good idea? If not, would it worth looking 
into updating it so that FreeBSD runs well on the Atom?


--Brett Glass

as far as i know, just enabling smp will allow ht to function. also, i 
don't know if intel changed ht in the new atom processor, they could have.

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to 
"freebsd-questions-unsubscr...@freebsd.org"

___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Status of hyperthreading in FreeBSD

2008-12-20 Thread Wojciech Puchar
"Netbooks" based on Intel's "Atom" microprocessor are turning into big hits 
this Christmas season. The Atom, a super-low-power x86 processor, is an 
"in-order" machine, which means that except for a few special cases it can 
spend a lot of time waiting for data to arrive when it encounters a cache 
miss. So, hyperthreading may make sense on this kind of processor as compared 
to one with out-of-order execution.


Which raises a question: What's the status of FreeBSD's support for 
hyperthreading?

for FreeBSD it's just like 2 processors.
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Status of hyperthreading in FreeBSD

2008-12-21 Thread Ivan Voras
Brett Glass wrote:

> Which raises a question: What's the status of FreeBSD's support for
> hyperthreading? As far as I know, after it was revealed that some
> processes on a machine with hyperthreading could "spy" on others, and

Yes, but that is a hardware problem which is independent of the
operating system (it's present in all of them).

> also that hyperthreading didn't always improve performance on high end
> processors, the feature was turned off by default. But on single-user

Yes, especially on the early Pentium 4 CPUs. This is also OS-independent.

> machines, or on servers where the CPU was likely to be shared by two
> processes that were both privileged anyway, it might make sense to
> re-enable it. But has this feature of the scheduler been maintained well
> enough for this to be a good idea? If not, would it worth looking into
> updating it so that FreeBSD runs well on the Atom?

It's as good as it can be on recent ULE2 scheduler. ULE2 has support for
HTT but there's not much that can be done at the scheduler level as the
Atom is single-socket, single-core CPU.

Atom's HTT is actually pretty good - I saw up to 25% more performance
simply by using multithreading in 7zip's compression benchmark (on
WinXP, though). Of course, OTOH it uses about that much more transistors
on the CPU die so it's not exactly free performance.





signature.asc
Description: OpenPGP digital signature


Re: Status of hyperthreading in FreeBSD

2008-12-21 Thread Sam Fourman Jr.
>>
> as far as i know, just enabling smp will allow ht to function. also, i don't
> know if intel changed ht in the new atom processor, they could have.
>>
is FreeBSD's smp special in some way that it would be the exception to
the following statement.
I know there was a lot of changes made in the new ULE2 scheduler maybe
that is why?

/*
Hyper-threading relies on support in the operating system as well as
the CPU. Conventional multiprocessor support is not enough to take
advantage of hyper-threading.[1] For example, even though Windows 2000
supports multiple CPUs, Intel does not recommend that hyper-threading
be enabled under that operating system.
*/

I found this in wikipedia at the following link
http://en.wikipedia.org/wiki/Hyper-threading

Sam Fourman Jr.
Fourman Networks
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Status of hyperthreading in FreeBSD

2008-12-22 Thread Wojciech Puchar


Atom's HTT is actually pretty good - I saw up to 25% more performance
simply by using multithreading in 7zip's compression benchmark (on
WinXP, though). Of course, OTOH it uses about that much more transistors
on the CPU die so it's not exactly free performance.


really that much? i thought maybe 1-2% (just 2 sets of registers).

it would be better to put 2 much simpler cores in place of this one.

or 100 ARM7 cores ;) (it would fit)
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "freebsd-questions-unsubscr...@freebsd.org"


Re: Status of hyperthreading in FreeBSD

2008-12-22 Thread Ivan Voras
Sam Fourman Jr. wrote:
>> as far as i know, just enabling smp will allow ht to function. also, i don't
>> know if intel changed ht in the new atom processor, they could have.
> is FreeBSD's smp special in some way that it would be the exception to
> the following statement.
> I know there was a lot of changes made in the new ULE2 scheduler maybe
> that is why?
> 
> /*
> Hyper-threading relies on support in the operating system as well as
> the CPU. Conventional multiprocessor support is not enough to take
> advantage of hyper-threading.[1] For example, even though Windows 2000
> supports multiple CPUs, Intel does not recommend that hyper-threading
> be enabled under that operating system.
> */
> 
> I found this in wikipedia at the following link
> http://en.wikipedia.org/wiki/Hyper-threading

Yes, system respond variously to hyperthreading but it's mostly in two
areas:

a) Granularity of locking - systems with "big locks" like FreeBSD's
Giant was when HTT was new don't scale well in multi-CPU configurations
("logical" CPUs) and simply using HTT can expose and increase these
inefficiencies. Modern FreeBSD locking is "good enough" for 8 cores in
7.x and it's improving in 8.x.

b) Behaviour in multi-core (or multi-CPU) case when individual CPUs or
cores support HTT. This is a scheduler issue - if the scheduler isn't
aware that some logical CPU's are "fake" and some are not (i.e. if it
treats all of them equally) it could move processes or threads from one
CPU or CPU core to another when it would be much better to move it from
one "fake" (hyperthreaded) CPU to another within the same "real" CPU.

There are more similar issues here, but none of them (including those I
described) are applicable to Atom since a) locking in FreeBSD is good
enough for it in recent releases (even in 6.x) and b) there are only two
"fake" logical CPUs and they really can be treated equally.

Now, with Nehalem design (i7) the system can have a quad-core CPU
(actually, several of those) with each core supporting hyperthreading. A
system with 16 logical CPUs (2 x quadcore x HTT) isn't really strange
any more. The scheduler knows about HTT, so the issues under "a)" are
much more noticable.




signature.asc
Description: OpenPGP digital signature


Re: Status of hyperthreading in FreeBSD

2008-12-22 Thread Ivan Voras
Wojciech Puchar wrote:
>>
>> Atom's HTT is actually pretty good - I saw up to 25% more performance
>> simply by using multithreading in 7zip's compression benchmark (on
>> WinXP, though). Of course, OTOH it uses about that much more transistors
>> on the CPU die so it's not exactly free performance.
> 
> really that much? i thought maybe 1-2% (just 2 sets of registers).

Screenshots are available :)

I was also surprised because in this case both threads use the same
algorithm with the same requirements on registers. It used to be (in the
days of Pentium 4) that HTT would work best if the two threads used
different sets of instructions and registers (e.g. one doing integer
math and another doing floating point math). I guess they made more
effort this time.




signature.asc
Description: OpenPGP digital signature


Hyperthreading not working on my 5.3 FreeBSD

2005-04-03 Thread faisal gillani
Well the output of my dmesg command is only showing 1
processor , HT is enabled in bios , & working on
windows XP on the same PC.
what can be wrong ? is there anyway to enable it ?

thanks



*º¤., ¸¸,.¤º*¨¨¨*¤ Allah-hu-Akber*º¤., ¸¸,.¤º*¨¨*¤
God is the Greatest


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 
___
freebsd-questions@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-questions
To unsubscribe, send any mail to "[EMAIL PROTECTED]"


  1   2   >