diff options
| author | Geo Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2026-07-12 15:51:52 +0300 |
|---|---|---|
| committer | Geo Halkiadakis <gchalkiadakis@sklavenitis.co.gr> | 2026-07-12 15:51:52 +0300 |
| commit | 02608271bb2a9f3a65ed536984d306ee14b48e34 (patch) | |
| tree | 3f23ec48a694ec014e845c4f70d9b5f1c065403c /tests/compare/md5-v-sha1.php | |
| download | kalassa-02608271bb2a9f3a65ed536984d306ee14b48e34.tar.gz kalassa-02608271bb2a9f3a65ed536984d306ee14b48e34.tar.bz2 kalassa-02608271bb2a9f3a65ed536984d306ee14b48e34.zip | |
Diffstat (limited to 'tests/compare/md5-v-sha1.php')
| -rwxr-xr-x | tests/compare/md5-v-sha1.php | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/compare/md5-v-sha1.php b/tests/compare/md5-v-sha1.php new file mode 100755 index 0000000..74d0371 --- /dev/null +++ b/tests/compare/md5-v-sha1.php @@ -0,0 +1,18 @@ +<?php + +echo "test started... "; +ob_flush(); + +Benchmark::add_spot('100.000 x md5'); +for($i = 0 ; $i<100000 ; $i++) $x = md5($i); + + +Benchmark::add_spot('100.000 x sha'); +for($i = 0 ; $i<100000 ; $i++) $x = sha1($i); + +Benchmark::add_spot('end'); +echo(Benchmark::report(BENCH_REPORT_COMMENT)); +echo "test completed!"; + +die(); +
\ No newline at end of file |
