This bugzilla service is closed. All entries have been migrated to https://gitlab.com/libeigen/eigen
Bug 1364 - GEMM: Allocate memory for blocks only once
Summary: GEMM: Allocate memory for blocks only once
Status: NEW
Alias: None
Product: Eigen
Classification: Unclassified
Component: Core - matrix products (show other bugs)
Version: unspecified
Hardware: All All
: Normal Optimization
Assignee: Nobody
URL:
Whiteboard:
Keywords:
Depends on: 1568
Blocks:
  Show dependency treegraph
 
Reported: 2016-12-19 04:20 UTC by Gael Guennebaud
Modified: 2019-12-04 16:36 UTC (History)
3 users (show)



Attachments

Description Gael Guennebaud 2016-12-19 04:20:05 UTC
Currently, for large enough matrices we dynamically allocate memory for the blocks for each call. With C++11 it should be possible to allocate only once at the first call in a thread safe manner. Of course, we would keep the current strategy as fallback for non C++11 builds.

Some questions through:

- shall we allocate for the maximal block size? This would be a waste of memory if the user only deal with, say, 50x50 matrices (blocks are much larger!)

- how to properly release the memory?
Comment 1 Christoph Hertzberg 2016-12-19 10:58:36 UTC
As mentioned on the mailing list, we also don't always use stack allocation for parallelized GEMM. Not sure how easy it is to integrate this (we could certainly not encapsulate the allocation as it is now).
Comment 2 Ilja Honkonen 2016-12-19 18:58:27 UTC
I think Whaley is working on threaded version of http://math-atlas.sourceforge.net/ , or upgrading the threading for latest hardware, so that mailing list might be a good place to ask or search for ideas.
Comment 3 Gael Guennebaud 2018-07-09 14:37:55 UTC
This is related to bug 1568.
Comment 4 Nobody 2019-12-04 16:36:57 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/1364.

Note You need to log in before you can comment on or make changes to this bug.