Zig's Andrew Kelley: "The compiler is too dam slow, that's why we have bugs..."
Steven Schveighoffer
schveiguy at gmail.com
Wed Jan 31 20:28:53 UTC 2024
On Wednesday, 31 January 2024 at 08:54:36 UTC, Paolo Invernizzi
wrote:
> On Wednesday, 31 January 2024 at 02:34:34 UTC, Steven
> Schveighoffer wrote:
>> On Tuesday, 30 January 2024 at 20:29:02 UTC, cc wrote:
>>> [...]
>>
>> I see a lot of posts about the speed of dmd. I've been
>> basically using ldc exclusively when I switched to mac M1,
>> and, I haven't been very disappointed.
>>
>> I'll say this, compiling my work project with dmd is 100x
>> slower than compiling my personal projects with ldc.
>>
>> I don't know if it's LLVM, is all I'm saying.
>>
>
> As dmd is x86_64, on Apple silicon it uses rosetta, so ldc
> which is aarch64 is faster as a compiler.
Work project is built with dmd on x86_64 linux.
My point really is that LDC is comparable, and still lightyears
ahead (in speed) of the likes of C++ and Rust. I don't know what
Zig is planning to achieve by removing LLVM, but I am comfortable
with the time taken so far. It helps to have 2 things to compare
such that you can judge what the true benefit will be. I wonder
if Zig has gone through that exercise, or is just undergoing this
large upheaval on the *hopes* that it makes things much faster
(Disclaimer, I'm reacting to posts here, I haven't watched the
video).
In my experience, the thing that slows down compilation is the
complexity of the code, especially when using
templates/generative code. That is all front-end stuff. I'd
rather we work on fixing that.
-Steve
More information about the Digitalmars-d
mailing list