[llvm] r257279 - [JumpThreading] Don't forget to report that the IR changed

Roman Divacky via llvm-commits llvm-commits at lists.llvm.org
Sun Jan 10 09:37:58 PST 2016


> Modified: llvm/trunk/lib/Transforms/Scalar/JumpThreading.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/Transforms/Scalar/JumpThreading.cpp?rev=257279&r1=257278&r2=257279&view=diff
> ==============================================================================
> --- llvm/trunk/lib/Transforms/Scalar/JumpThreading.cpp (original)
> +++ llvm/trunk/lib/Transforms/Scalar/JumpThreading.cpp Sun Jan 10 01:13:04 2016
> @@ -211,11 +211,12 @@ bool JumpThreading::runOnFunction(Functi
>    // we will loop forever. We take care of this issue by not jump threading for
>    // back edges. This works for normal cases but not for unreachable blocks as
>    // they may have cycle with no back edge.
> -  removeUnreachableBlocks(F);
> +  bool EverChanged = false;
> +  EverChanged |= removeUnreachableBlocks(F, LVI);

This is 

bool EverChanged = removeUnreachableBlocks(F, LVI); 

right?

Roman


More information about the llvm-commits mailing list