Re: [PATCH v2 1/6] pack-objects: add --full-name-hash option

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Derrick Stolee via GitGitGadget" <gitgitgadget@xxxxxxxxx> writes:

> +static inline uint32_t pack_full_name_hash(const char *name)
> +{
> +	const uint32_t bigp = 1234572167U;
> +	uint32_t c, hash = bigp;
> +
> +	if (!name)
> +		return 0;
> +
> +	/*
> +	 * Do the simplest thing that will resemble pseduo-randomness: add

"pseduo" -> "pseudo"

> +	 * random multiples of a large prime number with a binary shift.
> +	 * The goal is not to be cryptographic, but to be generally
> +	 * uniformly distributed.
> +	 */

Other than that, there is no substantial difference since the
previous iteration; this step looks good.

Thanks.




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux