From: Dan Gohman Date: Mon, 21 Jun 2010 14:17:46 +0000 (+0000) Subject: Generalize this to look in the regular ValueMap in addition to X-Git-Url: http://plrg.eecs.uci.edu/git/?a=commitdiff_plain;h=37db6cdaea47d0637bdbe624f7b10ff8f82928ad;p=oota-llvm.git Generalize this to look in the regular ValueMap in addition to the LocalValueMap, to make it more flexible when fast-isel isn't proceding straight top-down. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@106414 91177308-0d34-0410-b5e6-96231b3b80d8 --- diff --git a/lib/CodeGen/SelectionDAG/FastISel.cpp b/lib/CodeGen/SelectionDAG/FastISel.cpp index d21ba233e9a..58d8344479c 100644 --- a/lib/CodeGen/SelectionDAG/FastISel.cpp +++ b/lib/CodeGen/SelectionDAG/FastISel.cpp @@ -162,7 +162,7 @@ unsigned FastISel::materializeRegForValue(const Value *V, MVT VT) { } } else if (const Operator *Op = dyn_cast(V)) { if (!SelectOperator(Op, Op->getOpcode())) return 0; - Reg = LocalValueMap[Op]; + Reg = lookUpRegForValue(Op); } else if (isa(V)) { Reg = createResultReg(TLI.getRegClassFor(VT)); BuildMI(MBB, DL, TII.get(TargetOpcode::IMPLICIT_DEF), Reg);