[MemoryBuiltins][NFC] Allow users to retrieve detailed (de)allocation info
There are some helpers to inspect a value or call but not all
information about the (de)allocation are made available outside of
MemoryBuiltins.cpp. The two new functions allow users a more in-depth
view of (de)allocations through a single API. To help with this, we now
read the alloc_align attribute to provide better alignment information
to users. alloc-family is used as well. Two new helpers provide argument
numbers, rather than values.
[MemoryBuiltins] Consistently infer and use MallocFamily
MallocFamily (the enum and StringRef) are used alongside AllocFnsTy.
The latter is picked up from the tables while the former is encoded in
the IR. While they should be merged at some point (see TODO), this
commit makes sure we consistently initialize the MallocFamily String and
pass it to users.
[MemoryBuiltins][NFC] Allow users to retrieve detailed (de)allocation info
There are some helpers to inspect a value or call but not all
information about the (de)allocation are made available outside of
MemoryBuiltins.cpp. The two new functions allow users a more in-depth
view of (de)allocations through a single API. To help with this, we now
read the alloc_align attribute to provide better alignment information
to users. alloc-family is used as well. Two new helpers provide argument
numbers, rather than values.
[clang-tidy] Fix crash in misc-static-initialization-cycle (#198155)
This commit fixes `misc-static-initialization-cycle` crashing on `catch
(...)`.
Catch-all handlers have no exception declaration, so traversal of
`CXXCatchStmt` can call `TraverseDecl(nullptr)`. The check previously
passed that null pointer to `DeclContext::containsDecl`. This commit
fixes the problem by adding a null guard.
Closes #198150
[compiler-rt] Fix StackDepot benchmark thread barrier (#197633)
Use Param.Threads (number of worker threads) as barrier threshold
instead of Param.UniqueThreads (boolean that controls input generation).
This also silences
[-Wbool-integral-comparison](https://github.com/llvm/llvm-project/pull/194180)
warning I'm working on.