@@ -761,7 +761,7 @@ class SCCPInstVisitor : public InstVisitor<SCCPInstVisitor> {
761761 void handleCallArguments (CallBase &CB);
762762 void handleExtractOfWithOverflow (ExtractValueInst &EVI,
763763 const WithOverflowInst *WO, unsigned Idx);
764- bool isInstUnderDefined (Instruction &Inst);
764+ bool isInstOverDefined (Instruction &Inst);
765765
766766private:
767767 friend class InstVisitor <SCCPInstVisitor>;
@@ -1381,9 +1381,9 @@ void SCCPInstVisitor::visitPHINode(PHINode &PN) {
13811381 if (PN.getNumIncomingValues () > 64 )
13821382 return (void )markOverdefined (&PN);
13831383
1384- if (isInstUnderDefined (PN))
1384+ if (isInstOverDefined (PN))
13851385 return ;
1386- llvm:: SmallVector<unsigned > FeasibleIncomingIndices;
1386+ SmallVector<unsigned > FeasibleIncomingIndices;
13871387 for (unsigned i = 0 , e = PN.getNumIncomingValues (); i != e; ++i) {
13881388 if (!isEdgeFeasible (PN.getIncomingBlock (i), PN.getParent ()))
13891389 continue ;
@@ -2146,10 +2146,10 @@ void SCCPInstVisitor::handleCallResult(CallBase &CB) {
21462146 }
21472147}
21482148
2149- bool SCCPInstVisitor::isInstUnderDefined (Instruction &Inst) {
2150- // For structure Type, we handle each member seperately .
2151- // A structure object won't be considered as overDefined when
2152- // there is at least one member can become constant .
2149+ bool SCCPInstVisitor::isInstOverDefined (Instruction &Inst) {
2150+ // For structure Type, we handle each member separately .
2151+ // A structure object won't be considered as overdefined when
2152+ // there is at least one member that is not overdefined .
21532153 if (StructType *STy = dyn_cast<StructType>(Inst.getType ())) {
21542154 for (unsigned i = 0 , e = STy->getNumElements (); i < e; ++i) {
21552155 if (!getStructValueState (&Inst, i).isOverdefined ())
0 commit comments