[gstreamer-bugs] [Bug 316088] MinGW compilation: fast-stack-trash does not work
bugzilla-daemon at bugzilla.gnome.org
bugzilla-daemon at bugzilla.gnome.org
Tue Sep 13 08:21:38 PDT 2005
Do not reply to this email. You can add comments to this bug at
http://bugzilla.gnome.org/show_bug.cgi?id=316088
GStreamer | gstreamer (core) | Ver: HEAD CVS
------- Additional Comments From Michal Benes 2005-09-13 15:21 -------
Sorry, for the general title. I did not known much more that before.
Now it seems I have found the problem:
gst_mem_chunk_alloc ends in infinite cycle, since
gst_trash_stack_pop always returns NULL.
(The function gst_mem_chunk_alloc is trying to allocate new chunks and push them
to TrashStack until gst_trash_stack_pop returns non-NULL)
When I try to add debug output to gst_mem_chunk_alloc:
210 gpointer
211 gst_mem_chunk_alloc (GstMemChunk * mem_chunk)
212 {
213 GstMemChunkElement *chunk;
214
215 g_return_val_if_fail (mem_chunk != NULL, NULL);
216
217 again:
218 printf("HERE\n");
219 chunk = gst_trash_stack_pop (&mem_chunk->stack);
it prints infinite number of HERE messages.
However, if I try the following debug prints
210 gpointer
211 gst_mem_chunk_alloc (GstMemChunk * mem_chunk)
212 {
213 GstMemChunkElement *chunk;
214
215 g_return_val_if_fail (mem_chunk != NULL, NULL);
216
217 again:
218 printf("HERE %d\n", mem_chunk->stack.count);
219 chunk = gst_trash_stack_pop (&mem_chunk->stack);
220 printf(" ----- %p\n", chunk);
it works! (Note that it does not work without the second printf).
So it seems that it is some optimization problem in GCC (probably related to the
use of inline assmebler).
------- You are receiving this mail because: -------
You are the assignee for the bug.
You are the QA contact for the bug.
More information about the Gstreamer-bugs
mailing list