summaryrefslogtreecommitdiff
path: root/src/profiler.c
diff options
context:
space:
mode:
authorPaul Eggert <eggert@cs.ucla.edu>2012-11-08 13:43:34 -0800
committerPaul Eggert <eggert@cs.ucla.edu>2012-11-08 13:43:34 -0800
commit04a2d0d38a2835db6c2e5a74cd7701555a7eb826 (patch)
treeab23bf51e55b69c0173647e33b0769d83a306cf8 /src/profiler.c
parentde5ef41a76f05eb072ef06b053e543ce67fa3241 (diff)
downloademacs-04a2d0d38a2835db6c2e5a74cd7701555a7eb826.tar.gz
Use same hash function for hashfn_profiler as for hash_string etc.
* fns.c (SXHASH_COMBINE): Remove. All uses replaced by sxhash_combine. * lisp.h (sxhash_combine): New inline function, with the contents of the old SXHASH_COMBINE. * profiler.c (hashfn_profiler): Use it, instead of having a special hash function containing a comparison that always yields 1.
Diffstat (limited to 'src/profiler.c')
-rw-r--r--src/profiler.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/profiler.c b/src/profiler.c
index 6f112440902..365d834b9e1 100644
--- a/src/profiler.c
+++ b/src/profiler.c
@@ -558,7 +558,7 @@ hashfn_profiler (struct hash_table_test *ht, Lisp_Object bt)
= (COMPILEDP (f) ? XUINT (AREF (f, COMPILED_BYTECODE))
: (CONSP (f) && CONSP (XCDR (f)) && EQ (Qclosure, XCAR (f)))
? XUINT (XCDR (XCDR (f))) : XUINT (f));
- hash = hash1 + (hash << 1) + (hash == (EMACS_INT) hash);
+ hash = sxhash_combine (hash, hash1);
}
return (hash & INTMASK);
}