| 文件 | 最后提交记录 | 最后更新时间 |
|---|---|---|
[mlir] Support DialectRegistry extension comparison (#101119) PassManager::run loads the dependent dialects for each pass into the current context prior to invoking the individual passes. If the dependent dialect is already loaded into the context, this should be a no-op. However, if there are extensions registered in the DialectRegistry, the dependent dialects are unconditionally registered into the context. This poses a problem for dynamic pass pipelines, however, because they will likely be executing while the context is in an immutable state (because of the parent pass pipeline being run). To solve this, we'll update the extension registration API on DialectRegistry to require a type ID for each extension that is registered. Then, instead of unconditionally registered dialects into a context if extensions are present, we'll check against the extension type IDs already present in the context's internal DialectRegistry. The context will only be marked as dirty if there are net-new extension types present in the DialectRegistry populated by PassManager::getDependentDialects. Note: this PR removes the addExtension overload that utilizes std::function as the parameter. This is because std::function is copyable and potentially allocates memory for the contained function so we can't use the function pointer as the unique type ID for the extension. Downstream changes required: - Existing DialectExtension subclasses will need a type ID to be registered for each subclass. More details on how to register a type ID can be found here: https://github.com/llvm/llvm-project/blob/8b68e06731e0033ed3f8d6fe6292ae671611cfa1/mlir/include/mlir/Support/TypeID.h#L30 - Existing uses of the std::function overload of addExtension will need to be refactored into dedicated DialectExtension classes with associated type IDs. The attached std::function can either be inlined into or called directly from DialectExtension::apply. --------- Co-authored-by: Mehdi Amini <joker.eph@gmail.com> | 1 年前 | |
[mlir][doc] Fix transform dialect tutorial ch3 (#150456) Fixed some bugs in documentation. Add CallOpInterfaceHandle to the arguments of ChangeCallTargetOp, after doing so the section described in the documentation works correctly, Otherwise the following code reports an error. // Cast to our new type. %casted = transform.cast %call : !transform.any_op to !transform.my.call_op_interface // Using our new operation. transform.my.change_call_target %casted, "microkernel" : !transform.my.call_op_interface | 1 年前 | |
[MLIR] Migrate some "transform dialect" source to use the standard LDBG macro (NFC) (#150695) | 1 年前 | |
[mlir] Revise IDE folder structure (#89749) Update the folder titles for targets in the monorepository that have not seen taken care of for some time. These are the folders that targets are organized in Visual Studio and XCode ( set_property(TARGET <target> PROPERTY FOLDER "<title>")) when using the respective CMake's IDE generator. * Ensure that every target is in a folder * Use a folder hierarchy with each LLVM subproject as a top-level folder * Use consistent folder names between subprojects * When using target-creating functions from AddLLVM.cmake, automatically deduce the folder. This reduces the number of set_property/set_target_property, but are still necessary when add_custom_target, add_executable, add_library, etc. are used. A LLVM_SUBPROJECT_TITLE definition is used for that in each subproject's root CMakeLists.txt. | 2 年前 | |
Fix link in transform example README.md | 3 年前 |
Transform Dialect Tutorial is available at https://mlir.llvm.org/docs/Tutorials/transform.
Test files are located under mlir/test/Examples/Transform.