Kim Jin Chul has posted comments on this change. Change subject: IMPALA-5116: Remove deprecated hash_* types in gutil ......................................................................
Patch Set 3: (2 comments) http://gerrit.cloudera.org:8080/#/c/7414/3/be/src/gutil/hash/hash.h File be/src/gutil/hash/hash.h: PS3, Line 218: As I told in the previous comment, _gnu_ctx is replaced into std. https://gerrit.cloudera.org/#/c/7414/1/be/src/gutil/hash/hash.h@a278 Line 251 You may know std already defined pointer type as below. /// Partial specializations for pointer types. template<typename _Tp> struct hash<_Tp*> : public __hash_base<size_t, _Tp*> { size_t operator()(_Tp* __p) const noexcept { return reinterpret_cast<size_t>(__p); } }; I guess your hash function is more faster than std's implementation, but there are pros and cons. I found the interesting article: https://stackoverflow.com/questions/20953390/what-is-the-fastest-hash-function-for-pointers I have the following issue on this. Please answer it. How to implement a customized hash specialization for pointer type. I removed your code because it cannot be redefined. I think we need to introduce a new template class which extends std::hash<T> if we want to keep own hash. -- To view, visit http://gerrit.cloudera.org:8080/7414 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I06af30fd15acd43a60e3c30af54056c96520b6e9 Gerrit-PatchSet: 3 Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-Owner: Kim Jin Chul <jinc...@gmail.com> Gerrit-Reviewer: Jim Apple <jbapple-imp...@apache.org> Gerrit-Reviewer: Kim Jin Chul <jinc...@gmail.com> Gerrit-HasComments: Yes