I am looking for a library routine callable from C++ to do an inplace matrix transpose. And I would like it done fast. Arbitrary size 2d dense matrices need to be supported.
By in-place, I mean not much extra storage should be allocated. Using a full size temporary does not count.
Eigen's has an transposeInPlace only has the effect of an in-place transpose. It still uses a full copy's worth of memory (when not square).
imatcopy does work inplace but it does so very slowly. On about 1GB input:
I've seen a few academic papers but I've not found usable code.
A permissive licences is preferred, but not required.