[all-commits] [llvm/llvm-project] 2e8c11: [mlir] Add elementAttr to TypedArrayAttrBase.

ftynse via All-commits all-commits at lists.llvm.org
Thu Feb 13 00:25:51 PST 2020


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 2e8c112ecf562afdd8a6b3c3467571233b9b55ae
      https://github.com/llvm/llvm-project/commit/2e8c112ecf562afdd8a6b3c3467571233b9b55ae
  Author: Abdurrahman Akkas <akkas at google.com>
  Date:   2020-02-13 (Thu, 13 Feb 2020)

  Changed paths:
    M mlir/include/mlir/IR/OpBase.td
    M mlir/test/mlir-tblgen/op-attribute.td

  Log Message:
  -----------
  [mlir] Add elementAttr to TypedArrayAttrBase.

In code generators, one can automate the translation of typed ArrayAttrs
if element attribute translators are already implemented. However, the
type of the element attribute is lost at the construction of
TypedArrayAttrBase. With this change one can inspect the element type
and generate the translation logic automatically, which will reduce the
code repetition.

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




More information about the All-commits mailing list