# alternative valgrind-like support for run-tests along other nice additions

- Thread: https://externals.io/message/90908
- Original archive: https://news-web.php.net/php.internals/90908
- Started by Pierre Joye on 2016-01-25T08:49:50+00:00
- Messages: 2
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #90908 — Pierre Joye — 2016-01-25T08:49:50+00:00

URL: https://externals.io/message/90908#90908

hi,

It has been a long due request to have something similar to valgrind
on Windows. I use a tool since quite some time for C projects and it
becomes so handy that it is now a good choice for testing PHP as well,
DrMemory (http://drmemory.org/)

It works on many other platforms as well and provide some other tools
and options that could be very handy for php as well. It uses their
toolset called DynamoRIO (http://www.dynamorio.org/) which is
amazingly powerful, brings strace for windows as well as many other
niches tools.

I made a quick port for run-tests.php -m using drmemory:

https://gist.github.com/pierrejoye/e53deffb7e069a67fc3f

(master). Draft stage, need cleanup of the log directory. Also willing
to provide a PR to their repo to support --logfile valgrind options
(will hopefully be discussed here
https://github.com/DynamoRIO/drmemory/issues/1853).

Be sure to have drmemory (1.9.x) in your path.

This is only for Windows but I think it could make sense to provide it
for other platforms as well, optionally. It can then allow us to
support other features more easily. I am particularly interested to
see if we can make some use of the fuzzy testing or use it to test our
internals APIs (what we cruelly miss now). I did not test the
performance but they claim to be faster than valgrind.

If there is any interest I can continue the port and make it available
on any supported platforms and create a RFC for it.

If not, I will simply apply the windows port so windows devs
(extension or core) can finally have something like valgrind.

Thoughts, ideas and comments welcome.

Cheers,
-- 
Pierre

@pierrejoye | http://www.libgd.org

---

## #90914 — Yasuo Ohgaki — 2016-01-25T11:36:32+00:00

URL: https://externals.io/message/90908#90914 · In reply to: #90908

Hi Pierre,


> This is only for Windows but I think it could make sense to provide it
> for other platforms as well, optionally. It can then allow us to
> support other features more easily. I am particularly interested to
> see if we can make some use of the fuzzy testing or use it to test our
> internals APIs (what we cruelly miss now). I did not test the
> performance but they claim to be faster than valgrind.

Although I don't have experience with DrMemory.
Nice idea, for windows developers especially.
+1

--
Yasuo Ohgaki
yohgaki@ohgaki.net
