[all-commits] [llvm/llvm-project] a51829: [mlir] Support for mutable types

ftynse via All-commits all-commits at lists.llvm.org
Mon Jul 27 04:08:05 PDT 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: a51829913dba28dae603fdcdddd242c7e20192a1
      https://github.com/llvm/llvm-project/commit/a51829913dba28dae603fdcdddd242c7e20192a1
  Author: Alex Zinenko <zinenko at google.com>
  Date:   2020-07-27 (Mon, 27 Jul 2020)

  Changed paths:
    M mlir/docs/Tutorials/DefiningAttributesAndTypes.md
    M mlir/include/mlir/IR/AttributeSupport.h
    M mlir/include/mlir/IR/Attributes.h
    M mlir/include/mlir/IR/StorageUniquerSupport.h
    M mlir/include/mlir/IR/TypeSupport.h
    M mlir/include/mlir/IR/Types.h
    M mlir/include/mlir/Support/StorageUniquer.h
    M mlir/lib/Support/StorageUniquer.cpp
    A mlir/test/IR/recursive-type.mlir
    M mlir/test/lib/Dialect/Test/TestDialect.cpp
    M mlir/test/lib/Dialect/Test/TestTypes.h
    M mlir/test/lib/IR/CMakeLists.txt
    A mlir/test/lib/IR/TestTypes.cpp
    M mlir/tools/mlir-opt/mlir-opt.cpp

  Log Message:
  -----------
  [mlir] Support for mutable types

Introduce support for mutable storage in the StorageUniquer infrastructure.
This makes MLIR have key-value storage instead of just uniqued key storage. A
storage instance now contains a unique immutable key and a mutable value, both
stored in the arena allocator that belongs to the context. This is a
preconditio for supporting recursive types that require delayed initialization,
in particular LLVM structure types.  The functionality is exercised in the test
pass with trivial self-recursive type. So far, recursive types can only be
printed in parsed in a closed type system. Removing this restriction is left
for future work.

Differential Revision: https://reviews.llvm.org/D84171




More information about the All-commits mailing list