The bitcast instruction during constant materialization was not placed correcly in the presence of phi nodes. This commit fixes the insertion point to be in the idom instead. This fixes PR18768 llvm-svn: 201009
Insert before the terminating instruction of the dominating block instead. llvm-svn: 200218