summaryrefslogtreecommitdiffstats
path: root/polly/lib/CodeGen/PPCGCodeGeneration.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'polly/lib/CodeGen/PPCGCodeGeneration.cpp')
-rw-r--r--polly/lib/CodeGen/PPCGCodeGeneration.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/polly/lib/CodeGen/PPCGCodeGeneration.cpp b/polly/lib/CodeGen/PPCGCodeGeneration.cpp
index d0ae82aec3c..20ab4999cf7 100644
--- a/polly/lib/CodeGen/PPCGCodeGeneration.cpp
+++ b/polly/lib/CodeGen/PPCGCodeGeneration.cpp
@@ -880,7 +880,8 @@ GPUNodeBuilder::getBlockSizes(ppcg_kernel *Kernel) {
Value *GPUNodeBuilder::createLaunchParameters(ppcg_kernel *Kernel,
Function *F) {
- Type *ArrayTy = ArrayType::get(Builder.getInt8PtrTy(), F->getNumOperands());
+ Type *ArrayTy = ArrayType::get(Builder.getInt8PtrTy(),
+ std::distance(F->arg_begin(), F->arg_end()));
BasicBlock *EntryBlock =
&Builder.GetInsertBlock()->getParent()->getEntryBlock();
OpenPOWER on IntegriCloud