Re: bug in zend_API.c (with patch)
| From: | Wez Furlong | Date: | Sat, 08 Mar 2003 01:38:33 +0000 |
| Subject: | Re: bug in zend_API.c (with patch) | ||
| References: | 1 2 3 4 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-94917@lists.php.net to get a copy of this message | ||
On Sat, 7 Mar 2003, Eric Lambart wrote:
> > Adding strtolower calls will only slow down the whole language.
> but my
> point is the overhead involved cannot possibly rival the amount already
> created by the zend_str_tolower() calls within zend_execute.c, which is
> surely encountered far more often in everyday use of PHP.
>
> Does what I am suggesting make sense, now?
Yes, but simple maths suggests that adding a strtolower call when
building the initial hash for each of 2837 functions is surely slower
than not having it :) (this is just for extensions in the core).
You have to remember that this cost is incurred each time php is loaded;
a big performance hit for people using CGI for example.
> But as I have seen no warnings or admonitions about using one or more
> upper case letters in a function or class name in the available
> extension-writing documentation (either online, or in the book ...
Consider this thread a warning ;-)
--Wez.