[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: gEDA-user: Strange segfaults in gschem when adding big symbols



On Tue, 2008-03-18 at 13:04 +0100, michalwd1979 wrote:
> Hello,
> I am using geda version 20070526 on gentoo 32 bit system, glibc 2.7.
> Whenever I want to place big symbol on a schematic page (like 500pin
> Xilinx, or event titleblock A1), gschem segfaults or looks up using
> 100% cpu power - no reaction on keyboard/mouse. I wanted to trace the
> problem with gdb but when I attach gdb to gschem it works right - no
> segfaults or lookups.

Doh, sorry - missed that bit!

Try running under valgrind. There will be a lot of warnings, but most
are harmless. Let it run, then press enter several times (making a mark
you can see on the console), and then perform the required action to
make it crash.

Valgrind will get very verbose and tell you if there are any issues with
bad memory usage.

My valgrind command line looks like this:

G_SLICE=always-malloc G_DEBUG=gc-friendly valgrind --suppressions=valgrind/gdk.supp --suppressions=valgrind/guile.supp --suppressions=valgrind/x11.supp --suppressions=valgrind/gschem.supp gschem

I've attached the suppression files, which would live in the valgrind/
directory relative to where I'm running valgrind from.

Good luck!

-- 
Peter Clifton

Electrical Engineering Division,
Engineering Department,
University of Cambridge,
9, JJ Thomson Avenue,
Cambridge
CB3 0FA

Tel: +44 (0)7729 980173 - (No signal in the lab!)
{
   <insert some suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:*
   fun:*
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:calloc
   fun:XkbGetMap
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
   fun:gdk_keymap_translate_keyboard_state
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:XAddConnectionWatch
   fun:gdk_display_open
   fun:gdk_display_open_default_libgtk_only
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:*
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:_X11TransConnectDisplay
   fun:XOpenDisplay
   fun:gdk_display_open
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
}
{
   <insert a suppression name here>
   Memcheck:Leak
   obj:/usr/lib/libgdk-x11-2.0.so.0.400.14
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:XOpenDisplay
   fun:gdk_display_open
   fun:gdk_display_open_default_libgtk_only
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:calloc
   fun:XOpenDisplay
   fun:gdk_display_open
   fun:gdk_display_open_default_libgtk_only
}

{
   <insert a suppression name here>
   Memcheck:Param
   write(buf)
   obj:/lib/ld-2.6.so
   fun:_X11TransWrite
   fun:_XFlushInt
   fun:_XReply
   fun:XInternAtom
   fun:gdk_x11_atom_to_xatom_for_display
   fun:gdk_x11_get_xatom_by_name_for_display
   fun:setup_toplevel_window
   fun:gdk_window_new
   fun:gdk_display_open
   fun:gdk_display_open_default_libgtk_only
   fun:gtk_init_check
}

{
   <Should this one be real perhaps>
   Memcheck:Param
   write(buf)
   obj:/lib/ld-2.6.so
   fun:_X11TransWrite
   fun:_XFlushInt
   fun:_XFlushGCCache
   fun:XDrawLine
   fun:gdk_x11_draw_segments
   fun:gdk_draw_segments
   fun:gdk_window_draw_segments
   fun:gdk_draw_line
   fun:o_line_draw
}

{
   <Should this one be real perhaps>
   Memcheck:Param
   write(buf)
   obj:/lib/ld-2.6.so
   fun:_X11TransWrite
   fun:_XFlushInt
   fun:XDrawLine
   fun:gdk_x11_draw_segments
   fun:gdk_draw_segments
   fun:gdk_window_draw_segments
   fun:gdk_draw_line
   fun:o_line_draw
}

{
   <insert a suppression name here>
   Memcheck:Param
   writev(vector[...])
   obj:/lib/ld-2.6.so
   fun:_X11TransSocketWritev
   fun:_X11TransWritev
   fun:_XSend
   fun:XDrawPoints
   fun:gdk_x11_draw_points
   fun:gdk_draw_points
   fun:gdk_pixmap_draw_points
   fun:gdk_draw_points
   fun:x_grid_draw
}

{
   <insert a suppression name here>
   Memcheck:Param
   write(buf)
   obj:/lib/ld-2.6.so
   fun:_X11TransWrite
   fun:_XFlushInt
   fun:_XEventsQueued
   fun:XPending
   fun:_gdk_events_queue
   fun:gdk_event_dispatch
   fun:g_main_context_dispatch
   fun:g_main_context_iterate
   fun:g_main_loop_run
   fun:gtk_main
   fun:main_prog
}

{
   <insert a suppression name here>
   Memcheck:Param
   write(buf)
   obj:/lib/ld-2.6.so
   fun:_X11TransWrite
   fun:_XFlushInt
   fun:XFlush
   fun:gdk_display_flush
   fun:gdk_window_process_all_updates
   fun:gtk_container_idle_sizer
   fun:gdk_threads_dispatch
   fun:g_idle_dispatch
   fun:g_main_context_dispatch
   fun:g_main_context_iterate
   fun:g_main_loop_run
}


# guile valgrind suppression file
{
    	guilegc
	Memcheck:Value4
    	fun:scm_c_hook_run
}
{
    	guilegc
	Memcheck:Cond
    	fun:scm_c_hook_run
}

{
    guilegc
	Memcheck:Value4
    fun:scm_gc_mark_dependencies
}

{
    guilegc
	Memcheck:Cond
    fun:scan_weak_hashtables
}

{
	guilegc
 	Memcheck:Cond
	fun:scm_i_mark_weak_vectors_non_weaks
}

{
	guilegc
	Memcheck:Value4
 	fun:scm_i_symbol_mark
}
{
	guilegc
	Memcheck:Value4
	fun:scm_markstream
}

{
	guilegc
	Memcheck:Value4
 	fun:scm_i_string_mark
}
{
    guilegc
	Memcheck:Cond
    fun:scm_gc_mark_dependencies
}

{
    guilegc
    Memcheck:Cond
    fun:scm_i_scan_weak_hashtables
}

{
    guilegc
    Memcheck:Cond
    fun:scm_i_remove_weaks_from_weak_vectors
}

{
    guilegc
    Memcheck:Cond
    fun:scan_dynamic_states_and_fluids
		}

{

    guilegc	    
	Memcheck:Value4
    fun:scm_gc_mark
}
{

    guilegc	    
	Memcheck:Value4
    fun:scm_gc_mark
}

{
guilegc
Memcheck:Value4
fun:scm_i_find_heap_segment_containing_object
}

{
guilegc
Memcheck:Cond
fun:scm_i_find_heap_segment_containing_object
}

{
guilegc
Memcheck:Value4
fun:scm_markcdr
}

{
	guilegc
	Memcheck:Value4
	fun:scm_mark_locations	
}

{
	guilegc4327
   Memcheck:Cond
   obj:/usr/lib/libguile.so.12.3.1
   fun:scm_mark_locations
   fun:scm_threads_mark_stacks
   fun:scm_igc
}

{
	guilegc
	Memcheck:Cond
	fun:scm_mark_locations	
}

{
    guilegc
	Memcheck:Cond
    fun:scm_gc_mark
}

{
    guilegc
	Memcheck:Cond
    fun:scm_i_sweep_card
}

{
    guilegc
	Memcheck:Cond
    fun:scm_mark_weak_vector_spines
}

{
    guilegc
	Memcheck:Cond
    fun:scm_gc_mark_dependencies
}

{
guilegc
Memcheck:Cond
fun:scm_scan_weak_vectors
}

{
   <Hopefully ignore lots of X11 leaks>
   Memcheck:Leak
   fun:malloc
   obj:/usr/lib/libX11.so.6
}
{
   <Hopefully ignore lots of X11 leaks>
   Memcheck:Leak
   fun:malloc
   fun:*
   fun:*
   obj:/usr/lib/libX11.so.6
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   obj:/usr/lib/libX11.so.6
   obj:/usr/lib/libX11.so.6
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:calloc
   obj:/usr/lib/libX11.so.6
   obj:/usr/lib/libX11.so.6
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:_XiGetExtensionVersion
   fun:_XiCheckExtInit
   fun:XListInputDevices
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:XextAddDisplay
   obj:/usr/lib/libXext.so.6.4
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:XextCreateExtension
   fun:XInput_find_display
   fun:XListInputDevices
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:_XOpenLC
   fun:_XlcCurrentLC
   fun:XSupportsLocale
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:_XlcCreateLC
   fun:_XlcUtf8Loader
   fun:_XlcDynamicLoad
}

{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   obj:/usr/lib/libX11.so.6
   fun:_XlcCreateLC
   fun:_XlcUtf8Loader
}

{
   <>
   Memcheck:Leak
   fun:malloc
   fun:_XcursorGetDisplayInfo
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   obj:/usr/lib/libX11.so.6
   fun:_X11TransConnect
   fun:_X11TransConnectDisplay
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   obj:/usr/lib/libX11.so.6
   obj:/usr/lib/libX11.so.6
   fun:_X11TransConnectDisplay
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:realloc
   obj:/usr/lib/libX11.so.6
   obj:/usr/lib/libX11.so.6
   obj:/usr/lib/libX11.so.6
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:_XlcAddCT
   fun:_XlcInitCTInfo
   obj:/usr/lib/libX11.so.6
}
{
   <insert a suppression name here>
   Memcheck:Leak
   fun:malloc
   fun:_XrmInternalStringToQuark
   fun:XrmStringToQuark
   fun:_XlcGetCharSet
}


_______________________________________________
geda-user mailing list
geda-user@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-user