lcs values for v1.2 and v2.0. Wonder if you get different values?
If you don't mind some huge logs, you could also try the attached patch that logs the voluntary context switch count for every executed IMAP command. Maybe some command shows up that generates them much more than others. <diff>
I have applied this patch to 1 server, and it's logging away. Let me know what kind of output you'd like to see. Or i can send you the raw logfile. As I said previously, im not longer running the imap server=0 patch because it caused these errors:
Dec 9 06:54:32 userimap30 dovecot: imap(cor): Error: user cor: Initialization failed: Namespace '': mkdir(/var/spool/mail/.4a/L/0/14/corbosch) failed: Permission denied (euid=1000(cor) egid=50(staff) missing +w perm: /var/spool/mail/.4a/L/0/14, euid is not dir owner).
After I removed the patch these errors disappeared.
Cor