Re: C++ static constructors and SMP

2013-10-21 Thread Chris Johns
On 22/10/13 5:30 AM, Sebastian Huber wrote: On 10/21/2013 04:59 PM, Chris Johns wrote: If you only configure one initialization thread, then the other processors will execute an idle thread. This assumes the primary core which enters the Init thread is always calling the static constructors p

Re: C++ static constructors and SMP

2013-10-21 Thread Sebastian Huber
On 10/21/2013 08:30 PM, Sebastian Huber wrote: What happens on Linux if you start thread in one of the static constructors on SMP? It runs and the user is responsible for managing this. What will not happen is 'main' is entered until all static constructors have been called. On my Linux th

Re: C++ static constructors and SMP

2013-10-21 Thread Sebastian Huber
On 10/21/2013 04:59 PM, Chris Johns wrote: If you only configure one initialization thread, then the other processors will execute an idle thread. This assumes the primary core which enters the Init thread is always calling the static constructors plus the primary code is calling Init. If a

Re: C++ static constructors and SMP

2013-10-21 Thread Chris Johns
On 21/10/13 6:25 PM, Sebastian Huber wrote: C++ has some severe problems with the current SMP support in RTEMS. It has some issues and these are being worked. If GCC is configured to use the RTEMS thread model some C++ constructs will end up in a fatal error. Yes the RTEMS thread model is

Re: C++ static constructors and SMP

2013-10-21 Thread Sebastian Huber
Hello, C++ has some severe problems with the current SMP support in RTEMS. If GCC is configured to use the RTEMS thread model some C++ constructs will end up in a fatal error. If GCC is configured to use the POSIX thread model, then some C++ constructs lead to unpredictable run-time behaviou