在 2023/12/1 17:09, Richard Biener via Gcc 写道:
Hmm, so why's it then referenced and not "GCed"?The classical "solution" is to make the reference weak via sth like extern typeof(fork) fork () __attribute__((weak));
There are issues about weak symbols on mingw targets. Calls to weak functions can jump to random, non-allocated memory and cause faults. Instead, duplicates of COMDAT sections are removed by the `.linkonce discard` directive.
-- Best regards, LIU Hao
OpenPGP_signature.asc
Description: OpenPGP digital signature