aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2012-03-09 02:49:38 +0000
committerChandler Carruth <chandlerc@gmail.com>2012-03-09 02:49:38 +0000
commit1bb80affe85d3497457645dd20957136f708468a (patch)
tree0b790bab28ec64f5a388bad1644bcb5a52f0bd19
parent783b7198b76ea32f6afbf933dbdf43f6f9f95744 (diff)
downloadllvm-1bb80affe85d3497457645dd20957136f708468a.zip
llvm-1bb80affe85d3497457645dd20957136f708468a.tar.gz
llvm-1bb80affe85d3497457645dd20957136f708468a.tar.bz2
Fix a silly restriction on the fast-path for hash_combine_range. This
caused several clients to select the slow variation. =[ This is extra annoying because we don't have any realistic way of testing this -- by design, these two functions *must* compute the same value. Found while inspecting the output of some benchmarks I'm working on. llvm-svn: 152369
-rw-r--r--llvm/include/llvm/ADT/Hashing.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/include/llvm/ADT/Hashing.h b/llvm/include/llvm/ADT/Hashing.h
index b2bd72e..81a5117 100644
--- a/llvm/include/llvm/ADT/Hashing.h
+++ b/llvm/include/llvm/ADT/Hashing.h
@@ -457,7 +457,7 @@ hash_code hash_combine_range_impl(InputIteratorT first, InputIteratorT last) {
/// and directly reads from the underlying memory.
template <typename ValueT>
typename enable_if<is_hashable_data<ValueT>, hash_code>::type
-hash_combine_range_impl(const ValueT *first, const ValueT *last) {
+hash_combine_range_impl(ValueT *first, ValueT *last) {
const size_t seed = get_execution_seed();
const char *s_begin = reinterpret_cast<const char *>(first);
const char *s_end = reinterpret_cast<const char *>(last);