Thomas Eastman <[EMAIL PROTECTED]> writes:

> 3. What's the deal with Hyperthreading?  Am I going to need to set up an SMP 
> kernel?  Is there anything else that is important to know about configuring a 
> Hyperthreading CPU?

For the software, a HT CPU is equivalent to two CPUs: It has two machine
contexts, that means two decoders and two register files. As the
Pentium4 has a very long pipeline, mispredicted jumps stall the whole
unit for a long period. When this happens, a HT P4 simply executes the
instructions on the other thread, while a non-HT P4 wouldn't do anything
(except refilling the pipeline).

> 4.  What's the deal with the sse2 on the P4?  I vaguely remember on the 
> mailing lists there was something bad going on with either sse2 or 
> -march=pentium4 and some version of gcc... Question:  Will it be safe for me 
> to specify -march=pentium4 in my CFLAGS?

gcc doesn't use SIMD instructions (except in very rare cases), because
it is hard for a compiler to use them. Additionally, gcc doesn't
generate much faster (just bigger) code when compiling with -march=...,
if it does generate different code at all. There is usually no
significiant performance gain with it. I'd suggest to use -march=i386
and -Os (equal to -O2 with all optimizations increasing code size
disabled).

Uli
-- 
"Or have we eaten on the insane root,
 that takes the reason prisoner?"  -- MacBeth I, 3


--
[EMAIL PROTECTED] mailing list

Reply via email to