[PATCH] D73495: [CodeGen] Attach no-builtin attributes to functions with no Decl

Francis Visoiu Mistrih via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jan 27 10:57:26 PST 2020


thegameg created this revision.
thegameg added reviewers: gchatelet, tejohnson, aaron.ballman, efriedma.
thegameg added a project: clang.

When using -fno-builtin[-<name>], we don't attach the IR attributes to functions with no Decl.

This results in projects using -fno-builtin or -ffreestanding to start seeing symbols like _memset_pattern16.

The fix changes the behavior to always add the attribute if LangOptions requests it.


https://reviews.llvm.org/D73495

Files:
  clang/lib/CodeGen/CGCall.cpp
  clang/test/CodeGenCXX/global-init.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D73495.240641.patch
Type: text/x-patch
Size: 4625 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20200127/f669f956/attachment-0001.bin>


More information about the cfe-commits mailing list