[all-commits] [llvm/llvm-project] a2122a: [mlir][llvm] Introduce a mapValue function in LLVM...

Tobias Gysi via All-commits all-commits at lists.llvm.org
Tue Oct 11 06:24:13 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: a2122a09cf66c29f82f911e35770786db09565a3
      https://github.com/llvm/llvm-project/commit/a2122a09cf66c29f82f911e35770786db09565a3
  Author: Tobias Gysi <tobias.gysi at nextsilicon.com>
  Date:   2022-10-11 (Tue, 11 Oct 2022)

  Changed paths:
    M mlir/include/mlir/Dialect/LLVMIR/LLVMOpBase.td
    M mlir/lib/Target/LLVMIR/ConvertFromLLVMIR.cpp
    M mlir/tools/mlir-tblgen/LLVMIRConversionGen.cpp

  Log Message:
  -----------
  [mlir][llvm] Introduce a mapValue function in LLVMIR import (nfc).

The revision adds a mapValue function to the Importer, which can be used
in the MLIR builders to provide controlled accesses to the result
mapping of the imported instructions. Additionally, the change allows us
to avoid accessing a private member variable of the Importer class,
which simplifies future refactorings that aim at factoring out a
conversion interface (similar to the MLIR to LLVM translation). The
revision also renames the variables used when emitting the MLIR builders
to prepare the generalization to non-intrinsic instructions. In
particular, it renames callInst to inst and it passes in the instruction
arguments using an llvmOperands array rather than accessing the call
arguments directly.

Reviewed By: ftynse

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




More information about the All-commits mailing list