[Mesa-dev] SIGFPE in libdrm_radeon on evergreen

Vadim Girlin vadimgirlin at gmail.com
Mon May 20 02:13:02 PDT 2013


On 05/20/2013 11:27 AM, Dragomir Ivanov wrote:
> 0x00007ffff69058d7 in eg_surface_init_2d (surf_man=0x633ea0, surf=0x88d848,
> level=0x88dea8, bpe=1, tile_split=0, offset=65536, start_level=0)
>
> It looks like division by 0. tile_split=0 from the call site.

Yes, I'm just not sure why tile_split is 0 here and what is the best way 
to fix it, possibly in fact this is a consequence of some problem in 
r600g, not in the libdrm. Though probably libdrm should handle it more 
gracefully anyway.

Vadim

>
>
> On Mon, May 20, 2013 at 4:11 AM, Vadim Girlin <vadimgirlin at gmail.com> wrote:
>
>> Reduced test app attached and below is gdb backtrace. I suspect something
>> is not initialized properly but I'm not very familiar with this code.
>>
>> Vadim
>>
>>
>> Program received signal SIGFPE, Arithmetic exception.
>> 0x00007ffff69058d7 in eg_surface_init_2d (surf_man=0x633ea0,
>> surf=0x88d848, level=0x88dea8, bpe=1, tile_split=0, offset=65536,
>> start_level=0)
>>       at radeon_surface.c:651
>> 651             slice_pt = tileb / tile_split;
>>
>> #0  0x00007ffff69058d7 in eg_surface_init_2d (surf_man=0x633ea0,
>> surf=0x88d848, level=0x88dea8, bpe=1, tile_split=0, offset=65536,
>> start_level=0)
>>       at radeon_surface.c:651
>> #1  0x00007ffff6905eea in eg_surface_init_2d_miptrees (surf_man=0x633ea0,
>> surf=0x88d848) at radeon_surface.c:807
>> #2  0x00007ffff6906062 in eg_surface_init (surf_man=0x633ea0,
>> surf=0x88d848) at radeon_surface.c:863
>> #3  0x00007ffff6907fe6 in radeon_surface_init (surf_man=0x633ea0,
>> surf=0x88d848) at radeon_surface.c:1901
>> #4  0x00007ffff713260b in radeon_drm_winsys_surface_init (rws=0x6339a0,
>> surf=0x88d848) at radeon_drm_winsys.c:477
>> #5  0x00007ffff70a3e1c in r600_setup_surface (screen=0x6340d0,
>> rtex=0x88d760, pitch_in_bytes_override=0) at r600_texture.c:203
>> #6  0x00007ffff70a4774 in r600_texture_create_object (screen=0x6340d0,
>> base=0x7fffffffd6d0, pitch_in_bytes_override=0, buf=0x0,
>> surface=0x7fffffffc8e0)
>>       at r600_texture.c:432
>> #7  0x00007ffff70a5268 in r600_texture_create (screen=0x6340d0,
>> templ=0x7fffffffd6d0) at r600_texture.c:607
>> #8  0x00007ffff708a5bd in r600_resource_create (screen=0x6340d0,
>> templ=0x7fffffffd6d0) at r600_resource.c:38
>> #9  0x00007ffff7125579 in dri2_drawable_process_buffers
>> (drawable=0x88af80, buffers=0x88aea0, buffer_count=1, atts=0x88b628,
>> att_count=2) at dri2.c:283
>> #10 0x00007ffff712590a in dri2_allocate_textures (drawable=0x88af80,
>> statts=0x88b628, statts_count=2) at dri2.c:404
>> #11 0x00007ffff7123e6a in dri_st_framebuffer_validate (stfbi=0x88af80,
>> statts=0x88b628, count=2, out=0x7fffffffd840) at dri_drawable.c:81
>> #12 0x00007ffff6e461c1 in st_framebuffer_validate (stfb=0x88b1e0,
>> st=0x883870) at ../../src/mesa/state_tracker/**st_manager.c:193
>> #13 0x00007ffff6e472a8 in st_api_make_current (stapi=0x7ffff761b9e0
>> <st_gl_api>, stctxi=0x883870, stdrawi=0x88af80, streadi=0x88af80)
>>       at ../../src/mesa/state_tracker/**st_manager.c:721
>> #14 0x00007ffff7122ce8 in dri_make_current (cPriv=0x7fdb70,
>> driDrawPriv=0x88af40, driReadPriv=0x88af40) at dri_context.c:255
>> #15 0x00007ffff6c6ba1f in driBindContext (pcp=0x7fdb70, pdp=0x88af40,
>> prp=0x88af40) at ../../../../src/mesa/drivers/**dri/common/dri_util.c:382
>> #16 0x00007ffff7dc57e3 in dri2_bind_context (context=0x7fd9d0,
>> old=0x616650, draw=67108873, read=67108873) at dri2_glx.c:172
>> #17 0x00007ffff7d8c253 in MakeContextCurrent (dpy=0x602040, draw=67108873,
>> read=67108873, gc_user=0x7fd9d0) at glxcurrent.c:269
>> #18 0x000000384e82713c in fgOpenWindow () from /lib64/libglut.so.3
>> #19 0x000000384e825afa in fgCreateWindow () from /lib64/libglut.so.3
>> #20 0x000000384e825b95 in fgCreateMenu () from /lib64/libglut.so.3
>> #21 0x000000384e823cd3 in glutCreateMenu () from /lib64/libglut.so.3
>> #22 0x0000000000400816 in main (argc=1, argv=0x7fffffffdf18) at test.c:17
>>
>>
>> _______________________________________________
>> mesa-dev mailing list
>> mesa-dev at lists.freedesktop.org
>> http://lists.freedesktop.org/mailman/listinfo/mesa-dev
>>
>>
>



More information about the mesa-dev mailing list