OSDN Git Service

02e2ce075579a5dbdefc9c125c2bbd247bd577fb
[android-x86/external-llvm.git] / include / llvm / Support / DJB.h
1 //===-- llvm/Support/DJB.h ---DJB Hash --------------------------*- C++ -*-===//
2 //
3 //                     The LLVM Compiler Infrastructure
4 //
5 // This file is distributed under the University of Illinois Open Source
6 // License. See LICENSE.TXT for details.
7 //
8 //===----------------------------------------------------------------------===//
9 //
10 // This file contains support for the DJ Bernstein hash function.
11 //
12 //===----------------------------------------------------------------------===//
13
14 #ifndef LLVM_SUPPORT_DJB_H
15 #define LLVM_SUPPORT_DJB_H
16
17 #include "llvm/ADT/StringRef.h"
18
19 namespace llvm {
20
21 /// The Bernstein hash function used by the DWARF accelerator tables.
22 uint32_t djbHash(StringRef Buffer, uint32_t H = 5381);
23 } // namespace llvm
24
25 #endif // LLVM_SUPPORT_DJB_H