明覺 wrote: > 2009/5/13 Brian Paul <[email protected]>: >> 明覺 wrote: >>> 2009/5/12 明覺 <[email protected]>: >>>> 2009/5/12 Ian Romanick <[email protected]>: >>>>> -----BEGIN PGP SIGNED MESSAGE----- >>>>> Hash: SHA1 >>>>> >>>>> 明覺 wrote: >>>>>> Greetings! >>>>>> my application crashes at line 660 of glxcmds.c, here is the gdb info: >>>>>> --------------------------------------------------------------------------------------- >>>>>> (gdb) break glxcmds.c:660 >>>>>> Breakpoint 1 (glxcmds.c:660) pending. >>>>>> (gdb) run >>>>>> Breakpoint 1, glXWaitX () at glxcmds.c:660 >>>>>> (gdb) print psc->driScreen->waitX >>>>>> $3 = (void (*)(__GLXDRIdrawable *)) 0x47206769666e6f63 >>>>>> (gdb) print *psc->driScreen->waitX >>>>>> Cannot access memory at address 0x47206769666e6f63 >>>>>> (gdb) step >>>>>> Program received signal SIGSEGV, Segmentation fault. >>>>>> --------------------------------------------------------------------------------------- >>>>>> is it a bug of mesa or something wrong in my application? thanks >>>>> It's a known bug in Mesa. I believe that this is already fixed, so you >>>>> should just need to update Mesa. >>>> I'm using mesa 7.4.1, is the bug fixed in 7.5? I will try it. thanks >>> I installed http://www.mesa3d.org/beta/MesaLib-7.6-devel-20090501.tar.gz >>> into /usr to overwrite the old mesa-7.4.1, and exed ldconfig, then >>> rebuilt my program by kdevelop, the previous "seg fault" error >>> disappear, but another new one appear, seems to be associated with the >>> glLightfv function, any advice to solve the new one? here is the gdb >>> info: >>> ------------------------------------------------------------------------------------------------------------------------------ >>> minjue:~/workspace/k3dsurf/k3dsurf-0.6.2/bin# gdb k3dsurf >>> GNU gdb (GDB) 6.8.50.20090106-cvs-debian >>> This GDB was configured as "x86_64-linux-gnu". >>> (gdb) break glviewer.cpp:740 >>> Breakpoint 1 at 0x472920: file glviewer.cpp, line 740. (2 locations) >>> (gdb) run >>> Starting program: /root/workspace/k3dsurf/k3dsurf-0.6.2/bin/k3dsurf >>> [Thread debugging using libthread_db enabled] >>> >>> Breakpoint 1, OpenGlWidget (this=0xa34a10, parent=<value optimized out>, >>> name=<value optimized out>) at glviewer.cpp:740 >>> 740 glLightfv(GL_LIGHT0, GL_AMBIENT, ambient); >>> (gdb) print GL_LIGHT0 >>> No symbol "GL_LIGHT0" in current context. >>> (gdb) print GL_AMBIENT >>> No symbol "GL_AMBIENT" in current context. >>> (gdb) print ambient >>> $1 = {0, 0, -4.28388841e+32, 4.59163468e-41} >>> (gdb) step >>> 736 GLfloat lmodel_ambient[] = { 0.2, 0.2, 0.2, 1.0 }; >>> (gdb) >>> 740 glLightfv(GL_LIGHT0, GL_AMBIENT, ambient); >>> (gdb) >>> 734 GLfloat ambient[] = { .0, .0, .0, 1.0 }; >>> (gdb) >>> 735 GLfloat diffuse[] = { 1.0, 1.0, 1.0, 1.0 }; >>> (gdb) >>> 736 GLfloat lmodel_ambient[] = { 0.2, 0.2, 0.2, 1.0 }; >>> (gdb) >>> 737 GLfloat local_view[] = { 1.0 }; >>> (gdb) >>> 740 glLightfv(GL_LIGHT0, GL_AMBIENT, ambient); >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5622 >>> 5622 pushq %rdi >>> Current language: auto; currently asm >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5623 >>> 5623 pushq %rsi >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5624 >>> 5624 pushq %rdx >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5625 >>> 5625 call _x86_64_get_dispa...@plt >>> (gdb) >>> _x86_64_get_dispatch () at ../../../src/mesa/x86-64/glapi_x86-64.S:76 >>> 76 movq _gl_DispatchTSD(%rip), %rdi >>> (gdb) >>> 77 jmp pthread_getspeci...@plt >>> (gdb) >>> 0x00007ffff6524840 in pthread_getspecific () from /lib/libpthread.so.0 >>> (gdb) >>> Single stepping until exit from function pthread_getspecific, >>> which has no line number information. >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5626 >>> 5626 popq %rdx >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5627 >>> 5627 popq %rsi >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5628 >>> 5628 popq %rdi >>> (gdb) >>> glLightfv () at ../../../src/mesa/x86-64/glapi_x86-64.S:5629 >>> 5629 movq 1280(%rax), %r11 >>> (gdb) >>> 5630 jmp *%r11 >>> (gdb) >>> >>> Program received signal SIGSEGV, Segmentation fault. >>> 0x0000000000000000 in ?? () >> >> Have you tried valgrind again? > thank you for the remind, I can saw the error path from valgrind now, > the a.out is produced by the example gtkglextmm program gears.cc from > the attachment, the error occurs when I resize the window: > ------------------------------------------------------------------------------------------ > minjue:~/workspace/Meck# valgrind --tool=memcheck ./a.out > ==26447== Using valgrind-3.4.1-Debian, a dynamic binary > instrumentation framework. > ==26447== Copyright (C) 2000-2008, and GNU GPL'd, by Julian Seward et al. > > OpenGL visual configurations : > > glconfig->is_rgba() = true > glconfig->is_double_buffered() = true > glconfig->is_stereo() = false > glconfig->has_alpha() = false > glconfig->has_depth_buffer() = true > glconfig->has_stencil_buffer() = false > glconfig->has_accum_buffer() = false > > Gdk::GL::USE_GL = true > Gdk::GL::BUFFER_SIZE = 24 > Gdk::GL::LEVEL = 0 > Gdk::GL::RGBA = true > Gdk::GL::DOUBLEBUFFER = true > Gdk::GL::STEREO = false > Gdk::GL::AUX_BUFFERS = 0 > Gdk::GL::RED_SIZE = 8 > Gdk::GL::GREEN_SIZE = 8 > Gdk::GL::BLUE_SIZE = 8 > Gdk::GL::ALPHA_SIZE = 0 > Gdk::GL::DEPTH_SIZE = 24 > Gdk::GL::STENCIL_SIZE = 0 > Gdk::GL::ACCUM_RED_SIZE = 0 > Gdk::GL::ACCUM_GREEN_SIZE = 0 > Gdk::GL::ACCUM_BLUE_SIZE = 0 > Gdk::GL::ACCUM_ALPHA_SIZE = 0 > > GL_RENDERER = Software Rasterizer > GL_VERSION = 2.1 Mesa 7.6-devel > GL_VENDOR = Mesa Project > GL_EXTENSIONS = GL_ARB_depth_texture GL_ARB_draw_buffers > GL_ARB_fragment_program GL_ARB_fragment_program_shadow > GL_ARB_fragment_shader GL_ARB_framebuffer_object > GL_ARB_half_float_pixel GL_ARB_imaging GL_ARB_multisample > GL_ARB_multitexture GL_ARB_occlusion_query GL_ARB_pixel_buffer_object > GL_ARB_point_parameters GL_ARB_point_sprite GL_ARB_shader_objects > GL_ARB_shading_language_100 GL_ARB_shading_language_120 GL_ARB_shadow > GL_ARB_shadow_ambient GL_ARB_texture_border_clamp > GL_ARB_texture_compression GL_ARB_texture_cube_map > GL_ARB_texture_env_add GL_ARB_texture_env_combine > GL_ARB_texture_env_crossbar GL_ARB_texture_env_dot3 > GL_ARB_texture_mirrored_repeat GL_ARB_texture_non_power_of_two > GL_ARB_texture_rectangle GL_ARB_transpose_matrix > GL_ARB_vertex_buffer_object GL_ARB_vertex_program GL_ARB_vertex_shader > GL_ARB_window_pos GL_EXT_abgr GL_EXT_bgra GL_EXT_blend_color > GL_EXT_blend_equation_separate GL_EXT_blend_func_separate > GL_EXT_blend_logic_op GL_EXT_blend_minmax GL_EXT_blend_subtract > GL_EXT_compiled_vertex_array GL_EXT_convolution GL_EXT_copy_texture > GL_EXT_depth_bounds_test GL_EXT_draw_range_elements > GL_EXT_framebuffer_object GL_EXT_framebuffer_blit GL_EXT_fog_coord > GL_EXT_gpu_program_parameters GL_EXT_histogram > GL_EXT_multi_draw_arrays GL_EXT_packed_depth_stencil > GL_EXT_packed_pixels GL_EXT_paletted_texture > GL_EXT_pixel_buffer_object GL_EXT_point_parameters > GL_EXT_polygon_offset GL_EXT_rescale_normal GL_EXT_secondary_color > GL_EXT_separate_specular_color GL_EXT_shadow_funcs > GL_EXT_shared_texture_palette GL_EXT_stencil_two_side > GL_EXT_stencil_wrap GL_EXT_subtexture GL_EXT_texture GL_EXT_texture3D > GL_EXT_texture_edge_clamp GL_EXT_texture_env_add > GL_EXT_texture_env_combine GL_EXT_texture_env_dot3 > GL_EXT_texture_lod_bias GL_EXT_texture_mirror_clamp > GL_EXT_texture_object GL_EXT_texture_rectangle GL_EXT_texture_sRGB > GL_EXT_texture_swizzle GL_EXT_vertex_array GL_EXT_vertex_array_bgra > GL_3DFX_texture_compression_FXT1 GL_APPLE_packed_pixels > GL_APPLE_vertex_array_object GL_ATI_blend_equation_separate > GL_ATI_envmap_bumpmap GL_ATI_texture_env_combine3 > GL_ATI_texture_mirror_once GL_ATI_fragment_shader > GL_ATI_separate_stencil GL_IBM_multimode_draw_arrays > GL_IBM_rasterpos_clip GL_IBM_texture_mirrored_repeat > GL_INGR_blend_func_separate GL_MESA_pack_invert GL_MESA_resize_buffers > GL_MESA_texture_array GL_MESA_ycbcr_texture GL_MESA_window_pos > GL_NV_blend_square GL_NV_fragment_program GL_NV_light_max_exponent > GL_NV_point_sprite GL_NV_texture_env_combine4 GL_NV_texture_rectangle > GL_NV_texgen_reflection GL_NV_vertex_program GL_NV_vertex_program1_1 > GL_OES_read_format GL_SGI_color_matrix GL_SGI_color_table > GL_SGI_texture_color_table GL_SGIS_generate_mipmap > GL_SGIS_texture_border_clamp GL_SGIS_texture_edge_clamp > GL_SGIS_texture_lod GL_SUN_multi_draw_arrays > > 11 frames in 5.071 seconds = 2.169 FPS > ==26447== Conditional jump or move depends on uninitialised value(s) > ==26447== at 0x5F8BE57: glXWaitX (glxcmds.c:659) > ==26447== by 0x9CB211C: g_closure_invoke (gclosure.c:767) > ==26447== by 0x9CC5C2A: signal_emit_unlocked_R (gsignal.c:3247) > ==26447== by 0x9CC7021: g_signal_emit_valist (gsignal.c:2980) > ==26447== by 0x9CC74F2: g_signal_emit (gsignal.c:3037) > ==26447== by 0x792D269: gtk_widget_size_allocate (in > /usr/lib/libgtk-x11-2.0.so.0.1600.1) > ==26447== by 0x783F157: (within /usr/lib/libgtk-x11-2.0.so.0.1600.1) > ==26447== by 0x9CB206E: g_closure_invoke (gclosure.c:767) > ==26447== by 0x9CC5512: signal_emit_unlocked_R (gsignal.c:3177) > ==26447== by 0x9CC7021: g_signal_emit_valist (gsignal.c:2980) > ==26447== by 0x9CC74F2: g_signal_emit (gsignal.c:3037) > ==26447== by 0x792D269: gtk_widget_size_allocate (in > /usr/lib/libgtk-x11-2.0.so.0.1600.1)
That's all that valgrind reports? There's no error detected in the glLightfv() call? I believe the error reported above was fixed on May 4th with commit e9d5569bf3e5d7a78a790c144aed275f1a32f325 (a few days after the snapshot you have). -Brian ------------------------------------------------------------------------------ The NEW KODAK i700 Series Scanners deliver under ANY circumstances! Your production scanning environment may not be a perfect world - but thanks to Kodak, there's a perfect scanner to get the job done! With the NEW KODAK i700 Series Scanner you'll get full speed at 300 dpi even with all image processing features enabled. http://p.sf.net/sfu/kodak-com _______________________________________________ Mesa3d-dev mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mesa3d-dev
