OpenGL "hello world" windowed vsync app brings unity to its knees

Bug #1415195 reported by Andrew Kelley
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
Unity
Confirmed
Undecided
Unassigned
unity (Ubuntu)
Confirmed
High
Unassigned

Bug Description

1. Create a basic hello world OpenGL app, e.g. one that draws a single triangle to the screen.
2. Use windowed mode with vsync on
3. Try alt+tabbing or activating between different windows and the opengl window by clicking.
4. Notice how laggy and slow it is.
5. Try a different window manager besides unity such as xcfe4
6. Notice that this problem no longer exists.
---
.proc.driver.nvidia.gpus.0: Error: [Errno 21] Is a directory: u'/proc/driver/nvidia/gpus/0'
.proc.driver.nvidia.registry: Binary: ""
.proc.driver.nvidia.version:
 NVRM version: NVIDIA UNIX x86_64 Kernel Module 331.113 Mon Dec 1 21:08:13 PST 2014
 GCC version: gcc version 4.9.1 (Ubuntu 4.9.1-16ubuntu6)
.tmp.unity.support.test.0:

ApportVersion: 2.14.7-0ubuntu8.1
Architecture: amd64
BootLog:
 * Setting up X socket directories... 
[ OK ]
CompizPlugins: No value set for `/apps/compiz-1/general/screen0/options/active_plugins'
CompositorRunning: compiz
CompositorUnredirectDriverBlacklist: '(nouveau|Intel).*Mesa 8.0'
CompositorUnredirectFSW: true
CurrentDesktop: Unity
DistUpgraded: 2014-10-22 01:04:42,973 DEBUG enabling apt cron job
DistroCodename: utopic
DistroRelease: Ubuntu 14.10
DistroVariant: ubuntu
EcryptfsInUse: Yes
GraphicsCard:
 NVIDIA Corporation GK104M [GeForce GTX 780M] [10de:119f] (rev a1) (prog-if 00 [VGA controller])
   Subsystem: CLEVO/KAPOK Computer Device [1558:0376]
InstallationDate: Installed on 2013-11-05 (448 days ago)
InstallationMedia: Ubuntu 13.10 "Saucy Salamander" - Release amd64 (20131016.1)
MachineType: System76, Inc. Bonobo Extreme
NonfreeKernelModules: nvidia
Package: unity 7.3.1+14.10.20141016-0ubuntu1
PackageArchitecture: amd64
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.16.0-25-generic root=UUID=f3c3398f-92de-4f0b-a638-d4691bec6e84 ro quiet splash
ProcVersionSignature: Ubuntu 3.16.0-25.33-generic 3.16.7
Tags: utopic utopic utopic ubuntu compiz-0.9
Uname: Linux 3.16.0-25-generic x86_64
UpgradeStatus: Upgraded to utopic on 2014-10-22 (97 days ago)
UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo vboxusers
_MarkForUpload: True
dmi.bios.date: 09/04/2013
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: 4.6.5
dmi.board.asset.tag: Tag 12345
dmi.board.name: Bonobo Extreme
dmi.board.vendor: System76, Inc.
dmi.board.version: bonx7
dmi.chassis.asset.tag: No Asset Tag
dmi.chassis.type: 9
dmi.chassis.vendor: System76, Inc.
dmi.chassis.version: bonx7
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvr4.6.5:bd09/04/2013:svnSystem76,Inc.:pnBonoboExtreme:pvrbonx7:rvnSystem76,Inc.:rnBonoboExtreme:rvrbonx7:cvnSystem76,Inc.:ct9:cvrbonx7:
dmi.product.name: Bonobo Extreme
dmi.product.version: bonx7
dmi.sys.vendor: System76, Inc.
version.compiz: compiz 1:0.9.12+14.10.20140918-0ubuntu1
version.ia32-libs: ia32-libs N/A
version.libdrm2: libdrm2 2.4.56-1
version.libgl1-mesa-dri: libgl1-mesa-dri 10.3.2-0ubuntu0.1
version.libgl1-mesa-dri-experimental: libgl1-mesa-dri-experimental N/A
version.libgl1-mesa-glx: libgl1-mesa-glx 10.3.2-0ubuntu0.1
version.nvidia-graphics-drivers: nvidia-graphics-drivers N/A
version.xserver-xorg-core: xserver-xorg-core 2:1.16.0-1ubuntu1.2
version.xserver-xorg-input-evdev: xserver-xorg-input-evdev 1:2.9.0-1ubuntu2
version.xserver-xorg-video-ati: xserver-xorg-video-ati 1:7.4.0-2ubuntu2
version.xserver-xorg-video-intel: xserver-xorg-video-intel 2:2.99.914-1~exp1ubuntu4.1
version.xserver-xorg-video-nouveau: xserver-xorg-video-nouveau 1:1.0.11-1ubuntu2
xserver.bootTime: Sun Jan 25 13:20:43 2015
xserver.configfile: default
xserver.errors:

xserver.logfile: /var/log/Xorg.0.log
xserver.outputs:

xserver.version: 2:1.16.0-1ubuntu1.2

Revision history for this message
Andrea Azzarone (azzar1) wrote :

Can you provide the code of the OpenGL app you are using? Please also run apport-collect.

Changed in unity:
status: New → Incomplete
Changed in unity (Ubuntu):
status: New → Incomplete
Revision history for this message
Andrew Kelley (andrewrk) wrote :

sudo apt-get install libglfw3-dev
gcc -o hello-opengl hello-opengl.c -I/usr/include/libdrm -lglfw -lGL

tags: added: apport-collected compiz-0.9 ubuntu utopic
description: updated
Revision history for this message
Andrew Kelley (andrewrk) wrote : .proc.driver.nvidia.params.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : BootDmesg.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : CurrentDmesg.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : Dependencies.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : DkmsStatus.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : DpkgLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : GconfCompiz.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : LightdmDisplayLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : LightdmGreeterLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : LightdmGreeterLogOld.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : LightdmLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : Lspci.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : Lsusb.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : MonitorsUser.xml.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : NvidiaBugReportLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : ProcCpuinfo.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : ProcEnviron.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : ProcInterrupts.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : ProcModules.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : UdevDb.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : UdevLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : UnitySupportTest.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : XorgLog.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : XorgLogOld.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : Xrandr.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : make.log.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : nvidia-settings.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : xdpyinfo.txt

apport information

Revision history for this message
Andrew Kelley (andrewrk) wrote : xserver.devices.txt

apport information

Revision history for this message
Andrea Azzarone (azzar1) wrote :

Seems to work fine here.

Changed in unity:
status: Incomplete → New
Changed in unity (Ubuntu):
status: Incomplete → Opinion
status: Opinion → New
Revision history for this message
Andrea Azzarone (azzar1) wrote :

Can you please post the output of:
apt-cache policy compiz

Changed in unity:
status: New → Incomplete
Changed in unity (Ubuntu):
status: New → Incomplete
Revision history for this message
Andrew Kelley (andrewrk) wrote :

andy@andy-bx:~$ apt-cache policy compiz
compiz:
  Installed: 1:0.9.12+14.10.20140918-0ubuntu1
  Candidate: 1:0.9.12+14.10.20140918-0ubuntu1
  Version table:
 *** 1:0.9.12+14.10.20140918-0ubuntu1 0
        500 http://us.archive.ubuntu.com/ubuntu/ utopic/main amd64 Packages
        100 /var/lib/dpkg/status

Revision history for this message
Andrea Azzarone (azzar1) wrote : Re: [Bug 1415195] Re: OpenGL "hello world" windowed vsync app brings unity to its knees
Download full text (4.9 KiB)

Would be nice to test if the problem still occurs with compiz
0.9.12.0+15.04.20141219-0ubuntu1. It contains a fix for some issues with
nvidia driver 331.

2015-01-28 18:49 GMT+01:00 Andrew Kelley <email address hidden>:

> andy@andy-bx:~$ apt-cache policy compiz
> compiz:
> Installed: 1:0.9.12+14.10.20140918-0ubuntu1
> Candidate: 1:0.9.12+14.10.20140918-0ubuntu1
> Version table:
> *** 1:0.9.12+14.10.20140918-0ubuntu1 0
> 500 http://us.archive.ubuntu.com/ubuntu/ utopic/main amd64
> Packages
> 100 /var/lib/dpkg/status
>
> --
> You received this bug notification because you are subscribed to Unity.
> https://bugs.launchpad.net/bugs/1415195
>
> Title:
> OpenGL "hello world" windowed vsync app brings unity to its knees
>
> Status in Unity:
> Incomplete
> Status in unity package in Ubuntu:
> Incomplete
>
> Bug description:
> 1. Create a basic hello world OpenGL app, e.g. one that draws a single
> triangle to the screen.
> 2. Use windowed mode with vsync on
> 3. Try alt+tabbing or activating between different windows and the
> opengl window by clicking.
> 4. Notice how laggy and slow it is.
> 5. Try a different window manager besides unity such as xcfe4
> 6. Notice that this problem no longer exists.
> ---
> .proc.driver.nvidia.gpus.0: Error: [Errno 21] Is a directory:
> u'/proc/driver/nvidia/gpus/0'
> .proc.driver.nvidia.registry: Binary: ""
> .proc.driver.nvidia.version:
> NVRM version: NVIDIA UNIX x86_64 Kernel Module 331.113 Mon Dec 1
> 21:08:13 PST 2014
> GCC version: gcc version 4.9.1 (Ubuntu 4.9.1-16ubuntu6)
> .tmp.unity.support.test.0:
>
> ApportVersion: 2.14.7-0ubuntu8.1
> Architecture: amd64
> BootLog:
> * Setting up X socket directories... [80G
> [74G[ OK ]
> CompizPlugins: No value set for
> `/apps/compiz-1/general/screen0/options/active_plugins'
> CompositorRunning: compiz
> CompositorUnredirectDriverBlacklist: '(nouveau|Intel).*Mesa 8.0'
> CompositorUnredirectFSW: true
> CurrentDesktop: Unity
> DistUpgraded: 2014-10-22 01:04:42,973 DEBUG enabling apt cron job
> DistroCodename: utopic
> DistroRelease: Ubuntu 14.10
> DistroVariant: ubuntu
> EcryptfsInUse: Yes
> GraphicsCard:
> NVIDIA Corporation GK104M [GeForce GTX 780M] [10de:119f] (rev a1)
> (prog-if 00 [VGA controller])
> Subsystem: CLEVO/KAPOK Computer Device [1558:0376]
> InstallationDate: Installed on 2013-11-05 (448 days ago)
> InstallationMedia: Ubuntu 13.10 "Saucy Salamander" - Release amd64
> (20131016.1)
> MachineType: System76, Inc. Bonobo Extreme
> NonfreeKernelModules: nvidia
> Package: unity 7.3.1+14.10.20141016-0ubuntu1
> PackageArchitecture: amd64
> ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-3.16.0-25-generic
> root=UUID=f3c3398f-92de-4f0b-a638-d4691bec6e84 ro quiet splash
> ProcVersionSignature: Ubuntu 3.16.0-25.33-generic 3.16.7
> Tags: utopic utopic utopic ubuntu compiz-0.9
> Uname: Linux 3.16.0-25-generic x86_64
> UpgradeStatus: Upgraded to utopic on 2014-10-22 (97 days ago)
> UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo vboxusers
> _MarkForUpload: True
> dmi.bios.date: 09/04/2013
> dmi.bios.vendor: American Megatre...

Read more...

Revision history for this message
Andrew Kelley (andrewrk) wrote :

Is there a PPA I can use for this purpose?

Revision history for this message
Andrea Azzarone (azzar1) wrote :
Revision history for this message
Andrew Kelley (andrewrk) wrote :

The PPA you linked has a compiz package with a version number less than the one on my system.

I used backportpackage to get the vivid version into a personal PPA for my utopic system and installed that. The issue persists. Here is my new apt-cache policy compiz:

compiz:
  Installed: 1:0.9.12.0+15.04.20141219-0ubuntu1~ubuntu14.10.1~ppa1
  Candidate: 1:0.9.12.0+15.04.20141219-0ubuntu1~ubuntu14.10.1~ppa1
  Version table:
 *** 1:0.9.12.0+15.04.20141219-0ubuntu1~ubuntu14.10.1~ppa1 0
        500 http://ppa.launchpad.net/andrewrk/misc/ubuntu/ utopic/main amd64 Packages
        100 /var/lib/dpkg/status
     1:0.9.12+14.10.20140918-0ubuntu1 0
        500 http://us.archive.ubuntu.com/ubuntu/ utopic/main amd64 Packages

Andrea Azzarone (azzar1)
Changed in unity:
status: Incomplete → Confirmed
Changed in unity (Ubuntu):
status: Incomplete → Confirmed
Changed in unity (Ubuntu):
importance: Undecided → High
To post a comment you must log in.