Pc386 bsp problem
Thomas Doerfler
Thomas.Doerfler at embedded-brains.de
Wed May 23 15:25:24 UTC 2007
Stephane,
using "RTEMS_MINIMUM_STACK_SIZE" for a task doing heavy math might be
risky. I would expect that your task calls various subroutines, and will
therefore need much more stack. Try increasing it (take additional
64*1024 for a start), maybe you can use the stack checker later on to
analyze in more detail how much stack your task actually consumes.
Note that this "RTEMS_MINIMUM_STACK_SIZE" may also be too small for
other tasks in your system :-)
wkr,
Thomas.
Arquer Stephane schrieb:
> Hi,
>
> Most of time I don't have any execption number, the task is cancelled while the other are continuing to work and sometimes there is an exception raised but I can't catch it because the console displays lines in continuous. It is the same with remote gdb, I can't see the problem with gdb in remote mode, there is no message.
>
> This problem occurs when I use complex simulnk models. I think it is a memory configuration allowed for a task. I use floating point unit and I need to do some calculations.
> The task which call the step function is created as follow:
>
>
> //*************************************************************
> mode = RTEMS_PREEMPT + RTEMS_TIMESLICE + RTEMS_INTERRUPT_LEVEL(0);
> attributs = RTEMS_FLOATING_POINT + RTEMS_LOCAL ;
>
> status = rtems_task_create(nommage("simuLoi"),
> current_priority,
> RTEMS_MINIMUM_STACK_SIZE,
> mode,
> attributs,
> &id_tLoi);
> //*************************************************************
>
> And my configuration is :
>
> /*---------------------------------------------------------------------------------
> configuration information
> ----------------------------------------------------------------------------------*/
> #define CONFIGURE_TEST_NEEDS_CONSOLE_DRIVER
> #define CONFIGURE_TEST_NEEDS_CLOCK_DRIVER
> #define CONFIGURE_TEST_NEEDS_TIMER_DRIVER
> #define CONFIGURE_INIT_TASK_PRIORITY 110
> #define CONFIGURE_INIT_TASK_ATTRIBUTES RTEMS_FLOATING_POINT + RTEMS_LOCAL
> #define CONFIGURE_MAXIMUM_TASKS 128
> #define CONFIGURE_MAXIMUM_SEMAPHORES 20
> #define CONFIGURE_MAXIMUM_MESSAGE_QUEUES 10
> #define CONFIGURE_MAXIMUM_TIMERS 16
> #define CONFIGURE_MAXIMUM_PERIODS 16
> #define CONFIGURE_MICROSECONDS_PER_TICK 1000 // 1 tick every 1ms
> #define CONFIGURE_TICKS_PER_TIMESLICE 200
>
> #define CONFIGURE_RTEMS_INIT_TASKS_TABLE
>
> #ifdef pc386
> #define CONFIGURE_HAS_OWN_DEVICE_DRIVER_TABLE
> rtems_driver_address_table Device_drivers[5] = {
> CONSOLE_DRIVER_TABLE_ENTRY,
> TTY1_DRIVER_TABLE_ENTRY,
> TTY2_DRIVER_TABLE_ENTRY,
> CLOCK_DRIVER_TABLE_ENTRY,
> {NULL, NULL, NULL, NULL, NULL, NULL}
> };
> #endif //pc386
>
> #define CONFIGURE_EXTRA_TASK_STACKS (3 * RTEMS_MINIMUM_STACK_SIZE)
>
> #define CONFIGURE_NUMBER_OF_TERMIOS_PORTS 10
> #define CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS 10
>
> #include <confdefs.h>
>
> ----------------------------
>
> Thanks for your help.
>
> Stephane.
>
>
>> -----Message d'origine-----
>> De : Daron Chabot [mailto:daron.chabot at usask.ca]
>> Envoyé : mardi 15 mai 2007 17:35
>> À : Arquer Stephane
>> Cc : rtems-users at rtems.org
>> Objet : Re: RE : Pc386 bsp problem
>>
>>
>> On Mon, 2007-05-14 at 17:34 +0200, Arquer Stephane wrote:
>>> The failure is an execption raised bay the "simuLoi" task when it
>>> calls the step function. The task is canceled by the
>> scheduler, only
>>> "trwsr" and "trwsw" are running for a moment then a complete crash
>>> occurs. When I compile the same code with the leon3 bsp, tsim
>>> simulator works fine.
>> Exactly what information does the exception provide ?
>> (exception number,
>> etc.)
>>
>> Can you use a debugger (gdb) to step through
>> "task_gestion_loi( )" and see precisely where the exception
>> is being raised ?
>>
>>
>> -- dc
>>
>>
>
> _______________________________________________
> rtems-users mailing list
> rtems-users at rtems.com
> http://rtems.rtems.org/mailman/listinfo/rtems-users
--
--------------------------------------------
embedded brains GmbH
Thomas Doerfler Obere Lagerstr. 30
D-82178 Puchheim Germany
Tel. : +49-89-18 90 80 79-2
Fax : +49-89-18 90 80 79-9
email: Thomas.Doerfler at embedded-brains.de
PGP public key available on request
More information about the users
mailing list