[polly] r234113 - Do not use the POLLY vector code generator if only strip-mining is requested

Tobias Grosser tobias at grosser.es
Sat Apr 4 23:53:21 PDT 2015


Author: grosser
Date: Sun Apr  5 01:53:21 2015
New Revision: 234113

URL: http://llvm.org/viewvc/llvm-project?rev=234113&view=rev
Log:
Do not use the POLLY vector code generator if only strip-mining is requested

This fixes http://llvm.org/PR23127

Reported-by: Jeremy Huddleston Sequoia <jeremyhu at apple.com>

Modified:
    polly/trunk/lib/CodeGen/IslCodeGeneration.cpp
    polly/trunk/test/Isl/CodeGen/simple_vec_assign_scalar.ll

Modified: polly/trunk/lib/CodeGen/IslCodeGeneration.cpp
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/lib/CodeGen/IslCodeGeneration.cpp?rev=234113&r1=234112&r2=234113&view=diff
==============================================================================
--- polly/trunk/lib/CodeGen/IslCodeGeneration.cpp (original)
+++ polly/trunk/lib/CodeGen/IslCodeGeneration.cpp Sun Apr  5 01:53:21 2015
@@ -693,7 +693,7 @@ void IslNodeBuilder::createForParallel(_
 }
 
 void IslNodeBuilder::createFor(__isl_take isl_ast_node *For) {
-  bool Vector = PollyVectorizerChoice != VECTORIZER_NONE;
+  bool Vector = PollyVectorizerChoice == VECTORIZER_POLLY;
 
   if (Vector && IslAstInfo::isInnermostParallel(For) &&
       !IslAstInfo::isReductionParallel(For)) {

Modified: polly/trunk/test/Isl/CodeGen/simple_vec_assign_scalar.ll
URL: http://llvm.org/viewvc/llvm-project/polly/trunk/test/Isl/CodeGen/simple_vec_assign_scalar.ll?rev=234113&r1=234112&r2=234113&view=diff
==============================================================================
--- polly/trunk/test/Isl/CodeGen/simple_vec_assign_scalar.ll (original)
+++ polly/trunk/test/Isl/CodeGen/simple_vec_assign_scalar.ll Sun Apr  5 01:53:21 2015
@@ -1,4 +1,5 @@
 ; RUN: opt %loadPolly -polly-detect-unprofitable -basicaa -polly-codegen-isl -polly-vectorizer=polly -dce -S < %s | FileCheck %s
+; RUN: opt %loadPolly -polly-detect-unprofitable -basicaa -polly-codegen-isl -polly-vectorizer=stripmine -dce -S < %s | FileCheck %s --check-prefix=STRIPMINE
 
 ;#define N 1024
 ;float A[N];
@@ -55,6 +56,8 @@ bb:
   ret i32 %tmp1
 }
 
+; STRIPMINE-NOT: <4 x float>
+
 ; CHECK: %tmp_p_vec_full = load <4 x float>, <4 x float>* bitcast ([1024 x float]* @A to <4 x float>*), align 8, !alias.scope !0, !noalias !2
 ; CHECK: %tmp4p_vec = fadd <4 x float> %tmp_p_vec_full, <float 1.000000e+00, float 1.000000e+00, float 1.000000e+00, float 1.000000e+00>
 ; CHECK: store <4 x float> %tmp4p_vec, <4 x float>* bitcast ([1024 x float]* @B to <4 x float>*), align 8, !alias.scope !3, !noalias !4





More information about the llvm-commits mailing list