[MPlayer-users] Stack size and threads
Sinisa Milivojevic
sinisa at mysql.com
Fri Dec 13 20:16:02 CET 2002
Hi!
I have suggestion regarding latest version of MPlayer.
You add freely 128 K to stack without making sure there is such space.
Some glibc come with smaller thread stack. Many apply patches, like
our patch that reduces stack size.
Therefore I sugest that in your init code, you use this:
(void) pthread_attr_init(&thread_attrib);
pthread_attr_setstacksize(&thread_attrib,1024*1024L);
pthread_attr_setscope(&thread_attrib, PTHREAD_SCOPE_SYSTEM);
You should of course declare pthread_attr_t thread_attrib as global
variable, and pass pointer to it in each pthread_create, instead of
NULL.
That would make things a bit more stable.
--
__ ___ ___ ____ __
/ |/ /_ __/ __/ __ \/ / Mr. Sinisa Milivojevic <sinisa at mysql.com>
/ /|_/ / // /\ \/ /_/ / /__ MySQL AB, Fulltime Developer
/_/ /_/\_, /___/\___\_\___/ Larnaca, Cyprus
<___/ www.mysql.com
Join MySQL Users Conference and Expo:
http://www.mysql.com/events/uc2003/
More information about the MPlayer-users
mailing list