lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <530B4058.80705@zytor.com>
Date:	Mon, 24 Feb 2014 04:51:36 -0800
From:	"H. Peter Anvin" <hpa@...or.com>
To:	Jan Beulich <JBeulich@...e.com>,
	Daniel Borkmann <dborkman@...hat.com>
CC:	davem@...emloft.net, mingo@...e.hu, tglx@...utronix.de,
	ffusco@...hat.com, tgraf@...hat.com, linux-kernel@...r.kernel.org
Subject: Re: [PATCH 2/3] x86/hash: swap parameters of crc32_u32()

On 02/24/2014 04:41 AM, Jan Beulich wrote:
>>
>> So I'm guessing this hash is deliberately using the CRC32 instruction
>> "backwards", which would actually make sense: an actual CRC is actually
>> a pretty poor hash due to linearity.
>>

OK, it really is even more confusing than that.

It does seem like the crc32 instruction really *is* commutative, which 
isn't something I would personally have expected at all.

Given that fact, I suspect the ordering in the DPDK is actually a bug, 
and that we should correct the ordering (which I would do at the call 
sites because it seems to make the code clearer) because it reduces the 
size of the loop by two instructions.

I guess I should find out how to file a bug report against DPDK too...

	-hpa

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ