2

Our team works on a project, it's purpose is to create a renderer, which will render data on the screen. We used to work on a HP Z600 station with the following specs: RAM: 6GB 6 Cores Processor: Intel(R) Xeon(R) CPU X5650 @ 2.67GHz 2.66GHz OS: Windows 7 32bit NVIDIA Quadro 4000

Now we moved to a newer HP Z620 Station with the following specs: RAM: 12GB 12 Cores Proccessor: Intel(R) Xeon(R) CPU E5-1650 0 @ 3.20 GHz 3.20GHz OS: Windows 7 sp1 64bit NVIDIA Quadro 4000

We tried to run our C# and c++\cli code on the new station in a 32bit emulation, and we are getting Out Of Memory Exception\COMException really fast, while I'm looking at the task manager and I see that the Memory of the application is only 450MB. The Exception is always thrown on the same action(but on different places in the code):

new WritableBitmap(width, height, 96, 96, PixelFormats.Bgra32, null)

Additional Information:

On the old station(Z600) it works with no problems. We tried to run it on Z600 with Windows 7 sp1 64Bit and again it works with no problems. One more problem I found was an example, which uses our renderer to render ".tif" file on the screen, using Z600(with Windows 7 32bit or 64bit) the memory of the application after rendering is 300MB(it does not matter if I run the application's .exe file or I run it through Visual Studio's debugger), but when I moved to Z620 (Windows 7 64 bit) running the application from the .exe file really takes only 300MB, but when I run it through Visual Studio (I tried VS 2010 and VS 2012) the Memory consumption goes up to 1000MB (unchecking the Visual studio hosting process didn't helped).

I tried to check why this happens, but after two days of searching I found no answer. Did someone got this problems or similar problems with Z620? I hope someone has an answer :)

Lev Levin
  • 21
  • 1
  • Use SysInternals' VMMap utility to find the DLL with the problematic load address. There's little point in fighting this problem when you've got such excellent hardware available, build the x64 version of your program. – Hans Passant Jul 16 '13 at 09:19

1 Answers1

0

In case if you are using .Net 3.5 there is a known bug in WritableBitmap.

http://social.msdn.microsoft.com/Forums/vstudio/en-US/5d88cdf1-e992-4ad4-8f56-b5dbf92dcf1c/possible-writeablebitmap-memory-leak

Vladimir Gondarev
  • 1,243
  • 7
  • 14