This is an archive of the discontinued LLVM Phabricator instance.

[mlir] switch the modeling of LLVM types to use the new mechanism
ClosedPublic

Authored by ftynse on Jul 31 2020, 3:53 AM.

Details

Summary

A new first-party modeling for LLVM IR types in the LLVM dialect has been
developed in parallel to the existing modeling based on wrapping LLVM Type *
instances. It resolves the long-standing problem of modeling identified
structure types, including recursive structures, and enables future removal of
LLVMContext and related locking mechanisms from LLVMDialect.

This commit only switches the modeling by (a) renaming LLVMTypeNew to LLVMType,
(b) removing the old implementaiton of LLVMType, and (c) updating the tests. It
is intentionally minimal. Separate commits will remove the infrastructure built
for the transition and update API uses where appropriate.

Depends On D85020

Diff Detail

Event Timeline

ftynse created this revision.Jul 31 2020, 3:53 AM
ftynse requested review of this revision.Jul 31 2020, 3:53 AM
rriddle accepted this revision.Jul 31 2020, 11:57 AM
rriddle added inline comments.
mlir/lib/Dialect/LLVMIR/IR/LLVMTypes.cpp
31

This should just need to cast from Type::getDialect()

This revision is now accepted and ready to land.Jul 31 2020, 11:57 AM
ftynse updated this revision to Diff 282646.Aug 3 2020, 9:18 AM
ftynse marked an inline comment as done.

Address review and rebase.

ftynse updated this revision to Diff 282647.Aug 3 2020, 9:21 AM

Remove dead code

Harbormaster completed remote builds in B66784: Diff 282646.
ftynse updated this revision to Diff 282673.Aug 3 2020, 10:25 AM

Update more tests

This revision was landed with ongoing or failed builds.Aug 4 2020, 5:29 AM
This revision was automatically updated to reflect the committed changes.