Skip to content

Commit 99adfec

Browse files
committed
The scheduler needs to be aware on the existence of untyped nodes when it performs type propagation for EXTRACT_SUBREG.
llvm-svn: 133838
1 parent 57e34b2 commit 99adfec

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

llvm/lib/CodeGen/SelectionDAG/ScheduleDAGSDNodes.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -521,7 +521,8 @@ void ScheduleDAGSDNodes::RegDefIter::Advance() {
521521
if (!Node->hasAnyUseOfValue(DefIdx))
522522
continue;
523523
if (Node->isMachineOpcode() &&
524-
Node->getMachineOpcode() == TargetOpcode::EXTRACT_SUBREG) {
524+
Node->getMachineOpcode() == TargetOpcode::EXTRACT_SUBREG &&
525+
Node->getOperand(0).getValueType() != MVT::untyped) {
525526
// Propagate the incoming (full-register) type. I doubt it's needed.
526527
ValueType = Node->getOperand(0).getValueType();
527528
}

0 commit comments

Comments
 (0)