Improve the OOP ABI
Bruce Carneal
bcarneal at gmail.com
Tue Jan 23 04:22:52 UTC 2024
On Tuesday, 23 January 2024 at 03:34:23 UTC, Jonathan M Davis
wrote:
> On Monday, January 22, 2024 7:33:33 PM MST Siarhei Siamashka
> via Digitalmars-d wrote:
>> On Monday, 22 January 2024 at 23:31:16 UTC, deadalnix wrote:
>> > On Monday, 22 January 2024 at 22:44:20 UTC, Walter Bright
>> > wrote:
>> >> On 1/22/2024 1:11 PM, Bruce Carneal wrote:
>> >>> Blake3 might be worth a look. It's reportedly faster and
>> >>> stronger than md5.
>>
>>
>> It's probably possible to take just the first (or last) 128
>> bits
>> of BLAKE3 and the result might have better properties than MD5
>> (considering that MD5 is broken). There are some answers
>> related
>> to "truncated hash" on the Internet about SHA-256, but any
>> cryptographically secure hash is likely to be similar in this
>> aspect:
>> https://crypto.stackexchange.com/questions/161/should-i-use-the-first-or-las
>> t-bits-from-a-sha-256-hash/163#163
>
> Why on earth would we care if the hash is secure in this
> context? We obviously care about the likelihood of collisions,
> and if that's high enough (which does not seem to be the case
> for md5), then the hash is unsuitable for comparing class
> names, but why would crytographic security matter when
> comparing class names in the compiler?
>
> - Jonathan M Davis
I don't think it matters at all except for what it implies about
collisions. And, again, I don't think any modern hash is bad wrt
collisions but I'm not a hash researcher.
If it is true that any modern hash is in the "more likely to be
smacked by a meteor than experience a collision" category *and*
the current (md5) time burn is more than a blip then it's
probably worth taking a look at the alternatives.
OTOH, it's not like there is a shortage of things to work on...
:-)
More information about the Digitalmars-d
mailing list