[llvm-dev] [RFC] Adding support for marking allocator functions in LLVM IR

James Y Knight via llvm-dev llvm-dev at lists.llvm.org
Fri Jan 7 13:55:31 PST 2022


On Fri, Jan 7, 2022 at 4:48 PM Philip Reames via llvm-dev <
llvm-dev at lists.llvm.org> wrote:

> I think I've already killed several of the ones you note.  I agree there's
> definite room to improve the handling of strdup/strndup.  If you wanted to
> write a patch for that specifically, I'd be happy to review.
>
IMO, it doesn't seem worthwhile to make strdup handling expressible with
generic attributes. We special case many other libc functions too, so this
is not unusual, and unlike other allocator properties, "strdup-like" does
not seem likely to be a very interesting thing to apply to other functions.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20220107/8f6b8c72/attachment.html>


More information about the llvm-dev mailing list