Add method to count events by stack

We need this method to efficiently count events by stack to allow
pruning them if there are too many.

Change-Id: Ifd5ed78e37a14116497f8bc008739ee9938e194d
Related-Bug: #1209492
Make HOT parser errors translatable

These errors can get passed back to the user so wrap them in _()

Change-Id: I2509b35fd7b6b68eb0342179656cbafd7559e2f3
Merge "Add method to count events by stack"
Merge "Make HOT parser errors translatable"