r189440 - Disable loop vectorizer unrolling when no unrolling requested

Hal Finkel hfinkel at anl.gov
Tue Aug 27 22:18:41 PDT 2013


----- Original Message -----
> 
> 
> 
> 
> On Tue, Aug 27, 2013 at 9:40 PM, Hal Finkel < hfinkel at anl.gov >
> wrote:
> 
> 
> 
> + // In addition to the regular loop unrolling transformation, the
> loop
> + // vectorizer can also unroll loops. If no unrolling has
> specifically been
> + // requested, then also prevent the loop vectorizer from unrolling
> loops.
> + if (Args.hasFlag(options::OPT_fno_unroll_loops,
> + options::OPT_funroll_loops, false)) {
> + CmdArgs.push_back("-backend-option");
> + CmdArgs.push_back("-force-vector-unroll=1");
> Please don't use -backend-option. Essentially ever.
> 
> 
> These options force the setting of thread hostile and un-resettable
> LLVM commandline flags that are only really suitable for debugging.
> When they are used directly in the Clang driver, tools which invoke
> CC1 actions with flagsets derived from the driver multiple times in
> a single process the result of this flag will cause a crash on the
> second invocation.
> 
> 
> I fixed most of the vectorizer flags to not do this, and wrote a
> commit message explaining why. Especially when committing with
> post-commit review, please make sure that you are following the
> commit lists.

Ack... you're right. Sorry about that. I'll revert and fix this another way.

 -Hal 


-- 
Hal Finkel
Assistant Computational Scientist
Leadership Computing Facility
Argonne National Laboratory



More information about the cfe-commits mailing list