Allocator-aware DynamicMatrix and DynamicVector

Issue #209 wontfix
Mikhail Katliar created an issue

There are cases when it is necessary to allocate memory for elements of a DynamicMatrix or DynamicVector from a specific memory resource. It would be convenient to be able to specify an allocator for Dynamic[Matrix|Vector] in the same way it is done in std::vector<> or std::pmr::vector<>.

Comments (2)

  1. Klaus Iglberger

    Hi Mikhail!

    Thanks for creating this proposal. For the purpose of using a custom memory resource Blaze provides the CustomVector and CustomMatrix class templates. These two allow you to use any kind of memory (static, dynamic, ...) and enable you to specify alignment and padding manually. In contrast to DynamicVector and DynamicMatrix, however, CustomVector and CustomMatrix do not own their memory resource. In issue #134 I have given some advice on how to extend these classes to also perform cleanup. Again, thanks for the proposal,

    Best regards,

    Klaus!

  2. Log in to comment