PHPackages                             jbzoo/profiler - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Testing &amp; Quality](/categories/testing)
4. /
5. jbzoo/profiler

Abandoned → [https://github.com/phpbench/phpbench](/?search=https%3A%2F%2Fgithub.com%2Fphpbench%2Fphpbench)ArchivedLibrary[Testing &amp; Quality](/categories/testing)

jbzoo/profiler
==============

Simple Profiler for PHP code and unit tests

1.0.5(10y ago)616.6k↑42.9%12MITPHPPHP &gt;=5.3

Since Mar 11Pushed 9y ago1 watchersCompare

[ Source](https://github.com/JBZoo/Profiler)[ Packagist](https://packagist.org/packages/jbzoo/profiler)[ RSS](/packages/jbzoo-profiler/feed)WikiDiscussions master Synced yesterday

READMEChangelog (6)Dependencies (2)Versions (8)Used By (2)

JBZoo Profiler [![Build Status](https://camo.githubusercontent.com/fb3cd497d6899d8ecd24e644ec31f7e43c45a7197767798a79105cd3391a7781/68747470733a2f2f7472617669732d63692e6f72672f4a425a6f6f2f50726f66696c65722e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/JBZoo/Profiler) [![Coverage Status](https://camo.githubusercontent.com/b1238ae1ee37012283c5d27bf32560a97efb3a7add8ad2f22a764d5621ceed5f/68747470733a2f2f636f766572616c6c732e696f2f7265706f732f6769746875622f4a425a6f6f2f50726f66696c65722f62616467652e7376673f6272616e63683d6d6173746572)](https://coveralls.io/github/JBZoo/Profiler?branch=master)
=============================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================================

[](#jbzoo-profiler--------)

#### Simple Profiler for PHP code and unit tests

[](#simple-profiler-for-php-code-and-unit-tests)

[![License](https://camo.githubusercontent.com/cf17bdfd58aa12d9a651e76459ad66dc2c2bd06925a7debfcb9c7b8f24df9203/68747470733a2f2f706f7365722e707567782e6f72672f4a425a6f6f2f50726f66696c65722f6c6963656e7365)](https://packagist.org/packages/JBZoo/Profiler) [![Latest Stable Version](https://camo.githubusercontent.com/a13e327aab9cbf1493cf02bcd8d413a7b69b1fe1c7cee41464c2115aa28600b1/68747470733a2f2f706f7365722e707567782e6f72672f4a425a6f6f2f50726f66696c65722f762f737461626c65)](https://packagist.org/packages/JBZoo/Profiler) [![Scrutinizer Code Quality](https://camo.githubusercontent.com/27b15d8df0db34ca5be5be8d582cb27230373ceaa95bed0d78143149c96e8c45/68747470733a2f2f7363727574696e697a65722d63692e636f6d2f672f4a425a6f6f2f50726f66696c65722f6261646765732f7175616c6974792d73636f72652e706e673f623d6d6173746572)](https://scrutinizer-ci.com/g/JBZoo/Profiler/?branch=master)

Usage
-----

[](#usage)

```
use JBZoo\Profiler\Benchmark;

// Compare performance of functions
Benchmark::compare([
    'md5'   => function () {
        $string = str_repeat(mt_rand(0, 9), 1024 * 1024);
        return md5($string);
    },
    'sha1'  => function () {
        $string = str_repeat(mt_rand(0, 9), 1024 * 1024);
        return sha1($string);
    },
    'crc32' => function () {
        $string = str_repeat(mt_rand(0, 9), 1024 * 1024);
        return crc32($string);
    },
], array('count' => 500, 'name' => 'Hash functions'));

/* Result:

  ---------- Start benchmark: Hash functions  ----------
  Running tests 500 times
  PHP Overhead: time=58 ms; memory=0 B;

  Testing 1/3 : md5 ... Done!
  Testing 2/3 : sha1 ... Done!
  Testing 3/3 : crc32 ... Done!

  Name of test    Time, ms    Time, %     Memory    Memory, %
  crc32              1 551          ~    1.25 MB            ~
  md5                1 938         25    1.25 MB            ~
  sha1               2 776         79    1.25 MB            ~

  TOTAL TIME: 6 547.37 ms/4.36 ms;   MEMO: 41.05 KB/0.03 KB;   COUNT: 1 500
  ---------- Finish benchmark: Hash functions  ----------
*/

Benchmark::run(function () {
      $string = str_repeat(mt_rand(0, 9), 1024 * 1024);
      return md5($string);
  }, ['count' => 1000]),
```

Unit tests and check code style
-------------------------------

[](#unit-tests-and-check-code-style)

```
make
make test-all
```

### License

[](#license)

MIT

###  Health Score

34

—

LowBetter than 75% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity29

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~5 days

Total

6

Last Release

3740d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/75e6de2785f6d099699f430ff58404af4fc0e83060d2953028c9664a54704a5f?d=identicon)[smetdenis](/maintainers/smetdenis)

---

Top Contributors

[![SmetDenis](https://avatars.githubusercontent.com/u/1118678?v=4)](https://github.com/SmetDenis "SmetDenis (12 commits)")

---

Tags

phpunitprofilerperformancetestsmemorytimerbenchmarkmicrotime

### Embed Badge

![Health badge](/badges/jbzoo-profiler/health.svg)

```
[![Health](https://phpackages.com/badges/jbzoo-profiler/health.svg)](https://phpackages.com/packages/jbzoo-profiler)
```

###  Alternatives

[dama/doctrine-test-bundle

Symfony bundle to isolate doctrine database tests and improve test performance

1.2k39.5M201](/packages/dama-doctrine-test-bundle)[jsanc623/phpbenchtime

A lightweight benchmark timer and lap profiler for PHP.

2439.3k1](/packages/jsanc623-phpbenchtime)[mybuilder/phpunit-accelerator

PHPUnit accelerator

1363.0M39](/packages/mybuilder-phpunit-accelerator)[whatthejeff/nyancat-phpunit-resultprinter

Nyan Cat result printer for PHPUnit

281695.3k24](/packages/whatthejeff-nyancat-phpunit-resultprinter)[phpbenchmark/phpbenchmark

Easy to use benchmark toolkit for your PHP-application. This library contains classes for comparing algorithms as well as benchmarking application responses

8011.5k2](/packages/phpbenchmark-phpbenchmark)[phpunit/phpunit-dom-assertions

DOM assertions for PHPUnit

29374.8k13](/packages/phpunit-phpunit-dom-assertions)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
