making it a view would save about half the memory usage and result in 2~7 times faster in reading EGI outputs. The downside, however, is that the new return arrays are now subarrays instead of regular arrays. Is it worth it?
The speedup is not obvious for thousand of cells, e.g., in bulk.2d.vlsv.
In
readvariable
, https://github.com/henry2004y/Vlasiator.jl/blob/e44af63de66306b68cf660d28a6199c5d4a0f736/src/vlsv/vlsvreader.jl#L508making it a view would save about half the memory usage and result in 2~7 times faster in reading EGI outputs. The downside, however, is that the new return arrays are now subarrays instead of regular arrays. Is it worth it?
The speedup is not obvious for thousand of cells, e.g., in
bulk.2d.vlsv
.