Building gimp-2.10.4 with gegl-0.4.6 that had been built with optimizations and without -gddb3 using GCC in Linux results in segfault
Using GCC-7.3.0 in Gentoo Linux, building gegl-0.4.6 segfaults. Specifically, while the build is in /var/tmp/portage/media-gfx/gimp-2.10.4/work/gimp-2.10.4/icons/Symbolic-Inverted
and executes GEGL_USE_OPENCL=no GEGL_SWAP=ram /usr/bin/gegl-0.4 ../../icons/Symbolic/64/gimp-texture.png -o 64/gimp-texture.png -- gegl:invert-gamma
it segfaults if gegl-0.4.6 was built at any optimization level (tested with -O1
, -O2
, and -Og
) and without -gddb3
. If optimizations were turned off with -O0
while building gegl-0.4.6 and -gddb3
added, there is no segfault.
The following is a gdb full backtrace with babl-0.1.54 and gegl-0.4.6 built with debugging symbols and gegl-0.4.6 built with -Og
:
Starting program: /usr/bin/gegl-0.4 ../../icons/Symbolic/64/gimp-texture.png -o 64/gimp-texture.png -- gegl:invert-gamma
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".
Program received signal SIGSEGV, Segmentation fault.
0x00007ffff6924261 in babl_get_name (babl=0xf6be7100) at babl-internal.c:110
110 babl_assert (BABL_IS_BABL (babl));
#0 0x00007ffff6924261 in babl_get_name (babl=0xf6be7100) at babl-internal.c:110
__PRETTY_FUNCTION__ = "babl_get_name"
#1 0x00007ffff69316bc in babl_space_from_chromaticities (name=0x0, wx=0.31270000000000003, wy=0.32900000000000001, rx=0.64000000000000001, ry=0.33000000000000002, gx=0.30000000000000004, gy=0.60000000000000009, bx=0.15000000000000002, by=0.060000000000000005, trc_red=0xf6be7100, trc_green=0xf6be7100, trc_blue=0xf6be7100, flags=BABL_SPACE_FLAG_EQUALIZE) at babl-space.c:368
i = 7
space = {instance = {class_type = 12235017, id = 0, creator = 0x0, name = 0x0}, xw = 0.31270000000000003, yw = 0.32900000000000001, xr = 0.64000000000000001, yr = 0.33000000000000002, xg = 0.30000000000000004, yg = 0.60000000000000009, xb = 0.15000000000000002, yb = 0.060000000000000005, trc = {0xf6be7100, 0xf6be7100, 0xf6be7100}, name = '\000' <repeats 511 times>, whitepoint = {0.95045592705167181, 1, 1.0890577507598784}, RGBtoXYZ = {0, 0, 0, 0, 0, 0, 0, 0, 0}, XYZtoRGB = {0, 0, 0, 0, 0, 0, 0, 0, 0}, RGBtoXYZf = {0, 0, 0, 0, 0, 0, 0, 0, 0}, XYZtoRGBf = {0, 0, 0, 0, 0, 0, 0, 0, 0}, icc_profile = 0x0, icc_length = 0}
__PRETTY_FUNCTION__ = "babl_space_from_chromaticities"
#2 0x00007fffd35cacdd in gegl_png_space (load_png_ptr=<optimized out>, load_info_ptr=<optimized out>) at png-load.c:202
red = {0.64000000000000001, 0.33000000000000002}
green = {0.30000000000000004, 0.60000000000000009}
blue = {0.15000000000000002, 0.060000000000000005}
gamma = 0.45455000000000001
wp = {0.31270000000000003, 0.32900000000000001}
name = 0x0
profile = 0x0
proflen = 0
compression_type = 32767
#3 0x00007fffd35cb011 in query_png (stream=stream@entry=0x55555594d210, width=width@entry=0x7fffffffc998, height=height@entry=0x7fffffffc99c, format=format@entry=0x7fffffffc9a0, err=err@entry=0x7fffffffc9a8) at png-load.c:462
bit_depth = 8
color_type = 0
f = <optimized out>
w = 64
h = 64
load_png_ptr = 0x555555948350
load_info_ptr = 0x555555961100
space = 0x0
__func__ = "query_png"
#4 0x00007fffd35cb110 in get_bounding_box (operation=0x55555594eb50) at png-load.c:491
o = <optimized out>
result = <optimized out>
width = 64
height = 64
status = <optimized out>
format = 0x555555945660
err = 0x0
infile = 0x5555559b1c60
stream = 0x55555594d210
#5 0x00007ffff7b809f7 in gegl_operation_get_bounding_box (self=self@entry=0x55555594eb50) at gegl-operation.c:197
klass = 0x55555593e4c0
rect = <optimized out>
__func__ = "gegl_operation_get_bounding_box"
#6 0x00007ffff7b9051f in gegl_graph_prepare (path=0x555555945660) at gegl-graph-traversal.c:191
node = 0x555555829d60
parent = <optimized out>
on = 0x55555594eb50
list_iter = 0x5555559b1c40
#7 0x00007ffff7b8fe0d in gegl_eval_manager_prepare (self=self@entry=0x5555559b3180) at gegl-eval-manager.c:93
__func__ = "gegl_eval_manager_prepare"
#8 0x00007ffff7b8fe5b in gegl_eval_manager_get_bounding_box (self=self@entry=0x5555559b3180) at gegl-eval-manager.c:102
No locals.
#9 0x00007ffff7b8ab3c in gegl_node_get_bounding_box (self=self@entry=0x555555829d60) at gegl-node.c:1810
eval = 0x5555559b3180
#10 0x00007ffff7b8b54b in gegl_node_property_changed (gobject=<optimized out>, arg1=0x555555933440, user_data=<optimized out>) at gegl-node.c:1352
dirty_rect = {x = 0, y = 2, width = 132, height = 12}
new_have_rect = {x = 1435784048, y = 21845, width = -149681544, height = 32767}
self = 0x555555829d60
#11 0x00007ffff7117f8d in g_closure_invoke () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#12 0x00007ffff712ad73 in ?? () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#13 0x00007ffff71335a5 in g_signal_emit_valist () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#14 0x00007ffff7133fc7 in g_signal_emit () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#15 0x00007ffff711c444 in ?? () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#16 0x00007ffff711bdee in ?? () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#17 0x00007ffff711ea5b in g_object_thaw_notify () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#18 0x00007ffff7b8db72 in gegl_node_set_valist (self=self@entry=0x555555829d60, first_property_name=<optimized out>, first_property_name@entry=0x7ffff10223d5 "path", var_args=var_args@entry=0x7fffffffd170) at gegl-node.c:1546
property_name = <optimized out>
__func__ = "gegl_node_set_valist"
#19 0x00007ffff7b8df95 in gegl_node_set (self=0x555555829d60, first_property_name=first_property_name@entry=0x7ffff10223d5 "path") at gegl-node.c:1442
var_args = {{gp_offset = 32, fp_offset = 48, overflow_arg_area = 0x7fffffffd260, reg_save_area = 0x7fffffffd190}}
__func__ = "gegl_node_set"
#20 0x00007ffff101be97 in do_setup (operation=operation@entry=0x555555845c00, path=0x55555595ef40 "/var/tmp/portage/media-gfx/gimp-2.10.4/work/gimp-2.10.4/icons/Symbolic/64/gimp-texture.png", uri=0x5555559438e0 "") at load.c:262
self = 0x555555845c00
handler = <optimized out>
content_type = 0x55555589d730 "image/png"
filename = 0x55555595f420 "/var/tmp/portage/media-gfx/gimp-2.10.4/work/gimp-2.10.4/icons/Symbolic/64/gimp-texture.png"
message = <optimized out>
load_from_uri = 0
uncertain = 0
stream = 0x55555593c270
error = 0x0
file = 0x5555559b17a0
buffer = 0x0
size = 93824996358336
__func__ = "do_setup"
#21 0x00007ffff101c0fc in my_set_property (gobject=0x555555845c00, property_id=1, value=0x7fffffffd370, pspec=0x5555558f25a0) at load.c:345
operation = 0x555555845c00
self = 0x555555845c00
o = 0x555555891ce0
old_path = 0x5555559438c0 ""
old_uri = 0x55555594e080 ""
props_changed = <optimized out>
#22 0x00007ffff711fa5e in g_object_setv () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#23 0x00007ffff71209fe in g_object_set_property () from /usr/lib64/libgobject-2.0.so.0
No symbol table info available.
#24 0x00007ffff7b8dd0e in gegl_node_set_valist (self=self@entry=0x555555829bc0, first_property_name=<optimized out>, first_property_name@entry=0x555555943060 "path", var_args=var_args@entry=0x7fffffffd4a0) at gegl-node.c:1537
value = {g_type = 64, data = {{v_int = 1435786128, v_uint = 1435786128, v_long = 93824996367248, v_ulong = 93824996367248, v_int64 = 93824996367248, v_uint64 = 93824996367248, v_float = 2.03901224e+13, v_double = 4.6355707426236994e-310, v_pointer = 0x555555945b90}, {v_int = 0, v_uint = 0, v_long = 0, v_ulong = 0, v_int64 = 0, v_uint64 = 0, v_float = 0, v_double = 0, v_pointer = 0x0}}}
pspec = <optimized out>
error = <optimized out>
object = 0x555555845c00
property_name = 0x555555943060 "path"
__func__ = "gegl_node_set_valist"
#25 0x00007ffff7b8df95 in gegl_node_set (self=self@entry=0x555555829bc0, first_property_name=first_property_name@entry=0x555555943060 "path") at gegl-node.c:1442
var_args = {{gp_offset = 24, fp_offset = 48, overflow_arg_area = 0x7fffffffd590, reg_save_area = 0x7fffffffd4c0}}
__func__ = "gegl_node_set"
#26 0x00007ffff7b519f4 in param_set (pd=pd@entry=0x7fffffffd780, new=new@entry=0x555555829bc0, param_name=<optimized out>, param_value=0x555555943e90 "gimp-texture.png") at gegl-xml.c:145
absolute_path = <optimized out>
buf = 0x555555945b90 "/var/tmp/portage/media-gfx/gimp-2.10.4/work/gimp-2.10.4/icons/Symbolic/64/gimp-texture.png"
paramspec = <optimized out>
#27 0x00007ffff7b525ba in start_element (context=<optimized out>, element_name=<optimized out>, attribute_names=<optimized out>, attribute_values=<optimized out>, user_data=0x7fffffffd780, error=0x7fffffffd6c0) at gegl-xml.c:424
new = 0x555555829bc0
a = 0x7fffffffd660
v = 0x7fffffffd640
pd = 0x7fffffffd780
#28 0x00007ffff6c3fed4 in ?? () from /usr/lib64/libglib-2.0.so.0
No symbol table info available.
#29 0x00007ffff6c40e9b in g_markup_parse_context_parse () from /usr/lib64/libglib-2.0.so.0
No symbol table info available.
#30 0x00007ffff7b53f23 in gegl_node_new_from_xml (xmldata=<optimized out>, path_root=<optimized out>) at gegl-xml.c:580
_gegl_instrument_ticks = 0
pd = {state = 1, path_root = 0x5555557c2300 "/var/tmp/portage/media-gfx/gimp-2.10.4/work/gimp-2.10.4/icons/Symbolic/64", gegl = 0x555555829880, param = 0x0, iter = 0x555555829880, parent = 0x555555892260, curve = 0x0, ids = 0x5555557f1860, refs = 0x0}
context = 0x55555582f440
success = 0
__func__ = "gegl_node_new_from_xml"
#31 0x000055555555691a in main (argc=<optimized out>, argv=<optimized out>) at gegl.c:216
o = 0x55555576f5d0
gegl = 0x0
script = 0x5555558572c0 "<gegl><gegl:load path='gimp-texture.png'/></gegl>"
err = 0x0
path_root = 0x5555557c2300 "/var/tmp/portage/media-gfx/gimp-2.10.4/work/gimp-2.10.4/icons/Symbolic/64"
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information