[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-22 Thread Fangrui Song via llvm-branch-commits
https://github.com/MaskRay edited https://github.com/llvm/llvm-project/pull/96282 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-22 Thread Fangrui Song via llvm-branch-commits
https://github.com/MaskRay updated https://github.com/llvm/llvm-project/pull/96282 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-22 Thread Fangrui Song via llvm-branch-commits
https://github.com/MaskRay updated https://github.com/llvm/llvm-project/pull/96282 ___ llvm-branch-commits mailing list llvm-branch-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-branch-commits

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-21 Thread Fangrui Song via llvm-branch-commits
MaskRay wrote: Due to ASLR and malloc non-determinism, `DenseMap` already introduces a lot of non-determinism to release builds. `DenseMap` issues are less pronounced compared with `DenseMap`. > I'm a little concerned that doing this in release builds is going to lead to > weird bug reports I

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-21 Thread Eli Friedman via llvm-branch-commits
efriedma-quic wrote: We restricted reverse-iteration when we added it just to save time when we were enabling it: we wanted to prioritize issues that were actually likely to cause non-determinism (as opposed to relying on the hash algorithm, which is annoying but not actually non-deterministic

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-21 Thread Fangrui Song via llvm-branch-commits
MaskRay wrote: > I like the idea, but I'm not sure this should be always enabled. This sounds > like a lot of debugging fun when a seed-dependent case is not caught in > testing. > > Can we have this part of LLVM_REVERSE_ITERATION instead, which is used to > detect similar hash iteration stab

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-21 Thread Nikita Popov via llvm-branch-commits
https://github.com/nikic commented: I like the idea, but I'm not sure this should be always enabled. This sounds like a lot of debugging fun when a seed-dependent case is not caught in testing. Can we have this part of LLVM_REVERSE_ITERATION instead, which is used to detect similar hash iterat

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-20 Thread via llvm-branch-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-support Author: Fangrui Song (MaskRay) Changes Hashing.h provides hash_value/hash_combine/hash_combine_range, which are primarily used by * `DenseMap` * `FoldingSetNodeIDRef::ComputeHash` (will be fixed by #96136) Users shouldn't rel

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-20 Thread via llvm-branch-commits
llvmbot wrote: @llvm/pr-subscribers-llvm-adt Author: Fangrui Song (MaskRay) Changes Hashing.h provides hash_value/hash_combine/hash_combine_range, which are primarily used by * `DenseMap` * `FoldingSetNodeIDRef::ComputeHash` (will be fixed by #96136) Users shouldn't rely on

[llvm-branch-commits] [Hashing] Use a non-deterministic seed (PR #96282)

2024-06-20 Thread Fangrui Song via llvm-branch-commits
https://github.com/MaskRay created https://github.com/llvm/llvm-project/pull/96282 Hashing.h provides hash_value/hash_combine/hash_combine_range, which are primarily used by * `DenseMap` * `FoldingSetNodeIDRef::ComputeHash` (will be fixed by #96136) Users shouldn't rely on specific hash values