proxsuite 0.6.7
The Advanced Proximal Optimization Toolbox
Loading...
Searching...
No Matches
ldlt.hpp
Go to the documentation of this file.
1
2//
3// Copyright (c) 2022 INRIA
4//
5#ifndef PROXSUITE_LINALG_DENSE_LDLT_LDLT_HPP
6#define PROXSUITE_LINALG_DENSE_LDLT_LDLT_HPP
7
13
14namespace proxsuite {
15namespace linalg {
16namespace dense {
17namespace _detail {
19{
20 friend auto operator==(SimdAlignedSystemAlloc /*unused*/,
21 SimdAlignedSystemAlloc /*unused*/) noexcept -> bool
22 {
23 return true;
24 }
25};
26} // namespace _detail
27} // namespace dense
28} // namespace linalg
29} // namespace proxsuite
30
31template<>
34{
35#ifdef PROXSUITE_VECTORIZE
36 static constexpr usize min_align = alignof(std::max_align_t) >
39 : alignof(std::max_align_t);
40#else
41 static constexpr usize min_align = 0;
42#endif
43
46
47 VEG_INLINE static auto adjusted_layout(Layout l) noexcept -> Layout
48 {
49 if (l.align < min_align) {
50 l.align = min_align;
51 }
52 return l;
53 }
54
55 VEG_INLINE static void dealloc(RefMut /*alloc*/, void* ptr, Layout l) noexcept
56 {
58 mut(SystemAlloc{}), ptr, adjusted_layout(l));
59 }
60
61 VEG_NODISCARD VEG_INLINE static auto alloc(RefMut /*alloc*/,
62 Layout l) noexcept
64 {
65 return Alloc<SystemAlloc>::alloc(mut(SystemAlloc{}), adjusted_layout(l));
66 }
67
68 VEG_NODISCARD VEG_INLINE static auto grow(RefMut /*alloc*/,
69 void* ptr,
70 Layout l,
72 RelocFn reloc) noexcept
74 {
76 mut(SystemAlloc{}), ptr, adjusted_layout(l), new_size, reloc);
77 }
78 VEG_NODISCARD VEG_INLINE static auto shrink(RefMut /*alloc*/,
79 void* ptr,
80 Layout l,
82 RelocFn reloc) noexcept
84 {
86 mut(SystemAlloc{}), ptr, adjusted_layout(l), new_size, reloc);
87 }
88};
89
90namespace proxsuite {
91namespace linalg {
92namespace dense {
164template<typename T>
165struct Ldlt
166{
167private:
168 static constexpr auto DYN = Eigen::Dynamic;
169 using ColMat = Eigen::Matrix<T, DYN, DYN, Eigen::ColMajor>;
170 using RowMat = Eigen::Matrix<T, DYN, DYN, Eigen::RowMajor>;
171 using Vec = Eigen::Matrix<T, DYN, 1>;
172
173 using LView = Eigen::TriangularView<Eigen::Map< //
174 ColMat const,
175 Eigen::Unaligned,
176 Eigen::OuterStride<DYN>>,
177 Eigen::UnitLower>;
178 using LViewMut = Eigen::TriangularView<Eigen::Map< //
179 ColMat,
180 Eigen::Unaligned,
181 Eigen::OuterStride<DYN>>,
182 Eigen::UnitLower>;
183
184 using LTView = Eigen::TriangularView<Eigen::Map< //
185 RowMat const,
186 Eigen::Unaligned,
187 Eigen::OuterStride<DYN>>,
188 Eigen::UnitUpper>;
189 using LTViewMut = Eigen::TriangularView<Eigen::Map< //
190 RowMat,
191 Eigen::Unaligned,
192 Eigen::OuterStride<DYN>>,
193 Eigen::UnitUpper>;
194
195 using DView =
196 Eigen::Map<Vec const, Eigen::Unaligned, Eigen::InnerStride<DYN>>;
197 using DViewMut = Eigen::Map<Vec, Eigen::Unaligned, Eigen::InnerStride<DYN>>;
198
199 using VecMapISize = Eigen::Map<Eigen::Matrix<isize, DYN, 1> const>;
200 using Perm = Eigen::PermutationWrapper<VecMapISize>;
201
202 using StorageSimdVec =
208
209 StorageSimdVec ld_storage;
210 isize stride{};
213
214 // sorted on a best effort basis
215 proxsuite::linalg::veg::Vec<T> maybe_sorted_diag;
216
217 VEG_REFLECT(Ldlt, ld_storage, stride, perm, perm_inv, maybe_sorted_diag);
218
219 static auto adjusted_stride(isize n) noexcept -> isize
220 {
221 return _detail::adjusted_stride<T>(n);
222 }
223
224 // soft invariants:
225 // - perm.len() == perm_inv.len() == dim
226 // - dim < stride
227 // - ld_storage.len() >= dim * stride
228public:
232 Ldlt() = default;
233
241 void reserve_uninit(isize cap) noexcept
242 {
243 static_assert(VEG_CONCEPT(nothrow_constructible<T>), ".");
244
245 auto new_stride = adjusted_stride(cap);
246 if (cap <= stride && cap * new_stride <= ld_storage.len()) {
247 return;
248 }
249
250 ld_storage.reserve_exact(cap * new_stride);
251 perm.reserve_exact(cap);
252 perm_inv.reserve_exact(cap);
253 maybe_sorted_diag.reserve_exact(cap);
254
255 ld_storage.resize_for_overwrite(cap * new_stride);
256 stride = new_stride;
257 }
258
266 void reserve(isize cap) noexcept
267 {
268 auto new_stride = adjusted_stride(cap);
269 if (cap <= stride && cap * new_stride <= ld_storage.len()) {
270 return;
271 }
272 auto n = dim();
273
274 ld_storage.reserve_exact(cap * new_stride);
275 perm.reserve_exact(cap);
276 perm_inv.reserve_exact(cap);
277 maybe_sorted_diag.reserve_exact(cap);
278
279 ld_storage.resize_for_overwrite(cap * new_stride);
280
281 for (isize i = 0; i < n; ++i) {
282 auto col = n - i - 1;
283 T* ptr = ld_col_mut().data();
284 std::move_backward( //
285 ptr + col * stride,
286 ptr + col * stride + n,
287 ptr + col * new_stride + n);
288 }
289 stride = new_stride;
290 }
291
299 static auto rank_r_update_req(isize n, isize r) noexcept
301 {
303 _detail::adjusted_stride<T>(n) * r * isize{ sizeof(T) },
304 _detail::align<T>(),
305 };
307 r * isize{ sizeof(T) },
308 alignof(T),
309 };
310 return w_req & alpha_req;
311 }
312
320 static auto delete_at_req(isize n, isize r) noexcept
322 {
324 r * isize{ sizeof(isize) },
325 alignof(isize),
326 } &
329 }
330
340 void delete_at(isize const* indices,
341 isize r,
343 {
344 if (r == 0) {
345 return;
346 }
347
348 VEG_ASSERT(std::is_sorted(indices, indices + r));
349
350 isize n = dim();
351
352 auto _indices_actual =
353 stack.make_new_for_overwrite(proxsuite::linalg::veg::Tag<isize>{}, r);
354 auto* indices_actual = _indices_actual.ptr_mut();
355
356 for (isize k = 0; k < r; ++k) {
357 indices_actual[k] = perm_inv[indices[k]];
358 }
359
361 ld_col_mut(),
362 indices_actual,
363 r,
364 stack);
365
366 // PERF: do this in one pass
367 for (isize k = 0; k < r; ++k) {
368 auto i_actual = indices_actual[r - 1 - k];
369 auto i = indices[r - 1 - k];
370
371 perm.pop_mid(i_actual);
372 perm_inv.pop_mid(i);
373 maybe_sorted_diag.pop_mid(i_actual);
374
375 for (isize j = 0; j < n - 1 - k; ++j) {
376 auto& p_j = perm[j];
377 auto& pinv_j = perm_inv[j];
378
379 if (p_j > i) {
380 --p_j;
381 }
382 if (pinv_j > i_actual) {
383 --pinv_j;
384 }
385 }
386 }
387 }
388
389 auto choose_insertion_position(isize i, Eigen::Ref<Vec const> a) -> isize
390 {
391 isize n = dim();
392 auto diag_elem = a[i];
393
394 isize pos = 0;
395 for (; pos < n; ++pos) {
396 if (diag_elem >= maybe_sorted_diag[pos]) {
397 break;
398 }
399 }
400 return pos;
401 }
402
410 static auto insert_block_at_req(isize n, isize r) noexcept
412 {
414 return StackReq{
415 isize{ sizeof(T) } * (adjusted_stride(n + r) * r),
416 _detail::align<T>(),
417 } &
420 }
421
431 void insert_block_at(isize i,
432 Eigen::Ref<ColMat const> a,
434 {
435
436 isize n = dim();
437 isize r = a.cols();
438
439 if (r == 0) {
440 return;
441 }
442
443 reserve(n + r);
444
445 isize i_actual = choose_insertion_position(i, a.col(0));
446
447 for (isize j = 0; j < n; ++j) {
448 auto& p_j = perm[j];
449 auto& pinv_j = perm_inv[j];
450
451 if (p_j >= i) {
452 p_j += r;
453 }
454 if (pinv_j >= i_actual) {
455 pinv_j += r;
456 }
457 }
458
459 for (isize k = 0; k < r; ++k) {
460 perm.push_mid(i + k, i_actual + k);
461 perm_inv.push_mid(i_actual + k, i + k);
462 maybe_sorted_diag.push_mid(a(i + k, k), i_actual + k);
463 }
464
465 LDLT_TEMP_MAT_UNINIT(T, permuted_a, n + r, r, stack);
466
467 for (isize k = 0; k < r; ++k) {
468 for (isize j = 0; j < n + r; ++j) {
469 permuted_a(j, k) = a(perm[j], k);
470 }
471 }
472
474 ld_col_mut(), i_actual, permuted_a, stack);
475 }
476
484 static auto diagonal_update_req(isize n, isize r) noexcept
486 {
488 auto algo_req = StackReq{
489 2 * r * isize{ sizeof(isize) },
490 alignof(isize),
491 };
492 auto w_req = StackReq{
493 _detail::adjusted_stride<T>(n) * r * isize{ sizeof(T) },
494 _detail::align<T>(),
495 };
496 auto alpha_req = StackReq{
497 r * isize{ sizeof(T) },
498 alignof(T),
499 };
500 return algo_req & w_req & alpha_req;
501 }
502
517 isize* indices,
518 isize r,
519 Eigen::Ref<Vec const> alpha,
521 {
522
523 if (r == 0) {
524 return;
525 }
526
527 auto _positions =
528 stack.make_new_for_overwrite(proxsuite::linalg::veg::Tag<isize>{}, r);
529 auto _sorted_indices =
530 stack.make_new_for_overwrite(proxsuite::linalg::veg::Tag<isize>{}, r);
531 auto* positions = _positions.ptr_mut();
532 auto* sorted_indices = _sorted_indices.ptr_mut();
533
534 for (isize k = 0; k < r; ++k) {
535 indices[k] = perm_inv[indices[k]];
536 positions[k] = k;
537 }
538
539 std::sort(
540 positions, positions + r, [indices](isize i, isize j) noexcept -> bool {
541 return indices[i] < indices[j];
542 });
543
544 for (isize k = 0; k < r; ++k) {
545 sorted_indices[k] = indices[positions[k]];
546 }
547
548 auto first = sorted_indices[0];
549 auto n = dim() - first;
550
551 LDLT_TEMP_MAT(T, _w, n, r, stack);
552 LDLT_TEMP_VEC_UNINIT(T, _alpha, r, stack);
553
554 for (isize k = 0; k < r; ++k) {
555 _alpha(k) = alpha(positions[k]);
556 _w(sorted_indices[k] - first, k) = 1;
557 }
558
560 util::submatrix(ld_col_mut(), first, first, n, n),
561 _w.data(),
562 _w.outerStride(),
563 _alpha.data(),
565 first,
566 0,
567 r,
568 sorted_indices,
569 });
570 }
571
581 Eigen::Ref<ColMat const> w,
582 Eigen::Ref<Vec const> alpha,
584 {
585
586 auto n = dim();
587 auto r = w.cols();
588 if (r == 0) {
589 return;
590 }
591
592 VEG_ASSERT(w.rows() == n);
593
594 LDLT_TEMP_MAT_UNINIT(T, _w, n, r, stack);
595 LDLT_TEMP_VEC_UNINIT(T, _alpha, r, stack);
596
597 for (isize k = 0; k < r; ++k) {
598 auto alpha_tmp = alpha(k);
599 _alpha(k) = alpha_tmp;
600 for (isize i = 0; i < n; ++i) {
601 auto w_tmp = w(perm[i], k);
602 _w(i, k) = w_tmp;
603 maybe_sorted_diag[i] += alpha_tmp * (w_tmp * w_tmp);
604 }
605 }
606
608 ld_col_mut(), _w, _alpha);
609 }
610
614 auto dim() const noexcept -> isize { return perm.len(); }
615
616 auto ld_col() const noexcept -> Eigen::Map< //
617 ColMat const,
618 Eigen::Unaligned,
619 Eigen::OuterStride<DYN>>
620 {
621 return { ld_storage.ptr(), dim(), dim(), stride };
622 }
623 auto ld_col_mut() noexcept -> Eigen::Map< //
624 ColMat,
625 Eigen::Unaligned,
626 Eigen::OuterStride<DYN>>
627 {
628 return { ld_storage.ptr_mut(), dim(), dim(), stride };
629 }
630 auto ld_row() const noexcept -> Eigen::Map< //
631 RowMat const,
632 Eigen::Unaligned,
633 Eigen::OuterStride<DYN>>
634 {
635 return {
636 ld_storage.ptr(),
637 dim(),
638 dim(),
639 Eigen::OuterStride<DYN>{ stride },
640 };
641 }
642 auto ld_row_mut() noexcept -> Eigen::Map< //
643 RowMat,
644 Eigen::Unaligned,
645 Eigen::OuterStride<DYN>>
646 {
647 return {
648 ld_storage.ptr_mut(),
649 dim(),
650 dim(),
651 Eigen::OuterStride<DYN>{ stride },
652 };
653 }
654
655 auto l() const noexcept -> LView
656 {
657 return ld_col().template triangularView<Eigen::UnitLower>();
658 }
659 auto l_mut() noexcept -> LViewMut
660 {
661 return ld_col_mut().template triangularView<Eigen::UnitLower>();
662 }
663 auto lt() const noexcept -> LTView
664 {
665 return ld_row().template triangularView<Eigen::UnitUpper>();
666 }
667 auto lt_mut() noexcept -> LTViewMut
668 {
669 return ld_row_mut().template triangularView<Eigen::UnitUpper>();
670 }
671
672 auto d() const noexcept -> DView
673 {
674 return {
675 ld_storage.ptr(),
676 dim(),
677 1,
678 Eigen::InnerStride<DYN>{ stride + 1 },
679 };
680 }
681 auto d_mut() noexcept -> DViewMut
682 {
683 return {
684 ld_storage.ptr_mut(),
685 dim(),
686 1,
687 Eigen::InnerStride<DYN>{ stride + 1 },
688 };
689 }
690 auto p() const -> Perm { return { VecMapISize(perm.ptr(), dim()) }; }
691 auto pt() const -> Perm { return { VecMapISize(perm_inv.ptr(), dim()) }; }
692
699 static auto factorize_req(isize n)
701 {
703 n * adjusted_stride(n) * isize{ sizeof(T) },
704 _detail::align<T>(),
705 } |
708 }
709
718 void factorize(Eigen::Ref<ColMat const> mat /* NOLINT */,
720 {
721 VEG_ASSERT(mat.rows() == mat.cols());
722 isize n = mat.rows();
724
725 perm.resize_for_overwrite(n);
726 perm_inv.resize_for_overwrite(n);
727 maybe_sorted_diag.resize_for_overwrite(n);
728
730 perm.ptr_mut(),
731 perm_inv.ptr_mut(),
732 util::diagonal(mat));
733
734 {
735 LDLT_TEMP_MAT_UNINIT(T, work, n, n, stack);
736 ld_col_mut() = mat;
738 ld_col_mut(), work, perm.ptr());
739 }
740 for (isize i = 0; i < n; ++i) {
741 maybe_sorted_diag[i] = ld_col()(i, i);
742 }
744 }
745
752 static auto solve_in_place_req(isize n)
754 {
755 return {
756 n * isize{ sizeof(T) },
757 _detail::align<T>(),
758 };
759 }
760
767 void solve_in_place(Eigen::Ref<Vec> rhs,
769 {
770 isize n = rhs.rows();
771 LDLT_TEMP_VEC_UNINIT(T, work, n, stack);
772
773 for (isize i = 0; i < n; ++i) {
774 work[i] = rhs[perm[i]];
775 }
776
778
779 for (isize i = 0; i < n; ++i) {
780 rhs[i] = work[perm_inv[i]];
781 }
782 }
783
785 Eigen::Ref<Vec> rhs,
786 isize n,
788 {
789 isize m = rhs.rows();
790 LDLT_TEMP_VEC_UNINIT(T, work, m, stack);
791
792 for (isize i = 0; i < m; ++i) {
793 work[i] = rhs[perm[n + i] -
794 n]; // n are the first n entries that are not considered
795 }
796 proxsuite::linalg::dense::solve(ld_col().bottomRightCorner(m, m), work);
797 for (isize i = 0; i < m; ++i) {
798 rhs[i] = work[perm_inv[n + i] - n];
799 }
800 }
801
803 {
804 isize n = dim();
805 auto tmp = ColMat(n, n);
806 tmp = l();
807 tmp = tmp * d().asDiagonal();
808 auto A = ColMat(tmp * lt());
809 return A;
810 }
811
812 auto dbg_reconstructed_matrix() const -> ColMat
813 {
814 isize n = dim();
815 auto tmp = ColMat(n, n);
816 tmp = l();
817 tmp = tmp * d().asDiagonal();
818 auto A = ColMat(tmp * lt());
819
820 for (isize i = 0; i < n; i++) {
821 tmp.row(i) = A.row(perm_inv[i]);
822 }
823 for (isize i = 0; i < n; i++) {
824 A.col(i) = tmp.col(perm_inv[i]);
825 }
826 return A;
827 }
828};
829} // namespace dense
830} // namespace linalg
831} // namespace proxsuite
832
833#endif /* end of include guard PROXSUITE_LINALG_DENSE_LDLT_LDLT_HPP */
#define VEG_ASSERT(...)
#define LDLT_TEMP_MAT_UNINIT(Type, Name, Rows, Cols, Stack)
Definition core.hpp:81
#define LDLT_TEMP_VEC_UNINIT(Type, Name, Rows, Stack)
Definition core.hpp:76
#define LDLT_TEMP_MAT(Type, Name, Rows, Cols, Stack)
Definition core.hpp:79
#define VEG_CONCEPT(...)
Definition macros.hpp:1243
#define VEG_INLINE
Definition macros.hpp:118
#define VEG_REFLECT(PClass,...)
Definition macros.hpp:1309
void apply_permutation_tri_lower(Mat &&mat, Work &&work, isize const *perm_indices)
Definition factorize.hpp:64
VEG_NO_INLINE void compute_permutation(isize *perm_indices, isize *perm_inv_indices, Diag const &diagonal)
Definition factorize.hpp:50
void rank_r_update_clobber_w_impl(LD ld, T *pw, isize w_stride, T *palpha, Fn r_fn)
Definition update.hpp:221
auto diagonal(Mat &&mat) noexcept -> Eigen::Map< _detail::const_if< _detail::ptr_is_const< decltype(mat.data())>::value, Eigen::Matrix< typename proxsuite::linalg::veg::uncvref_t< Mat >::Scalar, Eigen::Dynamic, 1, Eigen::ColMajor > >, Eigen::Unaligned, Eigen::InnerStride< Eigen::Dynamic > >
Definition core.hpp:624
auto submatrix(Mat &&mat, isize row_start, isize col_start, isize nrows, isize ncols) noexcept -> Eigen::Map< _detail::const_if< _detail::ptr_is_const< decltype(mat.data())>::value, _detail::OwnedMatrix< proxsuite::linalg::veg::uncvref_t< Mat > > >, Eigen::Unaligned, _detail::StrideOf< proxsuite::linalg::veg::uncvref_t< Mat > > >
Definition core.hpp:645
auto ldlt_insert_rows_and_cols_req(proxsuite::linalg::veg::Tag< T > tag, isize n, isize r) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
Definition modify.hpp:300
void ldlt_delete_rows_and_cols_sort_indices(Mat &&ld, isize *indices, isize r, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition modify.hpp:288
void ldlt_insert_rows_and_cols(Mat &&ld, isize pos, A_1 const &a_1, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition modify.hpp:321
void solve(Mat const &mat, Rhs &&rhs)
Definition solve.hpp:30
void rank_r_update_clobber_inputs(LD &&ld, W &&w, A &&alpha)
Definition update.hpp:316
void factorize(Mat &&mat, proxsuite::linalg::veg::dynstack::DynStackMut stack)
auto ldlt_delete_rows_and_cols_req(proxsuite::linalg::veg::Tag< T >, isize n, isize r) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
Definition modify.hpp:269
auto factorize_req(proxsuite::linalg::veg::Tag< T > tag, isize n) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
typename _detail::_meta::conditional_< B >::template type< T, F > if_t
Definition core.hpp:83
decltype(sizeof(0)) usize
Definition macros.hpp:702
#define VEG_NODISCARD
Definition prologue.hpp:97
static auto insert_block_at_req(isize n, isize r) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
Definition ldlt.hpp:410
static auto delete_at_req(isize n, isize r) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
Definition ldlt.hpp:320
auto ld_col() const noexcept -> Eigen::Map< ColMat const, Eigen::Unaligned, Eigen::OuterStride< DYN > >
Definition ldlt.hpp:616
auto pt() const -> Perm
Definition ldlt.hpp:691
void reserve(isize cap) noexcept
Definition ldlt.hpp:266
auto dim() const noexcept -> isize
Definition ldlt.hpp:614
void dual_solve_in_place(Eigen::Ref< Vec > rhs, isize n, proxsuite::linalg::veg::dynstack::DynStackMut stack) const
Definition ldlt.hpp:784
auto l() const noexcept -> LView
Definition ldlt.hpp:655
auto dbg_reconstructed_matrix_internal() const -> ColMat
Definition ldlt.hpp:802
auto lt() const noexcept -> LTView
Definition ldlt.hpp:663
static auto factorize_req(isize n) -> proxsuite::linalg::veg::dynstack::StackReq
Definition ldlt.hpp:699
auto dbg_reconstructed_matrix() const -> ColMat
Definition ldlt.hpp:812
static auto solve_in_place_req(isize n) -> proxsuite::linalg::veg::dynstack::StackReq
Definition ldlt.hpp:752
auto choose_insertion_position(isize i, Eigen::Ref< Vec const > a) -> isize
Definition ldlt.hpp:389
void diagonal_update_clobber_indices(isize *indices, isize r, Eigen::Ref< Vec const > alpha, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition ldlt.hpp:516
static auto rank_r_update_req(isize n, isize r) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
Definition ldlt.hpp:299
auto d_mut() noexcept -> DViewMut
Definition ldlt.hpp:681
auto ld_row() const noexcept -> Eigen::Map< RowMat const, Eigen::Unaligned, Eigen::OuterStride< DYN > >
Definition ldlt.hpp:630
void delete_at(isize const *indices, isize r, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition ldlt.hpp:340
void rank_r_update(Eigen::Ref< ColMat const > w, Eigen::Ref< Vec const > alpha, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition ldlt.hpp:580
void solve_in_place(Eigen::Ref< Vec > rhs, proxsuite::linalg::veg::dynstack::DynStackMut stack) const
Definition ldlt.hpp:767
void insert_block_at(isize i, Eigen::Ref< ColMat const > a, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition ldlt.hpp:431
auto ld_row_mut() noexcept -> Eigen::Map< RowMat, Eigen::Unaligned, Eigen::OuterStride< DYN > >
Definition ldlt.hpp:642
void factorize(Eigen::Ref< ColMat const > mat, proxsuite::linalg::veg::dynstack::DynStackMut stack)
Definition ldlt.hpp:718
auto d() const noexcept -> DView
Definition ldlt.hpp:672
auto l_mut() noexcept -> LViewMut
Definition ldlt.hpp:659
void reserve_uninit(isize cap) noexcept
Definition ldlt.hpp:241
auto ld_col_mut() noexcept -> Eigen::Map< ColMat, Eigen::Unaligned, Eigen::OuterStride< DYN > >
Definition ldlt.hpp:623
static auto diagonal_update_req(isize n, isize r) noexcept -> proxsuite::linalg::veg::dynstack::StackReq
Definition ldlt.hpp:484
auto lt_mut() noexcept -> LTViewMut
Definition ldlt.hpp:667
auto p() const -> Perm
Definition ldlt.hpp:690
friend auto operator==(SimdAlignedSystemAlloc, SimdAlignedSystemAlloc) noexcept -> bool
Definition ldlt.hpp:20
VEG_NODISCARD VEG_INLINE auto ptr_mut() VEG_NOEXCEPT -> T *
Definition vec.hpp:966
VEG_NODISCARD VEG_INLINE auto ptr() const VEG_NOEXCEPT -> T const *
Definition vec.hpp:962
VEG_NODISCARD VEG_INLINE auto len() const VEG_NOEXCEPT -> isize
Definition vec.hpp:970
VEG_INLINE void reserve_exact(isize new_cap)
Definition vec.hpp:750
VEG_NODISCARD auto ptr_mut() const VEG_NOEXCEPT -> void *
static VEG_INLINE void dealloc(RefMut, void *ptr, Layout l) noexcept
Definition ldlt.hpp:55
VEG_NODISCARD static VEG_INLINE auto alloc(RefMut, Layout l) noexcept -> mem::AllocBlock
Definition ldlt.hpp:61
VEG_NODISCARD static VEG_INLINE auto grow(RefMut, void *ptr, Layout l, usize new_size, RelocFn reloc) noexcept -> mem::AllocBlock
Definition ldlt.hpp:68
VEG_NODISCARD static VEG_INLINE auto shrink(RefMut, void *ptr, Layout l, usize new_size, RelocFn reloc) noexcept -> mem::AllocBlock
Definition ldlt.hpp:78