2006/1/13, Trenton Adams <[EMAIL PROTECTED]>:
> On 1/12/06, John Myers <[EMAIL PROTECTED]> wrote:
> > On Thursday 12 January 2006 18:45, Tom Smith wrote:
> > > Well, if they're /not/ mutually exclusive, another question that comes
> > > up is...
> > >
> > > If a program is compiled with sse or sse2 support on a Pentium II, will
> > > the program run slower than it otherwise would? (Some of the programs I
> > > have are compiled and then distributed to servers with different
> > > CPUs--P-IIs and P-IVs, mainly.)
> > >
> >
> > If a program uses an instruction that the processor doesn't support, the
> > program will be sent SIGILL, the default action of which is to terminate
> > immediately.
>
> Are you absolutely positive of that?  I *thought* (would have thought)
> compilers these days would compile in conditional use of such
> instructions?  That way if large blocks could benefit from these new
> instructions, they would use them, otherwise fall back to a common set
> of instructions.  Of course this wouldn't be very beneficial for small
> sections of code.  I've been wondering about this for quite some time
> though, but never bothered to investigate.

GCC does make architecture exclusive code, specially with optimed for
size code. For example, code that is compiled with -march=pentium4
won't run in PIII and will give you error messages, like SIGILL or
more verbose error like Invalid Instruction or something like that.

>
> > --
> > #
> > # electronerd, the electronerdian from electronerdia
> > #
> >
> >
> >
>
> --
> [email protected] mailing list
>
>

-- 
[email protected] mailing list

Reply via email to