[PATCH] CodeGenPrep: rewrite a few loops in C++11 style

Ramkumar Ramachandra artagnon at gmail.com
Wed Jan 7 15:23:41 PST 2015


Sean Silva wrote:
>> It depends on what you want to construct from the iteration.
>
> Why did you choose Function::iterator instead of BasicBlock &?

Honestly? Because this doesn't work:

    for (BasicBlock &BB : F)
      EverMadeChange |= bypassSlowDivision(F, &BB, BypassWidths);

I'm going to refactor the other two hunks to do BasicBlock and revert
this hunk, before resubmitting.



More information about the llvm-commits mailing list