On Wed, 19 Oct 2022 at 15:56, Jonathan Yong via Gcc-patches <gcc-patches@gcc.gnu.org> wrote:
> Just pushed to master branch. Wouldn't you want to cut down on the libs respectively refine the order of the libs, though? You've now got: +#define MCFGTHREAD_SPEC " -lmcfgthread -lkernel32 -lntdll " +#else +#define MCFGTHREAD_SPEC "" +#endif #undef REAL_LIBGCC_SPEC #define REAL_LIBGCC_SPEC \ "%{mthreads:-lmingwthrd} -lmingw32 \ " SHARED_LIBGCC_SPEC " \ - -lmoldname -lmingwex -lmsvcrt -lkernel32" + -lmoldname -lmingwex -lmsvcrt -lkernel32 " MCFGTHREAD_SPEC which has kernel32 twice, which might not be ideal for the speed of linking? I'm not familiar with the content of ntdll so cannot judge if you'd put that in MCFGTHREAD_SPEC and drop kernel32 there, though, and put the whole MCFG spec simply before the kernel32 in the REAL_LIBGCC_SPEC. i.e. +#define MCFGTHREAD_SPEC " -lmcfgthread -lntdll " ... + -lmoldname -lmingwex -lmsvcrt " MCFGTHREAD_SPEC " -lkernel32 " I hope this is constructive. thanks,