llvm/mlir/test
Alex Zinenko 168213f91c [mlir] Move data layout from LLVMDialect to module Op attributes
Legacy implementation of the LLVM dialect in MLIR contained an instance of
llvm::Module as it was required to parse LLVM IR types. The access to the data
layout of this module was exposed to the users for convenience, but in practice
this layout has always been the default one obtained by parsing an empty layout
description string. Current implementation of the dialect no longer relies on
wrapping LLVM IR types, but it kept an instance of DataLayout for
compatibility. This effectively forces a single data layout to be used across
all modules in a given MLIR context, which is not desirable. Remove DataLayout
from the LLVM dialect and attach it as a module attribute instead. Since MLIR
does not yet have support for data layouts, use the LLVM DataLayout in string
form with verification inside MLIR. Introduce the layout when converting a
module to the LLVM dialect and keep the default "" description for
compatibility.

This approach should be replaced with a proper MLIR-based data layout when it
becomes available, but provides an immediate solution to compiling modules with
different layouts, e.g. for GPUs.

This removes the need for LLVMDialectImpl, which is also removed.

Depends On D85650

Reviewed By: aartbik

Differential Revision: https://reviews.llvm.org/D85652
2020-08-17 15:12:36 +02:00
..
Analysis
Bindings/Python Initial MLIR python bindings based on the C API. 2020-08-16 19:34:25 -07:00
CAPI Revert "Separate the Registration from Loading dialects in the Context" 2020-08-15 09:21:47 +00:00
Conversion [mlir] Move data layout from LLVMDialect to module Op attributes 2020-08-17 15:12:36 +02:00
Dialect [mlir] Move data layout from LLVMDialect to module Op attributes 2020-08-17 15:12:36 +02:00
EDSC Revert "Separate the Registration from Loading dialects in the Context" 2020-08-15 09:21:47 +00:00
Examples
IR Add missing parsing for attributes to std.generic_atomic_rmw op 2020-08-16 22:13:58 +00:00
lib Revert "Separate the Registration from Loading dialects in the Context" 2020-08-15 09:21:47 +00:00
mlir-cpu-runner [mlir] Lower DimOp to LLVM for unranked memrefs. 2020-08-06 11:46:11 +02:00
mlir-cuda-runner [MLIR] Adding gpu.host_register op and lower it to a runtime call. 2020-08-10 22:46:17 +02:00
mlir-linalg-ods-gen
mlir-opt Revert "Separate the Registration from Loading dialects in the Context" 2020-08-15 09:21:47 +00:00
mlir-reduce Create Reduction Tree Pass 2020-08-07 23:17:31 +00:00
mlir-rocm-runner [MLIR] Adding gpu.host_register op and lower it to a runtime call. 2020-08-10 22:46:17 +02:00
mlir-tblgen [NFC][MLIR][OpenMP] Add comments and test for OpenMP enum declaration utility 2020-08-14 23:22:23 +01:00
mlir-vulkan-runner
Pass
SDBM Revert "Separate the Registration from Loading dialects in the Context" 2020-08-15 09:21:47 +00:00
Target [mlir] Move data layout from LLVMDialect to module Op attributes 2020-08-17 15:12:36 +02:00
Transforms [mlir] Test CallOp STD->LLVM conversion. 2020-08-13 19:10:21 +02:00
Unit
APITest.h
CMakeLists.txt [mlir] Initial version of C APIs 2020-08-05 15:04:08 +02:00
lit.cfg.py [mlir] Initial version of C APIs 2020-08-05 15:04:08 +02:00
lit.site.cfg.py.in Initial boiler-plate for python bindings. 2020-07-09 12:03:58 -07:00