Why hasn't LLVM/Clang taken over MinGW as the main MSVC alternative on windows yet?
>>61227568
Can Clang even target Windows XP?
>>61227568
Windows users are late bloomers.
>>61227568
Because Stallman hates Clang, if they use it they can't claim GCC as GNU's greatest achievement.
>>61227568
Most shit, at least when they come from relatively big companies, are already compiled with Clang I suppose.
>>61227568
Because Intel compiler is years ahead of both MSVC and LLVM
GCC supports more architectures and produces faster code in the majority of cases.
>>61227568
Cool logo, that's all.
>>61231686
>using compilers that will fuck you over for not using intel products
no
>>61231698
>GCC supports more architectures
True
>produces faster code in the majority of cases.
False
>>61233922
>False
False
>>61227568
Clang is pretty smart. Compare the output of this snippet:#include <cstdio>
#include <memory>
struct state {
int val;
};
struct S {
S() : ptr(std::make_unique<state>()) {
ptr->val = 42;
}
std::unique_ptr<state> ptr;
};
std::unique_ptr<state> sink_func(std::unique_ptr<state> ptr) {
printf("%d\n", ptr->val);
return ptr;
}
int main()
{
S s;
printf("%d\n", s.ptr->val);
++s.ptr->val;
sink_func(std::move(s.ptr));
}
While GCC's O2 output still shows calls to new and delete, Clang can optimize that away.
>>61227568
>windows
Because no one gives a fuck about that shit OS anymore.
>>61234241
Clang is 1 year ahead of GCC when it comes to optimization. And Clang's diagnostics is 5 years ahead. GCC is obsolete.
>>61227568
Clang still has quite a few bugs on Windows because nobody that's paid to work on it gives a fuck whether it works on Windows or not. A lot of open source software doesn't work on Windows because Windows is shit and most decent developers refuse to use it.
>>61234257
>Clang is 1 year ahead of GCC when it comes to optimization. And Clang's diagnostics is 5 years ahead. GCC is obsolete.
Unless you compile to ARM
>>61234257
Except a GCC binary still runs faster in two out of three cases, friend.
>>61235653
>Except a GCC binary still runs faster in two out of three cases, friend.
sure, but 9 out of 10 times Clang runs much faster.
>>61234247
It's still like 90% of the desktop market though...
>>61227568
Because it's not free
>>61227568
because the logo is autistic as fuck