MLIR  20.0.0git
Utils.h
Go to the documentation of this file.
1 //===- Utils.h - Transform utilities -----------------------------*- C++-*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 
9 #include "mlir/IR/Operation.h"
10 
11 namespace mlir {
12 namespace nvgpu {
13 
14 /// Get the indices that the given load/store operation is operating on.
16 
17 /// Set the indices that the given load/store operation is operating on.
18 void setIndices(Operation *op, ArrayRef<Value> indices);
19 
20 /// Get the value that is stored by the given store operation.
21 Value getValueStored(Operation *op);
22 
23 /// Get the memref that is loaded from/stored into by the given load/store
24 /// operation.
25 Value getMemrefOperand(Operation *op);
26 
27 } // namespace nvgpu
28 } // namespace mlir
OperandRange operand_range
Definition: Operation.h:371
void setIndices(Operation *op, ArrayRef< Value > indices)
Set the indices that the given load/store operation is operating on.
Definition: Utils.cpp:38
Value getMemrefOperand(Operation *op)
Get the memref that is loaded from/stored into by the given load/store operation.
Definition: Utils.cpp:68
Value getValueStored(Operation *op)
Get the value that is stored by the given store operation.
Definition: Utils.cpp:58
Operation::operand_range getIndices(Operation *op)
Get the indices that the given load/store operation is operating on.
Definition: Utils.cpp:18
Include the generated interface declarations.