[all-commits] [llvm/llvm-project] 1b8465: [mlir] Add CastInfo for mlir classes subclassing f...

Tres via All-commits all-commits at lists.llvm.org
Thu May 25 22:48:00 PDT 2023


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 1b8465aac4368c64d3e78ebd94fb8ca048b9e801
      https://github.com/llvm/llvm-project/commit/1b8465aac4368c64d3e78ebd94fb8ca048b9e801
  Author: Tres Popp <tpopp at google.com>
  Date:   2023-05-26 (Fri, 26 May 2023)

  Changed paths:
    M mlir/include/mlir/Analysis/DataFlowFramework.h
    M mlir/include/mlir/Dialect/LLVMIR/LLVMDialect.h
    M mlir/include/mlir/IR/OpDefinition.h
    M mlir/include/mlir/IR/Unit.h
    M mlir/include/mlir/Interfaces/CallInterfaces.h

  Log Message:
  -----------
  [mlir] Add CastInfo for mlir classes subclassing from PointerUnion

This is required to use the function variants of cast/isa/dyn_cast/etc
on them.

Context:
- https://mlir.llvm.org/deprecation/ at "Use the free function variants for dyn_cast/cast/isa/…"
- Original discussion at https://discourse.llvm.org/t/preferred-casting-style-going-forward/68443


  Commit: 6de63b82cc1d1a98151aa19fa8f65bd6888789b1
      https://github.com/llvm/llvm-project/commit/6de63b82cc1d1a98151aa19fa8f65bd6888789b1
  Author: Tres Popp <tpopp at google.com>
  Date:   2023-05-26 (Fri, 26 May 2023)

  Changed paths:
    M mlir/test/mlir-linalg-ods-gen/test-linalg-ods-yaml-gen.yaml
    M mlir/test/mlir-tblgen/attr-or-type-format.td
    M mlir/test/mlir-tblgen/op-attribute.td
    M mlir/test/mlir-tblgen/op-result.td
    M mlir/tools/mlir-linalg-ods-gen/mlir-linalg-ods-yaml-gen.cpp
    M mlir/tools/mlir-tblgen/AttrOrTypeFormatGen.cpp
    M mlir/tools/mlir-tblgen/EnumsGen.cpp
    M mlir/tools/mlir-tblgen/OpDefinitionsGen.cpp
    M mlir/tools/mlir-tblgen/OpFormatGen.cpp
    M mlir/tools/mlir-tblgen/OpInterfacesGen.cpp
    M mlir/tools/mlir-tblgen/SPIRVUtilsGen.cpp

  Log Message:
  -----------
  [mlir] Move tblgen code generation to use functional forms of cast/isa

Summary:
The method forms are deprecated. This updates the rest of the tblgen
uses of methods where a function call is available.

Context:
- https://mlir.llvm.org/deprecation/ at "Use the free function variants for dyn_cast/cast/isa/…"
- Original discussion at https://discourse.llvm.org/t/preferred-casting-style-going-forward/68443

Reviewers: rriddle


  Commit: d46a135db54f6589a77628437aa7115cb90c80db
      https://github.com/llvm/llvm-project/commit/d46a135db54f6589a77628437aa7115cb90c80db
  Author: Tres Popp <tpopp at google.com>
  Date:   2023-05-26 (Fri, 26 May 2023)

  Changed paths:
    M mlir/include/mlir/Dialect/OpenMP/OpenMPOpsInterfaces.td
    M mlir/include/mlir/IR/BuiltinAttributes.td
    M mlir/include/mlir/IR/EnumAttr.td
    M mlir/include/mlir/IR/FunctionInterfaces.td
    M mlir/lib/Conversion/VectorToSPIRV/VectorToSPIRV.cpp
    M mlir/lib/Dialect/EmitC/IR/EmitC.cpp
    M mlir/lib/Dialect/Tosa/IR/TosaCanonicalizations.cpp
    M mlir/lib/Dialect/Tosa/IR/TosaOps.cpp
    M mlir/lib/Dialect/Tosa/Utils/QuantUtils.cpp
    M mlir/test/python/python_test_ops.td

  Log Message:
  -----------
  [mlir] Update cast/isa method calls to function calls

This updates the rest (at implementation) of MLIR's use of cast/isa
method calls where function calls are possible and automatic refactoring
is not. These changes occured in .td files or in macros.

Context:
- https://mlir.llvm.org/deprecation/ at "Use the free function variants for dyn_cast/cast/isa/…"
- Original discussion at https://discourse.llvm.org/t/preferred-casting-style-going-forward/68443


Compare: https://github.com/llvm/llvm-project/compare/00c7bdf80cb0...d46a135db54f


More information about the All-commits mailing list