[llvm-commits] [llvm] r167785 - /llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp
Dirk Steinke
steinke.dirk.ml at googlemail.com
Tue Nov 13 05:42:13 PST 2012
Hi Andrew,
On 11/13/2012 12:59 AM, Andrew Trick wrote:
> Author: atrick
> Date: Mon Nov 12 17:59:48 2012
> New Revision: 167785
>
> URL: http://llvm.org/viewvc/llvm-project?rev=167785&view=rev
> Log:
> Cleanup -join-splitedges. Make the loop more obvious.
>
> Modified:
> llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp
>
> Modified: llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp?rev=167785&r1=167784&r2=167785&view=diff
> ==============================================================================
> --- llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp (original)
> +++ llvm/trunk/lib/CodeGen/RegisterCoalescer.cpp Mon Nov 12 17:59:48 2012
> @@ -234,11 +234,8 @@
>
> for (MachineBasicBlock::const_iterator MII = MBB->begin(), E = MBB->end();
> MII != E; ++MII) {
> - if (MII->isCopyLike())
> - continue;
> - if (MII->isUnconditionalBranch())
> - continue;
> - return false;
> + if (!MII->isCopyLike() || !MII->isUnconditionalBranch())
> + return false;
> }
> return true;
> }
Shouldn't this rather be
+ if (!MII->isCopyLike() && !MII->isUnconditionalBranch())
+ return false;
?
Dirk
>
>
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
More information about the llvm-commits
mailing list