[all-commits] [llvm/llvm-project] 9dbf36: [mlir][llvm] Move LLVM IR import into separate fil...

Tobias Gysi via All-commits all-commits at lists.llvm.org
Mon Dec 19 02:22:57 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9dbf362556fe5d4d11b5e36e9c5588ea77293c3f
      https://github.com/llvm/llvm-project/commit/9dbf362556fe5d4d11b5e36e9c5588ea77293c3f
  Author: Tobias Gysi <tobias.gysi at nextsilicon.com>
  Date:   2022-12-19 (Mon, 19 Dec 2022)

  Changed paths:
    A mlir/include/mlir/Target/LLVMIR/ModuleImport.h
    M mlir/lib/Target/LLVMIR/CMakeLists.txt
    M mlir/lib/Target/LLVMIR/ConvertFromLLVMIR.cpp
    A mlir/lib/Target/LLVMIR/ModuleImport.cpp

  Log Message:
  -----------
  [mlir][llvm] Move LLVM IR import into separate file (NFC).

The revision renames the Importer to ModuleImport and moves the class
out of the ConvertFromLLVMIR.cpp file into ModuleImport.h and
ModuleImport.cpp. Additionally, it introduces two helper methods
on the ModuleImport class that convert functions and globals, and it
merges the translateLLVMIRToModule function into the
registerFromLLVMIRTranslation function to match the design of
the MLIR to LLVM IR export.

This restructuring is a step towards the file structure of the export
and a preparation for an extensible import
https://discourse.llvm.org/t/rfc-extensible-llvm-ir-import/67256/6 that
uses a dialect interface to import intrinsics and metadata.

Reviewed By: ftynse

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




More information about the All-commits mailing list