diff options
author | River Riddle <riverriddle@google.com> | 2020-01-11 08:54:04 -0800 |
---|---|---|
committer | River Riddle <riverriddle@google.com> | 2020-01-11 08:54:39 -0800 |
commit | 2bdf33cc4c733342fc83081bc7410ac5e9a24f55 (patch) | |
tree | 3306d769c2bbabda1060928e0cea79d021ea9da2 /mlir/lib/Dialect/GPU/Transforms | |
parent | 1d641daf260308815d014d1bf1b424a1ed1e7277 (diff) | |
download | bcm5719-llvm-2bdf33cc4c733342fc83081bc7410ac5e9a24f55.tar.gz bcm5719-llvm-2bdf33cc4c733342fc83081bc7410ac5e9a24f55.zip |
[mlir] NFC: Remove Value::operator* and Value::operator-> now that Value is properly value-typed.
Summary: These were temporary methods used to simplify the transition.
Reviewed By: antiagainst
Differential Revision: https://reviews.llvm.org/D72548
Diffstat (limited to 'mlir/lib/Dialect/GPU/Transforms')
-rw-r--r-- | mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp b/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp index 2d00ac03d33..37f9c2e7b84 100644 --- a/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp +++ b/mlir/lib/Dialect/GPU/Transforms/KernelOutlining.cpp @@ -45,7 +45,7 @@ static void injectGpuIndexOperations(Location loc, Region &body) { // Replace the leading 12 function args with the respective thread/block index // operations. Iterate backwards since args are erased and indices change. for (int i = 11; i >= 0; --i) { - firstBlock.getArgument(i)->replaceAllUsesWith(indexOps[i]); + firstBlock.getArgument(i).replaceAllUsesWith(indexOps[i]); firstBlock.eraseArgument(i); } } @@ -66,7 +66,7 @@ static gpu::LaunchFuncOp inlineBeneficiaryOps(gpu::GPUFuncOp kernelFunc, map.map(launch.getKernelOperand(i), kernelFunc.getArgument(i)); } for (int i = launch.getNumKernelOperands() - 1; i >= 0; --i) { - auto operandOp = launch.getKernelOperand(i)->getDefiningOp(); + auto operandOp = launch.getKernelOperand(i).getDefiningOp(); if (!operandOp || !isInliningBeneficiary(operandOp)) { newLaunchArgs.push_back(launch.getKernelOperand(i)); continue; @@ -77,7 +77,7 @@ static gpu::LaunchFuncOp inlineBeneficiaryOps(gpu::GPUFuncOp kernelFunc, continue; } auto clone = kernelBuilder.clone(*operandOp, map); - firstBlock.getArgument(i)->replaceAllUsesWith(clone->getResult(0)); + firstBlock.getArgument(i).replaceAllUsesWith(clone->getResult(0)); firstBlock.eraseArgument(i); } if (newLaunchArgs.size() == launch.getNumKernelOperands()) @@ -88,7 +88,7 @@ static gpu::LaunchFuncOp inlineBeneficiaryOps(gpu::GPUFuncOp kernelFunc, SmallVector<Type, 8> newArgumentTypes; newArgumentTypes.reserve(firstBlock.getNumArguments()); for (auto value : firstBlock.getArguments()) { - newArgumentTypes.push_back(value->getType()); + newArgumentTypes.push_back(value.getType()); } kernelFunc.setType(LaunchBuilder.getFunctionType(newArgumentTypes, {})); auto newLaunch = LaunchBuilder.create<gpu::LaunchFuncOp>( |