[Mesa-dev] [Mesa3d-dev] mesa commit e648d4a1d1c0c5f70916e38366b863f0bec79a62 st/mesa: ignore gl_texture_object::BaseLevel when allocating gallium textures

Maxim Levitsky maximlevitsky at gmail.com
Mon May 3 16:10:11 PDT 2010


On Mon, 2010-05-03 at 16:48 -0600, Brian Paul wrote: 
> Maxim Levitsky wrote:
> > On Mon, 2010-05-03 at 15:18 -0600, Brian Paul wrote: 
> >> Maxim Levitsky wrote:
> >>> On Mon, 2010-05-03 at 13:11 -0600, Brian Paul wrote: 
> >>>> Xavier Chantry wrote:
> >>>>> On Sun, May 2, 2010 at 3:16 PM, Marek Olšák <maraeo at gmail.com> wrote:
> >>>>>> On Sat, May 1, 2010 at 11:31 PM, Maxim Levitsky <maximlevitsky at gmail.com>
> >>>>>> wrote:
> >>>>>>> This commit breaks compiz completely here on nvidia G50 (Geforce 8400M)
> >>>>>>> Compiz shows dark screen.
> >>>>>>> (Using nouveau drivers)
> >>>>>>>
> >>>>>>> Without this commit compiz works almost perfectly.
> >>>>>>>
> >>>>>>> The error messages from compiz:
> >>>>>>>
> >>>>>>>
> >>>>>>> debug_get_bool_option: NV50_ALWAYS_PUSH = FALSE
> >>>>>>> debug_get_bool_option: DRAW_FSE = FALSE
> >>>>>>> debug_get_bool_option: DRAW_NO_FSE = FALSE
> >>>>>>> debug_get_bool_option: GALLIUM_DUMP_VS = FALSE
> >>>>>>> Mesa: Mesa 7.9-devel DEBUG build May  1 2010 19:02:06
> >>>>>>> Mesa warning: software DXTn compression/decompression available
> >>>>>>> debug_get_bool_option: MESA_MVP_DP4 = FALSE
> >>>>>>> debug_get_flags_option: ST_DEBUG = 0x0
> >>>>>>> Mesa: User error: GL_OUT_OF_MEMORY in glTexImage
> >>>>>>> compiz (cube) - Warn: Failed to load
> >>>>>>> slide: /usr/share/gdm/themes/Human/ubuntu.png
> >>>>>>> ^CMesa: User error: GL_OUT_OF_MEMORY in glTexImage
> >>>>>> The commit also causes surface_copy to be called with S3TC textures,
> >>>>>> breaking loading of such textures in r300g. I am working on a fix for r300g
> >>>>>> but I haven't expected to get such weird formats in surface_copy.
> >>>>>>
> >>>>>> FYI Maxim, please use mesa-dev at lists.freedesktop.org instead.
> >>>>>>
> >>>>>> -Marek
> >>>>>>
> >>>>> This commit also causes piglit fbo-3d test to fail with both llvmpipe
> >>>>> and nv50 gallium.
> >>>>> http://img163.imageshack.us/img163/535/fbo3d.png
> >>>> Can you retest now?
> >>> Nope, still same error.
> >> Both compiz and fbo-3d?
> > 
> > Didn't test fbo-3d, but compiz fails:
> > 
> > Breakpoint 1, _mesa_error (ctx=0x949690, error=1285, fmtString=0x7ffff34d8341 "glTexImage") at main/imports.c:1005
> > 1005	{
> > (gdb) bt
> > #0  _mesa_error (ctx=0x949690, error=1285, fmtString=0x7ffff34d8341 "glTexImage") at main/imports.c:1005
> > #1  0x00007ffff3417504 in st_finalize_texture (ctx=0x949690, pipe=<value optimized out>, tObj=0xcb1a80, 
> >     needFlush=<value optimized out>) at state_tracker/st_cb_texture.c:1920
> > #2  0x00007ffff340830a in finalize_textures (st=0x991f80) at state_tracker/st_atom_texture.c:145
> > #3  0x00007ffff34045d9 in st_validate_state (st=0x991f80) at state_tracker/st_atom.c:167
> > #4  0x00007ffff33d5b2a in st_draw_vbo (ctx=<value optimized out>, arrays=0x9956c8, prims=<value optimized out>, 
> >     nr_prims=<value optimized out>, ib=0xcc49b0, index_bounds_valid=0 '\000', min_index=0, max_index=15)
> >     at state_tracker/st_draw.c:577
> > #5  0x00007ffff33fcf84 in vbo_exec_DrawArrays (mode=7, start=0, count=<value optimized out>)
> >     at vbo/vbo_exec_array.c:525
> > #6  0x0000000000427c9e in ?? ()
> > #7  0x0000000000427afb in drawWindowTexture ()
> > #8  0x0000000000427013 in drawWindow ()
> > #9  0x00007fffef6bbd4f in ?? () from /usr/lib/compiz/libdecoration.so
> > #10 0x0000000000426ef9 in paintWindow ()
> > #11 0x00007fffefcd0988 in ?? () from /usr/lib/compiz/libmove.so
> > #12 0x00007fffefacaa80 in ?? () from /usr/lib/compiz/libresize.so
> > #13 0x0000000000428c3d in ?? ()
> > #14 0x00000000004299b5 in paintOutput ()
> > #15 0x00007fffefacaee0 in ?? () from /usr/lib/compiz/libresize.so
> > #16 0x0000000000410b67 in paintScreen ()
> > #17 0x0000000000412a35 in eventLoop ()
> > #18 0x000000000040d8e9 in main ()
> > (gdb) q
> > A debugging session is active.
> 
> Can you recompile for debugging and step into the st_texture_create() 
> call and find out why it's failing?  At least print out the parameters 
> to that function call.  Thanks.

Breakpoint 1, st_texture_create (st=0x991ec0, target=PIPE_TEXTURE_2D, format=PIPE_FORMAT_I8_UNORM, last_level=0, width0=512, height0=32, depth0=1, bind=4) at state_tracker/st_texture.c:64
64	{
#0  st_texture_create (st=0x991ec0, target=PIPE_TEXTURE_2D, format=PIPE_FORMAT_I8_UNORM, last_level=0, width0=512, height0=32, depth0=1, bind=4) at state_tracker/st_texture.c:64
#1  0x00007ffff3409224 in reset_cache (st=0x991ec0) at state_tracker/st_cb_bitmap.c:542
#2  0x00007ffff33d519e in st_create_context_priv (pipe=0x900370, visual=<value optimized out>, share=<value optimized out>) at state_tracker/st_context.c:149
#3  st_create_context (pipe=0x900370, visual=<value optimized out>, share=<value optimized out>) at state_tracker/st_context.c:219
#4  0x00007ffff3398bd7 in st_api_create_context (stapi=<value optimized out>, smapi=0x9123e0, visual=0x7fffffffd2a0, shared_stctxi=0x0) at state_tracker/st_manager.c:589
#5  0x00007ffff32a0d5e in dri_create_context (api=<value optimized out>, visual=0x931740, cPriv=<value optimized out>, sharedContextPrivate=<value optimized out>) at dri_context.c:79
#6  0x00007ffff329aeda in dri2CreateNewContextForAPI (screen=0x912170, api=0, config=0x931740, shared=<value optimized out>, data=0x200) at ../../../../src/mesa/drivers/dri/common/dri_util.c:662
#7  0x00007ffff63be1c9 in dri2CreateContext (psc=0x900090, mode=0x904700, gc=0x900160, shareList=<value optimized out>, renderType=<value optimized out>) at dri2_glx.c:150
#8  0x00007ffff6395905 in CreateContext (dpy=0x64ed00, generic_id=33, fbconfig=<value optimized out>, shareList=0x0, allowDirect=<value optimized out>, code=3, renderType=32788, screen=0) at glxcmds.c:403
#9  0x00007ffff6396e38 in glXCreateContext (dpy=0x64ed00, vis=0x8f3860, shareList=0x0, allowDirect=1) at glxcmds.c:527
#10 0x00000000004196ff in addScreen ()
#11 0x0000000000412334 in addDisplay ()
#12 0x000000000040d8dc in main ()

Breakpoint 1, st_texture_create (st=0x991ec0, target=PIPE_TEXTURE_2D, format=PIPE_FORMAT_B8G8R8X8_UNORM, last_level=0, width0=0, height0=0, depth0=0, bind=6) at state_tracker/st_texture.c:64
64	{
#0  st_texture_create (st=0x991ec0, target=PIPE_TEXTURE_2D, format=PIPE_FORMAT_B8G8R8X8_UNORM, last_level=0, width0=0, height0=0, depth0=0, bind=6) at state_tracker/st_texture.c:64
#1  0x00007ffff34174e0 in st_finalize_texture (ctx=0x9495d0, pipe=<value optimized out>, tObj=0xcbbcb0, needFlush=<value optimized out>) at state_tracker/st_cb_texture.c:1910
#2  0x00007ffff340830a in finalize_textures (st=0x991ec0) at state_tracker/st_atom_texture.c:145
#3  0x00007ffff34045d9 in st_validate_state (st=0x991ec0) at state_tracker/st_atom.c:167
#4  0x00007ffff33d5b2a in st_draw_vbo (ctx=<value optimized out>, arrays=0x995608, prims=<value optimized out>, nr_prims=<value optimized out>, ib=0x0, index_bounds_valid=0 '\000', min_index=0, max_index=3) at state_tracker/st_draw.c:577
#5  0x00007ffff33fcf84 in vbo_exec_DrawArrays (mode=7, start=0, count=<value optimized out>) at vbo/vbo_exec_array.c:525
#6  0x0000000000427c9e in ?? ()
#7  0x0000000000427afb in drawWindowTexture ()
#8  0x0000000000427013 in drawWindow ()
#9  0x00007fffef6bbd4f in ?? () from /usr/lib/compiz/libdecoration.so
#10 0x0000000000426ef9 in paintWindow ()
#11 0x00007fffefcd0988 in ?? () from /usr/lib/compiz/libmove.so
#12 0x00007fffefacaa80 in ?? () from /usr/lib/compiz/libresize.so
#13 0x0000000000428c3d in ?? ()
#14 0x00000000004299b5 in paintOutput ()
#15 0x00007fffefacaee0 in ?? () from /usr/lib/compiz/libresize.so
#16 0x0000000000410b67 in paintScreen ()
#17 0x0000000000412a35 in eventLoop ()
#18 0x000000000040d8e9 in main ()
Mesa: User error: GL_OUT_OF_MEMORY in glTexImage


Even I notice that arguments looks fishy...

Best regards,
	Maxim Levitsky



More information about the mesa-dev mailing list