Stas Malyshev wrote:
> Hi!
>
>> http://volnitsky.com/project/str_search/
>
> I'm not sure it'd be easy to integrate this into PHP codebase as-is,
> provided it relies on C++ standard libraries which PHP makes no use of
> (and thus potentially introduces a world of dependencies and
> complexities into the build process). I'm sure it can be re-done in
> pure standard C, then it can be tested in PHP and if it's better - I
> don't see why it can't be integrated.
>
Not really. It only uses std::search, which would be equivalent to the
current zend_memnstr(). And std::numeric_limits can be replaced with a
limits.h macro.
I'd be more concerned about the "only for little-endian platforms and
where access to misaligned W is allowed" remark. php is also available
for big endian architectures, but that seems easy. Some architecture
supported by php won't probably accept that, so it would also need some
configure test to disable it.



-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to