mirror of
https://github.com/RPCS3/llvm.git
synced 2024-12-27 14:45:50 +00:00
add support for loading bools
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@24182 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
7d090f3485
commit
9f7290633a
@ -369,7 +369,13 @@ SDOperand IA64DAGToDAGISel::Select(SDOperand Op) {
|
||||
unsigned Opc;
|
||||
switch (TypeBeingLoaded) {
|
||||
default: N->dump(); assert(0 && "Cannot load this type!");
|
||||
// FIXME: bools? case MVT::i1:
|
||||
case MVT::i1: { // this is a bool
|
||||
Opc = IA64::LD1; // first we load a byte, then compare for != 0
|
||||
CurDAG->SelectNodeTo(N, IA64::CMPNE, MVT::i1, MVT::Other,
|
||||
CurDAG->getTargetNode(Opc, MVT::i64, Address),
|
||||
CurDAG->getRegister(IA64::r0, MVT::i64), Chain);
|
||||
return SDOperand(N, Op.ResNo); // XXX: early exit
|
||||
}
|
||||
case MVT::i8: Opc = IA64::LD1; break;
|
||||
case MVT::i16: Opc = IA64::LD2; break;
|
||||
case MVT::i32: Opc = IA64::LD4; break;
|
||||
|
Loading…
Reference in New Issue
Block a user