https://github.com/joshuarli/dotfiles/blob/master/misc/firef...
Also have a bunch of umatrix rules, but not inclined on sharing those. Regarding gmail, keep a pinned tab open on about:memory and periodically click on GC and minimize memory, that might be a better solution than reloading.