dgraph-io / ristretto

A high performance memory-bound Go cache

Home Page:https://dgraph.io/blog/post/introducing-ristretto-high-perf-go-cache/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

KeyToHash possibly letting key interfaces escape to heap

karlmcguire opened this issue · comments

As brought up in the performance Gopher channel, since we're using interface{} for keys, this call to keyToHash is probably letting the interface escape to heap.

Solution: switch over to string or []byte for public API calls.

@karlmcguire should the change be for keys or keys and values?

Github issues have been deprecated.
This issue has been moved to discuss. You can follow the conversation there and also subscribe to updates by changing your notification preferences.

drawing