https://gcc.gnu.org/bugzilla/show_bug.cgi?id=90500
--- Comment #11 from Guobing <neochen.life at aliyun dot com> --- (In reply to Martin Liška from comment #10) > (In reply to Guobing from comment #8) > > Hi, I am the original reporter of this bug. This problem seems not happen on > > GCC8 while do on GCC9. We try to use FMV (target_clone) for some of the > > GlibC libm functions which leads us to this issue. From the Patch below, > > seems this fix the GCC9 crash issue but still not allow target_clone to be > > used together with alias. But this is allowed in GCC8 as we can compile and > > run well under GCC8. So could you help to make the behavior the same as GCC8 > > or tell us a way to walkaround it? > > Well, maybe that was allowed in GCC8, but it was not intentional. Please > describe me your use case and we can come up to a solution that will use > target_clone (or target attribute)? The background is that, we want to try optimize libm with avx2/avx512, and found that not all the libm math functions will have benefit when we generally use 'arch=haswell' or 'arch=skylake-avx512' to compile libm. So we picked those 'good' libm math functions to add FMV attribute like target_clone("default", "arch=haswell", "arch=skylake-avx512") to get performance benefit. The alias is used in libm code by default. I have no idea why these two are conflicting that not allowed by GCC9.