Doxygen is the de facto standard tool for generating documentation from C++ code sources. It works to some extent with perl.
This is not as helpful for finding commands in the PG language as it might be since so many of them are in a single domain space: "main".
It is somewhat more useful for tracking down the location of MathObjects commands.
At the moment Doxygen is useful but not very convenient for tracking down the file where commands are defined.
Another aid in this regard is the table at http://webwork.maa.org/moodle/mod/data/view.php?id=5 which is much better at locating the file in which a command is defined.
Unfortunately this table is far out of date and won't have the newest commands.