DMD backend quality (Was: Re: DIP 1031--Deprecate Brace-Style Struct Initializers--Community Review Round 1 Discussion)

Mike Parker aldacron at gmail.com
Sun Feb 16 10:55:26 UTC 2020


On Sunday, 16 February 2020 at 10:52:33 UTC, NaN wrote:
> On Sunday, 16 February 2020 at 00:16:24 UTC, H. S. Teoh wrote:
>> [Moving this to separate thread because it's tangential to DIP 
>> 1031 discussion.]
>>
>> On Sat, Feb 15, 2020 at 03:59:39PM -0800, Walter Bright via 
>> Digitalmars-d wrote:
>>> On 2/15/2020 9:58 AM, jxel wrote:
>>> > how poor quality the backend code is.
>>> 
>>> Baloney.
>>> 
>>> It's written in an older style, sure, but it's remarkably bug 
>>> free considering how complex it is. The complexity is a 
>>> result of the fiendishly complex x86 instructions set.
>>> 
>>> The proof of its quality is it has successfully been extended 
>>> from a purely 16 bit generator to 32 and extended again to 64 
>>> bit, and has been extended to support multiple ABIs and 
>>> object file formats.
>>> 
>>> The DFA optimizer has also proven to be fast and very robust.
>>
>> Unfortunately, the GDC and LDC optimizers consistently produce 
>> code that outperforms code generated by the DMD backend by 
>> 20-30%, sometimes as high as 40% for CPU-intensive code. DMD 
>> also tends to have more codegen bugs when run with -O -inline 
>> (which, ironically, still produces inferior code to what 
>> LDC/GDC produces with -O).
>
> I was seeing worse than that last time i used DMD, it was 
> mostly int code, no fpu, and it was around 60% slower with DMD 
> than LDC. Haven't used it since. SIMD support with DMD was 
> awful at the time too, dont know if thats improved.

This discussion has veered off topic. Let's please stick to 
discussion the DIP. Thanks!


More information about the Digitalmars-d mailing list