[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
parent
a93d0331
Please register or sign in to comment