]> granicus.if.org Git - clang/commit
Add a 'dynamic' parameter to the objectsize intrinsic
authorErik Pilkington <erik.pilkington@gmail.com>
Wed, 30 Jan 2019 20:34:35 +0000 (20:34 +0000)
committerErik Pilkington <erik.pilkington@gmail.com>
Wed, 30 Jan 2019 20:34:35 +0000 (20:34 +0000)
commit932217bae430fefcb3df6c51c9c7d2dd4970b048
tree78bc6646775c9d32714561e8c40f8707150ebc22
parent5257f1ab6e667cf688368055b05a9f4e22c7cbcd
Add a 'dynamic' parameter to the objectsize intrinsic

This is meant to be used with clang's __builtin_dynamic_object_size.
When 'true' is passed to this parameter, the intrinsic has the
potential to be folded into instructions that will be evaluated
at run time. When 'false', the objectsize intrinsic behaviour is
unchanged.

rdar://32212419

Differential revision: https://reviews.llvm.org/D56761

git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@352664 91177308-0d34-0410-b5e6-96231b3b80d8
lib/CodeGen/CGBuiltin.cpp
lib/CodeGen/CGExpr.cpp
test/CodeGen/alloc-size.c
test/CodeGen/catch-undef-behavior.c
test/CodeGen/object-size.c
test/CodeGen/object-size.cpp