[PATCH] D104378: [FuncSpec] Don't specialize functions with attribute NoDuplicate.

Sjoerd Meijer via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Jun 17 00:41:17 PDT 2021


SjoerdMeijer added a comment.

In D104378#2823573 <https://reviews.llvm.org/D104378#2823573>, @ChuanqiXu wrote:

> It makes sense to me. If a function is marked with `NoDuplicate`, we shouldn't clone it. Everything is fine.
> But I want to ask, in what situations, generally a function would be marked with `NoDuplicate` attribute? I didn't find it in docs or codes.

In Clang, there's a no duplicate function attribute, see https://clang.llvm.org/docs/AttributeReference.html#noduplicate.
And that can translate to  LLVM IR function attribute no duplicate, see also https://llvm.org/docs/LangRef.html#function-attributes.


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

https://reviews.llvm.org/D104378



More information about the llvm-commits mailing list