What's the oldest Mac targeted by D programmers?

Walter Bright via Digitalmars-d digitalmars-d at puremagic.com
Tue Dec 6 01:12:16 PST 2016


I've been experimenting with code generation in DMD for the AVX instruction set, 
in particular the replacement of SSE 16 byte vectors with AVX 16 byte vectors 
(no, not the 32 byte ones!).

In my experiments on my machines, two of them support the AVX instruction set,
one of which is my Mac Mini, as determined by this program:

   import core.stdc.stdio;
   import core.cpuid;

   void main() {
     printf("%d %d\n", core.cpuid.avx, core.cpuid.avx2);
   }

or by running:

   sysctl -a | grep machdep.cpu.features

and looking for AVX1.0.

My Mac Mini sez:

   ~> sysctl -a | grep machdep.cpu.features
   machdep.cpu.features: FPU VME DE PSE TSC MSR PAE MCE CX8 APIC SEP MTRR PGE
   MCA CMOV PAT PSE36 CLFSH DS ACPI MMX FXSR SSE SSE2 SS HTT TM PBE SSE3
   PCLMULQDQ DTES64 MON DSCPL VMX EST TM2 SSSE3 CX16 TPR PDCM SSE4.1 SSE4.2
   xAPIC POPCNT AES PCID XSAVE OSXSAVE TSCTMR AVX1.0

My older MM clearly does not support AVX2, though.

This leads to the question is AVX support a minimum configuration for Macs? Can 
AVX instruction generation become the default for OSX?


More information about the Digitalmars-d mailing list