It's both Gmail and Exchange accounts.
I fixed on my gmail account. I did this accidentally when testing. I logged in under another account on my Mac in Safe Mode; added the gmail account there and tested with no issues under the new login. Came back to my regular login account and gmail working fine again. Went back to other account and deleted.
However, all of my Exchange accounts I have not been able to fix. I can run one at a time for a little while, but eventually have to disable once the "accountsd" process spins out of control.
All other types of email accounts work fine... this is limited to Gmail and Exchange, Exchange being the worst offender I think.
I've also noted that other 'tied in' apps will freeze and need to be force quit that are tied in via Exchange, such as Notes, Contacts, Calendar, Reminders. Deselecting these under Exchange Account settings seems to fix them freezing.
I've also seen Messages freeze when "accountsd" process is ramped up.
It's amazing this doesn't affect iOS whatsoever... but I remember about 3 years ago I had same issue on iOS until updates fixed.