Before I spend time and money downloading Xcode 4, can开发者_运维知识库 anyone tell me whether it comes with a version of gcc (or any other compiler, e.g. LLVM) which supports the AVX instruction set on Sandy Bridge CPUs (i.e. gcc -mavx
on mainstream gcc builds) ? I don't seen any public release notes anywhere so it's not easy to check, and I don't really need Xcode 4 yet unless it has AVX support.
I eventually cracked and downloaded Xcode 4 - it looks like clang is the only compiler that may support AVX currently, although I haven't tested it properly:
$ clang -dM -E -mavx - < /dev/null | grep -i avx
#define __AVX__ 1
精彩评论