Hello! >> On Wed, Dec 31, 2014 at 01:28:47PM +0100, Allan Sandfeld Jensen wrote: >> > I recently wanted to use multiversioning for BMI2 specific extensions >> > PDEP/PEXT, and noticed it wasn't there. So I wrote this patch to add it, >> > and also added AES, F16C and BMI1 for completeness. >> >> AES nor F16C doesn't make any sense IMHO for multiversioning, you need >> special intrinsics for that anyway and when you use them, the function will >> fail to compile without those features. >> Multiversioning only makes sense for ISA features the compiler uses for >> normal C/C++ code without any intrinsics. >> > Patch reduced to just adding BMI and BMI2 multiversioning:
+2014-12-29 Allan Sandfeld Jensen <sandf...@kde.org> + + * config/i386/i386.c (get_builtin_code_for_version): Add + support for BMI and BMI2 multiversion functions. +2014-12-29 Allan Sandfeld Jensen <sandf...@kde.org> + + * gcc.target/i386/funcspec-5.c: Test new multiversion targets. + * g++.dg/ext/mv17.C: Test BMI/BMI2 multiversion dispatcher. +2014-12-29 Allan Sandfeld Jensen <sandf...@kde.org> + + * config/i386/cpuinfo.c (enum processor_features): Add FEATURE_BMI and + FEATURE_BMI2. + (get_available_features): Detect FEATURE_BMI and FEATURE_BMI2. OK for mainline (In future, please add ChangeLogs as plaintext as instructed in [1]). [1] https://gcc.gnu.org/contribute.html#patches Thanks, Uros.