Hacking up valgrind-mmt

Posted at 2007-01-08

Last week I hacked on Dave Airlie's valgrind-mmt.

Features I implemented:

  • Support for tracking write-only registers. This is done by asking Valgrind for the value that the application wanted to set, rather than reading the register after it was set.
  • Support for tracking register reads. Actually you have to comment out some code (it's pretty obvious which) to make it not track those. FIXME :)
  • The MMIO address isn't hardcoded anymore, but it's set with an command line argument (--offset). Weird stuff will happen if you don't set the offset.
  • It now tracks up to 100 MMIO areas instead of just one. This hardcoded limit is butt-ugly, but 100 mmaps should be enough for everyone, right? ;)
  • It probably only works on 32 bit arches now, and 64 bit registers are not supported.

Here's the diff against Valgrind SVN trunk.

Tags ,