diff options
author | Quentin Colombet <quentin.colombet@gmail.com> | 2022-10-12 21:23:27 +0000 |
---|---|---|
committer | Quentin Colombet <quentin.colombet@gmail.com> | 2022-11-14 18:43:34 +0000 |
commit | 41783666e4ae958e85db8e7ef04bea4ab909ab9e (patch) | |
tree | 85df74d154d41418c8c551a098d0d5bd523ce015 /llvm/lib/CodeGen/MachineCSE.cpp | |
parent | 244af24faf3a2a674f38de7b085482e9f49d76fc (diff) | |
download | llvm-41783666e4ae958e85db8e7ef04bea4ab909ab9e.zip llvm-41783666e4ae958e85db8e7ef04bea4ab909ab9e.tar.gz llvm-41783666e4ae958e85db8e7ef04bea4ab909ab9e.tar.bz2 |
[mlir][MemRef] Change the anchor point of a subview pattern
Essentially, this patches changes the anchor point of the
`extract_strided_metadata(subview)` pattern from
`extract_strided_metadata` to `subview`.
In details, this means that instead of replacing:
```
base, offset, sizes, strides = extract_strided_metadata(subview(src))
```
With
```
base, ... = extract_strided_metadata(src)
offset = <some math>
sizes = subSizes
strides = <some math>
```
We replace only the subview part and connect it back with a
reinterpret_cast:
```
val = subview(src)
```
=>
```
base, ... = extract_strided_metadata(src)
offset = <some math>
sizes = subSizes
strides = <some math>
val = reinterpret_cast base, offset, sizes, strides
```
Differential Revision: https://reviews.llvm.org/D135839
Diffstat (limited to 'llvm/lib/CodeGen/MachineCSE.cpp')
0 files changed, 0 insertions, 0 deletions