shred: add sector-phase patterns and Pattern::from_code - #13694
shred: add sector-phase patterns and Pattern::from_code#13694sankalpsthakur wants to merge 2 commits into
Conversation
|
GNU testsuite comparison: |
Merging this PR will degrade performance by 0.38%
Warning Please fix the performance issues or acknowledge them on CodSpeed. Performance Changes
Tip Investigate this regression by commenting Comparing Footnotes
|
|
This is a way too big patch. Please ask your llm to make it shorter |
5380872 to
f662966
Compare
|
Slimmed the patch for review: same fix (Gutmann pass groups + sector-phase patterns + residual-entropy scheduling), but dropped verbose comments/helpers and extra unit tests. Diff is now +258/−222 (was +477/−202). |
|
Removing tests isn't the right approach Splitting it into several PR yes |
f662966 to
7a59857
Compare
|
Agreed - I will split instead of dropping tests. Plan: (1) Pattern model + sector-phase write path, (2) genpattern / pass-group scheduler, (3) residual-entropy --random-source + full distribution regressions. This PR is now (1) only. Stacked PRs next; only the last Fixes #11611. |
|
The diff is still quite large... |
Add Pattern { bytes, flip_sector } and from_code (bit 0x1000).
On write, XOR the first byte of each 512-byte sector with 0x80.
Keep the existing pass schedulers unchanged.
7a59857 to
e0d91cd
Compare
Prep for #11611. Pattern model + sector-phase write only.
Pattern { bytes, flip_sector }andfrom_code(bit 0x1000)Follow-ups: #13699 genpattern, #13700 residual-entropy (Fixes #11611).
Test:
cargo test -p uu_shred --libandcargo test --test tests test_shredAI-assisted; I reviewed the diff.