[php-src] PR #14170: BCMath: Avoid using the heap for temporary objects by using arena allocations
| From: | nielsdos | Date: | Tue, 07 May 2024 18:58:49 +0000 |
| Subject: | [php-src] PR #14170: BCMath: Avoid using the heap for temporary objects by using arena allocations | ||
| Groups: | php.git-pulls | ||
| Request: | Send a blank email to git-pulls+get-26077@lists.php.net to get a copy of this message | ||
Pull Request: https://github.com/php/php-src/pull/14170
Author: nielsdos
Benchmark: https://github.com/php/php-src/pull/14132
Bench 1:
```
Benchmark 1: ./sapi/cli/php 1.php
Time (mean ± σ): 401.4 ms ± 2.4 ms [User: 397.9 ms, System: 3.2 ms]
Range (min … max): 399.2 ms … 407.8 ms 10 runs
Benchmark 2: ./sapi/cli/php_old 1.php
Time (mean ± σ): 450.6 ms ± 8.0 ms [User: 448.0 ms, System: 2.2 ms]
Range (min … max): 445.1 ms … 472.8 ms 10 runs
Summary
./sapi/cli/php 1.php ran
1.12 ± 0.02 times faster than ./sapi/cli/php_old 1.php
```
Bench 2:
```
Benchmark 1: ./sapi/cli/php 2.php
Time (mean ± σ): 462.0 ms ± 4.5 ms [User: 459.8 ms, System: 1.9 ms]
Range (min … max): 454.2 ms … 467.6 ms 10 runs
Benchmark 2: ./sapi/cli/php_old 2.php
Time (mean ± σ): 521.8 ms ± 8.7 ms [User: 519.8 ms, System: 1.5 ms]
Range (min … max): 515.1 ms … 536.5 ms 10 runs
Summary
./sapi/cli/php 2.php ran
1.13 ± 0.02 times faster than ./sapi/cli/php_old 2.php
```
Bench 3:
```
Benchmark 1: ./sapi/cli/php 3.php
Time (mean ± σ): 562.3 ms ± 4.9 ms [User: 560.9 ms, System: 0.6 ms]
Range (min … max): 557.7 ms … 571.9 ms 10 runs
Benchmark 2: ./sapi/cli/php_old 3.php
Time (mean ± σ): 607.9 ms ± 9.4 ms [User: 604.8 ms, System: 2.5 ms]
Range (min … max): 602.9 ms … 634.0 ms 10 runs
Summary
./sapi/cli/php 3.php ran
1.08 ± 0.02 times faster than ./sapi/cli/php_old 3.php
```