Duncan P. N. Exon Smith b03916a88b IR: Fix ConstantExpr::replaceUsesOfWithOnConstant()
Change `ConstantExpr` to follow the model the other constants are using:
only malloc a replacement if it's going to be used.  This fixes a subtle
bug where if an API user had used `ConstantExpr::get()` already to
create the replacement but hadn't given it any users, we'd delete the
replacement.

This relies on r216015 to thread `OnlyIfReduced` through
`ConstantExpr::getWithOperands()`.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@216016 91177308-0d34-0410-b5e6-96231b3b80d8
2014-08-19 20:03:35 +00:00
..
2014-07-18 15:51:28 +00:00
2014-07-18 15:51:28 +00:00
2014-06-27 18:19:56 +00:00
2014-06-25 23:39:08 +00:00
2014-07-18 15:51:28 +00:00
2014-06-27 18:19:56 +00:00
2014-06-27 18:19:56 +00:00
2014-08-15 22:17:28 +00:00
2014-07-24 14:25:39 +00:00
2014-07-24 14:25:39 +00:00
2014-08-06 17:36:08 +00:00
2014-08-01 23:28:49 +00:00