Do you think if statement as expression would be nice to have in D?
Bruce Carneal
bcarneal at gmail.com
Tue Jun 7 06:16:03 UTC 2022
On Tuesday, 7 June 2022 at 04:53:36 UTC, bauss wrote:
> On Tuesday, 7 June 2022 at 01:24:07 UTC, Walter Bright wrote:
>>
>> There is a persistent idea that there is something
>> fundamentally wrong with DMD. There isn't. It's just that
>> optimization involves an accumulation of a large number of
>> special cases, and clang has a lot of people adding special
>> cases.
>>
>
> I have only ever used DMD, never bothered using anything else
> and it has never hindered any of my work or mattered in the
> slightest.
>
> Nothing I work with suffers from the difference in optimization
> as I don't have anything that's real-time sensitive.
>
> As long as the work is done in a reasonable amount of time
> (That of course depends on what it is.) then I'm fine with it.
>
> Typically the difference is in the milliseconds, which won't
> matter much for most enterprise work.
Mileage varies of course. If watts and/or throughput is
important, and you're working on something that admits data
parallelism, ldc and gdc can help. Here's an example of a 32X
speedup (16X if you cripple the target):
https://godbolt.org/z/bT7qKnfMP
More information about the Digitalmars-d
mailing list