Author: baldrick Date: Tue Oct 16 04:07:20 2007 New Revision: 43028 URL: http://llvm.org/viewvc/llvm-project?rev=43028&view=rev Log: Fixes due to lack of type-safety for ValueType: (1) ValueType being passed instead of an opcode; (2) ValueType being passed for isVolatile (!) in getLoad.
Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Modified: llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp?rev=43028&r1=43027&r2=43028&view=diff ============================================================================== --- llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp (original) +++ llvm/trunk/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp Tue Oct 16 04:07:20 2007 @@ -772,7 +772,7 @@ case ISD::STRING: case ISD::CONDCODE: // Primitives must all be legal. - assert(TLI.isOperationLegal(Node->getValueType(0), Node->getValueType(0)) && + assert(TLI.isOperationLegal(Node->getOpcode(), Node->getValueType(0)) && "This must be legal!"); break; default: @@ -2752,7 +2752,7 @@ case ISD::UDIVREM: // These nodes will only be produced by target-specific lowering, so // they shouldn't be here if they aren't legal. - assert(TLI.isOperationLegal(Node->getValueType(0), Node->getValueType(0)) && + assert(TLI.isOperationLegal(Node->getOpcode(), Node->getValueType(0)) && "This must be legal!"); Tmp1 = LegalizeOp(Node->getOperand(0)); // LHS @@ -3521,7 +3521,7 @@ } else { Result = DAG.getTruncStore(DAG.getEntryNode(), Node->getOperand(0), StackSlot, NULL, 0, newVT); - Result = DAG.getLoad(newVT, Result, StackSlot, NULL, 0, newVT); + Result = DAG.getLoad(newVT, Result, StackSlot, NULL, 0); } break; } _______________________________________________ llvm-commits mailing list llvm-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits