Predefined Version expansion

torhu fake at address.dude
Mon Apr 2 15:15:11 PDT 2007


Dan wrote:
<snip>
> Yes, the GDC and DMD implementations support all the SSE3 instructions, but someone with a i486 Pentium Pro does not, and neither might another D implementation implementing the D language spec.
> 
> When I use an SSE3 instruction in D, is it going to raise an error if the person's system is only a Pentium Pro?
> 
> If that could be done by checking the CPU support for each instruction implicitly, then it would be even better than versioning it all off...  but I don't think that's the case - and it's not specified?
> 

Wouldn't you need runtime checking for cpu capabilities most of the time 
anyway?  The functions in std.cpuid should get you a long way in most 
cases.  Only works for x86, though.



More information about the Digitalmars-d mailing list