While you want to look in only one directory, then yes, encoding it using PHP functions is faster. But if you want to search recursively through the tree for a specific file name, then it will probably be much faster to lay out:
$cmd="dir $fname /s"
chdir("C:/");
$found=explode("\n",`$cmd`);
, NT , , - - .
.