SDL (1.2.6) CPU identification bug

Pentium 4 Mobile chips may crash with an illegal instruction.

The problem has to do with this code:

	f=CPU_Flags();
            if((f&(TDNOW_CPU|MMX_CPU))==(TDNOW_CPU|MMX_CPU))
	    return BlitRGBtoRGBPixelAlphaMMX3DNOW;

Unfortunately, the P4M has those bits set, even though it’s not an Athlon
of any sort. This results in SIGILL crashes.

-s

Pentium 4 Mobile chips may crash with an illegal instruction.

The problem has to do with this code:

  f=CPU_Flags();
            if((f&(TDNOW_CPU|MMX_CPU))==(TDNOW_CPU|MMX_CPU))
      return BlitRGBtoRGBPixelAlphaMMX3DNOW;

Unfortunately, the P4M has those bits set, even though it’s not an Athlon
of any sort. This results in SIGILL crashes.

This is fixed in CVS, along with a new API for CPU feature detection.
Feel free to check it out!
http://www.libsdl.org/cvs/SDL-1.2.tar.gz (PRERELEASE CODE)

See ya!
-Sam Lantinga, Software Engineer, Blizzard Entertainment