simplehash.h 678 B

1234567891011121314151617181920212223242526
  1. /*
  2. * Copyright (c) 2023, smartmx <smartmx@qq.com>
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. *
  6. * Change Logs:
  7. * Date Author Notes
  8. * 2023-03-03 smartmx the first version
  9. *
  10. */
  11. #ifndef _SIMPLEHASH_H_
  12. #define _SIMPLEHASH_H_
  13. #include "stdio.h"
  14. #include "stdint.h"
  15. /* The seed value, you can change as you want. */
  16. #define SIMPLEHASH_SEED_VALUE 0x30393235
  17. extern uint32_t simplehash_caculate32(const void *hash_key, uint32_t len);
  18. extern uint32_t simplehash_upper_caculate32(const void *hash_key, uint32_t len);
  19. extern uint8_t simplehash_lower_char_upper_memcmp(const void *src1, const void *src2, uint32_t len);
  20. #endif /* _SIMPLEHASH_H_ */