Commit 47d5201
Validate runtime split sizes are non-negative
When split sizes come from a runtime tensor input (not an attribute),
they were not validated for non-negative values. Crafted negative
split sizes that sum to the correct total could pass the sum check
and create tensors with negative dimensions. The attribute path
already had this validation.
Added non-negative check in both CPU PrepareForCompute and CUDA
PrepareForComputeLocal.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>1 parent f6b172a commit 47d5201
2 files changed
Lines changed: 6 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
65 | 65 | | |
66 | 66 | | |
67 | 67 | | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
68 | 71 | | |
69 | 72 | | |
70 | 73 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
89 | 89 | | |
90 | 90 | | |
91 | 91 | | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
92 | 95 | | |
93 | 96 | | |
94 | 97 | | |
| |||
0 commit comments