[all-commits] [llvm/llvm-project] d0541b: [mlir] Add I1 support to DenseArrayAttr

Jeff Niu via All-commits all-commits at lists.llvm.org
Thu Aug 4 07:24:59 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: d0541b47000739c68c540170c6b9790ec1ea3b77
      https://github.com/llvm/llvm-project/commit/d0541b47000739c68c540170c6b9790ec1ea3b77
  Author: Jeff Niu <jeff at modular.com>
  Date:   2022-08-04 (Thu, 04 Aug 2022)

  Changed paths:
    M mlir/include/mlir/IR/BuiltinAttributes.h
    M mlir/include/mlir/IR/BuiltinAttributes.td
    M mlir/include/mlir/IR/OpBase.td
    M mlir/lib/AsmParser/AttributeParser.cpp
    M mlir/lib/AsmParser/Parser.cpp
    M mlir/lib/IR/AsmPrinter.cpp
    M mlir/lib/IR/BuiltinAttributes.cpp
    M mlir/test/IR/attribute.mlir
    M mlir/test/IR/elements-attr-interface.mlir
    M mlir/test/lib/Dialect/Test/TestOps.td
    M mlir/test/lib/IR/TestBuiltinAttributeInterfaces.cpp

  Log Message:
  -----------
  [mlir] Add I1 support to DenseArrayAttr

This patch adds a DenseI1ArrayAttr to support arrays of i1. Importantly,
the implementation is as a simple `ArrayRef<bool>` instead of using bit
compression, which was problematic in DenseElementsAttr.

Reviewed By: rriddle

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




More information about the All-commits mailing list