Bug #74929 [Com]: mbstring functions version 7.1.1 are slow compared to 5.3 on Windows
| From: | andxfiles at gmail dot com | Date: | Mon, 24 Jul 2017 06:53:23 +0000 |
| Subject: | Bug #74929 [Com]: mbstring functions version 7.1.1 are slow compared to 5.3 on Windows | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-210251@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=74929&edit=1
ID: 74929
Comment by: andxfiles at gmail dot com
Reported by: andxfiles at gmail dot com
Summary: mbstring functions version 7.1.1 are slow compared
to 5.3 on Windows
Status: Feedback
Type: Bug
Package: mbstring related
Operating System: Windows
PHP Version: 7.1.7
Block user comment: N
Private report: N
New Comment:
ab@php.net, nikic@php.net:
Unfortunately under Windows I still see no difference. New results:
5.3.28:
mb_strlen: 309.4 milliseconds
mb_stripos: 3523.4 milliseconds
mb_substr: 326.6 milliseconds
7.1.1:
mb_strlen: 426.3 milliseconds
mb_stripos: 4812.5 milliseconds
mb_substr: 421.9 milliseconds
7.1.9-dev (master)
mb_strlen: 421.9 milliseconds
mb_stripos: 4890.6 milliseconds
mb_substr: 421.9 milliseconds
Previous Comments:
------------------------------------------------------------------------
[2017-07-23 19:15:31] ab@php.net
@andxfiles, Nikita made quite a few improvements to ext mbstring in master, see bug #74933. I'd
say, it would make sense to check some latest master snapshot, to fetch here http://windows.php.net/snapshots/ . We also work on a
new PGO approach, so further improvements are to come.
Thanks.
------------------------------------------------------------------------
[2017-07-23 03:14:28] andxfiles at gmail dot com
Both versions of php are Non Thread Safe. Windows version is: Windows Server 2012 Standard 64bit.
However, a user on stackoverflow (link in previous comment) has replicated it in Windows 7 as well.
------------------------------------------------------------------------
[2017-07-22 12:22:34] ab@php.net
Ok. As a followup - both use same flavor TS/NTS? Both tested on the same machine? Which exact Widows
version?
Thanks.
------------------------------------------------------------------------
[2017-07-22 10:45:39] andxfiles at gmail dot com
In both cases I'm using 32bit versions of php. One case is php 5.3.28 and the other is 7.1.1.
The OS is Windows, the problem does not seem to exist under Linux. Both versions are installed via
Web Platform Installer from within IIS.
Other people have been able to reproduce it: https://stackoverflow.com/questions/45028018/php-7-mb-multibyte-functions-are-60-slower-than-in-5-3-possibly-windows-on
------------------------------------------------------------------------
[2017-07-22 08:47:18] ab@php.net
Thanks for the report. Do you use a 64-bit build of PHP 7? If so, please compare with a 32-bit
build. I basically can't reproduce such a big discrepancy, but otherwise it could be possible a
64-bit build would be slower a little bit.
Thanks.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=74929
--
Edit this bug report at https://bugs.php.net/bug.php?id=74929&edit=1