[Mesa-dev] segfault in pstip_bind_sampler_states

Kevin H. Hobbs hobbsk at ohio.edu
Tue Aug 13 08:45:59 PDT 2013


On 08/13/2013 09:50 AM, Brian Paul wrote:
> On 08/12/2013 11:30 AM, Kevin H. Hobbs wrote:
>> 
>> --30166-- VALGRIND INTERNAL ERROR: Valgrind received a signal 11 (SIGSEGV) - exiting
>> 
> Well, that's not too helpful.

I think it may have been helpful.

Before Valgrind crashed it mentions that
osmesa_st_framebuffer_flush_front wrote to an address it should not have.

In the test VTK uses a filter that tiles the rendering of a (not very)
large image.

The render window is initially 150x150 and then after some fooling
around magnification is set to 3.

I think this results in what I see in gdb :

res->width0     = 450
res->height0    = 450
osbuffer->width = 150
bytes           = 1800
dst_stride      = -600

If I read that last right then in the for loop we write 1800 bytes to
dst move back 600 bytes and write another 1800 bytes.

Are we overwriting 2/3 of what we just wrote?

>  Can you send me an executable?

Not quickly.

>  Or, is it 
> simple to build the test case?
> 

I loose track of what's simple and not for me there's a cron job that
just runs a bunch of scripts while I sleep.

The test is a python wrapped test so the whole hour long build of vtk is
hard to avoid.

They are attached for good measure but all I do is:

The mesa I use is built nightly with :
./autogen.sh \
  --prefix=/home/kevin/mesa_nightly \
  --enable-glx \
  --enable-dri \
  --enable-shared-glapi \
  --enable-gallium-llvm \
  --with-gallium-drivers=nouveau,swrast \
  --enable-osmesa


I have VTK cloned :
git clone http://vtk.org/VTK.git

I happen to be on the nightly-master branch for the dashboard but that
shouldn't matter.

ctest builds and tests VTK with :
ctest -S vtk_osmesa.cmake

Since you only want one test a build just like mine is :

VTK_BUILD=~/VTK_Build
VTK_SRC=~/VTK
mkdir $VTK_BUILD
cd $VTK_BUILD
cmake \
\
  -DBUILD_EXAMPLES:BOOL=ON\
  -DBUILD_SHARED_LIBS:BOOL=ON\
\
  -DVTK_BUILD_ALL_MODULES:BOOL=OFF\
  -DVTK_Group_Imaging:BOOL=ON\
  -DVTK_Group_MPI:BOOL=ON\
  -DVTK_Group_Rendering:BOOL=ON\
  -DVTK_Group_StandAlone:BOOL=ON\
  -DVTK_Group_Views:BOOL=ON\
\
  -DVTK_WRAP_JAVA:BOOL=OFF\
  -DVTK_WRAP_PYTHON:BOOL=ON\
  -DVTK_WRAP_TCL:BOOL=ON\
\
  -DOPENGL_INCLUDE_DIR:PATH=/home/kevin/mesa_nightly/include\
  -DOPENGL_gl_LIBRARY:FILEPATH=/home/kevin/mesa_nightly/lib/libGL.so\
  -DOPENGL_glu_LIBRARY:FILEPATH=/home/kevin/mesa_nightly/lib/libGLU.so\
  -DVTK_OPENGL_HAS_OSMESA:BOOL=ON\
  -DOSMESA_INCLUDE_DIR:PATH=/home/kevin/mesa_nightly/include\
  -DOSMESA_LIBRARY:FILEPATH=/home/kevin/mesa_nightly/lib/libOSMesa.so\
\
  -DVTK_USE_OFFSCREEN:BOOL=ON\
  -DVTK_USE_X:BOOL=OFF\
  -DVTK_USE_TK:BOOL=OFF\
  $VTK_SRC

and the test is :

$VTK_BUILD/bin/vtkpython "--enable-bt"
"$VTK_BUILD/Utilities/vtkTclTest2Py/rtImageTest.py"
"$VTK_SRC/Filters/Hybrid/Testing/Python/largeImageOffset.py" "-D"
"$VTK_BUILD/ExternalData/Testing" "-T" "$VTK_BUILD/Testing/Temporary"
"-V"
"$VTK_BUILD/ExternalData/Filters/Hybrid/Testing/Data/Baseline/largeImageOffset.png"
"-A" "$VTK_BUILD/Utilities/vtkTclTest2Py"


ctest usually downloads the the validation image largeImageOffset.png
and the input file mentioned in the test iflamigm.3ds

I don't know if this happens without ctest.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vtk_osmesa.cmake
Type: text/x-cmake
Size: 1349 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20130813/b7ac9394/attachment-0003.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: update_kitware.sh
Type: application/x-shellscript
Size: 2443 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20130813/b7ac9394/attachment-0004.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: update_mesa.sh
Type: application/x-shellscript
Size: 901 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20130813/b7ac9394/attachment-0005.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 255 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20130813/b7ac9394/attachment-0001.pgp>


More information about the mesa-dev mailing list