FireProfile is a C library for identifying bottlenecks in programs that use MySQL. FireProfile can be LD_PRELOAD'ed in before the program in question to provide profiling information without recompiling.
It shows what queries are being executed, the time being spent on them, and the EXPLAIN SELECT output for any SELECT queries. It also produces warnings for common MySQL programming errors.
To build the library, simply type:
(su to root)
The makefile accepts the following environment variables to change its behaviour:
You may need to alter these for your individual configuration.