If we are extracting it is more useful to push the index_cast past the
extraction. This increases the chance the tensor.extract can evaluated at
compile time.
Details
Details
- Reviewers
rriddle - Commits
- rG7c984be21a35: [mlir] Propagate arith.index_cast past tensor.extract
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
Missing a test?
mlir/lib/Dialect/Tensor/IR/TensorOps.cpp | ||
---|---|---|
428–429 | Does this generalize to other similar element casts? |
mlir/lib/Dialect/Tensor/IR/TensorOps.cpp | ||
---|---|---|
428–429 | This would hold true for any cast op. So feasibly I could template this and repeat for all of Arith's cast operations. |
mlir/lib/Dialect/Tensor/IR/TensorOps.cpp | ||
---|---|---|
452 |
Does this generalize to other similar element casts?