]> granicus.if.org Git - llvm/commit
[InstCombine] Refactor substitution of instruction in the parent BB (NFC)
authorEvandro Menezes <e.menezes@samsung.com>
Fri, 6 Sep 2019 22:07:11 +0000 (22:07 +0000)
committerEvandro Menezes <e.menezes@samsung.com>
Fri, 6 Sep 2019 22:07:11 +0000 (22:07 +0000)
commitaf17674bf4e2e7de5aa207ed68342973c5199734
tree0d0752994e58cc9c5246e4647ce2a7b7970818cc
parent761cdf8f50ad57523c2e615e9708a839c9a34ebc
[InstCombine] Refactor substitution of instruction in the parent BB (NFC)

Add the new method `LibCallSimplifier::substituteInParent()` that calls
`LibCallSimplifier::replaceAllUsesWith()' and
`LibCallSimplifier::eraseFromParent()` back to back, simplifying the
resulting code.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@371264 91177308-0d34-0410-b5e6-96231b3b80d8
include/llvm/Transforms/Utils/SimplifyLibCalls.h
lib/Transforms/Utils/SimplifyLibCalls.cpp