]> granicus.if.org Git - llvm/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)
commit99ef84fa6f8b0521d1c7baf290c4a727f2bdb208
tree0ef7c68c539321a9c8cfd474a885a1887d0952bf
parent72fb48359948b3fbe7e44d4e57300d049122753f
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/llvm/trunk@352664 91177308-0d34-0410-b5e6-96231b3b80d8
23 files changed:
docs/LangRef.rst
include/llvm/Analysis/MemoryBuiltins.h
include/llvm/IR/Intrinsics.td
lib/Analysis/MemoryBuiltins.cpp
lib/CodeGen/CodeGenPrepare.cpp
lib/IR/AutoUpgrade.cpp
lib/Target/AMDGPU/AMDGPUPromoteAlloca.cpp
lib/Transforms/InstCombine/InstCombineCalls.cpp
lib/Transforms/InstCombine/InstructionCombining.cpp
lib/Transforms/Instrumentation/BoundsChecking.cpp
test/Assembler/auto_upgrade_intrinsics.ll
test/CodeGen/AMDGPU/promote-alloca-mem-intrinsics.ll
test/CodeGen/X86/is-constant.ll
test/Other/cgscc-libcall-update.ll
test/Transforms/CodeGenPrepare/basic.ll
test/Transforms/CodeGenPrepare/crash-on-large-allocas.ll
test/Transforms/InferAddressSpaces/AMDGPU/intrinsics.ll
test/Transforms/InstCombine/builtin-dynamic-object-size.ll [new file with mode: 0644]
test/Transforms/InstCombine/invoke.ll
test/Transforms/InstCombine/memset_chk-1.ll
test/Transforms/InstCombine/objsize.ll
test/Transforms/InstCombine/stpcpy_chk-1.ll
test/Transforms/InstCombine/strcpy_chk-1.ll