[Bug 32455] New: Crash with mame using OpenGL with newest Gallium on Radeon 4350

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Thu Dec 16 14:01:39 PST 2010


https://bugs.freedesktop.org/show_bug.cgi?id=32455

           Summary: Crash with mame using OpenGL with newest Gallium on
                    Radeon 4350
           Product: Mesa
           Version: git
          Platform: All
        OS/Version: Linux (All)
            Status: NEW
          Severity: critical
          Priority: medium
         Component: Drivers/Gallium/r600
        AssignedTo: dri-devel at lists.freedesktop.org
        ReportedBy: bitbytebit at gmail.com


This is a backtrace of the issue, seems the first buffer is 0x0 and crashing on
that in the r600g Gallium driver.  This is running the newest Mame using
OpenGL, Linux-Next, everything basically from GIT and newest up to date code.

I suspect something in Mame might be causing the first buffer to be NULL, but
not sure and it works on Classic so something is different in Gallium I am
guessing.  

arcade mesa # lspci -v -s 01:00.0
01:00.0 VGA compatible controller: ATI Technologies Inc RV710 [Radeon HD 4350]
(prog-if 00 [VGA controller])
    Subsystem: Diamond Multimedia Systems Device 4350
    Flags: bus master, fast devsel, latency 0, IRQ 41
    Memory at d0000000 (64-bit, prefetchable) [size=256M]
    Memory at c8b00000 (64-bit, non-prefetchable) [size=64K]
    I/O ports at 2000 [size=256]
    [virtual] Expansion ROM at e01e0000 [disabled] [size=128K]
    Capabilities: [50] Power Management version 3
    Capabilities: [58] Express Legacy Endpoint, MSI 00
    Capabilities: [a0] MSI: Enable+ Count=1/1 Maskable- 64bit+
    Capabilities: [100] Vendor Specific Information <?>
    Kernel driver in use: radeon
    Kernel modules: radeon

Linux arcade 2.6.37-rc5-next-20101213 #1 SMP Tue Dec 14 18:23:46 CST 2010 i686
Intel(R) Core(TM)2 CPU 6300 @ 1.86GHz GenuineIntel GNU/Linux

(gdb) run pacman -verbose
Starting program: /mnt/livecd/usr/games/bin/mame pacman -verbose
[Thread debugging using libthread_db enabled]
Parsing mame.ini
[New Thread 0xb6f4db70 (LWP 25175)]
Build version:      0.140u2 (Dec 16 2010)
Build architecure:  SDLMAME_ARCH= 
Build defines 1:    SDLMAME_UNIX=1 SDLMAME_X11=1 SDLMAME_LINUX=1 
Build defines 1:    LSB_FIRST=1 MAME_DEBUG=1 DISTRO=generic
SYNC_IMPLEMENTATION=tc 
SDL/OpenGL defines: SDL_COMPILEDVERSION=1214 USE_OPENGL=1 USE_DISPATCH_GL=1 
Compiler defines A: __GNUC__=4 __GNUC_MINOR__=4 __GNUC_PATCHLEVEL__=4
__VERSION__="4.4.4" 
Compiler defines B: __unix__=1 __i386__=1 
Compiler defines C: __USE_FORTIFY_LEVEL=0 
SDL Device Driver     : x11
SDL Monitor Dimensions: 648 x 480
Enter sdlwindow_init
Using SDL single-window OpenGL driver (SDL 1.2)
Leave sdlwindow_init
 648x 480 -> 0.001621
Loaded opengl shared library: <default>
Mesa warning: couldn't open libtxc_dxtn.so, software DXTn
compression/decompression unavailable
OpenGL: X.Org
OpenGL: Gallium 0.4 on AMD RV710
OpenGL: 2.1 Mesa 7.10-devel
OpenGL: texture rectangle supported
OpenGL: non-power-of-2 textures supported (new method)
OpenGL: vertex buffer supported
OpenGL: pixel buffers supported
OpenGL: framebuffer object supported
OpenGL: GLSL supported, but disabled
OpenGL: max texture size 8192 x 8192
Keyboard: Start initialization
Input: Adding Kbd #1: System keyboard
Keyboard: Registered System keyboard
Keyboard: End initialization
Mouse: Start initialization
Input: Adding Mouse #1: System mouse
Mouse: Registered System mouse
Mouse: End initialization

Joystick: Start initialization
Joystick: End initialization
Audio: Start initialization
Audio: Driver is alsa
[New Thread 0xb565eb70 (LWP 25176)]
Audio: frequency: 48000, channels: 2, samples: 1024
sdl_create_buffers: creating stream buffer of 57344 bytes
Audio: End initialization
ouput: unable to open output notifier file /tmp/sdlmame_out
Input: Changing default joystick map = s8.4s8.44s8.4445
  s8888888s
  4s88888s6
  44s888s66
  444555666
  444555666
  444555666
  44s222s66
  4s22222s6
  s2222222s
Input: Changing default joystick map = s8.4s8.44s8.4445
  s8888888s
  4s88888s6
  44s888s66
  444555666
  444555666
  444555666
  44s222s66
  4s22222s6
  s2222222s
Matching font: /usr/share/fonts/liberation-fonts/LiberationSans-Regular.ttf
 648x 480 -> 0.001621
Starting Driver Device 'root'
  (missing dependencies; rescheduling)
Starting Z80 'maincpu'
Starting Video Screen 'screen'
Starting Speaker 'mono'
  (missing dependencies; rescheduling)
Starting Namco 'namco'
Starting Driver Device 'root'
  (missing dependencies; rescheduling)
Starting Speaker 'mono'

Starting Driver Device 'root'
OpenGL: VBO supported
OpenGL: PBO supported
OpenGL: FBO supported
OpenGL: using vid filter: 0
GL texture: copy 1, shader 0, dynamic 1, 288x224 288x224 [PALETTE16, Equal: 0,
Palette: 1,
            scale 1x1, border 0, pitch 384,288/8192], colors: 512, bytes/pix 4

Program received signal SIGSEGV, Segmentation fault.
0xb5c01eec in r600_buffer_is_user_buffer (buffer=0x0) at r600_resource.h:103
103    r600_resource.h: No such file or directory.
    in r600_resource.h
(gdb) backtrace 
#0  0xb5c01eec in r600_buffer_is_user_buffer (buffer=0x0) at
r600_resource.h:103
#1  0xb5c0247b in r600_set_vertex_buffers (ctx=0xe0aadc0, count=1,
buffers=0xbfffe9fc) at r600_state_common.c:191
#2  0xb5ced384 in st_draw_vbo (ctx=0xe484218, arrays=0xe4b0468,
prims=0xbfffec5c, nr_prims=1, ib=0x0, index_bounds_valid=1 '\001', min_index=0, 
    max_index=3) at state_tracker/st_draw.c:701
#3  0xb5ce692a in vbo_draw_arrays (ctx=0xe484218, mode=7, start=0, count=4,
numInstances=1) at vbo/vbo_exec_array.c:588
#4  0xb5ce6a67 in vbo_exec_DrawArrays (mode=7, start=0, count=4) at
vbo/vbo_exec_array.c:619
#5  0x08fd463f in drawogl_window_draw (window=0xdf9cdf8, dc=0, update=1) at
src/osd/sdl/drawogl.c:1525
#6  0x08fc5090 in draw_video_contents_wt (param=0xdfb58e8, threadid=0) at
src/osd/sdl/window.c:1233
#7  0x08fc2e7f in execute_async (callback=0x8fc4f7f <draw_video_contents_wt>,
wp=0xbfffee3c) at src/osd/sdl/window.c:160
#8  0x08fc4781 in sdlwindow_video_window_update (machine=0xdfb1aa0,
window=0xdf9cdf8) at src/osd/sdl/window.c:1009
#9  0x08f9f281 in sdl_osd_interface::update (this=0xbffff3a0,
skip_redraw=false) at src/osd/sdl/video.c:346
#10 0x0984308f in video_manager::frame_update (this=0xe4c1670, debug=false) at
src/emu/video.c:253
#11 0x0981551d in screen_device::vblank_begin_callback (this=0xdf748f8) at
src/emu/screen.c:799
#12 0x098164f2 in screen_device::static_vblank_begin_callback
(machine=0xdfb1aa0, ptr=0xdf748f8, param=0) at src/emu/screen.h:207
#13 0x098297d2 in timer_execute_timers (machine=0xdfb1aa0) at
src/emu/timer.c:389
#14 0x098116bd in device_scheduler::timeslice (this=0xdfb23dc) at
src/emu/schedule.c:244
#15 0x097b3fe1 in running_machine::run (this=0xdfb1aa0, firstrun=true) at
src/emu/machine.c:412
#16 0x097b1131 in mame_execute (osd=..., options=0xdfa2498) at
src/emu/mame.c:203
#17 0x0973fe2d in cli_execute (argc=3, argv=0xbffff474, osd=...,
osd_options=0xada9460) at src/emu/clifront.c:175
#18 0x08f9a37c in main (argc=3, argv=0xbffff474) at src/osd/sdl/sdlmain.c:328




(gdb) bt full

#0  0xb5c01eec in r600_buffer_is_user_buffer (buffer=0x0) at
r600_resource.h:103
No locals.
#1  0xb5c0247b in r600_set_vertex_buffers (ctx=0xe0aadc0, count=1,
buffers=0xbfffe9fc) at r600_state_common.c:191
        i = 0
        rctx = 0xe0aadc0
        vbo = 0xbfffe9fc
        max_index = 4294967295
#2  0xb5ced384 in st_draw_vbo (ctx=0xe484218, arrays=0xe4b0468,
prims=0xbfffec5c, nr_prims=1, ib=0x0, index_bounds_valid=1 '\001', min_index=0, 
    max_index=3) at state_tracker/st_draw.c:701
        st = 0xe4ad880
        pipe = 0xe0aadc0
        vp = 0xe9086f0
        vpv = 0xe8f4db8
        vbuffer = {{stride = 8, max_index = 3, buffer_offset = 0, buffer =
0x0}, {stride = 27394048, max_index = 1, buffer_offset = 9584641, 
            buffer = 0x1248001}, {stride = 28753921, max_index = 3059970036,
buffer_offset = 244352752, buffer = 0xbfffea78}, {stride = 3050865665, 
            max_index = 3221220076, buffer_offset = 27394050, buffer =
0xbfffea58}, {stride = 27394049, max_index = 3, buffer_offset = 8, 
            buffer = 0xbfffea78}, {stride = 3050862229, max_index = 3073952510,
buffer_offset = 3059184192, buffer = 0x62f}, {stride = 27394070, 
            max_index = 27394086, buffer_offset = 3073952510, buffer =
0xe8f7b08}, {stride = 3059970036, max_index = 3059970036, 
            buffer_offset = 244352752, buffer = 0xbfffeab8}, {stride =
3074823052, max_index = 3, buffer_offset = 16, buffer = 0x6}, {stride = 64, 
            max_index = 3074823064, buffer_offset = 6, buffer = 0x2c}, {stride
= 3059184192, max_index = 3074690840, buffer_offset = 20, 
            buffer = 0xb74613b8}, {stride = 3074690564, max_index = 3074691314,
buffer_offset = 48, buffer = 0xb745fff4}, {stride = 0, 
            max_index = 3074823040, buffer_offset = 3221220088, buffer =
0xb74613b0}, {stride = 3074818036, max_index = 3074823040, buffer_offset = 0, 
            buffer = 0xbfffeaf8}, {stride = 3073962252, max_index = 16,
buffer_offset = 244370256, buffer = 0x204b0}, {stride = 3059970036, 
            max_index = 3061087648, buffer_offset = 0, buffer = 0x0}, {stride =
3050328421, max_index = 244272520, buffer_offset = 3221220192, 
            buffer = 0x2c}, {stride = 13, max_index = 13, buffer_offset = 13,
buffer = 0x11}, {stride = 0, max_index = 0, buffer_offset = 244352752, 
            buffer = 0x9d60251c}, {stride = 234445880, max_index = 3059970036,
buffer_offset = 3061087648, buffer = 0xbfffeb98}, {stride = 3050879936, 
            max_index = 239616536, buffer_offset = 234567304, buffer =
0xbfffeb60}, {stride = 44, max_index = 244352752, buffer_offset = 234622136, 
            buffer = 0xbfffeb88}, {stride = 3051056141, max_index = 239616536,
buffer_offset = 138412032, buffer = 0x101}, {stride = 16, max_index = 0, 
            buffer_offset = 0, buffer = 0xbfffeb98}, {stride = 239790520,
max_index = 3051171495, buffer_offset = 3059970036, buffer = 0xbfffeba8}, {
            stride = 3051055507, max_index = 239616536, buffer_offset =
138412032, buffer = 0x8}, {stride = 3049939911, max_index = 239616536, 
            buffer_offset = 3059970036, buffer = 0xbfffebd8}, {stride =
3050223256, max_index = 239616536, buffer_offset = 138412032, 
            buffer = 0xbfffebd8}, {stride = 3049938678, max_index = 2000000000,
buffer_offset = 234554628, buffer = 0xb7f15319}, {stride = 239786112, 
            max_index = 16, buffer_offset = 3059970036, buffer = 0xbfffec08},
{stride = 3059970036, max_index = 3061087648, buffer_offset = 0, 
            buffer = 0xbfffec08}, {stride = 3050004713, max_index = 233940708,
buffer_offset = 138412032, buffer = 0x9cc2505}}
        attr = 3049941235

        velements = {{src_offset = 235552416, instance_divisor = 0,
vertex_buffer_index = 0, src_format = PIPE_FORMAT_R32G32_FLOAT}, {src_offset =
0, 
            instance_divisor = 0, vertex_buffer_index = 0, src_format =
PIPE_FORMAT_R32G32_FLOAT}, {src_offset = 0, instance_divisor = 0, 
            vertex_buffer_index = 0, src_format = PIPE_FORMAT_NONE},
{src_offset = 0, instance_divisor = 0, vertex_buffer_index = 0, 
            src_format = PIPE_FORMAT_NONE}, {src_offset = 0, instance_divisor =
0, vertex_buffer_index = 0, src_format = PIPE_FORMAT_NONE}, {
            src_offset = 0, instance_divisor = 0, vertex_buffer_index = 0,
src_format = PIPE_FORMAT_NONE}, {src_offset = 0, instance_divisor = 0, 
            vertex_buffer_index = 3073952510, src_format = PIPE_FORMAT_NONE},
{src_offset = 0, instance_divisor = 0, vertex_buffer_index = 0, 
            src_format = PIPE_FORMAT_NONE}, {src_offset = 0, instance_divisor =
0, vertex_buffer_index = 0, src_format = PIPE_FORMAT_B5G5R5A1_UNORM}, {
            src_offset = 56, instance_divisor = 3074823060, vertex_buffer_index
= 5, src_format = PIPE_FORMAT_R32G32B32_UNORM}, {src_offset = 0, 
            instance_divisor = 3074690840, vertex_buffer_index = 0, src_format
= 3074823096}, {src_offset = 3074690564, instance_divisor = 3074691314, 
            vertex_buffer_index = 40, src_format = PIPE_FORMAT_NONE},
{src_offset = 0, instance_divisor = 3074823040, vertex_buffer_index = 0, 
            src_format = 3074823088}, {src_offset = 3074818036,
instance_divisor = 3074823040, vertex_buffer_index = 244352752, src_format =
3221219576}, 
---Type <return> to continue, or q <return> to quit--- 
          {src_offset = 3073962252, instance_divisor = 0, vertex_buffer_index =
0, src_format = 3073948022}, {src_offset = 3059970036, 
            instance_divisor = 3221219852, vertex_buffer_index = 244352752,
src_format = 3221219624}, {src_offset = 3049429450, 
            instance_divisor = 244272480, vertex_buffer_index = 244271440,
src_format = PIPE_FORMAT_NONE}, {src_offset = 0, instance_divisor = 0, 
            vertex_buffer_index = 0, src_format = PIPE_FORMAT_R32G32_UNORM},
{src_offset = 244272480, instance_divisor = 0, 
            vertex_buffer_index = 27394177, src_format = 3221219704},
{src_offset = 3050860887, instance_divisor = 3221219772, vertex_buffer_index =
1, 
            src_format = PIPE_FORMAT_R10G10B10A2_UNORM}, {src_offset =
244352752, instance_divisor = 3221219672, vertex_buffer_index = 3073962045, 
            src_format = 3221219704}, {src_offset = 3050862229,
instance_divisor = 244284112, vertex_buffer_index = 3059184463, src_format =
705}, {
            src_offset = 244352752, instance_divisor = 4294967295,
vertex_buffer_index = 4, src_format = 244284112}, {src_offset = 1, 
            instance_divisor = 3059970036, vertex_buffer_index = 16, src_format
= 3221219784}, {src_offset = 3050864047, instance_divisor = 3221220076, 
            vertex_buffer_index = 45, src_format = 27394114}, {src_offset = 0,
instance_divisor = 27394177, vertex_buffer_index = 13, 
            src_format = PIPE_FORMAT_L16_UNORM}, {src_offset = 3059184463,
instance_divisor = 705, vertex_buffer_index = 3059184544, src_format = 665}, {
            src_offset = 3221219868, instance_divisor = 28753921,
vertex_buffer_index = 3, src_format = 27394114}, {src_offset = 27394177, 
            instance_divisor = 3221219940, vertex_buffer_index = 3059970036,
src_format = 3221219960}, {src_offset = 3050877559, 
            instance_divisor = 3221220076, vertex_buffer_index = 8, src_format
= PIPE_FORMAT_X8R8G8B8_UNORM}, {src_offset = 0, 
            instance_divisor = 28753921, vertex_buffer_index = 27394102,
src_format = 27394048}, {src_offset = 3059184544, instance_divisor = 665, 
            vertex_buffer_index = 3, src_format = PIPE_FORMAT_R8G8_B8G8_UNORM}}
        num_vbuffers = 1
        num_velements = 2
        ibuffer = {index_size = 0, offset = 0, buffer = 0x0}
        userSpace = 0 '\000'
        vertDataEdgeFlags = 0 '\000'
        info = {indexed = 0 '\000', mode = 0, start = 0, count = 0,
start_instance = 0, instance_count = 0, index_bias = 0, min_index = 0,
max_index = 0, 
          primitive_restart = 0 '\000', restart_index = 0}
        i = 239620080

        __FUNCTION__ = "st_draw_vbo"
#3  0xb5ce692a in vbo_draw_arrays (ctx=0xe484218, mode=7, start=0, count=4,
numInstances=1) at vbo/vbo_exec_array.c:588
        vbo = 0xe4ae118
        exec = 0xe4ae9b8
        prim = {{mode = 7, indexed = 0, begin = 1, end = 1, weak = 0,
no_current_update = 1, pad = 0, start = 0, count = 4, basevertex = 0, 
            num_instances = 1}, {mode = 24, indexed = 0, begin = 1, end = 0,
weak = 0, no_current_update = 0, pad = 29250, start = 1, count = 3221220504, 
            basevertex = -1244223421, num_instances = 239616536}}
#4  0xb5ce6a67 in vbo_exec_DrawArrays (mode=7, start=0, count=4) at
vbo/vbo_exec_array.c:619
        ctx = 0xe484218
        __FUNCTION__ = "vbo_exec_DrawArrays"
#5  0x08fd463f in drawogl_window_draw (window=0xdf9cdf8, dc=0, update=1) at
src/osd/sdl/drawogl.c:1525
        i = 0
        vofs = 96
        pendingPrimitive = -1
        is_vector = 0
        prim = 0xe8db8e0
        texture = 0xe8ebcc0
        scrnum = 0
        screen = 0xdf295c0
        sdl = 0xe0a1df0
        hofs = 100
        curPrimitive = -1
---Type <return> to continue, or q <return> to quit---
#6  0x08fc5090 in draw_video_contents_wt (param=0xdfb58e8, threadid=0) at
src/osd/sdl/window.c:1233
        dc = 0
        update = 1
        wp = 0xdfb58e8
        window = 0xdf9cdf8
#7  0x08fc2e7f in execute_async (callback=0x8fc4f7f <draw_video_contents_wt>,
wp=0xbfffee3c) at src/osd/sdl/window.c:160
        wp_temp = 0xdfb58e8
#8  0x08fc4781 in sdlwindow_video_window_update (machine=0xdfb1aa0,
window=0xdf9cdf8) at src/osd/sdl/window.c:1009
        wp = {window = 0xdf9cdf8, list = 0xe0a0cdc, machine = 0xdfb1aa0,
resize_new_width = 0, resize_new_height = 0}
        primlist = 0xe0a0cdc
        tempwidth = 224
        tempheight = 288
#9  0x08f9f281 in sdl_osd_interface::update (this=0xbffff3a0,
skip_redraw=false) at src/osd/sdl/video.c:346
        window = 0xdf9cdf8
#10 0x0984308f in video_manager::frame_update (this=0xe4c1670, debug=false) at
src/emu/video.c:253
        phase = 3
        skipped_it = false
        current_time = {seconds = 0, attoseconds = 16499999999932416}
#11 0x0981551d in screen_device::vblank_begin_callback (this=0xdf748f8) at
src/emu/screen.c:799

No locals.
#12 0x098164f2 in screen_device::static_vblank_begin_callback
(machine=0xdfb1aa0, ptr=0xdf748f8, param=0) at src/emu/screen.h:207
No locals.
#13 0x098297d2 in timer_execute_timers (machine=0xdfb1aa0) at
src/emu/timer.c:389
        was_enabled = 1
        global = 0xe086390
        timer = 0xe0864e0
#14 0x098116bd in device_scheduler::timeslice (this=0xdfb23dc) at
src/emu/schedule.c:244
        call_debugger = false
        timerexec = 0xe08b79c
#15 0x097b3fe1 in running_machine::run (this=0xdfb1aa0, firstrun=true) at
src/emu/machine.c:412
        settingsloaded = false
        error = 0
#16 0x097b1131 in mame_execute (osd=..., options=0xdfa2498) at
src/emu/mame.c:203
        gamename = {<_astring_base> = {text = 0xbffff13c "pacman", alloclen =
56, 
            smallbuf =
"pacman\000\277\373w7\267pa\371\r\006\341\372\nh\361\377\277\364\377E\267\230\361\377\277\300\200\305\tpa\371\r\006\341\372\n\210\361\377\277\006\000\000\000@\362\377\277"},
<No data fields>}
        driver = 0xa6be760
        config = 0xdf9a390
        machine = 0xdfb1aa0
        firstgame = false
        firstrun = true
        exit_pending = false
        error = 0
#17 0x0973fe2d in cli_execute (argc=3, argv=0xbffff474, osd=...,
osd_options=0xada9460) at src/emu/clifront.c:175
        gamename_option = 0xdfa0820 "pacman"
        driver = 0xa6be760
---Type <return> to continue, or q <return> to quit---
        exename = {<_astring_base> = {text = 0xbffff200 "mame", alloclen = 56, 
            smallbuf =
"mame\000\000\000\000k\035\356\267\364\237\360\267\364\237\360\267\000\000\000\000\240\362\377\277\\\362\377\277h\362\377\277\300+\367\r\340\370\377\267\000\000\000\000X~\355\r\365\270\357\267"},
<No data fields>}
        options = 0xdfa2498
        result = -1
        gamename = {<_astring_base> = {text = 0xbffff240 "pacman", alloclen =
56, 
            smallbuf =
"pacman\000\000\rH\356\267\364\237\360\267X~\355\r(\312\355\r\210\362\377\277\bz\362\267
\t\376\267(\312\355\r\377\377\377\377\304\357\377\267@\252\004\b\001\000\000"},
<No data fields>}
#18 0x08f9a37c in main (argc=3, argv=0xbffff474) at src/osd/sdl/sdlmain.c:328
        osd = {<osd_interface> = {_vptr.osd_interface = 0xada9a28, m_machine =
0xdfb1aa0}, <No data fields>}
        res = 0

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the dri-devel mailing list