new StoreInst(ConstantInt::get(Type::Int8Ty,0), Ptr, CI);
return ReplaceCallWith(CI, ConstantInt::get(Type::Int32Ty, 1));
}
case 's': {
// sprintf(dest,"%s",str) -> llvm.memcpy(dest, str, strlen(str)+1, 1)
new StoreInst(ConstantInt::get(Type::Int8Ty,0), Ptr, CI);
return ReplaceCallWith(CI, ConstantInt::get(Type::Int32Ty, 1));
}
case 's': {
// sprintf(dest,"%s",str) -> llvm.memcpy(dest, str, strlen(str)+1, 1)