llvm-capstone/mlir/lib/Target
Billy Zhu 2ea60f4197
[MLIR][LLVM] Fuse Scope into CallsiteLoc Callee (#74546)
There's an issue in the translator today where, for a CallsiteLoc, if
the callee does not have a DI scope (perhaps due to compile options or
optimizations), it may get propagated the DI scope of its callsite's
parent function, which will create a non-existent DILocation combining
line & col number from one file, and the filename from another.

The root problem is we cannot propagate the parent scope when
translating the callee location, as it no longer applies to inlined
locations (see code diff and hopefully this will make sense).

To facilitate this, the importer is also changed so that callee scopes
are fused with the callee FileLineCol loc, instead of on the Callsite
loc itself. This comes with the benefit that we now have a symmetric
Callsite loc representation. If we required the callee scope be always
annotated on the Callsite loc, it would be hard for generic inlining
passes to maintain that, since it would have to somehow understand the
semantics of the fused metadata and pull it out while inlining.
2023-12-06 09:13:12 +01:00
..
Cpp [mlir][emitc] Rename call op to call_opaque (#72494) 2023-11-17 10:22:15 +01:00
LLVM [mlir] Fix -Wunused-variable in ROCDL/Target.cpp (NFC) 2023-11-04 08:15:37 +08:00
LLVMIR [MLIR][LLVM] Fuse Scope into CallsiteLoc Callee (#74546) 2023-12-06 09:13:12 +01:00
SPIRV [mlir][spirv] Add some op decorations (#72809) 2023-11-21 15:31:23 +03:00
CMakeLists.txt [mlir][Target][LLVM] Adds an utility class for serializing operations to binary strings. 2023-08-08 14:48:11 +00:00