Bug 21770 - [945GM] [UXA] Running Out of Memory with UXA
Summary: [945GM] [UXA] Running Out of Memory with UXA
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i915 (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: high major
Assignee: Eric Anholt
QA Contact:
URL: https://bugs.launchpad.net/ubuntu/+so...
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-05-16 09:23 UTC by Jonathan Michalon
Modified: 2009-06-22 12:40 UTC (History)
7 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Xorg log without external screen (16.01 KB, text/plain)
2009-05-19 00:50 UTC, Jonathan Michalon
Details

Description Jonathan Michalon 2009-05-16 09:23:34 UTC
When I run compiz, the cached memory grows continuously until the system becomes unusable. I suspect this to be a memory leak.
I've found that this is related to UXA, KMS used or not, and happens with all the driver versions I have tested:
-- The official Jaunty 2.6.1
-- The 2.7.0 from ubuntu-x-swat (launchpad)
-- The 2.7.99 from xorg-edgers (launchpad)

OpenGL version string: 1.4 Mesa 7.5-rc1 (happens with default Jaunty too)
X.Org X Server 1.6.0

This doesn't happen when using EXA or without compiz.

To reproduce:
Do some window open/close/resize/…
I use this bash line:
while true; do firefox & sleep 3; pkill firefox; done
You could see the cached memory grow quickly and about one minute after I'm out of memory (on 1GB).


The attachments and details of how I investigated are on the original bug report given as URL:
https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/376092

Summary:
This is neither related to architecture (both i386, amd64) nor (actual) kernel version (Jaunty official / 2.6.30-rc).

The external monitor doesn't play any role here.

It seems that the leak go with the resolution, bigger screen, quicker run out.


I hope to be complete…
Comment 1 Jonathan Michalon 2009-05-19 00:50:11 UTC
Created attachment 25990 [details]
Xorg log without external screen

Here is the Xorg.0.log when starting X using KMS and the 2.7.99 driver.
Comment 2 Geir Ove Myhr 2009-05-20 08:47:33 UTC
lscpi from downstream bug report:

00:00.0 Host bridge [0600]: Intel Corporation Mobile 945GM/PM/GMS, 943/940GML and 945GT Express Memory Controller Hub [8086:27a0] (rev 03)
 Subsystem: Micro-Star International Co., Ltd. Device [1462:0341]
00:02.0 VGA compatible controller [0300]: Intel Corporation Mobile 945GM/GMS, 943/940GML Express Integrated Graphics Controller [8086:27a2] (rev 03)
 Subsystem: Micro-Star International Co., Ltd. Device [1462:0341]
Comment 3 Milan Bouchet-Valat 2009-05-24 05:03:26 UTC
Seeing the same dramatic symptoms with a i915 card, kernels 2.6.30rc5 and rc6, drivers 2.6.99 (still Ubuntu). UXA is working fast with this release, though.
Comment 4 Eric Anholt 2009-05-26 16:22:03 UTC
Thanks for the specifics on how to reproduce it!  I'll try that.
Comment 5 Dark Shadow 2009-05-31 05:57:51 UTC
Suffering from the same memory leaks, using 2.6.30-rc7, gm965/GL960 rev0c, font glyph patch applied (see bug 21790). Xorg-server 1.6.1.901, everything else current git versions.

And like stated in comment #3, UXA is really fast ;-)

Comment 6 Jonathan Michalon 2009-05-31 13:30:40 UTC
Just an idea: may a ssh connexion help you find the specificity of my hardware that make this happen? I've a DynDns account and ssh enabled but my machine must be on, so just ask if this could help and I will give you my DNS name and let the computer on when you want.

BTW did you success in reproducing this issue?
Comment 7 Milan Bouchet-Valat 2009-06-08 02:16:20 UTC
Any idea about how a mem leak can lead to growing caches? That's not obvious to debug, since X.org's mem usage doesn't really increase. But those caches can't be dropped, to the point that hibernating is no longer possible.
Comment 8 Shuang He 2009-06-08 22:13:19 UTC
this issue really looks like bug #20704
Comment 9 Jonathan Michalon 2009-06-11 01:31:13 UTC
Still an issue with 2.7.99.901+git20090610.9d3c3b05-0ubuntu0sarvatt~jaunty package from xorg-edgers.

Yes symptoms are the same as in the other bug... but this is only with UXA, KMS or not. I'm not sure this is a duplicate but may.
Had the fix for bug #20704 been pushed and integrated before git 20090610? If yes then this is a different issue...

Yesterday, I've seen this problem with metacity too: playing some time with google maps' Street View reproduces this. But it's only slowly growing.
Comment 10 Shuang He 2009-06-11 02:22:57 UTC
(In reply to comment #9)
> Still an issue with 2.7.99.901+git20090610.9d3c3b05-0ubuntu0sarvatt~jaunty
> package from xorg-edgers.
> 
> Yes symptoms are the same as in the other bug... but this is only with UXA, KMS
> or not. I'm not sure this is a duplicate but may.
> Had the fix for bug #20704 been pushed and integrated before git 20090610? If
> yes then this is a different issue...
> 
> Yesterday, I've seen this problem with metacity too: playing some time with
> google maps' Street View reproduces this. But it's only slowly growing.
> 

the fix for bug #20704 is still waiting for review, so not pushed yet
Comment 11 Gordon Jin 2009-06-22 01:45:12 UTC
The fix for bug #20704 has been committed into mesa. Please verify.
Comment 12 Johannes Mockenhaupt 2009-06-22 06:10:28 UTC
Verified. As I reported on the downstream bug report the patch(es) fix the issues I saw in this bug report as well as in #20704. (I'm using the 7.5 branch of mesa).
Comment 13 Eric Anholt 2009-06-22 12:40:27 UTC
commit d027e8feff7d38cccadc6aaccc0454b21ce4dca0
Author: Shuang He <shuang.he@intel.com>
Date:   Mon Jun 15 16:19:30 2009 -0600

    intel: Release fb backing regions in intelDestroyBuffer()
    
    Fixes memory leak when destroying framebuffers.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.