| 5ff7be28 | 12-Dec-2020 |
Barry Smith <bsmith@mcs.anl.gov> |
Fix memory leaks in TSTrajectoryCreate_Memory() and possibly bugs
1) The binary open did not switch to native vector loads hence each load for vectors with DMDA involved transforms between natural a
Fix memory leaks in TSTrajectoryCreate_Memory() and possibly bugs
1) The binary open did not switch to native vector loads hence each load for vectors with DMDA involved transforms between natural and PETSc ordering, this used large memory allocations. But the binary create for writing the vectors did set the native option hence likely the results for the example ex5adj.c were incorrect in the past
2) add the skipinfo for the binary open in TSTrajectoryCreate_Memory() since they are not needed.
3) when allocating buffer space in PetscViewerBinaryWriteReadAll() do not use the space on rank zero since the buffer is not needed for that.
Reported-by: Anton Glazkov <anton.glazkov@chch.ox.ac.uk> Thanks-to: Hong Zhang <hongzhang@anl.gov> /spend 1h
show more ...
|