What does HackerNews think of llvm-mingw?

An LLVM/Clang/LLD based mingw-w64 toolchain

Language: C

> AFAIK there is no native GCC compiler for Windows

might want to check your facts before spouting nonsense. there is, and has been for many, many years. more than one in fact:

https://github.com/mstorsjo/llvm-mingw

https://packages.msys2.org/base/mingw-w64-gcc

https://mirrors.kernel.org/sourceware/cygwin/x86_64/release/...

Visual Studio is a bloated mess, and has been for many years. Its at least 10 times larger than other options, such as MinGW-LLVM:

https://github.com/mstorsjo/llvm-mingw

Sadly Qt ships MinGW 8.1 which is positively ancient (released in 2018). If you're starting a new project (which you likely are if you are installing an IDE aha) there's no reason not to go for more recent compilers - msys2 has GCC12 (https://packages.msys2.org/package/mingw-w64-x86_64-gcc) and Clang 14 (https://packages.msys2.org/package/mingw-w64-x86_64-clang) which just work better overall, have much more complete C++20 support, have less bugs, better compile times (especially clang with the various PCH options that appeared in the last few versions), better static analysis, etc.

Personally I use https://github.com/mstorsjo/llvm-mingw's releases directly which does not require MSYS but that's because I recompile all my libraries with specific options - if the MSYS libs as they are built are good for you there's no reason not to use them.

Clang (and lld) do support native TLS, and mingw-w64 does have the things that are needed. I think binutils also might have what's needed too, but AFAIK the thing that's missing is support for it in GCC.

Actually, (upstream) Clang defaults to native TLS instead of emulated TLS. In MSYS2, Clang is overridden to use emulated TLS by deafult to interoperate better with GCC built code and libstdc++ though.

The toolchain I maintain, https://github.com/mstorsjo/llvm-mingw, defaults to native TLS throughout.

Hello,

Win32 is supported with MSVC just fine.

You can also use MinGW with LLVM (not MinGW with GCC), available at: https://github.com/mstorsjo/llvm-mingw

In the same vein I've been using https://github.com/mstorsjo/llvm-mingw + lld + cmake + ninja on windows for over a year with great success, dev experience is much better than with MSVC.