From 55b5708b6bbffc79cf133c31faa51d144bfc5d4a Mon Sep 17 00:00:00 2001 From: Chris Lattner Date: Tue, 10 Oct 2006 18:54:19 +0000 Subject: [PATCH] Fix another bug in extload promotion. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30857 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/SelectionDAG/LegalizeDAG.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) 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; -- 2.34.1