segfault while running glmark2-es2

Bug #1009306 reported by Chirag Varde
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
glmark2
Fix Committed
Undecided
Unassigned

Bug Description

I have compiled glmark2 using following commands
./waf configure --enable-glesv2
./waf

and when I try to run glmark2-es2, it shows segmentation fault.
I am using OpenSUSE 11.4 64bit and gcc 4.6.3

gdb shows this

Try: zypper install -C "debuginfo(build-id)=113ba00ae2c1794de40dbd41b41133e6152f7956"
Missing separate debuginfo for /usr/lib64/libXfixes.so.3
Try: zypper install -C "debuginfo(build-id)=3bc046d7ea5494d8770309240eeb198e9ec76d19"
libEGL warning: failed to create DRM screen
libEGL warning: use software fallback

Program received signal SIGSEGV, Segmentation fault.
glDeleteFramebuffers () at glapi/glapi_x86-64.S:19190
19190 glapi/glapi_x86-64.S: No such file or directory.
 in glapi/glapi_x86-64.S
(gdb) back
#0 glDeleteFramebuffers () at glapi/glapi_x86-64.S:19190
#1 0x00000000004be115 in CanvasX11::release_fbo (this=0x7fffffffdd20) at ../src/canvas-x11.cpp:463
#2 0x00000000004be9b8 in CanvasX11::reset (this=0x7fffffffdd20) at ../src/canvas-x11.cpp:38
#3 0x0000000000406d2a in main (argc=<value optimized out>, argv=0x7fffffffdf18) at ../src/main.cpp:183
(gdb) ^CQuit
(gdb) q
A debugging session is active.

 Inferior 1 [process 16282] will be killed.

Quit anyway? (y or n) y

Revision history for this message
Alexandros Frantzis (afrantzis) wrote :

First of all, to get a cleaner environment, I suggest building and running completely in-tree:

$ ./waf uninstall (optional, to uninstall system-wide installation)

$ ./waf configure --enable-gl --enable-glesv2 --data-path=$(pwd)/data
$ ./waf

$ build/src/glmark2
$ build/src/glmark2-es2

Please check if running 'build/src/glmark2' (the desktop GL variant) causes the same problem. Also, which version of Mesa are you using?

Revision history for this message
Chirag Varde (chirag-varde-crg) wrote :

I built glmark2 as instructed, but still its showing segfault. Both glmark2 and glmark2-es2 are not running.

I am using Mesa 7.10.2.

Earlier I bullt glmark2 and it built fine. Then I installed gcc 4.6.3 and built it again in separate directory and now it is showing segfault.

I still have glmark2 built by old gcc and that one is working fine.

Revision history for this message
Chirag Varde (chirag-varde-crg) wrote :

Now when I am running glmark2, I am getting this error with segfault

Error: eglGetConfigAttrib() failed with error: 12293
Segmentation fault

Revision history for this message
Chirag Varde (chirag-varde-crg) wrote :

I mean glmark2-es

Revision history for this message
Eric Brower (ebrower) wrote :

In 2012.08 and 2012.12, canvas-x11.cpp CanvasX11::release_fbo() unconditionally calls glDeleteFramebuffers() without a valid context enabled. This is undefined behavior per the spec, and though different drivers handle this differently, it's indicative of an application bug and a crash could be expected.

In the trunk, a check was put in for "if (fbo_)" so you may see the crashing moved lower to the call to glDeleteRenderbuffers(). Checks were put in place but have an incorrect negation (checking for zero rather than non-zero).

A patch to trunk is attached, along with a somewhat hacky patch for 2012.08 that you could try for testing.

Revision history for this message
Eric Brower (ebrower) wrote :
Changed in glmark2:
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.