Sometimes, black or incorrect textures appear in KDE instead of window contents or other interface elements, like widgets on the panel. One easy way to reproduce the problem is this:

Toggle Kwin compositing off and then on again with a hotkey.

Have multiple windows opened, from different applications. I typically use Firefox, Thunderbird, QtCreator, Kate and other KDE applications for testing. Preferably, one window should be maximized in the background.

Open new windows or resize (preferably increase the size) of windows with mouse. At this point you should see some windows blinking briefly to black. After prolonged use you will notice some windows or regions on the screen stay black instead of just blinking. This happens especially often on resizing windows.

This can be reproduced on a freshly booted system, no suspend or switching to VT.

The case of incorrect textures is harder to reproduce and sometimes appear as some pieces of interface stopping updates unless interacted with. For example, the network bandwidth indicator on the panel stops being redrawn unless the panel is resized or the indicator is interacted with to that it has to be redrawn. I don’t have a step-by-step way to reproduce, it just happens sometimes after a few days of uptime of the system that is being worked on.

This is not a new problem and has appeared for many years on different versions of Nvidia drivers, KDE, Qt and X.org. The manifestation of the problem was different at some points, but the black textures were always present in one way or the other. It was reported to KDE developers multiple times and they refer to Nvidia:

https://bugs.kde.org/show_bug.cgi?id=386752

https://bugs.kde.org/show_bug.cgi?id=354731

https://bugs.kde.org/show_bug.cgi?id=347425

The most recent report (the first link) happens to me on Kubuntu 17.10 x86_64, Nvidia 387.22, GTX980. The step-by-step presented above triggers the problem on this system.

nvidia-bug-report.log.gz (299 KB)

