[gst-devel] use of g_alloca

Steve Lhomme steve.lhomme at free.fr
Sun Sep 11 07:53:27 CEST 2005


 From what I understood, g_alloca() is not available on all platforms. 
But your change (and changes in the code) could help solve that and make 
it faster when possible.

Steve

Stefan Kost wrote:
> hi all,
> 
> what is the problem with using g_alloca() [1][2]? The advantages are 
> clear. In processing function the use of g_alloca for temporary data 
> blocks is better as it is really fast and cannot leak.
> I there  know plattform where it does not work? If so why aren't we use 
> the cpp to use g_malloc then? e.g.
> 
> #ifdef HAVE_G_ALLOC_A
> #define gst_alloca(size) g_alloca(size)
> #define gst_freea(mem)
> #else
> #define gst_alloca(size) g_malloc(size)
> #define gst_freea(mem) g_free(mem)
> #endif
> 
> Stefan
> 
> [1] 
> http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gstreamer/gst/gstpad.c.diff?r1=1.357.2.6&r2=1.357.2.7 
> 
> [2] 
> http://freedesktop.org/cgi-bin/viewcvs.cgi/gstreamer/gst-plugins/gst/audioconvert/gstchannelmix.c.diff?r1=1.6.2.5&r2=1.6.2.6 
> 
> 
> 
> 
> 
> -------------------------------------------------------
> SF.Net email is Sponsored by the Better Software Conference & EXPO
> September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices
> Agile & Plan-Driven Development * Managing Projects & Teams * Testing & QA
> Security * Process Improvement & Measurement * http://www.sqe.com/bsce5sf
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
> 

-- 
robUx4 on blog <http://robux4.blogspot.com/>




More information about the gstreamer-devel mailing list