libretro / beetle-psx-libretro

Standalone port/fork of Mednafen PSX to the Libretro API.
GNU General Public License v2.0
311 stars 131 forks source link

[OpenGL] Segfault using Intel graphics #104

Open sergiobenrocha2 opened 8 years ago

sergiobenrocha2 commented 8 years ago

I'm getting segfault using Intel graphics

Core i7 4700hq 00:02.0 VGA compatible controller: Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06) Xubuntu 14.04, kernel 3.13.0-93 mesa 10.1.3

Program received signal SIGSEGV, Segmentation fault.
__memcpy_sse2_unaligned () at ../sysdeps/x86_64/multiarch/memcpy-sse2-unaligned.S:158
158 ../sysdeps/x86_64/multiarch/memcpy-sse2-unaligned.S: No such file or directory.
(gdb) 
(gdb) bt full
#0  __memcpy_sse2_unaligned () at ../sysdeps/x86_64/multiarch/memcpy-sse2-unaligned.S:158
No locals.
#1  0x00007fffcd12616c in DrawBuffer<ImageLoadVertex>::push_slice (this=0x15b12e0, slice=0x7fffffff9240, n=4) at rustation-libretro/src/renderer/../retrogl/buffer.h:304
No locals.
#2  0x00007fffcd12382c in GlRenderer::upload_textures (this=0x1519280, top_left=0x7fffffff92a0, dimensions=0x7fffffff92b0, pixel_buffer=0x7fffcc62d578)
    at rustation-libretro/src/renderer/GlRenderer.cpp:449
        x_start = 0
        y_end = 512
        _fb = {id = 1024, _color_texture = 0x1647020}
        x_end = 1024
        y_start = 0
        slice_len = 4
        slice = {{position = {0, 0}}, {position = {1024, 0}}, {position = {0, 512}}, {position = {1024, 512}}}
#3  0x00007fffcd122daa in GlRenderer::GlRenderer (this=0x1519280, config=0x14fa580) at rustation-libretro/src/renderer/GlRenderer.cpp:176
        depth = 16 '\020'
        scale_dither = true
        image_load_buffer = 0x15b12e0
        upscaling = 2 '\002'
        output_buffer = 0x159a960
        dither_scaling = 2
        fb_out = 0x1596ab0
        wireframe = false
        native_width = 1024
        filter = 0 '\000'
        var = {key = 0x7fffcd4561a3 "beetle_psx_display_vram", value = 0x89bf50 "disabled"}
        display_vram = false
        command_buffer = 0x14fdf90
        native_height = 512
        fb_texture = 0x1691600
        command_draw_mode = 6914
        texture_storage = 32855
        fb_out_depth = 0x1647020
        top_left = {0, 0}
        dimensions = {1024, 512}
#4  0x00007fffcd12bd7b in RetroGl::context_reset (this=0x89d620) at rustation-libretro/src/retrogl/retrogl.cpp:113
        config = {display_top_left = {0, 0}, display_resolution = {1024, 512}, display_24bpp = false, display_off = true, draw_offset = {0, 0}, draw_area_top_left = {0, 0}, 
          draw_area_bot_right = {0, 0}}
        copy_of_config = 0x14fa580
#5  0x00007fffcd12c2e4 in shim_context_reset () at rustation-libretro/src/retrogl/retrogl.cpp:332
No locals.
#6  0x000000000043d566 in init_drivers (flags=255) at driver.c:325
        hwr = 0x806600 <hw_render>
#7  0x000000000043d0df in driver_ctl (state=<optimized out>, data=0x7fffffff9400) at driver.c:452
        flags = 0x7fffffff9400
#8  0x000000000043d0fc in driver_ctl (state=state@entry=RARCH_DRIVER_CTL_INIT_ALL, data=data@entry=0x0) at driver.c:458
        flags = 255
#9  0x0000000000418a2a in retroarch_main_init (argc=4, argv=argv@entry=0x7fffffffddc8) at retroarch.c:1081
        init_failed = <optimized out>
#10 0x0000000000426f1b in content_load (info=0x7fffffffaad0) at tasks/task_content.c:279
        i = <optimized out>
        retval = true
        rarch_argc = 0
        rarch_argv_ptr = 0x7fffffffddc8
        rarch_argv = {0x0 <repeats 32 times>}
        argv_copy = {0x0 <repeats 32 times>}
        rarch_argc_ptr = 0x7fffffffdcb0
        wrap_args = 0x889910
#11 task_load_content (content_info=content_info@entry=0x7fffffffdcb0, launched_from_menu=launched_from_menu@entry=false, mode=CONTENT_MODE_LOAD_FROM_CLI)
    at tasks/task_content.c:895
        name = '\000' <repeats 4095 times>
        msg = '\000' <repeats 4095 times>
#12 0x000000000042800d in task_push_content_load_default (core_path=core_path@entry=0x0, fullpath=fullpath@entry=0x0, content_info=content_info@entry=0x7fffffffdcb0, 
    type=type@entry=CORE_TYPE_PLAIN, mode=mode@entry=CONTENT_MODE_LOAD_FROM_CLI, cb=cb@entry=0x0, user_data=user_data@entry=0x0) at tasks/task_content.c:1235
        loading_from_menu = <optimized out>
#13 0x00000000004154f4 in rarch_main (argc=4, argv=0x7fffffffddc8, data=0x0) at frontend/frontend.c:110
        info = {argc = 4, argv = 0x7fffffffddc8, args = 0x0, environ_get = 0x414530 <frontend_linux_get_env>}
        args = 0x0
#14 0x00007ffff27c7f45 in __libc_start_main (main=0x412970 <main>, argc=4, argv=0x7fffffffddc8, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, 
    stack_end=0x7fffffffddb8) at libc-start.c:287
        result = <optimized out>
        unwind_buf = {cancel_jmp_buf = {{jmp_buf = {0, 3587822260007666203, 4270455, 140737488346560, 0, 0, -3587822261045886437, -3587849726356815333}, mask_was_saved = 0}}, 
          priv = {pad = {0x0, 0x0, 0x50fc50 <__libc_csu_init>, 0x7fffffffddc8}, data = {prev = 0x0, cleanup = 0x0, canceltype = 5307472}}}
        not_first_call = <optimized out>
#15 0x00000000004129a0 in _start ()
No symbol table info available.

It does work with Nvidia

simias commented 8 years ago

That's an interesting backtrace.

Does Intel support permanently mapped textures?