note 48296 deleted from function.stripos by tularis
| From: | tularis@php.net | Date: | Sat, 18 Dec 2004 09:27:35 +0000 |
| Subject: | note 48296 deleted from function.stripos by tularis | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-81966@lists.php.net to get a copy of this message | ||
Note Submitter: drenintell
----
Something came to my attention that it is worth mentioning here. It seems that striPos is an
expensive function. That is, if you run strPos, say on a 50mb of text 1mb at a time, and run striPos
with the same setup, striPos is about 15 times slower then strPos. Ouch. Performace improves
slightly if you process the above text file 4096 kiloytes at a time. In this case striPos is about
9 times slower.
Of course there are many factors involed that influence the above numbers, including cluster size,
available memory, memory speed, CPU speed etc., however keep in mind that striPos can and it is an
expensive function to use on large files. I will try to rewrite striPos and see if there is a better
and faster implementation and post my findings here. (if any)...here goes nothing.
*drenintell*
----
Reason: useless note