[mlir] (NFC) Clean up bazel and CMake target namesAll dialect targets in bazel have been named *Dialect and all dialecttargets in CMake have been named MLIR*Dialect.
[mlir] Rework the implementation of TypeIDThis commit restructures how TypeID is implemented to ideally avoidthe current problems related to shared libraries. This is done by changingthe "implici
[mlir] Rework the implementation of TypeIDThis commit restructures how TypeID is implemented to ideally avoidthe current problems related to shared libraries. This is done by changingthe "implicit" fallback path to use the name of the type, instead of usinga static template variable (which breaks shared libraries). The major downside to thisis that it adds some additional initialization costs for the implicit path. Given theuse of type names for uniqueness in the fallback, we also no longer allow typesdefined in anonymous namespaces to have an implicit TypeID. To simplify definingan ID for these classes, a new `MLIR_DEFINE_EXPLICIT_INTERNAL_INLINE_TYPE_ID` macrowas added to allow for explicitly defining a TypeID directly on an internal class.To help identify when types are using the fallback, `-debug-only=typeid` can beused to log which types are using implicit ids.This change generally only requires changes to the test passes, which are all definedin anonymous namespaces, and thus can't use the fallback any longer.Differential Revision: https://reviews.llvm.org/D122775
show more ...
[mlir][NFC] Rename StandardToLLVM to FuncToLLVMThe current StandardToLLVM conversion patterns only really handlethe Func dialect. The pass itself adds patterns for Arithmetic/CFToLLVM, butthose s
[mlir][NFC] Rename StandardToLLVM to FuncToLLVMThe current StandardToLLVM conversion patterns only really handlethe Func dialect. The pass itself adds patterns for Arithmetic/CFToLLVM, butthose should be/will be split out in a followup. This commit focuses solelyon being an NFC rename.Aside from the directory change, the pattern and pass creation API have been renamed: * populateStdToLLVMFuncOpConversionPattern -> populateFuncToLLVMFuncOpConversionPattern * populateStdToLLVMConversionPatterns -> populateFuncToLLVMConversionPatterns * createLowerToLLVMPass -> createConvertFuncToLLVMPassDifferential Revision: https://reviews.llvm.org/D120778
[mlir] Rename the Standard dialect to the Func dialectThe last remaining operations in the standard dialect all revolve aroundFuncOp/function related constructs. This patch simply handles the init
[mlir] Rename the Standard dialect to the Func dialectThe last remaining operations in the standard dialect all revolve aroundFuncOp/function related constructs. This patch simply handles the initialrenaming (which by itself is already huge), but there are a large numberof cleanups unlocked/necessary afterwards:* Removing a bunch of unnecessary dependencies on Func* Cleaning up the From/ToStandard conversion passes* Preparing for the move of FuncOp to the Func dialectSee the discussion at https://discourse.llvm.org/t/standard-dialect-the-final-chapter/6061Differential Revision: https://reviews.llvm.org/D120624
[mlir] recursively convert builtin types to LLVM when possibleGiven that LLVM dialect types may now optionally contain types from otherdialects, which itself is motivated by dialect interoperabili
[mlir] recursively convert builtin types to LLVM when possibleGiven that LLVM dialect types may now optionally contain types from otherdialects, which itself is motivated by dialect interoperability and progressivelowering, the conversion should no longer assume that the outermost LLVMdialect type can be left as is. Instead, it should inspect the types itcontains and attempt to convert them to the LLVM dialect. Introduce thiscapability for LLVM array, pointer and structure types. Only literal structuresare currently supported as handling identified structures requires theconverison infrastructure to have a mechanism for avoiding infite recursion incase of recursive types.Reviewed By: rriddleDifferential Revision: https://reviews.llvm.org/D112550
[mlir:OpConversion] Remove the remaing usages of the deprecated matchAndRewrite methodsThis commits updates the remaining usages of the ArrayRef<Value> basedmatchAndRewrite/rewrite methods in favo
[mlir:OpConversion] Remove the remaing usages of the deprecated matchAndRewrite methodsThis commits updates the remaining usages of the ArrayRef<Value> basedmatchAndRewrite/rewrite methods in favor of the new OpAdaptoroverload.Differential Revision: https://reviews.llvm.org/D110360
[mlir] Replace `include_directories`Switches to adding target specific, private includes instead of addingglobal includes.Reviewed By: ftynseDifferential Revision: https://reviews.llvm.org/D10
[mlir] Replace `include_directories`Switches to adding target specific, private includes instead of addingglobal includes.Reviewed By: ftynseDifferential Revision: https://reviews.llvm.org/D109494
[mlir] factor memref-to-llvm lowering out of std-to-llvmAfter the MemRef has been split out of the Standard dialect, theconversion to the LLVM dialect remained as a huge monolithic pass.This is u
[mlir] factor memref-to-llvm lowering out of std-to-llvmAfter the MemRef has been split out of the Standard dialect, theconversion to the LLVM dialect remained as a huge monolithic pass.This is undesirable for the same complexity management reasons as havinga huge Standard dialect itself, and is even more confusing given theexistence of a separate dialect. Extract the conversion of the MemRefdialect operations to LLVM into a separate library and a separateconversion pass.Reviewed By: herhut, silvasDifferential Revision: https://reviews.llvm.org/D105625
Migrate MLIR test passes to the new registration APIMake sure they all define getArgument()/getDescription().Depends On D104421Differential Revision: https://reviews.llvm.org/D104426
[mlir][NFC] Move passes in test/lib/Transforms/ to a directory that mirrors what they testtest/lib/Transforms/ has bitrot and become somewhat of a dumping grounds for testing pretty much any part o
[mlir][NFC] Move passes in test/lib/Transforms/ to a directory that mirrors what they testtest/lib/Transforms/ has bitrot and become somewhat of a dumping grounds for testing pretty much any part of the project. This revision cleans this up, and moves the files within to a directory that reflects what is actually being tested.Differential Revision: https://reviews.llvm.org/D102456