dmd codegen improvements
Jonathan M Davis via Digitalmars-d
digitalmars-d at puremagic.com
Fri Aug 21 07:50:43 PDT 2015
On Friday, 21 August 2015 at 02:02:57 UTC, rsw0x wrote:
> On Friday, 21 August 2015 at 01:20:27 UTC, jmh530 wrote:
>> On Friday, 21 August 2015 at 00:00:09 UTC, H. S. Teoh wrote:
>>>
>>> The gdc version, by contrast, inlines *everything*,
>>
>> This could be why I've observed performance differentials in
>> dmd for doing some manual for loops rather than using the
>> stuff in std.algorithms.
>
> ldc and gdc typically produce output nearly the same as
> handwritten loops for ranges.
Which is really what we need to be happening with ranges. The
fact that they make code so much more idiomatic helps a _lot_,
making code faster to write and easier to understand and
maintain, but if we're taking performance hits from it, then we
start losing out to C++ code pretty quickly, which is _not_ what
we want.
- Jonathan M Davis
More information about the Digitalmars-d
mailing list