]> granicus.if.org Git - llvm/commit
[ObjCARC] Do not move a release that has the clang.imprecise_release tag
authorAkira Hatanaka <ahatanaka@apple.com>
Mon, 16 Oct 2017 16:46:59 +0000 (16:46 +0000)
committerAkira Hatanaka <ahatanaka@apple.com>
Mon, 16 Oct 2017 16:46:59 +0000 (16:46 +0000)
commit4bd9c52fadd800122f3b3756c9621da387496d77
tree7ed22163af3019ef8a40e063d3cc48717b662d33
parentcd102716d7fd4b8ed292fe0068a3787a0270060a
[ObjCARC] Do not move a release that has the clang.imprecise_release tag
above PHI instructions.

ARC optimizer has an optimization that moves a call to an ObjC runtime
function above a phi instruction when the phi has a null operand and is
an argument passed to the function call. This optimization should not
kick in when the runtime function is an objc_release that releases an
object with precise lifetime semantics.

rdar://problem/34959669

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@315914 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Transforms/ObjCARC/ObjCARCOpts.cpp
test/Transforms/ObjCARC/basic.ll