#
659192b1 |
| 18-Oct-2024 |
Rahul Joshi <rjoshi@nvidia.com> |
[NFC][MLIR][TableGen] Eliminate `llvm::` for commonly used types (#112456)
Eliminate `llvm::` namespace qualifier for commonly used types in MLIR
TableGen backends to reduce code clutter.
|
#
e768b076 |
| 16-Oct-2024 |
Rahul Joshi <rjoshi@nvidia.com> |
[MLIR][TableGen] Use const pointers for various `Init` objects (#112562)
This reverts commit 0eed3055511381436ee69d1caf64a4af47f8d65c and applies
additional fixes in `verifyArgument` in OmpOpGen.cp
[MLIR][TableGen] Use const pointers for various `Init` objects (#112562)
This reverts commit 0eed3055511381436ee69d1caf64a4af47f8d65c and applies
additional fixes in `verifyArgument` in OmpOpGen.cpp for gcc-7 bot
failures
show more ...
|
#
0eed3055 |
| 16-Oct-2024 |
Mehdi Amini <joker.eph@gmail.com> |
Revert "[MLIR][TableGen] Use const pointers for various `Init` objects" (#112506)
Reverts llvm/llvm-project#112316
Bots are failing.
|
#
1ae9fe5e |
| 15-Oct-2024 |
Rahul Joshi <rjoshi@nvidia.com> |
[MLIR][TableGen] Use const pointers for various `Init` objects (#112316)
Use const pointers for various `Init` objects. This is a part of effort
to have better const correctness in TableGen backend
[MLIR][TableGen] Use const pointers for various `Init` objects (#112316)
Use const pointers for various `Init` objects. This is a part of effort
to have better const correctness in TableGen backends:
https://discourse.llvm.org/t/psa-planned-changes-to-tablegen-getallderiveddefinitions-api-potential-downstream-breakages/81089
show more ...
|
#
d256b9e8 |
| 02-Oct-2024 |
Rahul Joshi <rjoshi@nvidia.com> |
[TableGen] Change `DefInit::Def` to a const Record pointer (#110747)
This change undoes a const_cast<> introduced in an earlier change to
help transition to const pointers. It is a part of effort t
[TableGen] Change `DefInit::Def` to a const Record pointer (#110747)
This change undoes a const_cast<> introduced in an earlier change to
help transition to const pointers. It is a part of effort to have better
const correctness in TableGen backends:
https://discourse.llvm.org/t/psa-planned-changes-to-tablegen-getallderiveddefinitions-api-potential-downstream-breakages/81089
show more ...
|
#
4f81805a |
| 11-Dec-2022 |
Kazu Hirata <kazu@google.com> |
[mlir] Use std::optional instead of None in comments (NFC)
This is part of an effort to migrate from llvm::Optional to std::optional:
https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasval
[mlir] Use std::optional instead of None in comments (NFC)
This is part of an effort to migrate from llvm::Optional to std::optional:
https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716
show more ...
|
#
3cfe412e |
| 06-Dec-2022 |
Fangrui Song <i@maskray.me> |
[TableGen] llvm::Optional => std::optional
|
#
1a36588e |
| 04-Dec-2022 |
Kazu Hirata <kazu@google.com> |
[mlir] Use std::nullopt instead of None (NFC)
This patch mechanically replaces None with std::nullopt where the compiler would warn if None were deprecated. The intent is to reduce the amount of ma
[mlir] Use std::nullopt instead of None (NFC)
This patch mechanically replaces None with std::nullopt where the compiler would warn if None were deprecated. The intent is to reduce the amount of manual work required in migrating from Optional to std::optional.
This is part of an effort to migrate from llvm::Optional to std::optional:
https://discourse.llvm.org/t/deprecating-llvm-optional-x-hasvalue-getvalue-getvalueor/63716
show more ...
|
#
a29fffc4 |
| 09-Aug-2022 |
Lei Zhang <antiagainst@google.com> |
[mlir][spirv] Migrate to use specalized enum attributes
Previously we are using IntegerAttr to back all SPIR-V enum attributes. Therefore we all such attributes are showed like IntegerAttr in IRs, w
[mlir][spirv] Migrate to use specalized enum attributes
Previously we are using IntegerAttr to back all SPIR-V enum attributes. Therefore we all such attributes are showed like IntegerAttr in IRs, which is barely readable and breaks roundtripability of the IR. This commit changes to use `EnumAttr` as the base directly so that we can have separate attribute definitions and better IR printing.
Reviewed By: kuhar
Differential Revision: https://reviews.llvm.org/D131311
show more ...
|
#
d883a02a |
| 21-Jun-2022 |
Mogball <jeffniu22@gmail.com> |
[mlir][ods] Remove StructAttr
Depends on D127373
Reviewed By: rriddle
Differential Revision: https://reviews.llvm.org/D127375
|
#
bf352e0b |
| 03-May-2022 |
River Riddle <riddleriver@gmail.com> |
[mlir:PDLL] Add better support for providing Constraint/Pattern/Rewrite documentation
This commit enables providing long-form documentation more seamlessly to the LSP by revamping decl documentation
[mlir:PDLL] Add better support for providing Constraint/Pattern/Rewrite documentation
This commit enables providing long-form documentation more seamlessly to the LSP by revamping decl documentation. For ODS imported constructs, we now also import descriptions and attach them to decls when possible. For PDLL constructs, the LSP will now try to provide documentation by parsing the comments directly above the decls location within the source file. This commit also adds a new parser flag `enableDocumentation` that gates the import and attachment of ODS documentation, which is unnecessary in the normal build process (i.e. it should only be used/consumed by tools).
Differential Revision: https://reviews.llvm.org/D124881
show more ...
|
#
4e5dee2f |
| 25-Apr-2022 |
jfurtek <jfurtek@nvidia.com> |
[mlir][ods] Add tablegen field for concise printing of BitEnum attributes
This diff introduces a tablegen field for bit enum attributes (`printBitEnumPrimaryGroups`) to control printing when the enu
[mlir][ods] Add tablegen field for concise printing of BitEnum attributes
This diff introduces a tablegen field for bit enum attributes (`printBitEnumPrimaryGroups`) to control printing when the enum uses "group" cases. An example would be an implementation that uses a `fastmath` enum value as an alias for individual fastmath flags. The proposed field would allow printing of simply `fast` for the enum value, instead of the more verbose list that would include `fast` as well as the individual flags (e.g. `reassoc,nnan, ninf,nsz,arcp,contract,afn,fast`).
Reviewed By: rriddle
Differential Revision: https://reviews.llvm.org/D123871
show more ...
|
#
60e34f8d |
| 02-Mar-2022 |
Mogball <jeffniu22@gmail.com> |
[mlir][ods] Remove StrEnumAttr
StrEnumAttr has been deprecated in favour of EnumAttr, a solution based on AttrDef (https://reviews.llvm.org/D115181). This patch removes StrEnumAttr, along with all t
[mlir][ods] Remove StrEnumAttr
StrEnumAttr has been deprecated in favour of EnumAttr, a solution based on AttrDef (https://reviews.llvm.org/D115181). This patch removes StrEnumAttr, along with all the custom ODS logic required to handle it.
See https://discourse.llvm.org/t/psa-stop-using-strenumattr-do-use-enumattr/5710 on how to transition to EnumAttr. In short,
``` // Before def MyEnumAttr : StrEnumAttr<"MyEnum", "", [ StrEnumAttrCase<"A">, StrEnumAttrCase<"B"> ]>;
// After (pick an integer enum of your choice) def MyEnum : I32EnumAttr<"MyEnum", "", [ I32EnumAttrCase<"A", 0>, I32EnumAttrCase<"B", 1> ]> { // Don't generate a C++ class! We want to use the AttrDef let genSpecializedAttr = 0; } // Define the AttrDef def MyEnum : EnumAttr<MyDialect, MyEnum, "my_enum">; ```
Reviewed By: rriddle, jpienaar
Differential Revision: https://reviews.llvm.org/D120834
show more ...
|
#
0be38d4f |
| 04-Apr-2022 |
Alex Zinenko <zinenko@google.com> |
[mlir][ods] Add description to Attr and ensure doc generation
Add the description textual field to the Attr ODS class to mirror an identical field in the Type ODS class. Add support for generating d
[mlir][ods] Add description to Attr and ensure doc generation
Add the description textual field to the Attr ODS class to mirror an identical field in the Type ODS class. Add support for generating documentation for attribute constraints defined using this field. This ensures mlir-tblgen produces at least some documentation for dialects that only define attribute constraints, such as DLTI.
Reviewed By: rriddle
Differential Revision: https://reviews.llvm.org/D123024
show more ...
|
#
e5639b3f |
| 22-Dec-2021 |
Mehdi Amini <joker.eph@gmail.com> |
Fix more clang-tidy cleanups in mlir/ (NFC)
|
#
02b6fb21 |
| 20-Dec-2021 |
Mehdi Amini <joker.eph@gmail.com> |
Fix clang-tidy issues in mlir/ (NFC)
Reviewed By: ftynse
Differential Revision: https://reviews.llvm.org/D115956
|
#
b8186b31 |
| 11-Nov-2021 |
Mogball <jeffniu22@gmail.com> |
[mlir][ods] Unique attribute, successor, region constraints
With `-Os` turned on, results in 2-5% binary size reduction (depends on the original binary). Without it, the binary size is essentially u
[mlir][ods] Unique attribute, successor, region constraints
With `-Os` turned on, results in 2-5% binary size reduction (depends on the original binary). Without it, the binary size is essentially unchanged.
Depends on D113128
Differential Revision: https://reviews.llvm.org/D113331
show more ...
|
#
0235e3c7 |
| 28-Aug-2021 |
Markus Böck <markus.boeck02@gmail.com> |
[mlir][NFC] Fully qualify default value of Attributes `getStorageType()` in files generated by mlir-tblgen
|
#
fee90542 |
| 27-Feb-2021 |
Vladislav Vinogradov <vlad.vinogradov@intel.com> |
[mlir][ODS] Support specialized Attribute class for Enums
Add a feature to `EnumAttr` definition to generate specialized Attribute class for the particular enumeration.
This class will inherit `Str
[mlir][ODS] Support specialized Attribute class for Enums
Add a feature to `EnumAttr` definition to generate specialized Attribute class for the particular enumeration.
This class will inherit `StringAttr` or `IntegerAttr` and will override `classof` and `getValue` methods.
With this class the enumeration predicate can be checked with simple RTTI calls (`isa`, `dyn_cast`) and it will return the typed enumeration directly instead of raw string/integer.
Based on the following discussion: https://llvm.discourse.group/t/rfc-add-enum-attribute-decorator-class/2252
Reviewed By: rriddle
Differential Revision: https://reviews.llvm.org/D97836
show more ...
|
#
415fab6f |
| 24-Nov-2020 |
Paul C. Anagnostopoulos <paul@windfall.com> |
[TableGen] Eliminate the 'code' type
Update the documentation.
Rework various backends that relied on the code type.
Differential Revision: https://reviews.llvm.org/D92269
|
#
c0958b7b |
| 19-Nov-2020 |
River Riddle <riddleriver@gmail.com> |
[mlir] Add support for referencing a SymbolRefAttr in a SideEffectInstance
This allows for operations that exclusively affect symbol operations to better describe their side effects.
Differential R
[mlir] Add support for referencing a SymbolRefAttr in a SideEffectInstance
This allows for operations that exclusively affect symbol operations to better describe their side effects.
Differential Revision: https://reviews.llvm.org/D91581
show more ...
|
#
a3942308 |
| 10-Sep-2020 |
Federico Lebrón <flebron@google.com> |
Make struct dialects have the same field name as everything else, 'dialect'.
Also make the behavior of getting a dialect more forgiving, in the case where there isn't a dialect associated with an at
Make struct dialects have the same field name as everything else, 'dialect'.
Also make the behavior of getting a dialect more forgiving, in the case where there isn't a dialect associated with an attribute.
Depends On D86807
Reviewed By: mehdi_amini
Differential Revision: https://reviews.llvm.org/D86809
show more ...
|
#
12d16de5 |
| 12-Aug-2020 |
Rahul Joshi <jurahul@google.com> |
[MLIR][NFC] Remove tblgen:: prefix in TableGen/*.cpp files
- Add "using namespace mlir::tblgen" in several of the TableGen/*.cpp files and eliminate the tblgen::prefix to reduce code clutter.
Dif
[MLIR][NFC] Remove tblgen:: prefix in TableGen/*.cpp files
- Add "using namespace mlir::tblgen" in several of the TableGen/*.cpp files and eliminate the tblgen::prefix to reduce code clutter.
Differential Revision: https://reviews.llvm.org/D85800
show more ...
|
#
31f40f60 |
| 27-May-2020 |
Jacques Pienaar <jpienaar@google.com> |
[mlir] Add simple generator for return types
Take advantage of equality constrains to generate the type inference interface. This is used for equality and trivially built types. The type inference m
[mlir] Add simple generator for return types
Take advantage of equality constrains to generate the type inference interface. This is used for equality and trivially built types. The type inference method is only generated when no type inference trait is specified already.
This reorders verification that changes some test error messages.
Differential Revision: https://reviews.llvm.org/D80484
show more ...
|
#
429d792f |
| 15-Mar-2020 |
River Riddle <riddleriver@gmail.com> |
[mlir] Add support for generating dialect declarations via tablegen.
Summary: This generates the class declarations for dialects using the existing 'Dialect' tablegen classes.
Differential Revision
[mlir] Add support for generating dialect declarations via tablegen.
Summary: This generates the class declarations for dialects using the existing 'Dialect' tablegen classes.
Differential Revision: https://reviews.llvm.org/D76185
show more ...
|