On Sat, 27 Apr 2024, Jacek Caban wrote:

On 26.04.2024 21:43, Pali Rohár wrote:
I played a bit with different msvc 19.x versions and 32-bit x86 variant
recognize time symbol and maps it to _time32 at link time. First
compiler maps time symbol to _time and then linker maps _time to
__time32. It means that msvc import libraries have symbol "time" as
alias to "_time32" function.

It can be easily played with it on godbolt:
https://godbolt.org/z/PT6WzEoaP

After adding #include <time.h> for proper time() declaration, msvc
translated at compile time it to _time64 symbol. And linker resolved
_time64 to __time64.

https://godbolt.org/z/1YY557ePK

So this shows that msvc "time" symbol in x86 32-bit object files uses
32-bit time_t type. It means that 64-bit time_t type is enforced by the
compiler which emits _time64 symbol.


Good point, that's not what I expected. Changing that seems fine to me then (as Martin said, separated from refactoring).

I guess this can be considered reasonable too.

In the commit that changes this, mention that this changes the earlier way how these symbols are interpreted, from e37b315bc039a10507c5cb1046d6b891506022be and 42aa3325fcfee934d7b706b701e49ee7a3c94982.

// Martin

_______________________________________________
Mingw-w64-public mailing list
Mingw-w64-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/mingw-w64-public

Reply via email to