6
6
//
7
7
// ===----------------------------------------------------------------------===//
8
8
9
- #ifndef MLIR_DIALECT_VECTOR_VECTORUTILS_H_
10
- #define MLIR_DIALECT_VECTOR_VECTORUTILS_H_
9
+ #ifndef MLIR_DIALECT_VECTOR_UTILS_VECTORUTILS_H_
10
+ #define MLIR_DIALECT_VECTOR_UTILS_VECTORUTILS_H_
11
11
12
12
#include " mlir/IR/BuiltinAttributes.h"
13
13
#include " mlir/Support/LLVM.h"
@@ -47,15 +47,6 @@ int64_t computeMaxLinearIndex(ArrayRef<int64_t> basis);
47
47
SmallVector<int64_t , 4 > computeStrides (ArrayRef<int64_t > shape,
48
48
ArrayRef<int64_t > sizes);
49
49
50
- // / Computes and returns the linearized index of 'offsets' w.r.t. 'basis'.
51
- int64_t linearize (ArrayRef<int64_t > offsets, ArrayRef<int64_t > basis);
52
-
53
- // / Given the strides together with a linear index in the dimension
54
- // / space, returns the vector-space offsets in each dimension for a
55
- // / de-linearized index.
56
- SmallVector<int64_t , 4 > delinearize (ArrayRef<int64_t > strides,
57
- int64_t linearIndex);
58
-
59
50
// / Given the target sizes of a vector, together with vector-space offsets,
60
51
// / returns the element-space offsets for each dimension.
61
52
SmallVector<int64_t , 4 >
@@ -158,38 +149,6 @@ AffineMap
158
149
makePermutationMap (Operation *insertPoint, ArrayRef<Value> indices,
159
150
const DenseMap<Operation *, unsigned > &loopToVectorDim);
160
151
161
- // / Build the default minor identity map suitable for a vector transfer. This
162
- // / also handles the case memref<... x vector<...>> -> vector<...> in which the
163
- // / rank of the identity map must take the vector element type into account.
164
- AffineMap getTransferMinorIdentityMap (ShapedType shapedType,
165
- VectorType vectorType);
166
-
167
- // / Return true if we can prove that the transfer operations access disjoint
168
- // / memory.
169
- bool isDisjointTransferSet (VectorTransferOpInterface transferA,
170
- VectorTransferOpInterface transferB);
171
-
172
- // / Same behavior as `isDisjointTransferSet` but doesn't require the operations
173
- // / to have the same tensor/memref. This allows comparing operations accessing
174
- // / different tensors.
175
- bool isDisjointTransferIndices (VectorTransferOpInterface transferA,
176
- VectorTransferOpInterface transferB);
177
-
178
- // / Return true if the transfer_write fully writes the data accessed by the
179
- // / transfer_read.
180
- bool checkSameValueRAW (vector::TransferWriteOp defWrite,
181
- vector::TransferReadOp read);
182
-
183
- // / Return true if the write op fully over-write the priorWrite transfer_write
184
- // / op.
185
- bool checkSameValueWAW (vector::TransferWriteOp write,
186
- vector::TransferWriteOp priorWrite);
187
-
188
- // Helper that returns a subset of `arrayAttr` as a vector of int64_t.
189
- SmallVector<int64_t , 4 > getI64SubArray (ArrayAttr arrayAttr,
190
- unsigned dropFront = 0 ,
191
- unsigned dropBack = 0 );
192
-
193
152
namespace matcher {
194
153
195
154
// / Matches vector.transfer_read, vector.transfer_write and ops that return a
@@ -205,4 +164,4 @@ bool operatesOnSuperVectorsOf(Operation &op, VectorType subVectorType);
205
164
} // namespace matcher
206
165
} // namespace mlir
207
166
208
- #endif // MLIR_DIALECT_VECTOR_VECTORUTILS_H_
167
+ #endif // MLIR_DIALECT_VECTOR_UTILS_VECTORUTILS_H_
0 commit comments