[PATCH] D123084: BuildLibCalls: infer allocptr attribute for free and realloc() family functions

Augie Fackler via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 26 10:11:57 PDT 2022


durin42 added a comment.

In D123084#3473893 <https://reviews.llvm.org/D123084#3473893>, @nikic wrote:

> Need to handle LibFunc___kmpc_free_shared as well?

No, for two reasons:

1. The attributes can be specified directly on the declaration in `llvm/Frontend/OpenMP/OMPKinds.def` (see D119583 <https://reviews.llvm.org/D119583>)

2. `MemoryBuiltins.cpp` never had any logic about `__kmpc_free_shared`: I can't tell if this was a bug or intentional, but what we have today matches the behavior of MemoryBuiltins.cpp.

We can do a follow-up later to add the required attributes in OMPKinds.def if you'd like.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D123084/new/

https://reviews.llvm.org/D123084



More information about the llvm-commits mailing list