[Mlir-commits] [mlir] [MLIR][LLVM] Block address support (PR #134335)
Tobias Gysi
llvmlistbot at llvm.org
Sat Apr 5 05:33:30 PDT 2025
================
@@ -136,6 +136,29 @@ class ModuleTranslation {
return callMapping.lookup(op);
}
+ /// Maps a blockaddress operation to its corresponding placeholder LLVM
+ /// value.
+ void mapUnresolvedBlockAddress(BlockAddressOp op, llvm::Value *cst) {
+ auto result = unresolvedBlockAddressMapping.try_emplace(op, cst);
+ (void)result;
+ assert(result.second &&
+ "attempting to map a blockaddress that is already mapped");
+ }
+
+ /// Maps a blockaddress operation to its corresponding placeholder LLVM
+ /// value.
+ void mapBlockTag(BlockAddressAttr attr, BlockTagOp blockTag) {
+ // Attempts to map already mapped block labels are fine given labels are
+ // verified to be unique.
----------------
gysit wrote:
```suggestion
// Attempts to map already mapped block labels which is fine if the given labels are
// verified to be unique.
```
nit:
https://github.com/llvm/llvm-project/pull/134335
More information about the Mlir-commits
mailing list