possible memory allocation bug

*** Please report new bugs here! ***

Moderators: helmut, XnTriq, xnview, Dreamer

Post Reply
CameronD
Posts: 311
Joined: Wed Aug 01, 2007 1:28 pm
Location: Australia

possible memory allocation bug

Post by CameronD »

Windows 7 64-bit, MP version 0.64.

I was first alerted to this by a system message box telling me I had run out of memory and I should close XnViewMP.

Task manager did not show any problems, and nothing unusual - The whole system was only using about 3GB of my 8GB physical according to taskman, and there were no jumps in the plot.
This had occurred while I was "rebuilding thumbnails" in the db (separate bug report not yet filed)

So I restarted xnviewMP, started up Process Explorer from sysinternals and followed xnview while I clicked "rebuild thumbnails" again.
This time the performance graph for "Private Bytes" showed two massive spikes, and after it finished the "peak private bytes" value was 16GB.

Initially this was with files and DB on a server, so as I repeated the process with various combinations I got peak private byte values of 16GB again, or 12GB a couple of times and also 4GB.

With everything on a local PC, I deleted the databases and started again, in browser mode, with a thumbnail view, so that new thumbnails are added to the db.
I then stepped through a set of folders each with between 15 and 100 images per folder.
Each time I opened a new folder, the private bytes value increased slightly (typically a few MB, up to 10-15MB and occasionally it dropped back down slightly).
However, the total private bytes kept increasing, and it was when it was somewhere around 100MB that the jump to 4GB occurred. (or 8 or 12) and then browsing further will see the allocation drop back to near the amount it was at before the jump.

I can only make it behave like this when it is creating the thumbnails - either initially or with "rebuild thumbnails".
User avatar
m.Th.
XnThusiast
Posts: 1676
Joined: Wed Aug 16, 2006 6:31 am
Contact:

Re: possible memory allocation bug

Post by m.Th. »

Also I had some occasions in which XnViewMP 'disappeared' from my screen.

In my experience this is a classical result of big memory leaks / stack overflows.
m. Th.

- Dark Themed XnViewMP 1.7.1 64bit on Win11 x64 -
CameronD
Posts: 311
Joined: Wed Aug 01, 2007 1:28 pm
Location: Australia

Re: possible memory allocation bug

Post by CameronD »

It might also be related to this bug report for v0.61.
User avatar
xnview
Author of XnView
Posts: 46235
Joined: Mon Oct 13, 2003 7:31 am
Location: France
Contact:

Re: possible memory allocation bug

Post by xnview »

Strange i've checked and there is no memory leak....
Pierre.
Post Reply