GlobalISel: use correct builder for ConstantExprs.
authorTim Northover <tnorthover@apple.com>
Wed, 7 Dec 2016 21:29:15 +0000 (21:29 +0000)
committerTim Northover <tnorthover@apple.com>
Wed, 7 Dec 2016 21:29:15 +0000 (21:29 +0000)
commitc53606ef02fa14e199c2ad65956ea33b5eb698f0
tree396735d4fa4ae7c6752d348f6286178be2691b1a
parent79e60eb94880f5beac5c69fb2e42393fec6c279b
GlobalISel: use correct builder for ConstantExprs.

ConstantExpr instances were emitting code into the current block rather than
the entry block. This meant they didn't necessarily dominate all uses, which is
clearly wrong.

llvm-svn: 288985
llvm/include/llvm/CodeGen/GlobalISel/IRTranslator.h
llvm/lib/CodeGen/GlobalISel/IRTranslator.cpp
llvm/test/CodeGen/AArch64/GlobalISel/arm64-irtranslator.ll