summaryrefslogtreecommitdiffstats
path: root/mlir/lib/Transforms/ViewFunctionGraph.cpp
diff options
context:
space:
mode:
authorAlex Zinenko <zinenko@google.com>2019-02-06 12:04:58 -0800
committerjpienaar <jpienaar@google.com>2019-03-29 16:18:14 -0700
commite9493cf14deec4198a3620d734f03e7e143f91d6 (patch)
treedb7727f9524a7ef6b5c6080b36fb78720bf60158 /mlir/lib/Transforms/ViewFunctionGraph.cpp
parent90d10b4e00cc6397a03ddc981b7be8bab43a9f38 (diff)
downloadbcm5719-llvm-e9493cf14deec4198a3620d734f03e7e143f91d6.tar.gz
bcm5719-llvm-e9493cf14deec4198a3620d734f03e7e143f91d6.zip
Port alloc/dealloc LLVM IR conversion into the LLVM IR dialect lowering
Implement the lowering of memref allocation and deallocation standard operations into the LLVM IR dialect. This largely follows the existing mechanism in MLIR-to-LLVM-IR translation for the sake of compatibility. A memref value is transformed into a memref descriptor value which holds the pointer to the underlying data buffer and the dynamic memref sizes. The buffer is allocated using `malloc` and freed using `free`. The lowering inserts declarations of these functions if necessary. Memref descriptors are values of the LLVM IR structure type wrapped into an MLIR LLVM dialect type. The pointer to the buffer and the individual sizes are accessed using `extractvalue` and `insertvalue` LLVM IR instructions. PiperOrigin-RevId: 232719419
Diffstat (limited to 'mlir/lib/Transforms/ViewFunctionGraph.cpp')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud