[all-commits] [llvm/llvm-project] 327d62: [mlir] share argument attributes interface between...

jeanPerier via All-commits all-commits at lists.llvm.org
Mon Feb 3 02:27:36 PST 2025


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 327d627066e6452b081365b595657d17f2690a3b
      https://github.com/llvm/llvm-project/commit/327d627066e6452b081365b595657d17f2690a3b
  Author: jeanPerier <jperier at nvidia.com>
  Date:   2025-02-03 (Mon, 03 Feb 2025)

  Changed paths:
    M flang/include/flang/Optimizer/Dialect/CUF/CUFOps.td
    M flang/include/flang/Optimizer/Dialect/FIROps.td
    M flang/lib/Lower/ConvertCall.cpp
    M flang/lib/Optimizer/CodeGen/TargetRewrite.cpp
    M flang/lib/Optimizer/Transforms/AbstractResult.cpp
    M flang/lib/Optimizer/Transforms/PolymorphicOpConversion.cpp
    M mlir/docs/Interfaces.md
    M mlir/examples/toy/Ch4/include/toy/Ops.td
    M mlir/examples/toy/Ch5/include/toy/Ops.td
    M mlir/examples/toy/Ch6/include/toy/Ops.td
    M mlir/examples/toy/Ch7/include/toy/Ops.td
    M mlir/examples/toy/Ch7/mlir/Dialect.cpp
    M mlir/examples/toy/Ch7/mlir/MLIRGen.cpp
    M mlir/include/mlir/Dialect/Async/IR/AsyncOps.td
    M mlir/include/mlir/Dialect/EmitC/IR/EmitC.td
    M mlir/include/mlir/Dialect/Func/IR/FuncOps.td
    M mlir/include/mlir/Dialect/LLVMIR/LLVMOps.td
    M mlir/include/mlir/Dialect/SPIRV/IR/SPIRVControlFlowOps.td
    M mlir/include/mlir/Dialect/Transform/IR/TransformOps.td
    M mlir/include/mlir/Interfaces/CallInterfaces.h
    M mlir/include/mlir/Interfaces/CallInterfaces.td
    M mlir/include/mlir/Interfaces/FunctionImplementation.h
    M mlir/lib/Dialect/Async/IR/Async.cpp
    M mlir/lib/Dialect/EmitC/IR/EmitC.cpp
    M mlir/lib/Dialect/Func/IR/FuncOps.cpp
    M mlir/lib/Dialect/GPU/IR/GPUDialect.cpp
    M mlir/lib/Dialect/LLVMIR/IR/LLVMDialect.cpp
    M mlir/lib/Dialect/SPIRV/IR/SPIRVOps.cpp
    M mlir/lib/Dialect/Shape/IR/Shape.cpp
    M mlir/lib/Interfaces/CallInterfaces.cpp
    M mlir/lib/Interfaces/FunctionImplementation.cpp
    M mlir/test/lib/Dialect/Test/TestOps.td

  Log Message:
  -----------
  [mlir] share argument attributes interface between calls and callables (#123176)

This patch shares core interface methods dealing with argument and
result attributes from CallableOpInterface with the CallOpInterface and
makes them mandatory to gives more consistent guarantees about concrete
operations using these interfaces.

This allows adding argument attributes on call like operations, which is
sometimes required to get proper ABI, like with  llvm.call (and llvm.invoke).


The patch adds optional `arg_attrs` and `res_attrs` attributes to operations using
these interfaces that did not have that already.
They can then re-use the common "rich function signature"
printing/parsing helpers if they want (for the LLVM dialect, this is
done in the next patch).

Part of RFC: https://discourse.llvm.org/t/mlir-rfc-adding-argument-and-result-attributes-to-llvm-call/84107



To unsubscribe from these emails, change your notification settings at https://github.com/llvm/llvm-project/settings/notifications


More information about the All-commits mailing list