From: Chris Lattner Date: Tue, 10 Oct 2006 18:54:19 +0000 (+0000) Subject: Fix another bug in extload promotion. X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=55b5708b6bbffc79cf133c31faa51d144bfc5d4a;p=oota-llvm.git Fix another bug in extload promotion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30857 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp index 699d5b1574b..d6b07a0f1b5 100644 --- a/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp +++ b/lib/CodeGen/SelectionDAG/LegalizeDAG.cpp @@ -3237,7 +3237,8 @@ SDOperand SelectionDAGLegalize::PromoteOp(SDOperand Op) { ? ISD::EXTLOAD : LD->getExtensionType(); Result = DAG.getExtLoad(ExtType, NVT, LD->getChain(), LD->getBasePtr(), - LD->getSrcValue(), LD->getSrcValueOffset(), VT); + LD->getSrcValue(), LD->getSrcValueOffset(), + LD->getLoadVT()); // Remember that we legalized the chain. AddLegalizedOperand(Op.getValue(1), LegalizeOp(Result.getValue(1))); break;