Due to an assembler design flaw (IMO), .symver foo,foo@v1 produces two symbols `foo` and foo@v1 if foo is defined. This has caused all sorts of linker complexity (in all of GNU ld, gold, and ld.lld AFAICT from PRs). .symver should really behave like "rename" && there should only be one defined symbol 'foo@v1'
I implemented a hack for LLD 13.0.0: https://reviews.llvm.org/D107235
Due to PR gold/28196, gold linked libc.so has many default version symbols (e.g. __free_hook@@GLIBC_2.2.5) while they should be non-default version symbols instead.
Migrating to .symver foo,foo@v1, remove can make all of GNU ld, gold, and ld.lld happier. They all implement some hacks to ensure foo and foo@v1 don't end up with two dynamic symbols. The migration is blocked on PR gas/28157 (make relocations work).
After glibc is migrated, if at some point the compatibility with the old `.symver foo,foo@v1` behavior is no longer needed, we can default gas to `,remove`. Over time, all linkers can drop their foo && foo@v1 combining hacks.