Commit f69b057
error instead of widening index types in sparse (#33083)
Followup to https://github.com/JuliaLang/julia/pull/31724/files#r317686891; instead of widening the index type dynamically based upon the index vector length, just throw an error in the case where the index type cannot hold all the indices in a CSC format. This previously was an OOB access (and likely segfault) in 1.2, so throwing an error here is not a breaking change -- and throwing an error restores type stability, addressing the performance regression flagged in #32985.
(cherry picked from commit 9725fb4)1 parent 9f39733 commit f69b057
2 files changed
+7
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
630 | 630 | | |
631 | 631 | | |
632 | 632 | | |
633 | | - | |
634 | | - | |
635 | | - | |
| 633 | + | |
| 634 | + | |
636 | 635 | | |
637 | 636 | | |
638 | 637 | | |
| |||
645 | 644 | | |
646 | 645 | | |
647 | 646 | | |
648 | | - | |
| 647 | + | |
649 | 648 | | |
650 | 649 | | |
651 | 650 | | |
652 | 651 | | |
653 | 652 | | |
654 | | - | |
| 653 | + | |
655 | 654 | | |
656 | 655 | | |
657 | 656 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2662 | 2662 | | |
2663 | 2663 | | |
2664 | 2664 | | |
2665 | | - | |
| 2665 | + | |
2666 | 2666 | | |
2667 | | - | |
| 2667 | + | |
2668 | 2668 | | |
2669 | 2669 | | |
2670 | 2670 | | |
2671 | 2671 | | |
2672 | | - | |
| 2672 | + | |
2673 | 2673 | | |
2674 | 2674 | | |
2675 | 2675 | | |
| |||
0 commit comments