Reduce instruction create and deletion during inlining.
authorSteven Perron <stevenperron@google.com>
Tue, 20 Feb 2018 16:24:08 +0000 (11:24 -0500)
committerSteven Perron <stevenperron@google.com>
Wed, 21 Feb 2018 14:50:47 +0000 (09:50 -0500)
commit51ecc7318f7aea8472cf49be768eac7f3236eeaa
tree14f2182b90b329142b044040fe5bb7a9ecee7d1d
parentc1b936637e55e76d7e6bb398e11fe71d0b0ede74
Reduce instruction create and deletion during inlining.

When inlining a function call the instructions in the same basic block
as the call get cloned.  The clone is added to the set of new blocks
containing the inlined code, and the original instructions are deleted.

This PR will change this so that we simply move the instructions to the
new blocks.  This saves on the creation and deletion of the
instructions.

Contributes to #1328.
source/opt/inline_pass.cpp