Assert that ValueHandleBase::ValueIsRAUWd doesn't change the tracked Value type.
authorFrederic Riss <friss@apple.com>
Thu, 23 Oct 2014 04:08:42 +0000 (04:08 +0000)
committerFrederic Riss <friss@apple.com>
Thu, 23 Oct 2014 04:08:42 +0000 (04:08 +0000)
commit648728d4e42e2bc6e744fcf41c04ea2029d21cd1
treefb6c01f894c112323fcf52839f1f6d60256a6c69
parent54d6b1b71e2f974f583aef34e3de9b64e654d8d9
Assert that ValueHandleBase::ValueIsRAUWd doesn't change the tracked Value type.

This invariant is enforced in Value::replaceAllUsesWith, thus it seems
logical to apply it also to ValueHandles. This commit fixes InstCombine
to not trigger the assertion during the removal of constant bitcasts in
call instructions.

Differential Revision: http://reviews.llvm.org/D5828

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@220468 91177308-0d34-0410-b5e6-96231b3b80d8
lib/IR/Value.cpp
lib/Transforms/InstCombine/InstCombineCalls.cpp