[llvm] r179825 - Don't run expensive -O2 and -O3 in tests.

Benjamin Kramer benny.kra at gmail.com
Fri Apr 19 01:49:53 PDT 2013


On 19.04.2013, at 03:10, Jakub Staszak <kubastaszak at gmail.com> wrote:

> Author: kuba
> Date: Thu Apr 18 20:10:45 2013
> New Revision: 179825
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=179825&view=rev
> Log:
> Don't run expensive -O2 and -O3 in tests.
> 
> Modified:
>    llvm/trunk/test/Transforms/GlobalDCE/complex-constantexpr.ll
>    llvm/trunk/test/Transforms/PhaseOrdering/scev.ll
> 
> Modified: llvm/trunk/test/Transforms/GlobalDCE/complex-constantexpr.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/GlobalDCE/complex-constantexpr.ll?rev=179825&r1=179824&r2=179825&view=diff
> ==============================================================================
> --- llvm/trunk/test/Transforms/GlobalDCE/complex-constantexpr.ll (original)
> +++ llvm/trunk/test/Transforms/GlobalDCE/complex-constantexpr.ll Thu Apr 18 20:10:45 2013
> @@ -1,4 +1,4 @@
> -; RUN: opt -O2 -disable-output < %s
> +; RUN: opt -globaldce -disable-output < %s
> ; PR15714

This test relied on other passes being run. One of the earlier passes transforms turns the loops into a big constantexpr (the textual form of constantexpr is inefficient and I didn't want to include megabytes of text in a testcase, that's also the reason why it passes -disable-output). GlobalDCE then hung itself because the large constexpr triggered exponential behavior.

I couldn't figure out the exact set of passes that triggers this behavior so I just included -O2. Now the test isn't testing what I intended it to do.

> 
> %struct.ham = type { i32 }
> 
> Modified: llvm/trunk/test/Transforms/PhaseOrdering/scev.ll
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/test/Transforms/PhaseOrdering/scev.ll?rev=179825&r1=179824&r2=179825&view=diff
> ==============================================================================
> --- llvm/trunk/test/Transforms/PhaseOrdering/scev.ll (original)
> +++ llvm/trunk/test/Transforms/PhaseOrdering/scev.ll Thu Apr 18 20:10:45 2013
> @@ -1,4 +1,4 @@
> -; RUN: opt -O3 -S -analyze -scalar-evolution < %s | FileCheck %s
> +; RUN: opt -S -analyze -scalar-evolution < %s | FileCheck %s

This test checked whether passes in -O3 create IR that SCEV doesn't understand, now the test is worthless.

Please revert this change.

- Ben

> ;
> ; This file contains phase ordering tests for scalar evolution.
> ; Test that the standard passes don't obfuscate the IR so scalar evolution can't
> 
> 
> _______________________________________________
> 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