acquia / statsgod

A Statsd implementation written in GO lang
Apache License 2.0
119 stars 8 forks source link

Improving string performance. #87

Closed kevinhankens closed 9 years ago

kevinhankens commented 9 years ago

After profiling I noticed that it was spending a ton of time in strings.Trim() so I reworked it a little bit to iterate over the runes (int32 char value) instead of using convenience functions in the strings lib. Subsequent profiling and pidstat monitoring looks much better. There is still a lot of room for improvement, but this is an incremental improvement.

protochron commented 9 years ago

Seems fine to me. I'm going to let @jfarrell push the button though since I suspect he's spent more time working on Go code than I have.