[llvm] [Bolt] Teach bolt about no-return functions (PR #115616)
Anatoly Trosinenko via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 18 06:52:09 PDT 2025
================
@@ -272,6 +272,10 @@ class BinaryContext {
/// DWARF line info for CUs.
std::map<unsigned, DwarfLineTable> DwarfLineTablesCUMap;
+ /// Container to cache results about functions that their paths lead to
+ /// a no-return function.
+ std::unordered_map<BinaryFunction *, bool> CallsNoReturnFunction;
----------------
atrosinenko wrote:
Hmm, it looks like LLVM Programmer's Manual [advises against](https://llvm.org/docs/ProgrammersManual.html#other-map-like-container-options) the usage of `std::unordered_map`, though there are several tens of occurrences even under `llvm/lib`. The same in `DiscoverNoReturnPass.h` below.
https://github.com/llvm/llvm-project/pull/115616
More information about the llvm-commits
mailing list