Home | History | Annotate | Download | only in Utils

Lines Matching refs:StrNCmp

609     // Verify the "strncmp" function prototype.
619 if (Str1P == Str2P) // strncmp(x,x,n) -> 0
629 if (Length == 0) // strncmp(x,y,0) -> 0
632 if (DL && Length == 1) // strncmp(x,y,1) -> memcmp(x,y,1)
639 // strncmp(x, y) -> cnst (if both x and y are constant strings)
646 if (HasStr1 && Str1.empty()) // strncmp("", x, n) -> -*x
650 if (HasStr2 && Str2.empty()) // strncmp(x, "", n) -> *x
944 // fold strstr(a, b) == a -> strncmp(a, b, strlen(b)) == 0
949 Value *StrNCmp = EmitStrNCmp(CI->getArgOperand(0), CI->getArgOperand(1),
951 if (!StrNCmp)
955 Value *Cmp = B.CreateICmp(Old->getPredicate(), StrNCmp,
956 ConstantInt::getNullValue(StrNCmp->getType()),
2065 static StrNCmpOpt StrNCmp;
2136 case LibFunc::strncmp:
2137 return &StrNCmp;