I've removed most all of that stuff from Drizzle (and removed two or three sets of now-no-longer-necessary mutex locks in the process), and replaced it with hooks into a logging plugin subsystem, and have implemented two plugins for it. One logs to a file, and the other logs to syslog.
The output looks almost completely unlike the current MySQL logging. There are no hash-prefixed pseudocomments, for one thing. And there is no distinction between the query log and the slow query log. Queries get logged, and the amount of time each query takes gets logged with it. This subsumes the "micro-slow patch" that is spreading around in the MySQL legacy world.
The current format is pretty "programmer-centric", but concrete advice and patches are welcome.
" t_connect=%lld t_start=%lld t_lock=%lld"
" rows_sent=%ld rows_examined=%u\n"
" db=\"%.*s\" query=\"%.*s\"\n",
(unsigned long) session->thread_id,
(unsigned long) session->query_id,
(unsigned long long)(t_mark - session->connect_utime),
(unsigned long long)(t_mark - session->start_utime),
(unsigned long long)(t_mark - session->utime_after_lock),
(unsigned long) session->sent_row_count,
How to interpret this output, and how to turn on, control, and use logging, will be described in additional posts.