The size of the code cache, its usage and the activity of the code cache sweeper would be useful information to export and track via perf data counters.
I am attaching a patch (based on jdk 8uXX version of hotspot) which exposes a few new counters, viz, the top few lines in the display below:
$ jcmd <pid> PerfCounter.print | grep -i "sun\.ci\."
sun.ci.codeCacheCapacity=6291456
sun.ci.codeCacheMaxCapacity=6291456
sun.ci.codeCacheMethodsReclaimedNum=1030
sun.ci.codeCacheSweepsTotalNum=93
sun.ci.codeCacheSweepsTotalTimeMillis=63
sun.ci.codeCacheUsed=3386880
...
These counters are useful to quickly assess code cache churn and sweeper activity.