[PATCH] D28221: Add check for AVX512 support before assuming skylake processor is SKX.

Craig Topper via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Jan 4 10:20:50 PST 2017


craig.topper added a comment.

Go ahead and add the feature check for 0x55. That's probably safest. And it's the only difference between "skylake" and "skylake-avx512".

I recommend anyone using getHostCPUName to also use getHostCPUFeatures to truly be safe. The are low end 0x4e and 0x5e processors in the world that don't even support AVX1. We used to have code in getHostCPUName that downgraded any such processors all the way down to "nehalem" which removed a bunch of other features and changed the scheduling model. Thus why getHostCPUFeatures is recommended so you can get the CPU name for the scheduling model, but the features come from proper detection.


https://reviews.llvm.org/D28221





More information about the llvm-commits mailing list