llvm-project/mlir/lib/Parser
Vladislav Vinogradov e41ebbecf9 [mlir][RFC] Refactor layout representation in MemRefType
The change is based on the proposal from the following discussion:
https://llvm.discourse.group/t/rfc-memreftype-affine-maps-list-vs-single-item/3968

* Introduce `MemRefLayoutAttr` interface to get `AffineMap` from an `Attribute`
  (`AffineMapAttr` implements this interface).
* Store layout as a single generic `MemRefLayoutAttr`.

This change removes the affine map composition feature and related API.
Actually, while the `MemRefType` itself supported it, almost none of the upstream
can work with more than 1 affine map in `MemRefType`.

The introduced `MemRefLayoutAttr` allows to re-implement this feature
in a more stable way - via separate attribute class.

Also the interface allows to use different layout representations rather than affine maps.
For example, the described "stride + offset" form, which is currently supported in ASM parser only,
can now be expressed as separate attribute.

Reviewed By: ftynse, bondhugula

Differential Revision: https://reviews.llvm.org/D111553
2021-10-19 12:31:15 +03:00
..
AffineParser.cpp [OpAsmParser] Add a parseCommaSeparatedList helper and beef up Delimeter. 2021-09-20 20:59:11 -07:00
AsmParserImpl.h [MLIR] Expose optional attribute parsing functions 2021-10-18 11:45:43 -07:00
AsmParserState.cpp [mlir-lsp-server] Add support for textDocument/documentSymbols 2021-06-10 10:58:39 -07:00
AttributeParser.cpp Fix parsing of hex-format index dense tensor attributes. 2021-10-08 15:44:02 +00:00
CMakeLists.txt Add a new AsmParserState class to capture detailed source information for .mlir files 2021-04-21 14:44:37 -07:00
DialectSymbolParser.cpp [mlir:OpAsm] Factor out the common bits of (Op/Dialect)Asm(Parser/Printer) 2021-09-24 20:12:19 +00:00
Lexer.cpp [Reland] [mlir] Speed up Lexer::getEncodedSourceLocation 2021-05-19 12:57:18 -07:00
Lexer.h Mass update the MLIR license header to mention "Part of the LLVM project" 2020-01-26 03:58:30 +00:00
LocationParser.cpp [OpAsmParser] Add a parseCommaSeparatedList helper and beef up Delimeter. 2021-09-20 20:59:11 -07:00
Parser.cpp [MLIR] Fix assert crash when an unregistered dialect op is encountered 2021-10-14 15:43:53 +05:30
Parser.h [OpAsmParser] Add a parseCommaSeparatedList helper and beef up Delimeter. 2021-09-20 20:59:11 -07:00
ParserState.h Add a new interface allowing to set a default dialect to be used for printing/parsing regions 2021-08-31 17:52:40 +00:00
Token.cpp [AsmParser] Fix support for zero bit integer types. 2020-12-12 21:24:18 -08:00
Token.h [mlir] Optimize the parsing of ElementsAttr hex strings 2020-10-28 16:58:06 -07:00
TokenKinds.def [mlir] Add better support for f80 and f128 2021-01-15 10:29:48 -05:00
TypeParser.cpp [mlir][RFC] Refactor layout representation in MemRefType 2021-10-19 12:31:15 +03:00