Skip to content

Commit d36d409

Browse files
committed
Compatibility with benchmark kit 4.0.0.-DEV
1 parent 8a287aa commit d36d409

File tree

14 files changed

+95
-46
lines changed

14 files changed

+95
-46
lines changed

.circleci/config.yml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
version: '2.1'
2+
3+
jobs:
4+
ValidateBenchmark:
5+
docker:
6+
- image: phpbenchmarks/benchmark-kit:4
7+
working_directory: /var/www/benchmark
8+
steps:
9+
- checkout
10+
- run:
11+
name: /var/entrypoint.sh
12+
command: /var/entrypoint.sh --nginx-as-service
13+
- run:
14+
name: "benchmark:validate"
15+
command: "/var/benchmark-kit/bin/console benchmark:validate:all"
16+
17+
workflows:
18+
version: '2.1'
19+
BenchmarkKit:
20+
jobs:
21+
- ValidateBenchmark

.gitignore

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,2 @@
1-
.idea/
2-
vendor/
3-
composer.lock
1+
/vendor/
2+
/composer.lock

.phpbenchmarks/config.yml

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
component:
2+
id: 1
3+
benchmark:
4+
type: 1
5+
relativeUrl: /
6+
sourceCode:
7+
entryPoint: public/index.php
8+
urls:
9+
entryPoint: 'https://github.com/phpbenchmarks/php/blob/7.1.33_hello-world_0/public/index.php'
10+
coreDependency:
11+
name: php
12+
version: 7.1.33

.phpbenchmarks/nginx/vhost.conf

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
server {
2+
listen ____PORT____;
3+
server_name ____HOST____;
4+
root ____INSTALLATION_PATH____/public;
5+
location / {
6+
try_files $uri /index.php$is_args$args;
7+
}
8+
location ~ ^/(index).php(/|$) {
9+
fastcgi_pass unix:/run/php/____PHP_FPM_SOCK____;
10+
fastcgi_split_path_info ^(.+.php)(/.*)$;
11+
include fastcgi_params;
12+
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
13+
fastcgi_param HTTPS off;
14+
}
15+
}

composer.lock renamed to .phpbenchmarks/php/7.1/composer.lock

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
#!/usr/bin/env bash
2+
3+
set -e
4+
5+
composer install --no-dev --classmap-authoritative --ansi

.phpbenchmarks/php/7.1/php.ini

Whitespace-only changes.

.phpbenchmarks/php/7.1/preload.php

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
<?php
2+
3+
declare(strict_types=1);
4+
5+
$rootDir = __DIR__ . '/../../..';
6+
require($rootDir . '/public/index.php');
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Hello World !

README.md

Lines changed: 29 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,24 +4,43 @@
44
<a href="http://www.phpbenchmarks.com" target="_blank">www.phpbenchmarks.com</a>
55
</p>
66

7-
## What is www.phpbenchmarks.com ?
7+
## What is www.phpbenchmarks.com?
88

9-
You will find lot of benchmarks for PHP frameworks and template engines.
9+
You will find a lot of benchmarks for PHP and PHP libraries on [phpbenchmarks.com](http://www.phpbenchmarks.com).
1010

11-
You can compare results between Apache Bench and Siege, and PHP 5.6 to 7.2.
11+
Benchmarks results are available from PHP 5.6 to latest version.
1212

13-
## What is this repository ?
13+
Our benchmarking protocol is available on [benchmarking protocol page](http://www.phpbenchmarks.com/en/documentation/benchmarking-protocol).
1414

15-
It's benchmark common code for PHP benchmarks.
15+
## What is this repository?
1616

17-
Switch branch to select your PHP major version and benchmark you want to see.
17+
It contains PHP benchmark code.
1818

19-
See all PHP benchmarked versions on [phpbenchmarks/php](https://github.com/phpbenchmarks/php).
19+
Switch branch to select version and benchmark you want to see.
2020

21-
You can find how we benchmark on [phpbenchmarks.com](http://www.phpbenchmarks.com/en/benchmark-protocol.html).
21+
You can find source code links into [Configuration::getSourceCodeUrls()](.phpbenchmarks/Configuration.php).
2222

2323
## Benchmarks
2424

25-
You can find all PHP benchmarks results on [phpbenchmarks.com](http://www.phpbenchmarks.com/en/benchmark/php.html).
25+
You can find PHP 7.1 benchmarks results on
26+
[benchmarks results page](http://www.phpbenchmarks.com/en/benchmark/php/7.1).
2627

27-
Scores are too low ? Do not hesitate to create a pull request, and ask a new benchmark !
28+
See all PHP benchmarked versions on [select version page](http://www.phpbenchmarks.com/en/benchmark/php/version).
29+
30+
## Community
31+
32+
Go to [community page](http://www.phpbenchmarks.com/en/community) to see the Hall of fame, or download the benchmark kit to add your code!
33+
34+
## How version works?
35+
36+
We do not follow semantic version for this repository.
37+
38+
Here is an explanation about our versioning system:
39+
40+
`X.Y.Z_benchmark-slug_W`
41+
42+
* `X`: PHP major version.
43+
* `Y`: PHP minor version.
44+
* `Z`: PHP patch version.
45+
* `benchmark-slug`: slug of the benchmark, list available on [documentation page](http://www.phpbenchmarks.com/en/documentation).
46+
* `W`: benchmark version

composer.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,6 @@
33
"license": "proprietary",
44
"type": "project",
55
"require": {
6-
"php": "7.1.*"
6+
"php": "7.1.33"
77
}
88
}

composer.lock.php7.1

Lines changed: 0 additions & 19 deletions
This file was deleted.

init_benchmark.sh

Lines changed: 0 additions & 8 deletions
This file was deleted.

index.php renamed to public/index.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,5 +3,3 @@
33
declare(strict_types=1);
44

55
echo 'Hello World !';
6-
7-
// require phpbenchmarks stats.php here when needed

0 commit comments

Comments
 (0)