diff options
author | Markus Böck <markus.bock+llvm@nextsilicon.com> | 2023-07-12 15:13:18 +0200 |
---|---|---|
committer | Markus Böck <markus.bock+llvm@nextsilicon.com> | 2023-07-14 11:14:42 +0200 |
commit | 78d00a160f34bffd25fef6e29e35a6b3906d6752 (patch) | |
tree | 3898aef06877f7e253ceefd7655dacce85913868 /llvm/lib/IR/Function.cpp | |
parent | afdb83b19c674dd2a622697863a201cd44e2458a (diff) | |
download | llvm-78d00a160f34bffd25fef6e29e35a6b3906d6752.zip llvm-78d00a160f34bffd25fef6e29e35a6b3906d6752.tar.gz llvm-78d00a160f34bffd25fef6e29e35a6b3906d6752.tar.bz2 |
[mlir][LLVM] Convert alias metadata to using attributes instead of ops
Using MLIR attributes instead of metadata has many advantages:
* No indirection: Attributes can simply refer to each other seemlessly without having to use the indirection of `SymbolRefAttr`. This also gives us correctness by construction in a lot of places as well
* Multithreading save: The Attribute infrastructure gives us thread-safety for free. Creating operations and inserting them into a block is not thread-safe. This is a major use case for e.g. the inliner in MLIR which runs in parallel
* Easier to create: There is no need for a builder or a metadata region
This patch therefore does exactly that. It leverages the new distinct attributes to create distinct alias domains and scopes in a deterministic and threadsafe manner.
Differential Revision: https://reviews.llvm.org/D155159
Diffstat (limited to 'llvm/lib/IR/Function.cpp')
0 files changed, 0 insertions, 0 deletions