https://gcc.gnu.org/bugzilla/show_bug.cgi?id=91664
Martin Liška <marxin at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|ASSIGNED |WAITING --- Comment #9 from Martin Liška <marxin at gcc dot gnu.org> --- (In reply to Richard Biener from comment #7) > The issue is that with a declaration like > > double fmv_test (double *dArray, int size) __attribute__ ((__target_clones__ > ("avx2","avx","sse4.1","sse2","default"))); > > we're creating a resolver even if there's no definition of fmv_test visible. > We shouldn't do that. We should only emit resolvers for definitions. Are you sure we want to generate resolver only for definitions? Similarly to normal declarations, it's linkers job to resolve symbols and eventually print errors. I don't see why the linker bails out when the archive is used.