diff options
author | Erik Pilkington <erik.pilkington@gmail.com> | 2019-02-11 23:21:39 +0000 |
---|---|---|
committer | Erik Pilkington <erik.pilkington@gmail.com> | 2019-02-11 23:21:39 +0000 |
commit | e3cd735ea6378e5dd7765828f560ed49be845a95 (patch) | |
tree | 91101427ae598d9ea6ced7a2e44f0f4f209fe4a9 /llvm/lib/CodeGen/MachineInstr.cpp | |
parent | 796ac80b863ed92c3d8bcc296f678ff416afc8a8 (diff) | |
download | llvm-e3cd735ea6378e5dd7765828f560ed49be845a95.zip llvm-e3cd735ea6378e5dd7765828f560ed49be845a95.tar.gz llvm-e3cd735ea6378e5dd7765828f560ed49be845a95.tar.bz2 |
Add a new attribute, fortify_stdlib
This attribute applies to declarations of C stdlib functions
(sprintf, memcpy...) that have known fortified variants
(__sprintf_chk, __memcpy_chk, ...). When applied, clang will emit
calls to the fortified variant functions instead of calls to the
defaults.
In GCC, this is done by adding gnu_inline-style wrapper functions,
but that doesn't work for us for variadic functions because we don't
support __builtin_va_arg_pack (and have no intention to).
This attribute takes two arguments, the first is 'type' argument
passed through to __builtin_object_size, and the second is a flag
argument that gets passed through to the variadic checking variants.
rdar://47905754
Differential revision: https://reviews.llvm.org/D57918
llvm-svn: 353765
Diffstat (limited to 'llvm/lib/CodeGen/MachineInstr.cpp')
0 files changed, 0 insertions, 0 deletions