From Fedora Project Wiki

NVidia issues with KDE 4

Background

There are some performance issues of NVidia proprietary driver and KWin with effects enabled.

Issues

KWin uses too much CPU

KWin uses too much CPU with NVidia proprietary drivers (about 75%) which is quite non-sense for window manager. Seems to be fixed in KDE 4.1.1 and latest NVidia drivers from Livna. Now the consumption of KWin is somewhere around 4%. If it's not better then try:

QT_NO_GLIB=1 kwin --replace

See http://labs.trolltech.com/blogs/2008/08/22/rant-desktop-effects-never-more/ for more information.

Overall KDE performance is bad

This issue causes that you can see strange artefacts when opening, resizing windows and overall performance of graphics operations is bad. See the solution in how to section to "solve" this issue. Seems to be better for me.

How-to

Tweak NVidia settings.

nvidia-settings -a InitialPixmapPlacement=2 -a GlyphCache=1

Edit your xorg.conf and add these options:

Option "AllowSHMPixmaps" "0"             
Option "PixmapCacheSize" "1000000"

KWIN_NVIDIA_HACK is enabled by default in KDE 4.0.3.