<html>
<head>
<base href="https://bugs.freedesktop.org/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW - Segfault when calling glViewport on surfaceless EGL context without bound FBO"
href="https://bugs.freedesktop.org/show_bug.cgi?id=90821">90821</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>Segfault when calling glViewport on surfaceless EGL context without bound FBO
</td>
</tr>
<tr>
<th>Product</th>
<td>Mesa
</td>
</tr>
<tr>
<th>Version</th>
<td>git
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Other
</td>
</tr>
<tr>
<th>OS</th>
<td>Linux (All)
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>medium
</td>
</tr>
<tr>
<th>Component</th>
<td>Drivers/DRI/i965
</td>
</tr>
<tr>
<th>Assignee</th>
<td>idr@freedesktop.org
</td>
</tr>
<tr>
<th>Reporter</th>
<td>martina.kollarova@intel.com
</td>
</tr>
<tr>
<th>QA Contact</th>
<td>intel-3d-bugs@lists.freedesktop.org
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=116246" name="attach_116246" title="glxinfo">attachment 116246</a> <a href="attachment.cgi?id=116246&action=edit" title="glxinfo">[details]</a></span>
glxinfo
The glViewport command creates a segfault when called without a bound FBO on a
surfaceless EGL context, even tough GL_OES_surfaceless_contex and
EGL_KHR_surfaceless_contex are supported. This ocurred in Chromium [1][2]. A
possible way to reproduce it in Chromium (without using egltest, which is a bit
flaky), is to just add `glViewport(0,0,0,0)` to gl_surface_egl.cc:378 [3] and
run `chrome --use-gl=egl --in-process-gpu` - a backtrace of this is at the end
of this message. I can try to create a simpler reproducer outside of Chromium.
I reproduced this in Linux with Mesa 10.7.0-devel (git-6cdb29d 2015-05-21
trusty-oibaf-ppa) and a colleague reproduced it with Mesa 10.5.2 (using the
same hardware). However, he couldn't reproduce it on ChromeOS (mesa-10.3-r33)
and Yocto (mesa-10.5.4).
[1] <a href="https://code.google.com/p/chromium/issues/detail?id=462948">https://code.google.com/p/chromium/issues/detail?id=462948</a>
[2] <a href="https://codereview.chromium.org/207443007/">https://codereview.chromium.org/207443007/</a>
[3]
<a href="https://code.google.com/p/chromium/codesearch#chromium/src/ui/gl/gl_surface_egl.cc&q=gl_surface_e&sq=package:chromium&l=378">https://code.google.com/p/chromium/codesearch#chromium/src/ui/gl/gl_surface_egl.cc&q=gl_surface_e&sq=package:chromium&l=378</a>
#0 0x00007fffcffe02b1 in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#1 0x00007fffd002d141 in ?? () from /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
#2 0x00007fffeeb32d02 in gfx::GLApiBase::glViewportFn (this=0x300e18765da0,
x=0, y=0, width=0, height=0) at ../../ui/gl/gl_bindings_autogen_gl.cc:7561
#3 0x00007fffeeb931ce in gfx::GLSurfaceEGL::InitializeOneOff () at
../../ui/gl/gl_surface_egl.cc:382
#4 0x00007fffeeb76040 in gfx::GLSurface::InitializeOneOffInternal () at
../../ui/gl/gl_surface_x11.cc:67
#5 0x00007fffeeb719e1 in gfx::GLSurface::InitializeOneOffImplementation
(impl=gfx::kGLImplementationEGLGLES2, fallback_to_osmesa=false,
gpu_service_logging=false, disable_gl_drawing=false) at
../../ui/gl/gl_surface.cc:79
#6 0x00007fffeeb7195e in gfx::GLSurface::InitializeOneOff () at
../../ui/gl/gl_surface.cc:70
#7 0x00007ffff07e93d9 in content::GpuChildThread::GpuChildThread
(this=0x300e18735b20, params=..., __in_chrg=<optimized out>,
__vtt_parm=<optimized out>) at ../../content/gpu/gpu_child_thread.cc:97
#8 0x00007ffff07f0453 in content::InProcessGpuThread::Init
(this=0x300e1835e3e0) at ../../content/gpu/in_process_gpu_thread.cc:26
#9 0x00007ffff5ad0c9a in base::Thread::ThreadMain (this=0x300e1835e3e0) at
../../base/threading/thread.cc:239
#10 0x00007ffff5abe717 in base::(anonymous namespace)::ThreadFunc
(params=0x7fffd63bb860) at ../../base/threading/platform_thread_posix.cc:77
#11 0x00007fffe8a68182 in start_thread () from
/lib/x86_64-linux-gnu/libpthread.so.0
#12 0x00007fffe879547d in clone () from /lib/x86_64-linux-gnu/libc.so.6</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the QA Contact for the bug.</li>
</ul>
</body>
</html>