Go Back   nV News Forums > Linux Support Forums > NVIDIA Linux

Newegg Daily Deals

Reply
 
Thread Tools
Old 10-31-07, 05:08 PM   #1
V|r
Registered User
 
Join Date: Apr 2007
Location: Germany
Posts: 8
Default process uses lot's of memory mapped to /dev/nvidia0

Hi,

any ideas how to debug a memory leak that makes /proc/<pid>/smaps look like this?

Code:
8b59e000-8c1fb000 rw-s 16b8c000 00:0e 18542      /dev/nvidia0
Size:              12660 kB
Rss:               12660 kB
Shared_Clean:          0 kB
Shared_Dirty:          0 kB
Private_Clean:     12660 kB
Private_Dirty:         0 kB
Referenced:        12660 kB
8c1fb000-8ce58000 rw-s 0d3d1000 00:0e 18542      /dev/nvidia0
Size:              12660 kB
Rss:               12660 kB
Shared_Clean:          0 kB
Shared_Dirty:          0 kB
Private_Clean:     12660 kB
Private_Dirty:         0 kB
Referenced:        12660 kB
8ce58000-8dab5000 rw-s 317ef000 00:0e 18542      /dev/nvidia0
Size:              12660 kB
Rss:               12660 kB
Shared_Clean:          0 kB
Shared_Dirty:          0 kB
Private_Clean:     12660 kB
Private_Dirty:         0 kB
Referenced:        12660 kB
8dab5000-8e712000 rw-s 1c040000 00:0e 18542      /dev/nvidia0
Size:              12660 kB
Rss:               12660 kB
Shared_Clean:          0 kB
Shared_Dirty:          0 kB
Private_Clean:     12660 kB
Private_Dirty:         0 kB
Referenced:        12660 kB
8e712000-8f36f000 rw-s 27d62000 00:0e 18542      /dev/nvidia0
Size:              12660 kB
Rss:               12660 kB
Shared_Clean:          0 kB
Shared_Dirty:          0 kB
Private_Clean:     12660 kB
Private_Dirty:         0 kB
Referenced:        12660 kB
8f36f000-8ffcc000 rw-s 052cd000 00:0e 18542      /dev/nvidia0
Size:              12660 kB
Rss:               12660 kB
Shared_Clean:          0 kB
Shared_Dirty:          0 kB
Private_Clean:     12660 kB
Private_Dirty:         0 kB
Referenced:        12660 kB
.
.
.
Code:
Total mapped memory:     709804 kB
  of which are resident: 590092 kB
                 Shared: 15932 kB clean (99.9%), 8 kB dirty (0.1%)
                Private: 557348 kB clean (98.2%), 10236 kB dirty (1.8%)
Almost all of those Private_Clean are coming from /dev/nvidia0 entries. Is it a leak in the app or a leak in the nvidia driver?
V|r is offline   Reply With Quote
Old 11-01-07, 03:16 AM   #2
Thunderbird
 
Join Date: Jul 2002
Location: Netherlands, Europe
Posts: 2,105
Default Re: process uses lot's of memory mapped to /dev/nvidia0

It is not a leak at all. Modern hardware uses 'memory mapped I/O'. Basically hardware advertises itself at a certain memory range. Drivers then access the device in the same way as if it was memory. The file /dev/nvidia0 is the way to access the nvidia GPU.
Thunderbird is offline   Reply With Quote
Old 11-01-07, 05:23 AM   #3
V|r
Registered User
 
Join Date: Apr 2007
Location: Germany
Posts: 8
Default Re: process uses lot's of memory mapped to /dev/nvidia0

Yes, that's what I expected at first, but looking through all of smaps /dev/nvidia0 is the only explanation for why the process ate half of my RAM. I have 1GB of RAM and I sure can notice the performance difference. If this were only memory mapped I/O then it wouldn't make a difference for the available mem of other processes. But the system is really thrashing.

So if this is memory mapped I/O could it be that it is mirrored in the RAM? I.e. that while those 12MB areas all are meant to access hardware (video RAM I guess) they also use up the same amount of system RAM?
V|r is offline   Reply With Quote
Reply


Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
GPU memory consumption, back buffer, Quadro tdsussman NVIDIA Linux 5 08-14-12 09:14 PM
Measuring card memory usage peter_ga NVIDIA Linux 0 05-24-12 08:07 PM

All times are GMT -5. The time now is 11:32 AM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Copyright 1998 - 2014, nV News.