Commit e2886cd
committed
fix: resolve UB in batch_invert and logderivative OOB in debug builds
Two bugs causing nightly debug build SIGABRT (exit code 134):
1. batch_invert: reserve() + operator[] is UB — use resize() to properly
allocate elements before indexing.
2. compute_logderivative_inverse: multithreaded path splits work by
circuit_size but inverse_polynomial can be smaller, causing OOB span
access. Clamp range to polynomial's actual data size.1 parent cf1a239 commit e2886cd
File tree
2 files changed
+13
-9
lines changed- barretenberg/cpp/src/barretenberg
- ecc/fields
- honk/proof_system
2 files changed
+13
-9
lines changedLines changed: 2 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
419 | 419 | | |
420 | 420 | | |
421 | 421 | | |
422 | | - | |
423 | | - | |
424 | | - | |
425 | | - | |
| 422 | + | |
| 423 | + | |
426 | 424 | | |
427 | 425 | | |
428 | 426 | | |
| |||
Lines changed: 11 additions & 5 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
59 | 59 | | |
60 | 60 | | |
61 | 61 | | |
62 | | - | |
63 | | - | |
64 | | - | |
65 | | - | |
66 | | - | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
67 | 73 | | |
68 | 74 | | |
69 | 75 | | |
| |||
0 commit comments