Performance penalty for using ranges

Timon Gehr timon.gehr at gmx.ch
Sun Aug 25 15:58:28 PDT 2013


On 08/26/2013 12:46 AM, Joseph Rushton Wakeling wrote:
> On 26/08/13 00:36, Timon Gehr wrote:
>> This is uncalled for.
>
> I'm sure you didn't mean it, but your original remark, "Why would that
> be the case?", came across as flip and dismissive about a serious
> practical problem

It was a genuine question. I assumed that the inliner actually works. 
But you are right, DMD does not even seem to inline iota, and gdc 
appears to fail to vectorize some iota-loops even though it vectorizes 
the range-foreach equivalent.



More information about the Digitalmars-d mailing list