Bug 169499 - kwin's effects are leaking pixmaps. (nVidia binary driver problem?)
Summary: kwin's effects are leaking pixmaps. (nVidia binary driver problem?)
Status: RESOLVED REMIND
Alias: None
Product: kwin
Classification: Plasma
Component: general (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-08-20 17:51 UTC by Gilboa Davara
Modified: 2009-02-20 19:26 UTC (History)
7 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Gilboa Davara 2008-08-20 17:51:30 UTC
Version:            (using KDE 4.1.0)
OS:                Linux
Installed from:    Fedora RPMs

I'm testing nVidia's latest beta drivers. (v177.67)
I've partially enabled desktop effects.

After 2-3 hours of use, kwin started eating CPU (>40%) and the following error appear in .xsession_errors

$ cat .xsession-errors | grep BadPixmap 
kwin: X Error (error: BadPixmap [4], request: X_FreePixmap[54], resource: 0x160577c)
kwin: X Error (error: BadPixmap [4], request: X_FreePixmap[54], resource: 0x160577d)
kwin: X Error (error: BadPixmap [4], request: X_FreePixmap[54], resource: 0x160577e)
...
$ cat .xsession-errors | grep BadPixmap | wc -l
751

Fedora 9, x86_64, KDE 4.1 (updates/testing)

- Gilboa
Comment 1 Martin Flöser 2008-08-20 18:26:12 UTC
Have you experienced this problem with the stable driver as well? I just tested on my machine and I have 10 such lines after nearly 10 h uptime (although compositing was disable for some time).
Comment 2 Gilboa Davara 2008-08-20 18:33:56 UTC
The stable driver has severe Xrender problems. Using it w/ KDE 4.1 is pure torture. (At least on my 9800GTX)

Can you enable kwin composition for a couple of hours and see if you can reproduce this problem?

- Gilboa
Comment 3 Lubos Lunak 2008-08-25 21:45:32 UTC
I've never noticed this. Please reopen if you can reproduce using stable drivers.
Comment 4 Gilboa Davara 2008-08-29 09:10:17 UTC
I've switched to stable drivers (v173.14.12), and I'm seeing more-or-less the same problem. (Different error, both on close)

$ cat .xsession-errors | grep "kwin: X Error"
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1801cff)
kwin: X Error (error: BadMatch [8], request: X_SetInputFocus[42], resource: 0x5200001)
kwin: X Error (error: BadMatch [8], request: X_SetInputFocus[42], resource: 0x5200001)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x180298c)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x180298f)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1802992)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1802998)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1803045)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x18036e6)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x18036e9)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x18036ec)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x18036ef)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x18036f2)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x18036f5)

Still looks like an nVidia bug?

- Gilboa
Comment 5 Lubos Lunak 2008-08-29 09:38:40 UTC
How can you see a problem with pixmaps leaking only on close?
Comment 6 Gilboa Davara 2008-08-29 16:42:28 UTC
The problem (at least AFAIKS) is not memory leaks - but the reason for the memory leaks.

If I understand correctly, the X resource pointer are somehow screwed, causing the close to fail.
As the actual resource don't get released, memory leak occurs.

As I'm not that familiar with Xlib and friends, I'm just guess.

Can I somehow get a listing of all valid Xlib objects being used by kwin?

- Gilboa
Comment 7 Lubos Lunak 2008-08-29 18:41:09 UTC
The warnings should be harmless, and definitely not cause huge memory leaks. Since you haven't confirmed any leaks with the stable driver, I still see no bug.

Comment 8 Gilboa Davara 2008-08-30 22:00:21 UTC
OK. I'll post a bug report in nvnews.com.

Thanks,
Gilboa
Comment 9 Jose 2008-09-02 09:39:07 UTC
I'm having the same behavior with an Intel card in Kubuntu Hardy (KDE 4.1 too).
After some hours, KWin starts to feel laggy and sometimes it starts eating CPU to the point that it makes the system unusable and I have to reset the machine.
Comment 10 Dominic Battre 2008-10-13 16:43:06 UTC
I am experiencing the same problems...

These are the final lines of my .xsession-errors file:

kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1426644)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1426e86)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x14278bd)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1427ab6)
QObject: Do not delete object, 'unnamed', during its event handler!
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x142b133)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x142baed)
e
kwin: X Error (error: BadMatch [8], request: X_SetInputFocus[42], resource: 0x30deb80)
X Error: BadWindow (invalid Window parameter) 3
  Major opcode: 2 (X_ChangeWindowAttributes)
  Resource id:  0x30dee5d
X Error: BadWindow (invalid Window parameter) 3
  Major opcode: 20 (X_GetProperty)
  Resource id:  0x3da70f5
kwin: X Error (error: BadPixmap [4], request: X_FreePixmap[54], resource: 0x142e3f5)
kwin: X Error (error: BadMatch [8], request: X_SetInputFocus[42], resource: 0x30e031c)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x142f6fc)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x142f8c5)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1430d6e)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1430d6f)
kwin: X Error (error: BadPixmap [4], request: X_FreePixmap[54], resource: 0x1430ecd)

This is happens using an ATI card with the latest proprietary driver on KDE 4.1.2 (Gentoo).
Comment 11 Chatmoa 2008-11-04 22:59:07 UTC
I am experiencing the same problems...

With ubuntu 8.10 x86_64, GeForce 6600 GT, NVIDIA Driver Version:177.80

When activating kwin effects, cpu > 40% and Xorg memory grows up
And then X goes black or freeze
When compositing is off, cpu is lower but memory stays up.

with this lines in .xsessions-errors:

kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1407aa7)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1407b46)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1407b9a)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1407eaf)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1407ebb)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1408030)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1408033)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1408827)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x140896c)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1408c1d)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1408da3)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x14093b3)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1409594)

Comment 12 Lubos Lunak 2008-11-05 11:38:12 UTC
Please file a separate bugreport for your separate issue. "When activating kwin effects, cpu > 40% and Xorg memory grows up" is not "kwin's effects are leaking pixmaps" just because the guessed cpu usage happens to be a similar number.
Comment 13 Gilboa Davara 2008-11-05 19:28:16 UTC
Lubos Lunak,

While parts of his bug report seem unrelated (Xorg goes blank, etc) - I should mention that once the leak party begins, CPU usage goes sky-high;
Seems to be that he's hitting the same issue (at a somewhat elevated state...)

- Gilboa
P.S. If indeed ATI users are seeing the same bug, is it possible that it isn't an nVidia bug after-all?
Comment 14 Chatmoa 2008-11-09 16:21:02 UTC
Ok seems to be a nvidia bug. Tested with GeForce5500 -> no problem.
Comment 15 Steven Newbury 2009-01-15 01:56:58 UTC
I'm seeing the same symptoms as many others with the current intel git master drivers+xorg, DRI2 etc. KWin from svn.
Comment 16 Dan Coats 2009-02-20 19:26:26 UTC
This is not nvidia specific i get it with radeon driver too
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x140cb7f)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x140cc52)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x140db3d)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x140dbd5)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x140f1fa)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1410277)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x141027a)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1410280)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x14107e5)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x14108e8)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x14108eb)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x14108f2)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1410970)
kwin: X Error (error: <unknown>[DAMAGE+0], request: XDamageDestroy[DAMAGE+2], resource: 0x1410a46)