BBC BASIC for Windows
Programming >> Libraries >> CPUIDLIB
http://bb4w.conforums.com/index.cgi?board=libraries&action=display&num=1254071243

CPUIDLIB
Post by Michael Hutton on Sep 27th, 2009, 5:07pm

For those into their ASM programming they might find this library a useful add on to test for certain CPU features such as an FPU, MMX, SSE1-4 and more. You can find more detailed info about the CPUID instruction in your local friendly Intel documentation.

http://tech.groups.yahoo.com/group/bb4w/files/Libraries/CPUIDLIB.bbc

Instructions on how to use it are in the program.

Michael
Re: CPUIDLIB
Post by admin on Sep 27th, 2009, 5:29pm

Quote:
For those into their ASM programming they might find this library a useful add on

Thanks. You might like to note that this line in your library:

Code:
IF USR(C%) THEN =TRUE ELSE =FALSE 

can be directly replaced with this:

Code:
= USR(C%)<>0 

which is (arguably) neater and avoids the 'end of function' (=) being buried inside another statement.

Richard.
Re: CPUIDLIB
Post by Michael Hutton on Sep 28th, 2009, 02:35am

Good point. I'll revise it.