After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 686770 - _cogl_bitmap_unbind: assertion failed: (bitmap->bound) for gnome-shell on nexus 7
_cogl_bitmap_unbind: assertion failed: (bitmap->bound) for gnome-shell on nex...
Status: RESOLVED OBSOLETE
Product: cogl
Classification: Platform
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: Cogl maintainer(s)
Cogl maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2012-10-24 08:42 UTC by Allison Karlitskaya (desrt)
Modified: 2021-06-10 11:19 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
bitmap: don't mark bitmap bound on _gl_bind error (2.24 KB, patch)
2013-02-28 18:09 UTC, Robert Bragg
accepted-commit_now Details | Review

Description Allison Karlitskaya (desrt) 2012-10-24 08:42:13 UTC
I installed Ubuntu on my nexus 7 and tried to run gnome-shell.  Sometimes it starts up, sometimes not.  In any case, very quickly after startup, I get the same crash:

  • #0 ??
    from /lib/arm-linux-gnueabihf/libc.so.6
  • #1 raise
    from /lib/arm-linux-gnueabihf/libc.so.6
  • #2 abort
    from /lib/arm-linux-gnueabihf/libc.so.6
  • #3 g_assertion_message
    at /build/buildd/glib2.0-2.34.0/./glib/gtestutils.c line 1877
  • #4 g_assertion_message_expr
    at /build/buildd/glib2.0-2.34.0/./glib/gtestutils.c line 1888
  • #5 _cogl_bitmap_unbind
    at ./cogl-bitmap.c line 467
  • #6 cogl_framebuffer_read_pixels_into_bitmap
    at ./cogl-framebuffer.c line 2196
  • #7 get_texture_bits_via_offscreen
    at ./cogl-texture.c line 978
  • #8 texture_get_cb
    at ./cogl-texture.c line 1090
  • #9 normalize_meta_coords_cb
    at ./cogl-meta-texture.c line 460
  • #10 padded_grid_repeat_cb
    at ./cogl-meta-texture.c line 90
  • #11 padded_grid_repeat_cb
    at ./cogl-meta-texture.c line 60
  • #12 _cogl_texture_spans_foreach_in_region
    at ./cogl-texture.c line 1390
  • #13 create_grid_and_repeat_cb
    at ./cogl-meta-texture.c line 203
  • #14 re_normalize_sub_texture_coords_cb
    at ./cogl-texture-2d-sliced.c line 81
  • #15 _cogl_texture_spans_foreach_in_region
    at ./cogl-texture.c line 1390
  • #16 _cogl_texture_2d_sliced_foreach_sub_texture_in_region
    at ./cogl-texture-2d-sliced.c line 118
  • #17 cogl_meta_texture_foreach_in_region
    at ./cogl-meta-texture.c line 598
  • #18 cogl_texture_get_data
    at ./cogl-texture.c line 1197
  • #19 _st_create_shadow_material
    at st/st-private.c line 426
  • #20 _st_create_shadow_material_from_actor
    at st/st-private.c line 515
  • #21 st_label_paint
    at st/st-label.c line 234
  • #22 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #23 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #24 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #25 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #26 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #27 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #28 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #29 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #30 shell_generic_container_paint
    at shell-generic-container.c line 139
  • #31 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #32 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #33 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #34 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #35 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #36 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #37 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #38 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #39 shell_generic_container_paint
    at shell-generic-container.c line 139
  • #40 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #41 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #42 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #43 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #44 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #45 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #46 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #47 clutter_actor_real_paint
    at ./clutter-actor.c line 3516
  • #48 st_widget_paint
    at st/st-widget.c line 417
  • #49 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #50 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #51 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #52 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #53 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #54 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #55 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #56 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #57 st_box_layout_paint
    at st/st-box-layout.c line 932
  • #58 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #59 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #60 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #61 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #62 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #63 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #64 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #65 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #66 shell_generic_container_paint
    at shell-generic-container.c line 139
  • #67 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #68 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #69 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #70 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #71 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #72 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #73 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #74 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #75 st_box_layout_paint
    at st/st-box-layout.c line 932
  • #76 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #77 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #78 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #79 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #80 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #81 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #82 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #83 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #84 shell_generic_container_paint
    at shell-generic-container.c line 139
  • #85 g_cclosure_marshal_VOID__VOIDv
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 115
  • #86 g_type_class_meta_marshalv
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 997
  • #87 _g_closure_invoke_va
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 840
  • #88 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3211
  • #89 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #90 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #91 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #92 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #93 clutter_stage_paint
    at ./clutter-stage.c line 716
  • #94 g_cclosure_marshal_VOID__VOID
    at /build/buildd/glib2.0-2.34.0/./gobject/gmarshal.c line 85
  • #95 g_type_class_meta_marshal
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 970
  • #96 g_closure_invoke
    at /build/buildd/glib2.0-2.34.0/./gobject/gclosure.c line 777
  • #97 signal_emit_unlocked_R
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3589
  • #98 g_signal_emit_valist
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3300
  • #99 g_signal_emit
    at /build/buildd/glib2.0-2.34.0/./gobject/gsignal.c line 3356
  • #100 clutter_actor_continue_paint
    at ./clutter-actor.c line 3867
  • #101 clutter_actor_paint
    at ./clutter-actor.c line 3791
  • #102 clutter_actor_paint
    at ./clutter-actor.c line 3813
  • #103 _clutter_stage_do_paint
    at ./clutter-stage.c line 669
  • #104 clutter_stage_cogl_redraw
    at ./cogl/clutter-stage-cogl.c line 404
  • #105 _clutter_stage_window_redraw
    at ./clutter-stage-window.c line 236
  • #106 clutter_stage_do_redraw
    at ./clutter-stage.c line 1170
  • #107 _clutter_stage_do_update
    at ./clutter-stage.c line 1228
  • #108 master_clock_update_stages
    at ./clutter-master-clock.c line 386
  • #109 clutter_clock_dispatch
    at ./clutter-master-clock.c line 520
  • #110 g_main_dispatch
    at /build/buildd/glib2.0-2.34.0/./glib/gmain.c line 2715
  • #111 g_main_context_dispatch
    at /build/buildd/glib2.0-2.34.0/./glib/gmain.c line 3219
  • #112 g_main_context_iterate
    at /build/buildd/glib2.0-2.34.0/./glib/gmain.c line 3290
  • #113 g_main_loop_run
    at /build/buildd/glib2.0-2.34.0/./glib/gmain.c line 3484
  • #114 meta_run
    at core/main.c line 545
  • #115 main
    at main.c line 416

Comment 1 Allison Karlitskaya (desrt) 2012-10-24 09:11:01 UTC
fwiw, cogl is using libEGL.so.1 from:

Source: nvidia-graphics-drivers-tegra3
Version: 16.0-0ubuntu2
Description-en: NVIDIA binary Xorg driver for Tegra3 (cardhu) GPUs.
 This package contains the proprietary firmware and drivers
 needed to run hardware accelerated Open GLES 2.0 under X11
 on NVIDIA Tegra3 (cardhu) based hardware.
Comment 2 Allison Karlitskaya (desrt) 2012-10-24 10:05:16 UTC
This allows it to stumble along mostly fine:

diff --git a/cogl/cogl-bitmap.c b/cogl/cogl-bitmap.c
index b0c6ec7..6a5892e 100644
--- a/cogl/cogl-bitmap.c
+++ b/cogl/cogl-bitmap.c
@@ -64,7 +64,7 @@ COGL_OBJECT_DEFINE (Bitmap, bitmap);
 static void
 _cogl_bitmap_free (CoglBitmap *bmp)
 {
-  g_assert (!bmp->mapped);
+  //g_assert (!bmp->mapped);
   g_assert (!bmp->bound);
 
   if (bmp->shared_bmp)
@@ -464,7 +464,7 @@ _cogl_bitmap_unbind (CoglBitmap *bitmap)
       return;
     }
 
-  g_assert (bitmap->bound);
+  //g_assert (bitmap->bound);
   bitmap->bound = FALSE;
 
   /* If the bitmap wasn't created from a pixel array then the


There is a probably-unrelated issues that the menus don't get their black background drawn.
Comment 3 Steve Riley 2012-11-21 06:58:25 UTC
What about the suggested workaround in bug 686806? Is that a viable alternative for Nexus 7?
Comment 4 Robert Bragg 2013-02-28 18:09:08 UTC
Created attachment 237639 [details] [review]
bitmap: don't mark bitmap bound on _gl_bind error

On inspection I came across this issue that might have possibly left cogl's status about when a bitmap has been bound in an inconsistent state.

I'm not quite sure what version of Cogl you were running, but when I look at the difference between cogl-1.12 and master it looks like we basically did nothing in cogl_framebuffer_read_pixels_into_bitmap after calling _cogl_bitmap_bind to check for an error with binding and so I guess _cogl_bitmap_bind may have possibly returned before marking the bitmap bound but we'd still hit the _cogl_bitmap_unbind which would hit one of the assertions you commented out.

In master (and cogl-1.14) we are more careful about checking for errors here but still I think the issue addressed in this patch could cause problems for you.
Comment 5 Neil Roberts 2013-03-04 18:57:54 UTC
The patch looks sensible to land to me even if it turns out not to be the cause of this bug.
Comment 6 André Klapper 2021-06-10 11:19:28 UTC
GNOME is going to shut down bugzilla.gnome.org in favor of gitlab.gnome.org.
As part of that, we are mass-closing older open tickets in bugzilla.gnome.org
which have not seen updates for a longer time (resources are unfortunately
quite limited so not every ticket can get handled).

If you can still reproduce the situation described in this ticket in a recent
and supported software version of cogl, then please follow
  https://wiki.gnome.org/GettingInTouch/BugReportingGuidelines
and create a ticket at
  https://gitlab.gnome.org/GNOME/cogl/-/issues/

Thank you for your understanding and your help.