On Fri, 14 Jan 2022, Pali Rohár wrote:

Thank you very much for information!

Could you point me where I can find source code of that mingw runtime
pseudo relocations fixer? It is in mingw-w64 or in libgcc code base?

It's here: https://github.com/mingw-w64/mingw-w64/blob/master/mingw-w64-crt/crt/pseudo-reloc.c

And how smart is LTO optimization for these cases? Could be usage of
regularGlobal and regularFunction postponed to LTO phase and converted
to __imp_?

Hmm, interesting idea. In theory I guess it should be possible to figure out such details, by having access to all the symbols involved before actually doing the LTO compilation, and then feeding that info into the LTO compilation. But in practice I think it's hard to achieve this due to the layering between linker and LTO compiler.

// Martin

_______________________________________________
Mingw-w64-public mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to