factor out perf.c
NEWS
Merge branch 'master' into auto
add perf.c