RTEMS 4.10.2Annotated Report
Tue Dec 13 19:32:43 2011
02007110 <_API_extensions_Run_postdriver>:
*
* _API_extensions_Run_postdriver
*/
void _API_extensions_Run_postdriver( void )
{
2007110: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
2007114: 23 00 80 77 sethi %hi(0x201dc00), %l1
2007118: e0 04 61 f4 ld [ %l1 + 0x1f4 ], %l0 ! 201ddf4 <_API_extensions_List>
200711c: a2 14 61 f4 or %l1, 0x1f4, %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2007120: a2 04 60 04 add %l1, 4, %l1
2007124: 80 a4 00 11 cmp %l0, %l1
2007128: 02 80 00 09 be 200714c <_API_extensions_Run_postdriver+0x3c><== NEVER TAKEN
200712c: 01 00 00 00 nop
* Currently all APIs configure this hook so it is always non-NULL.
*/
#if defined(FUNCTIONALITY_NOT_CURRENTLY_USED_BY_ANY_API)
if ( the_extension->postdriver_hook )
#endif
(*the_extension->postdriver_hook)();
2007130: c2 04 20 08 ld [ %l0 + 8 ], %g1
2007134: 9f c0 40 00 call %g1
2007138: 01 00 00 00 nop
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
!_Chain_Is_tail( &_API_extensions_List, the_node ) ;
the_node = the_node->next ) {
200713c: e0 04 00 00 ld [ %l0 ], %l0
void _API_extensions_Run_postdriver( void )
{
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
2007140: 80 a4 00 11 cmp %l0, %l1
2007144: 32 bf ff fc bne,a 2007134 <_API_extensions_Run_postdriver+0x24><== NEVER TAKEN
2007148: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED
200714c: 81 c7 e0 08 ret
2007150: 81 e8 00 00 restore
02007154 <_API_extensions_Run_postswitch>:
*
* _API_extensions_Run_postswitch
*/
void _API_extensions_Run_postswitch( void )
{
2007154: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
2007158: 23 00 80 77 sethi %hi(0x201dc00), %l1
200715c: e0 04 61 f4 ld [ %l1 + 0x1f4 ], %l0 ! 201ddf4 <_API_extensions_List>
2007160: a2 14 61 f4 or %l1, 0x1f4, %l1
2007164: a2 04 60 04 add %l1, 4, %l1
2007168: 80 a4 00 11 cmp %l0, %l1
200716c: 02 80 00 0a be 2007194 <_API_extensions_Run_postswitch+0x40><== NEVER TAKEN
2007170: 25 00 80 77 sethi %hi(0x201dc00), %l2
2007174: a4 14 a0 70 or %l2, 0x70, %l2 ! 201dc70 <_Thread_Executing>
* provide this hook.
*/
#if defined(RTEMS_ITRON_API)
if ( the_extension->postswitch_hook )
#endif
(*the_extension->postswitch_hook)( _Thread_Executing );
2007178: c2 04 20 0c ld [ %l0 + 0xc ], %g1
200717c: 9f c0 40 00 call %g1
2007180: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
!_Chain_Is_tail( &_API_extensions_List, the_node ) ;
the_node = the_node->next ) {
2007184: e0 04 00 00 ld [ %l0 ], %l0
void _API_extensions_Run_postswitch( void )
{
Chain_Node *the_node;
API_extensions_Control *the_extension;
for ( the_node = _API_extensions_List.first ;
2007188: 80 a4 00 11 cmp %l0, %l1
200718c: 32 bf ff fc bne,a 200717c <_API_extensions_Run_postswitch+0x28><== NEVER TAKEN
2007190: c2 04 20 0c ld [ %l0 + 0xc ], %g1 <== NOT EXECUTED
2007194: 81 c7 e0 08 ret
2007198: 81 e8 00 00 restore
020012a8 <_Barrier_Manager_initialization>:
#include <rtems/score/object.h>
#include <rtems/rtems/barrier.h>
void _Barrier_Manager_initialization(void)
{
}
20012a8: 81 c3 e0 08 retl
02017af0 <_CORE_message_queue_Broadcast>:
Objects_Id id __attribute__((unused)),
CORE_message_queue_API_mp_support_callout api_message_queue_mp_support __attribute__((unused)),
#endif
uint32_t *count
)
{
2017af0: 9d e3 bf a0 save %sp, -96, %sp
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
2017af4: c2 06 20 4c ld [ %i0 + 0x4c ], %g1
Objects_Id id __attribute__((unused)),
CORE_message_queue_API_mp_support_callout api_message_queue_mp_support __attribute__((unused)),
#endif
uint32_t *count
)
{
2017af8: a0 10 00 18 mov %i0, %l0
Thread_Control *the_thread;
uint32_t number_broadcasted;
Thread_Wait_information *waitp;
if ( size > the_message_queue->maximum_message_size ) {
2017afc: 80 a0 40 1a cmp %g1, %i2
2017b00: 0a 80 00 17 bcs 2017b5c <_CORE_message_queue_Broadcast+0x6c><== NEVER TAKEN
2017b04: b0 10 20 01 mov 1, %i0
* NOTE: This check is critical because threads can block on
* send and receive and this ensures that we are broadcasting
* the message to threads waiting to receive -- not to send.
*/
if ( the_message_queue->number_of_pending_messages != 0 ) {
2017b08: c2 04 20 48 ld [ %l0 + 0x48 ], %g1
2017b0c: 80 a0 60 00 cmp %g1, 0
2017b10: 02 80 00 0a be 2017b38 <_CORE_message_queue_Broadcast+0x48>
2017b14: a4 10 20 00 clr %l2
*count = 0;
2017b18: c0 27 40 00 clr [ %i5 ]
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
2017b1c: 81 c7 e0 08 ret
2017b20: 91 e8 20 00 restore %g0, 0, %o0
const void *source,
void *destination,
size_t size
)
{
memcpy(destination, source, size);
2017b24: d0 04 60 2c ld [ %l1 + 0x2c ], %o0
2017b28: 40 00 29 fb call 2022314 <memcpy>
2017b2c: a4 04 a0 01 inc %l2
buffer,
waitp->return_argument_second.mutable_object,
size
);
*(size_t *) the_thread->Wait.return_argument = size;
2017b30: c2 04 60 28 ld [ %l1 + 0x28 ], %g1
2017b34: f4 20 40 00 st %i2, [ %g1 ]
* There must be no pending messages if there is a thread waiting to
* receive a message.
*/
number_broadcasted = 0;
while ((the_thread =
_Thread_queue_Dequeue(&the_message_queue->Wait_queue))) {
2017b38: 40 00 0a 9e call 201a5b0 <_Thread_queue_Dequeue>
2017b3c: 90 10 00 10 mov %l0, %o0
2017b40: 92 10 00 19 mov %i1, %o1
2017b44: a2 10 00 08 mov %o0, %l1
/*
* There must be no pending messages if there is a thread waiting to
* receive a message.
*/
number_broadcasted = 0;
while ((the_thread =
2017b48: 80 a2 20 00 cmp %o0, 0
2017b4c: 12 bf ff f6 bne 2017b24 <_CORE_message_queue_Broadcast+0x34>
2017b50: 94 10 00 1a mov %i2, %o2
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_message_queue_mp_support) ( the_thread, id );
#endif
}
*count = number_broadcasted;
2017b54: e4 27 40 00 st %l2, [ %i5 ]
2017b58: b0 10 20 00 clr %i0
return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL;
}
2017b5c: 81 c7 e0 08 ret
2017b60: 81 e8 00 00 restore
020111b0 <_CORE_message_queue_Initialize>:
CORE_message_queue_Control *the_message_queue,
CORE_message_queue_Attributes *the_message_queue_attributes,
uint32_t maximum_pending_messages,
size_t maximum_message_size
)
{
20111b0: 9d e3 bf a0 save %sp, -96, %sp
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
the_message_queue->number_of_pending_messages = 0;
20111b4: c0 26 20 48 clr [ %i0 + 0x48 ]
)
{
size_t message_buffering_required;
size_t allocated_message_size;
the_message_queue->maximum_pending_messages = maximum_pending_messages;
20111b8: f4 26 20 44 st %i2, [ %i0 + 0x44 ]
the_message_queue->number_of_pending_messages = 0;
the_message_queue->maximum_message_size = maximum_message_size;
20111bc: f6 26 20 4c st %i3, [ %i0 + 0x4c ]
/*
* Round size up to multiple of a pointer for chain init and
* check for overflow on adding overhead to each message.
*/
allocated_message_size = maximum_message_size;
if (allocated_message_size & (sizeof(uint32_t) - 1)) {
20111c0: 80 8e e0 03 btst 3, %i3
20111c4: 02 80 00 09 be 20111e8 <_CORE_message_queue_Initialize+0x38>
20111c8: a2 10 00 1b mov %i3, %l1
allocated_message_size += sizeof(uint32_t);
20111cc: a2 06 e0 04 add %i3, 4, %l1
allocated_message_size &= ~(sizeof(uint32_t) - 1);
20111d0: a2 0c 7f fc and %l1, -4, %l1
}
if (allocated_message_size < maximum_message_size)
20111d4: 80 a6 c0 11 cmp %i3, %l1
20111d8: 08 80 00 05 bleu 20111ec <_CORE_message_queue_Initialize+0x3c><== ALWAYS TAKEN
20111dc: a0 04 60 10 add %l1, 0x10, %l0
STATES_WAITING_FOR_MESSAGE,
CORE_MESSAGE_QUEUE_STATUS_TIMEOUT
);
return true;
}
20111e0: 81 c7 e0 08 ret
20111e4: 91 e8 20 00 restore %g0, 0, %o0
/*
* Calculate how much total memory is required for message buffering and
* check for overflow on the multiplication.
*/
message_buffering_required = (size_t) maximum_pending_messages *
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
20111e8: a0 04 60 10 add %l1, 0x10, %l0
/*
* Calculate how much total memory is required for message buffering and
* check for overflow on the multiplication.
*/
message_buffering_required = (size_t) maximum_pending_messages *
20111ec: 92 10 00 1a mov %i2, %o1
20111f0: 40 00 53 06 call 2025e08 <.umul>
20111f4: 90 10 00 10 mov %l0, %o0
(allocated_message_size + sizeof(CORE_message_queue_Buffer_control));
if (message_buffering_required < allocated_message_size)
20111f8: 80 a2 00 11 cmp %o0, %l1
20111fc: 0a bf ff f9 bcs 20111e0 <_CORE_message_queue_Initialize+0x30><== NEVER TAKEN
2011200: 01 00 00 00 nop
return false;
/*
* Attempt to allocate the message memory
*/
the_message_queue->message_buffers = (CORE_message_queue_Buffer *)
2011204: 40 00 0c 7a call 20143ec <_Workspace_Allocate>
2011208: 01 00 00 00 nop
_Workspace_Allocate( message_buffering_required );
if (the_message_queue->message_buffers == 0)
201120c: 80 a2 20 00 cmp %o0, 0
2011210: 02 bf ff f4 be 20111e0 <_CORE_message_queue_Initialize+0x30>
2011214: d0 26 20 5c st %o0, [ %i0 + 0x5c ]
/*
* Initialize the pool of inactive messages, pending messages,
* and set of waiting threads.
*/
_Chain_Initialize (
2011218: 92 10 00 08 mov %o0, %o1
201121c: 94 10 00 1a mov %i2, %o2
2011220: 90 06 20 60 add %i0, 0x60, %o0
2011224: 40 00 19 cf call 2017960 <_Chain_Initialize>
2011228: 96 10 00 10 mov %l0, %o3
allocated_message_size + sizeof( CORE_message_queue_Buffer_control )
);
_Chain_Initialize_empty( &the_message_queue->Pending_messages );
_Thread_queue_Initialize(
201122c: c2 06 40 00 ld [ %i1 ], %g1
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2011230: c0 26 20 54 clr [ %i0 + 0x54 ]
2011234: 82 18 60 01 xor %g1, 1, %g1
2011238: 80 a0 00 01 cmp %g0, %g1
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
201123c: 82 06 20 54 add %i0, 0x54, %g1
2011240: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2011244: 82 06 20 50 add %i0, 0x50, %g1
2011248: 90 10 00 18 mov %i0, %o0
201124c: c2 26 20 58 st %g1, [ %i0 + 0x58 ]
2011250: 92 60 3f ff subx %g0, -1, %o1
2011254: 94 10 20 80 mov 0x80, %o2
2011258: 96 10 20 06 mov 6, %o3
201125c: 40 00 09 22 call 20136e4 <_Thread_queue_Initialize>
2011260: b0 10 20 01 mov 1, %i0
THREAD_QUEUE_DISCIPLINE_PRIORITY : THREAD_QUEUE_DISCIPLINE_FIFO,
STATES_WAITING_FOR_MESSAGE,
CORE_MESSAGE_QUEUE_STATUS_TIMEOUT
);
return true;
2011264: 81 c7 e0 08 ret
2011268: 81 e8 00 00 restore
020074bc <_CORE_mutex_Seize>:
Objects_Id _id,
bool _wait,
Watchdog_Interval _timeout,
ISR_Level _level
)
{
20074bc: 9d e3 bf a0 save %sp, -96, %sp
_CORE_mutex_Seize_body( _the_mutex, _id, _wait, _timeout, _level );
20074c0: 21 00 80 76 sethi %hi(0x201d800), %l0
20074c4: c2 04 23 b0 ld [ %l0 + 0x3b0 ], %g1 ! 201dbb0 <_Thread_Dispatch_disable_level>
20074c8: 80 a0 60 00 cmp %g1, 0
20074cc: 02 80 00 05 be 20074e0 <_CORE_mutex_Seize+0x24>
20074d0: f8 27 a0 54 st %i4, [ %fp + 0x54 ]
20074d4: 80 8e a0 ff btst 0xff, %i2
20074d8: 12 80 00 1a bne 2007540 <_CORE_mutex_Seize+0x84> <== ALWAYS TAKEN
20074dc: 03 00 80 77 sethi %hi(0x201dc00), %g1
20074e0: 90 10 00 18 mov %i0, %o0
20074e4: 40 00 18 a1 call 200d768 <_CORE_mutex_Seize_interrupt_trylock>
20074e8: 92 07 a0 54 add %fp, 0x54, %o1
20074ec: 80 a2 20 00 cmp %o0, 0
20074f0: 02 80 00 12 be 2007538 <_CORE_mutex_Seize+0x7c>
20074f4: 80 8e a0 ff btst 0xff, %i2
20074f8: 02 80 00 1a be 2007560 <_CORE_mutex_Seize+0xa4>
20074fc: 01 00 00 00 nop
2007500: c4 04 23 b0 ld [ %l0 + 0x3b0 ], %g2
2007504: 03 00 80 77 sethi %hi(0x201dc00), %g1
2007508: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 201dc70 <_Thread_Executing>
200750c: f2 20 60 20 st %i1, [ %g1 + 0x20 ]
2007510: f0 20 60 44 st %i0, [ %g1 + 0x44 ]
2007514: 82 00 a0 01 add %g2, 1, %g1
2007518: c2 24 23 b0 st %g1, [ %l0 + 0x3b0 ]
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section (
Thread_queue_Control *the_thread_queue
)
{
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
200751c: 82 10 20 01 mov 1, %g1
2007520: c2 26 20 30 st %g1, [ %i0 + 0x30 ]
2007524: 7f ff ea e4 call 20020b4 <sparc_enable_interrupts>
2007528: d0 07 a0 54 ld [ %fp + 0x54 ], %o0
200752c: 90 10 00 18 mov %i0, %o0
2007530: 7f ff ff c0 call 2007430 <_CORE_mutex_Seize_interrupt_blocking>
2007534: 92 10 00 1b mov %i3, %o1
2007538: 81 c7 e0 08 ret
200753c: 81 e8 00 00 restore
2007540: c2 00 61 50 ld [ %g1 + 0x150 ], %g1
2007544: 80 a0 60 01 cmp %g1, 1
2007548: 28 bf ff e7 bleu,a 20074e4 <_CORE_mutex_Seize+0x28>
200754c: 90 10 00 18 mov %i0, %o0
2007550: 90 10 20 00 clr %o0
2007554: 92 10 20 00 clr %o1
2007558: 40 00 01 c5 call 2007c6c <_Internal_error_Occurred>
200755c: 94 10 20 13 mov 0x13, %o2
2007560: 7f ff ea d5 call 20020b4 <sparc_enable_interrupts>
2007564: d0 07 a0 54 ld [ %fp + 0x54 ], %o0
2007568: 03 00 80 77 sethi %hi(0x201dc00), %g1
200756c: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 201dc70 <_Thread_Executing>
2007570: 84 10 20 01 mov 1, %g2
2007574: c4 20 60 34 st %g2, [ %g1 + 0x34 ]
2007578: 81 c7 e0 08 ret
200757c: 81 e8 00 00 restore
0200d768 <_CORE_mutex_Seize_interrupt_trylock>:
#if defined(__RTEMS_DO_NOT_INLINE_CORE_MUTEX_SEIZE__)
int _CORE_mutex_Seize_interrupt_trylock(
CORE_mutex_Control *the_mutex,
ISR_Level *level_p
)
{
200d768: 9d e3 bf a0 save %sp, -96, %sp
{
Thread_Control *executing;
/* disabled when you get here */
executing = _Thread_Executing;
200d76c: 03 00 80 77 sethi %hi(0x201dc00), %g1
200d770: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 201dc70 <_Thread_Executing>
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
200d774: c0 20 60 34 clr [ %g1 + 0x34 ]
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
200d778: c4 06 20 50 ld [ %i0 + 0x50 ], %g2
200d77c: 80 a0 a0 00 cmp %g2, 0
200d780: 22 80 00 13 be,a 200d7cc <_CORE_mutex_Seize_interrupt_trylock+0x64>
200d784: c4 06 20 5c ld [ %i0 + 0x5c ], %g2
the_mutex->lock = CORE_MUTEX_LOCKED;
200d788: c0 26 20 50 clr [ %i0 + 0x50 ]
the_mutex->holder = executing;
the_mutex->holder_id = executing->Object.id;
200d78c: c6 00 60 08 ld [ %g1 + 8 ], %g3
*/
RTEMS_INLINE_ROUTINE bool _CORE_mutex_Is_inherit_priority(
CORE_mutex_Attributes *the_attribute
)
{
return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT;
200d790: c4 06 20 48 ld [ %i0 + 0x48 ], %g2
executing = _Thread_Executing;
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
the_mutex->lock = CORE_MUTEX_LOCKED;
the_mutex->holder = executing;
the_mutex->holder_id = executing->Object.id;
200d794: c6 26 20 60 st %g3, [ %i0 + 0x60 ]
executing = _Thread_Executing;
executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL;
if ( !_CORE_mutex_Is_locked( the_mutex ) ) {
the_mutex->lock = CORE_MUTEX_LOCKED;
the_mutex->holder = executing;
200d798: c2 26 20 5c st %g1, [ %i0 + 0x5c ]
the_mutex->holder_id = executing->Object.id;
the_mutex->nest_count = 1;
200d79c: 86 10 20 01 mov 1, %g3
if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ||
200d7a0: 80 a0 a0 02 cmp %g2, 2
200d7a4: 02 80 00 0f be 200d7e0 <_CORE_mutex_Seize_interrupt_trylock+0x78>
200d7a8: c6 26 20 54 st %g3, [ %i0 + 0x54 ]
200d7ac: 80 a0 a0 03 cmp %g2, 3
200d7b0: 22 80 00 1f be,a 200d82c <_CORE_mutex_Seize_interrupt_trylock+0xc4>
200d7b4: da 00 60 1c ld [ %g1 + 0x1c ], %o5
the_mutex->nest_count++;
_ISR_Enable( *level_p );
return 0;
case CORE_MUTEX_NESTING_IS_ERROR:
executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
_ISR_Enable( *level_p );
200d7b8: d0 06 40 00 ld [ %i1 ], %o0
200d7bc: 7f ff d2 3e call 20020b4 <sparc_enable_interrupts>
200d7c0: b0 10 20 00 clr %i0
200d7c4: 81 c7 e0 08 ret
200d7c8: 81 e8 00 00 restore
/*
* At this point, we know the mutex was not available. If this thread
* is the thread that has locked the mutex, let's see if we are allowed
* to nest access.
*/
if ( _Thread_Is_executing( the_mutex->holder ) ) {
200d7cc: 80 a0 40 02 cmp %g1, %g2
200d7d0: 22 80 00 0c be,a 200d800 <_CORE_mutex_Seize_interrupt_trylock+0x98>
200d7d4: c4 06 20 40 ld [ %i0 + 0x40 ], %g2
return _CORE_mutex_Seize_interrupt_trylock_body( the_mutex, level_p );
}
200d7d8: 81 c7 e0 08 ret
200d7dc: 91 e8 20 01 restore %g0, 1, %o0
_Chain_Prepend_unprotected( &executing->lock_mutex,
&the_mutex->queue.lock_queue );
the_mutex->queue.priority_before = executing->current_priority;
#endif
executing->resource_count++;
200d7e0: c4 00 60 1c ld [ %g1 + 0x1c ], %g2
200d7e4: 84 00 a0 01 inc %g2
200d7e8: c4 20 60 1c st %g2, [ %g1 + 0x1c ]
the_mutex->nest_count++;
_ISR_Enable( *level_p );
return 0;
case CORE_MUTEX_NESTING_IS_ERROR:
executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
_ISR_Enable( *level_p );
200d7ec: d0 06 40 00 ld [ %i1 ], %o0
200d7f0: 7f ff d2 31 call 20020b4 <sparc_enable_interrupts>
200d7f4: b0 10 20 00 clr %i0
200d7f8: 81 c7 e0 08 ret
200d7fc: 81 e8 00 00 restore
* At this point, we know the mutex was not available. If this thread
* is the thread that has locked the mutex, let's see if we are allowed
* to nest access.
*/
if ( _Thread_Is_executing( the_mutex->holder ) ) {
switch ( the_mutex->Attributes.lock_nesting_behavior ) {
200d800: 80 a0 a0 00 cmp %g2, 0
200d804: 12 80 00 2b bne 200d8b0 <_CORE_mutex_Seize_interrupt_trylock+0x148>
200d808: 80 a0 a0 01 cmp %g2, 1
case CORE_MUTEX_NESTING_ACQUIRES:
the_mutex->nest_count++;
200d80c: c2 06 20 54 ld [ %i0 + 0x54 ], %g1
200d810: 82 00 60 01 inc %g1
200d814: c2 26 20 54 st %g1, [ %i0 + 0x54 ]
_ISR_Enable( *level_p );
200d818: d0 06 40 00 ld [ %i1 ], %o0
200d81c: 7f ff d2 26 call 20020b4 <sparc_enable_interrupts>
200d820: b0 10 20 00 clr %i0
200d824: 81 c7 e0 08 ret
200d828: 81 e8 00 00 restore
{
Priority_Control ceiling;
Priority_Control current;
ceiling = the_mutex->Attributes.priority_ceiling;
current = executing->current_priority;
200d82c: c4 00 60 14 ld [ %g1 + 0x14 ], %g2
_Chain_Prepend_unprotected( &executing->lock_mutex,
&the_mutex->queue.lock_queue );
the_mutex->queue.priority_before = executing->current_priority;
#endif
executing->resource_count++;
200d830: 88 03 60 01 add %o5, 1, %g4
200d834: c8 20 60 1c st %g4, [ %g1 + 0x1c ]
*/
{
Priority_Control ceiling;
Priority_Control current;
ceiling = the_mutex->Attributes.priority_ceiling;
200d838: c8 06 20 4c ld [ %i0 + 0x4c ], %g4
current = executing->current_priority;
if ( current == ceiling ) {
200d83c: 80 a1 00 02 cmp %g4, %g2
200d840: 02 bf ff de be 200d7b8 <_CORE_mutex_Seize_interrupt_trylock+0x50>
200d844: 01 00 00 00 nop
_ISR_Enable( *level_p );
return 0;
}
if ( current > ceiling ) {
200d848: 1a 80 00 11 bcc 200d88c <_CORE_mutex_Seize_interrupt_trylock+0x124>
200d84c: 84 10 20 06 mov 6, %g2 ! 6 <PROM_START+0x6>
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
200d850: 03 00 80 76 sethi %hi(0x201d800), %g1
200d854: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201dbb0 <_Thread_Dispatch_disable_level>
200d858: 84 00 a0 01 inc %g2
200d85c: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
_Thread_Disable_dispatch();
_ISR_Enable( *level_p );
200d860: 7f ff d2 15 call 20020b4 <sparc_enable_interrupts>
200d864: d0 06 40 00 ld [ %i1 ], %o0
_Thread_Change_priority(
200d868: d2 06 20 4c ld [ %i0 + 0x4c ], %o1
200d86c: d0 06 20 5c ld [ %i0 + 0x5c ], %o0
200d870: 94 10 20 00 clr %o2
200d874: 7f ff eb 83 call 2008680 <_Thread_Change_priority>
200d878: b0 10 20 00 clr %i0
the_mutex->holder,
the_mutex->Attributes.priority_ceiling,
false
);
_Thread_Enable_dispatch();
200d87c: 7f ff ed 1f call 2008cf8 <_Thread_Enable_dispatch>
200d880: 01 00 00 00 nop
200d884: 81 c7 e0 08 ret
200d888: 81 e8 00 00 restore
return 0;
}
/* if ( current < ceiling ) */ {
executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED;
200d88c: c4 20 60 34 st %g2, [ %g1 + 0x34 ]
the_mutex->lock = CORE_MUTEX_UNLOCKED;
200d890: c6 26 20 50 st %g3, [ %i0 + 0x50 ]
the_mutex->nest_count = 0; /* undo locking above */
200d894: c0 26 20 54 clr [ %i0 + 0x54 ]
executing->resource_count--; /* undo locking above */
200d898: da 20 60 1c st %o5, [ %g1 + 0x1c ]
_ISR_Enable( *level_p );
200d89c: d0 06 40 00 ld [ %i1 ], %o0
200d8a0: 7f ff d2 05 call 20020b4 <sparc_enable_interrupts>
200d8a4: b0 10 20 00 clr %i0
200d8a8: 81 c7 e0 08 ret
200d8ac: 81 e8 00 00 restore
* At this point, we know the mutex was not available. If this thread
* is the thread that has locked the mutex, let's see if we are allowed
* to nest access.
*/
if ( _Thread_Is_executing( the_mutex->holder ) ) {
switch ( the_mutex->Attributes.lock_nesting_behavior ) {
200d8b0: 12 bf ff ca bne 200d7d8 <_CORE_mutex_Seize_interrupt_trylock+0x70><== ALWAYS TAKEN
200d8b4: 84 10 20 02 mov 2, %g2
case CORE_MUTEX_NESTING_ACQUIRES:
the_mutex->nest_count++;
_ISR_Enable( *level_p );
return 0;
case CORE_MUTEX_NESTING_IS_ERROR:
executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED;
200d8b8: 10 bf ff c0 b 200d7b8 <_CORE_mutex_Seize_interrupt_trylock+0x50><== NOT EXECUTED
200d8bc: c4 20 60 34 st %g2, [ %g1 + 0x34 ] <== NOT EXECUTED
0200771c <_CORE_semaphore_Surrender>:
CORE_semaphore_Status _CORE_semaphore_Surrender(
CORE_semaphore_Control *the_semaphore,
Objects_Id id,
CORE_semaphore_API_mp_support_callout api_semaphore_mp_support
)
{
200771c: 9d e3 bf a0 save %sp, -96, %sp
2007720: a0 10 00 18 mov %i0, %l0
ISR_Level level;
CORE_semaphore_Status status;
status = CORE_SEMAPHORE_STATUS_SUCCESSFUL;
if ( (the_thread = _Thread_queue_Dequeue(&the_semaphore->Wait_queue)) ) {
2007724: b0 10 20 00 clr %i0
2007728: 40 00 06 79 call 200910c <_Thread_queue_Dequeue>
200772c: 90 10 00 10 mov %l0, %o0
2007730: 80 a2 20 00 cmp %o0, 0
2007734: 02 80 00 04 be 2007744 <_CORE_semaphore_Surrender+0x28>
2007738: 01 00 00 00 nop
status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED;
_ISR_Enable( level );
}
return status;
}
200773c: 81 c7 e0 08 ret
2007740: 81 e8 00 00 restore
if ( !_Objects_Is_local_id( the_thread->Object.id ) )
(*api_semaphore_mp_support) ( the_thread, id );
#endif
} else {
_ISR_Disable( level );
2007744: 7f ff ea 58 call 20020a4 <sparc_disable_interrupts>
2007748: 01 00 00 00 nop
if ( the_semaphore->count < the_semaphore->Attributes.maximum_count )
200774c: c2 04 20 48 ld [ %l0 + 0x48 ], %g1
2007750: c4 04 20 40 ld [ %l0 + 0x40 ], %g2
2007754: 80 a0 40 02 cmp %g1, %g2
2007758: 1a 80 00 05 bcc 200776c <_CORE_semaphore_Surrender+0x50> <== NEVER TAKEN
200775c: b0 10 20 04 mov 4, %i0
the_semaphore->count += 1;
2007760: 82 00 60 01 inc %g1
2007764: b0 10 20 00 clr %i0
2007768: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
else
status = CORE_SEMAPHORE_MAXIMUM_COUNT_EXCEEDED;
_ISR_Enable( level );
200776c: 7f ff ea 52 call 20020b4 <sparc_enable_interrupts>
2007770: 01 00 00 00 nop
}
return status;
}
2007774: 81 c7 e0 08 ret
2007778: 81 e8 00 00 restore
0200d64c <_Chain_Initialize>:
Chain_Node *current;
Chain_Node *next;
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
200d64c: c0 22 20 04 clr [ %o0 + 4 ]
next = starting_address;
while ( count-- ) {
200d650: 80 a2 a0 00 cmp %o2, 0
200d654: 02 80 00 08 be 200d674 <_Chain_Initialize+0x28> <== NEVER TAKEN
200d658: 82 10 00 08 mov %o0, %g1
current->next = next;
next->previous = current;
200d65c: c2 22 60 04 st %g1, [ %o1 + 4 ]
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
next = starting_address;
while ( count-- ) {
current->next = next;
200d660: d2 20 40 00 st %o1, [ %g1 ]
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
next = starting_address;
while ( count-- ) {
200d664: 94 82 bf ff addcc %o2, -1, %o2
current->next = next;
next->previous = current;
current = next;
next = (Chain_Node *)
200d668: 82 10 00 09 mov %o1, %g1
count = number_nodes;
current = _Chain_Head( the_chain );
the_chain->permanent_null = NULL;
next = starting_address;
while ( count-- ) {
200d66c: 12 bf ff fc bne 200d65c <_Chain_Initialize+0x10>
200d670: 92 02 40 0b add %o1, %o3, %o1
next->previous = current;
current = next;
next = (Chain_Node *)
_Addresses_Add_offset( (void *) next, node_size );
}
current->next = _Chain_Tail( the_chain );
200d674: 84 02 20 04 add %o0, 4, %g2
200d678: c4 20 40 00 st %g2, [ %g1 ]
the_chain->last = current;
}
200d67c: 81 c3 e0 08 retl
200d680: c2 22 20 08 st %g1, [ %o0 + 8 ]
020012b0 <_Dual_ported_memory_Manager_initialization>:
#include <rtems/rtems/types.h>
#include <rtems/rtems/dpmem.h>
void _Dual_ported_memory_Manager_initialization(void)
{
}
20012b0: 81 c3 e0 08 retl
020012b8 <_Event_Manager_initialization>:
#include <rtems/score/thread.h>
#include <rtems/score/interr.h>
void _Event_Manager_initialization(void)
{
}
20012b8: 81 c3 e0 08 retl
020062cc <_Event_Seize>:
rtems_event_set event_in,
rtems_option option_set,
rtems_interval ticks,
rtems_event_set *event_out
)
{
20062cc: 9d e3 bf a0 save %sp, -96, %sp
rtems_event_set pending_events;
ISR_Level level;
RTEMS_API_Control *api;
Thread_blocking_operation_States sync_state;
executing = _Thread_Executing;
20062d0: 03 00 80 77 sethi %hi(0x201dc00), %g1
20062d4: e0 00 60 70 ld [ %g1 + 0x70 ], %l0 ! 201dc70 <_Thread_Executing>
executing->Wait.return_code = RTEMS_SUCCESSFUL;
20062d8: c0 24 20 34 clr [ %l0 + 0x34 ]
api = executing->API_Extensions[ THREAD_API_RTEMS ];
_ISR_Disable( level );
20062dc: 7f ff ef 72 call 20020a4 <sparc_disable_interrupts>
20062e0: e4 04 21 60 ld [ %l0 + 0x160 ], %l2
pending_events = api->pending_events;
20062e4: c2 04 80 00 ld [ %l2 ], %g1
seized_events = _Event_sets_Get( pending_events, event_in );
if ( !_Event_sets_Is_empty( seized_events ) &&
20062e8: a2 8e 00 01 andcc %i0, %g1, %l1
20062ec: 02 80 00 07 be 2006308 <_Event_Seize+0x3c>
20062f0: 80 8e 60 01 btst 1, %i1
20062f4: 80 a6 00 11 cmp %i0, %l1
20062f8: 02 80 00 23 be 2006384 <_Event_Seize+0xb8>
20062fc: 80 8e 60 02 btst 2, %i1
2006300: 12 80 00 21 bne 2006384 <_Event_Seize+0xb8> <== ALWAYS TAKEN
2006304: 80 8e 60 01 btst 1, %i1
_ISR_Enable( level );
*event_out = seized_events;
return;
}
if ( _Options_Is_no_wait( option_set ) ) {
2006308: 12 80 00 18 bne 2006368 <_Event_Seize+0x9c>
200630c: 82 10 20 01 mov 1, %g1
* set properly when we are marked as in the event critical section.
*
* NOTE: Since interrupts are disabled, this isn't that much of an
* issue but better safe than sorry.
*/
executing->Wait.option = (uint32_t) option_set;
2006310: f2 24 20 30 st %i1, [ %l0 + 0x30 ]
executing->Wait.count = (uint32_t) event_in;
2006314: f0 24 20 24 st %i0, [ %l0 + 0x24 ]
executing->Wait.return_argument = event_out;
2006318: f6 24 20 28 st %i3, [ %l0 + 0x28 ]
_Event_Sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
200631c: 33 00 80 77 sethi %hi(0x201dc00), %i1
2006320: c2 26 62 6c st %g1, [ %i1 + 0x26c ] ! 201de6c <_Event_Sync_state>
_ISR_Enable( level );
2006324: 7f ff ef 64 call 20020b4 <sparc_enable_interrupts>
2006328: 01 00 00 00 nop
if ( ticks ) {
200632c: 80 a6 a0 00 cmp %i2, 0
2006330: 32 80 00 1c bne,a 20063a0 <_Event_Seize+0xd4>
2006334: c2 04 20 08 ld [ %l0 + 8 ], %g1
NULL
);
_Watchdog_Insert_ticks( &executing->Timer, ticks );
}
_Thread_Set_state( executing, STATES_WAITING_FOR_EVENT );
2006338: 90 10 00 10 mov %l0, %o0
200633c: 40 00 0c f5 call 2009710 <_Thread_Set_state>
2006340: 92 10 21 00 mov 0x100, %o1
_ISR_Disable( level );
2006344: 7f ff ef 58 call 20020a4 <sparc_disable_interrupts>
2006348: 01 00 00 00 nop
sync_state = _Event_Sync_state;
200634c: f0 06 62 6c ld [ %i1 + 0x26c ], %i0
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
2006350: c0 26 62 6c clr [ %i1 + 0x26c ]
if ( sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
2006354: 80 a6 20 01 cmp %i0, 1
2006358: 02 80 00 1f be 20063d4 <_Event_Seize+0x108>
200635c: b2 10 00 10 mov %l0, %i1
* An interrupt completed the thread's blocking request.
* The blocking thread was satisfied by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
_Thread_blocking_operation_Cancel( sync_state, executing, level );
2006360: 40 00 08 b1 call 2008624 <_Thread_blocking_operation_Cancel>
2006364: 95 e8 00 08 restore %g0, %o0, %o2
*event_out = seized_events;
return;
}
if ( _Options_Is_no_wait( option_set ) ) {
_ISR_Enable( level );
2006368: 7f ff ef 53 call 20020b4 <sparc_enable_interrupts>
200636c: 01 00 00 00 nop
executing->Wait.return_code = RTEMS_UNSATISFIED;
2006370: 82 10 20 0d mov 0xd, %g1 ! d <PROM_START+0xd>
2006374: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
*event_out = seized_events;
2006378: e2 26 c0 00 st %l1, [ %i3 ]
200637c: 81 c7 e0 08 ret
2006380: 81 e8 00 00 restore
pending_events = api->pending_events;
seized_events = _Event_sets_Get( pending_events, event_in );
if ( !_Event_sets_Is_empty( seized_events ) &&
(seized_events == event_in || _Options_Is_any( option_set )) ) {
api->pending_events =
2006384: 82 28 40 11 andn %g1, %l1, %g1
2006388: c2 24 80 00 st %g1, [ %l2 ]
_Event_sets_Clear( pending_events, seized_events );
_ISR_Enable( level );
200638c: 7f ff ef 4a call 20020b4 <sparc_enable_interrupts>
2006390: 01 00 00 00 nop
*event_out = seized_events;
2006394: e2 26 c0 00 st %l1, [ %i3 ]
return;
2006398: 81 c7 e0 08 ret
200639c: 81 e8 00 00 restore
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
20063a0: f4 24 20 54 st %i2, [ %l0 + 0x54 ]
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
the_watchdog->id = id;
20063a4: c2 24 20 68 st %g1, [ %l0 + 0x68 ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
20063a8: 03 00 80 19 sethi %hi(0x2006400), %g1
20063ac: 82 10 61 70 or %g1, 0x170, %g1 ! 2006570 <_Event_Timeout>
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
20063b0: c0 24 20 50 clr [ %l0 + 0x50 ]
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
20063b4: c0 24 20 6c clr [ %l0 + 0x6c ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
20063b8: c2 24 20 64 st %g1, [ %l0 + 0x64 ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
20063bc: 11 00 80 77 sethi %hi(0x201dc00), %o0
20063c0: 92 04 20 48 add %l0, 0x48, %o1
20063c4: 40 00 0e dd call 2009f38 <_Watchdog_Insert>
20063c8: 90 12 20 90 or %o0, 0x90, %o0
NULL
);
_Watchdog_Insert_ticks( &executing->Timer, ticks );
}
_Thread_Set_state( executing, STATES_WAITING_FOR_EVENT );
20063cc: 10 bf ff dc b 200633c <_Event_Seize+0x70>
20063d0: 90 10 00 10 mov %l0, %o0
_ISR_Disable( level );
sync_state = _Event_Sync_state;
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
if ( sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) {
_ISR_Enable( level );
20063d4: 7f ff ef 38 call 20020b4 <sparc_enable_interrupts>
20063d8: 91 e8 00 08 restore %g0, %o0, %o0
02006438 <_Event_Surrender>:
*/
void _Event_Surrender(
Thread_Control *the_thread
)
{
2006438: 9d e3 bf a0 save %sp, -96, %sp
rtems_event_set event_condition;
rtems_event_set seized_events;
rtems_option option_set;
RTEMS_API_Control *api;
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
200643c: e0 06 21 60 ld [ %i0 + 0x160 ], %l0
option_set = (rtems_option) the_thread->Wait.option;
_ISR_Disable( level );
2006440: 7f ff ef 19 call 20020a4 <sparc_disable_interrupts>
2006444: e4 06 20 30 ld [ %i0 + 0x30 ], %l2
2006448: a2 10 00 08 mov %o0, %l1
pending_events = api->pending_events;
200644c: c4 04 00 00 ld [ %l0 ], %g2
event_condition = (rtems_event_set) the_thread->Wait.count;
2006450: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
seized_events = _Event_sets_Get( pending_events, event_condition );
/*
* No events were seized in this operation
*/
if ( _Event_sets_Is_empty( seized_events ) ) {
2006454: 86 88 40 02 andcc %g1, %g2, %g3
2006458: 02 80 00 3a be 2006540 <_Event_Surrender+0x108>
200645c: 09 00 80 77 sethi %hi(0x201dc00), %g4
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
2006460: c8 01 20 4c ld [ %g4 + 0x4c ], %g4 ! 201dc4c <_ISR_Nest_level>
2006464: 80 a1 20 00 cmp %g4, 0
2006468: 12 80 00 1d bne 20064dc <_Event_Surrender+0xa4>
200646c: 09 00 80 77 sethi %hi(0x201dc00), %g4
}
/*
* Otherwise, this is a normal send to another thread
*/
if ( _States_Is_waiting_for_event( the_thread->current_state ) ) {
2006470: c8 06 20 10 ld [ %i0 + 0x10 ], %g4
2006474: 80 89 21 00 btst 0x100, %g4
2006478: 02 80 00 32 be 2006540 <_Event_Surrender+0x108>
200647c: 80 a0 40 03 cmp %g1, %g3
if ( seized_events == event_condition || _Options_Is_any( option_set ) ) {
2006480: 02 80 00 04 be 2006490 <_Event_Surrender+0x58>
2006484: 80 8c a0 02 btst 2, %l2
2006488: 02 80 00 2e be 2006540 <_Event_Surrender+0x108> <== NEVER TAKEN
200648c: 01 00 00 00 nop
api->pending_events = _Event_sets_Clear( pending_events, seized_events );
the_thread->Wait.count = 0;
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
2006490: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
/*
* Otherwise, this is a normal send to another thread
*/
if ( _States_Is_waiting_for_event( the_thread->current_state ) ) {
if ( seized_events == event_condition || _Options_Is_any( option_set ) ) {
api->pending_events = _Event_sets_Clear( pending_events, seized_events );
2006494: 84 28 80 03 andn %g2, %g3, %g2
2006498: c4 24 00 00 st %g2, [ %l0 ]
the_thread->Wait.count = 0;
200649c: c0 26 20 24 clr [ %i0 + 0x24 ]
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
20064a0: c6 20 40 00 st %g3, [ %g1 ]
_ISR_Flash( level );
20064a4: 7f ff ef 04 call 20020b4 <sparc_enable_interrupts>
20064a8: 90 10 00 11 mov %l1, %o0
20064ac: 7f ff ee fe call 20020a4 <sparc_disable_interrupts>
20064b0: 01 00 00 00 nop
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
20064b4: c2 06 20 50 ld [ %i0 + 0x50 ], %g1
20064b8: 80 a0 60 02 cmp %g1, 2
20064bc: 02 80 00 23 be 2006548 <_Event_Surrender+0x110>
20064c0: 82 10 20 03 mov 3, %g1
_ISR_Enable( level );
20064c4: 90 10 00 11 mov %l1, %o0
20064c8: 7f ff ee fb call 20020b4 <sparc_enable_interrupts>
20064cc: 33 04 00 ff sethi %hi(0x1003fc00), %i1
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
20064d0: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 <RAM_END+0xdc3fff8>
20064d4: 40 00 08 ef call 2008890 <_Thread_Clear_state>
20064d8: 81 e8 00 00 restore
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
20064dc: c8 01 20 70 ld [ %g4 + 0x70 ], %g4
20064e0: 80 a6 00 04 cmp %i0, %g4
20064e4: 32 bf ff e4 bne,a 2006474 <_Event_Surrender+0x3c>
20064e8: c8 06 20 10 ld [ %i0 + 0x10 ], %g4
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
20064ec: 09 00 80 77 sethi %hi(0x201dc00), %g4
20064f0: da 01 22 6c ld [ %g4 + 0x26c ], %o5 ! 201de6c <_Event_Sync_state>
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
20064f4: 80 a3 60 02 cmp %o5, 2
20064f8: 02 80 00 07 be 2006514 <_Event_Surrender+0xdc> <== NEVER TAKEN
20064fc: 80 a0 40 03 cmp %g1, %g3
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
2006500: da 01 22 6c ld [ %g4 + 0x26c ], %o5
/*
* If we are in an ISR and sending to the current thread, then
* we have a critical section issue to deal with.
*/
if ( _ISR_Is_in_progress() &&
2006504: 80 a3 60 01 cmp %o5, 1
2006508: 32 bf ff db bne,a 2006474 <_Event_Surrender+0x3c>
200650c: c8 06 20 10 ld [ %i0 + 0x10 ], %g4
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
if ( seized_events == event_condition || _Options_Is_any(option_set) ) {
2006510: 80 a0 40 03 cmp %g1, %g3
2006514: 02 80 00 04 be 2006524 <_Event_Surrender+0xec>
2006518: 80 8c a0 02 btst 2, %l2
200651c: 02 80 00 09 be 2006540 <_Event_Surrender+0x108> <== NEVER TAKEN
2006520: 01 00 00 00 nop
api->pending_events = _Event_sets_Clear( pending_events,seized_events );
the_thread->Wait.count = 0;
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
2006524: c2 06 20 28 ld [ %i0 + 0x28 ], %g1
if ( _ISR_Is_in_progress() &&
_Thread_Is_executing( the_thread ) &&
((_Event_Sync_state == THREAD_BLOCKING_OPERATION_TIMEOUT) ||
(_Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED)) ) {
if ( seized_events == event_condition || _Options_Is_any(option_set) ) {
api->pending_events = _Event_sets_Clear( pending_events,seized_events );
2006528: 84 28 80 03 andn %g2, %g3, %g2
200652c: c4 24 00 00 st %g2, [ %l0 ]
the_thread->Wait.count = 0;
2006530: c0 26 20 24 clr [ %i0 + 0x24 ]
*(rtems_event_set *)the_thread->Wait.return_argument = seized_events;
2006534: c6 20 40 00 st %g3, [ %g1 ]
_Event_Sync_state = THREAD_BLOCKING_OPERATION_SATISFIED;
2006538: 82 10 20 03 mov 3, %g1
200653c: c2 21 22 6c st %g1, [ %g4 + 0x26c ]
_Thread_Unblock( the_thread );
}
return;
}
}
_ISR_Enable( level );
2006540: 7f ff ee dd call 20020b4 <sparc_enable_interrupts>
2006544: 91 e8 00 11 restore %g0, %l1, %o0
RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate(
Watchdog_Control *the_watchdog
)
{
the_watchdog->state = WATCHDOG_REMOVE_IT;
2006548: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
if ( !_Watchdog_Is_active( &the_thread->Timer ) ) {
_ISR_Enable( level );
_Thread_Unblock( the_thread );
} else {
_Watchdog_Deactivate( &the_thread->Timer );
_ISR_Enable( level );
200654c: 7f ff ee da call 20020b4 <sparc_enable_interrupts>
2006550: 90 10 00 11 mov %l1, %o0
(void) _Watchdog_Remove( &the_thread->Timer );
2006554: 40 00 0e e2 call 200a0dc <_Watchdog_Remove>
2006558: 90 06 20 48 add %i0, 0x48, %o0
200655c: 33 04 00 ff sethi %hi(0x1003fc00), %i1
2006560: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 <RAM_END+0xdc3fff8>
2006564: 40 00 08 cb call 2008890 <_Thread_Clear_state>
2006568: 81 e8 00 00 restore
02006570 <_Event_Timeout>:
void _Event_Timeout(
Objects_Id id,
void *ignored
)
{
2006570: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
ISR_Level level;
the_thread = _Thread_Get( id, &location );
2006574: 90 10 00 18 mov %i0, %o0
2006578: 40 00 09 ee call 2008d30 <_Thread_Get>
200657c: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2006580: c2 07 bf fc ld [ %fp + -4 ], %g1
2006584: 80 a0 60 00 cmp %g1, 0
2006588: 12 80 00 15 bne 20065dc <_Event_Timeout+0x6c> <== NEVER TAKEN
200658c: a0 10 00 08 mov %o0, %l0
*
* If it is not satisfied, then it is "nothing happened" and
* this is the "timeout" transition. After a request is satisfied,
* a timeout is not allowed to occur.
*/
_ISR_Disable( level );
2006590: 7f ff ee c5 call 20020a4 <sparc_disable_interrupts>
2006594: 01 00 00 00 nop
return;
}
#endif
the_thread->Wait.count = 0;
if ( _Thread_Is_executing( the_thread ) ) {
2006598: 03 00 80 77 sethi %hi(0x201dc00), %g1
200659c: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 201dc70 <_Thread_Executing>
20065a0: 80 a4 00 01 cmp %l0, %g1
20065a4: 02 80 00 10 be 20065e4 <_Event_Timeout+0x74>
20065a8: c0 24 20 24 clr [ %l0 + 0x24 ]
if ( _Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
_Event_Sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;
}
the_thread->Wait.return_code = RTEMS_TIMEOUT;
20065ac: 82 10 20 06 mov 6, %g1
20065b0: c2 24 20 34 st %g1, [ %l0 + 0x34 ]
_ISR_Enable( level );
20065b4: 7f ff ee c0 call 20020b4 <sparc_enable_interrupts>
20065b8: 01 00 00 00 nop
20065bc: 90 10 00 10 mov %l0, %o0
20065c0: 13 04 00 ff sethi %hi(0x1003fc00), %o1
20065c4: 40 00 08 b3 call 2008890 <_Thread_Clear_state>
20065c8: 92 12 63 f8 or %o1, 0x3f8, %o1 ! 1003fff8 <RAM_END+0xdc3fff8>
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
20065cc: 03 00 80 76 sethi %hi(0x201d800), %g1
20065d0: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201dbb0 <_Thread_Dispatch_disable_level>
20065d4: 84 00 bf ff add %g2, -1, %g2
20065d8: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
20065dc: 81 c7 e0 08 ret
20065e0: 81 e8 00 00 restore
}
#endif
the_thread->Wait.count = 0;
if ( _Thread_Is_executing( the_thread ) ) {
if ( _Event_Sync_state == THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
20065e4: 03 00 80 77 sethi %hi(0x201dc00), %g1
20065e8: c4 00 62 6c ld [ %g1 + 0x26c ], %g2 ! 201de6c <_Event_Sync_state>
20065ec: 80 a0 a0 01 cmp %g2, 1
20065f0: 32 bf ff f0 bne,a 20065b0 <_Event_Timeout+0x40>
20065f4: 82 10 20 06 mov 6, %g1
_Event_Sync_state = THREAD_BLOCKING_OPERATION_TIMEOUT;
20065f8: 84 10 20 02 mov 2, %g2
20065fc: c4 20 62 6c st %g2, [ %g1 + 0x26c ]
}
the_thread->Wait.return_code = RTEMS_TIMEOUT;
2006600: 10 bf ff ec b 20065b0 <_Event_Timeout+0x40>
2006604: 82 10 20 06 mov 6, %g1
020012f0 <_Extension_Manager_initialization>:
#include <rtems/extension.h>
#include <rtems/score/interr.h>
void _Extension_Manager_initialization(void)
{
}
20012f0: 81 c3 e0 08 retl
0200d93c <_Heap_Allocate_aligned_with_boundary>:
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
200d93c: 9d e3 bf 98 save %sp, -104, %sp
Heap_Statistics *const stats = &heap->stats;
Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
Heap_Block *block = _Heap_Free_list_first( heap );
uintptr_t const block_size_floor = alloc_size + HEAP_BLOCK_HEADER_SIZE
- HEAP_BLOCK_SIZE_OFFSET;
200d940: a8 06 60 04 add %i1, 4, %l4
Heap_Control *heap,
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
200d944: a0 10 00 18 mov %i0, %l0
- HEAP_BLOCK_SIZE_OFFSET;
uintptr_t const page_size = heap->page_size;
uintptr_t alloc_begin = 0;
uint32_t search_count = 0;
if ( block_size_floor < alloc_size ) {
200d948: 80 a6 40 14 cmp %i1, %l4
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
200d94c: e4 06 20 08 ld [ %i0 + 8 ], %l2
200d950: 18 80 00 72 bgu 200db18 <_Heap_Allocate_aligned_with_boundary+0x1dc>
200d954: fa 06 20 10 ld [ %i0 + 0x10 ], %i5
/* Integer overflow occured */
return NULL;
}
if ( boundary != 0 ) {
200d958: 80 a6 e0 00 cmp %i3, 0
200d95c: 12 80 00 6d bne 200db10 <_Heap_Allocate_aligned_with_boundary+0x1d4>
200d960: 80 a6 40 1b cmp %i1, %i3
if ( alignment == 0 ) {
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200d964: 80 a4 00 12 cmp %l0, %l2
200d968: 02 80 00 6f be 200db24 <_Heap_Allocate_aligned_with_boundary+0x1e8>
200d96c: a2 10 20 00 clr %l1
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200d970: 82 10 20 04 mov 4, %g1
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
200d974: b8 07 60 07 add %i5, 7, %i4
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200d978: 82 20 40 19 sub %g1, %i1, %g1
200d97c: 10 80 00 09 b 200d9a0 <_Heap_Allocate_aligned_with_boundary+0x64>
200d980: c2 27 bf fc st %g1, [ %fp + -4 ]
boundary
);
}
}
if ( alloc_begin != 0 ) {
200d984: 80 a6 20 00 cmp %i0, 0
200d988: 32 80 00 54 bne,a 200dad8 <_Heap_Allocate_aligned_with_boundary+0x19c><== ALWAYS TAKEN
200d98c: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
break;
}
block = block->next;
200d990: e4 04 a0 08 ld [ %l2 + 8 ], %l2
if ( alignment == 0 ) {
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200d994: 80 a4 00 12 cmp %l0, %l2
200d998: 22 80 00 57 be,a 200daf4 <_Heap_Allocate_aligned_with_boundary+0x1b8>
200d99c: b0 10 20 00 clr %i0
/*
* The HEAP_PREV_BLOCK_USED flag is always set in the block size_and_flag
* field. Thus the value is about one unit larger than the real block
* size. The greater than operator takes this into account.
*/
if ( block->size_and_flag > block_size_floor ) {
200d9a0: e6 04 a0 04 ld [ %l2 + 4 ], %l3
200d9a4: 80 a5 00 13 cmp %l4, %l3
200d9a8: 1a bf ff fa bcc 200d990 <_Heap_Allocate_aligned_with_boundary+0x54>
200d9ac: a2 04 60 01 inc %l1
if ( alignment == 0 ) {
200d9b0: 80 a6 a0 00 cmp %i2, 0
200d9b4: 02 bf ff f4 be 200d984 <_Heap_Allocate_aligned_with_boundary+0x48>
200d9b8: b0 04 a0 08 add %l2, 8, %i0
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200d9bc: c2 07 bf fc ld [ %fp + -4 ], %g1
uintptr_t alignment,
uintptr_t boundary
)
{
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
200d9c0: ee 04 20 14 ld [ %l0 + 0x14 ], %l7
uintptr_t const block_begin = (uintptr_t) block;
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
200d9c4: a6 0c ff fe and %l3, -2, %l3
200d9c8: a6 04 80 13 add %l2, %l3, %l3
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
uintptr_t alloc_end = block_end + HEAP_BLOCK_SIZE_OFFSET;
uintptr_t alloc_begin = alloc_end - alloc_size;
200d9cc: b0 00 40 13 add %g1, %l3, %i0
uintptr_t const block_size = _Heap_Block_size( block );
uintptr_t const block_end = block_begin + block_size;
uintptr_t const alloc_begin_floor = _Heap_Alloc_area_of_block( block );
uintptr_t const alloc_begin_ceiling = block_end - min_block_size
+ HEAP_BLOCK_HEADER_SIZE + page_size - 1;
200d9d0: 82 27 00 17 sub %i4, %l7, %g1
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
200d9d4: 90 10 00 18 mov %i0, %o0
200d9d8: a6 00 40 13 add %g1, %l3, %l3
200d9dc: 40 00 30 9c call 2019c4c <.urem>
200d9e0: 92 10 00 1a mov %i2, %o1
200d9e4: b0 26 00 08 sub %i0, %o0, %i0
uintptr_t alloc_begin = alloc_end - alloc_size;
alloc_begin = _Heap_Align_down( alloc_begin, alignment );
/* Ensure that the we have a valid new block at the end */
if ( alloc_begin > alloc_begin_ceiling ) {
200d9e8: 80 a4 c0 18 cmp %l3, %i0
200d9ec: 1a 80 00 06 bcc 200da04 <_Heap_Allocate_aligned_with_boundary+0xc8>
200d9f0: ac 04 a0 08 add %l2, 8, %l6
200d9f4: 90 10 00 13 mov %l3, %o0
200d9f8: 40 00 30 95 call 2019c4c <.urem>
200d9fc: 92 10 00 1a mov %i2, %o1
200da00: b0 24 c0 08 sub %l3, %o0, %i0
}
alloc_end = alloc_begin + alloc_size;
/* Ensure boundary constaint */
if ( boundary != 0 ) {
200da04: 80 a6 e0 00 cmp %i3, 0
200da08: 02 80 00 24 be 200da98 <_Heap_Allocate_aligned_with_boundary+0x15c>
200da0c: 80 a5 80 18 cmp %l6, %i0
/* Ensure that the we have a valid new block at the end */
if ( alloc_begin > alloc_begin_ceiling ) {
alloc_begin = _Heap_Align_down( alloc_begin_ceiling, alignment );
}
alloc_end = alloc_begin + alloc_size;
200da10: a6 06 00 19 add %i0, %i1, %l3
200da14: 92 10 00 1b mov %i3, %o1
200da18: 40 00 30 8d call 2019c4c <.urem>
200da1c: 90 10 00 13 mov %l3, %o0
200da20: 90 24 c0 08 sub %l3, %o0, %o0
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
200da24: 80 a4 c0 08 cmp %l3, %o0
200da28: 08 80 00 1b bleu 200da94 <_Heap_Allocate_aligned_with_boundary+0x158>
200da2c: 80 a6 00 08 cmp %i0, %o0
200da30: 1a 80 00 1a bcc 200da98 <_Heap_Allocate_aligned_with_boundary+0x15c>
200da34: 80 a5 80 18 cmp %l6, %i0
alloc_end = alloc_begin + alloc_size;
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
200da38: aa 05 80 19 add %l6, %i1, %l5
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
if ( boundary_line < boundary_floor ) {
200da3c: 80 a5 40 08 cmp %l5, %o0
200da40: 28 80 00 09 bleu,a 200da64 <_Heap_Allocate_aligned_with_boundary+0x128>
200da44: b0 22 00 19 sub %o0, %i1, %i0
if ( alloc_begin != 0 ) {
break;
}
block = block->next;
200da48: 10 bf ff d3 b 200d994 <_Heap_Allocate_aligned_with_boundary+0x58>
200da4c: e4 04 a0 08 ld [ %l2 + 8 ], %l2
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
200da50: 1a 80 00 11 bcc 200da94 <_Heap_Allocate_aligned_with_boundary+0x158>
200da54: 80 a5 40 08 cmp %l5, %o0
if ( boundary_line < boundary_floor ) {
200da58: 38 bf ff cf bgu,a 200d994 <_Heap_Allocate_aligned_with_boundary+0x58><== NEVER TAKEN
200da5c: e4 04 a0 08 ld [ %l2 + 8 ], %l2 <== NOT EXECUTED
return 0;
}
alloc_begin = boundary_line - alloc_size;
200da60: b0 22 00 19 sub %o0, %i1, %i0
200da64: 92 10 00 1a mov %i2, %o1
200da68: 40 00 30 79 call 2019c4c <.urem>
200da6c: 90 10 00 18 mov %i0, %o0
200da70: 92 10 00 1b mov %i3, %o1
200da74: b0 26 00 08 sub %i0, %o0, %i0
alloc_begin = _Heap_Align_down( alloc_begin, alignment );
alloc_end = alloc_begin + alloc_size;
200da78: a6 06 00 19 add %i0, %i1, %l3
200da7c: 40 00 30 74 call 2019c4c <.urem>
200da80: 90 10 00 13 mov %l3, %o0
200da84: 90 24 c0 08 sub %l3, %o0, %o0
/* Ensure boundary constaint */
if ( boundary != 0 ) {
uintptr_t const boundary_floor = alloc_begin_floor + alloc_size;
uintptr_t boundary_line = _Heap_Align_down( alloc_end, boundary );
while ( alloc_begin < boundary_line && boundary_line < alloc_end ) {
200da88: 80 a4 c0 08 cmp %l3, %o0
200da8c: 18 bf ff f1 bgu 200da50 <_Heap_Allocate_aligned_with_boundary+0x114>
200da90: 80 a6 00 08 cmp %i0, %o0
boundary_line = _Heap_Align_down( alloc_end, boundary );
}
}
/* Ensure that the we have a valid new block at the beginning */
if ( alloc_begin >= alloc_begin_floor ) {
200da94: 80 a5 80 18 cmp %l6, %i0
200da98: 18 bf ff be bgu 200d990 <_Heap_Allocate_aligned_with_boundary+0x54>
200da9c: 82 10 3f f8 mov -8, %g1
uintptr_t const alloc_block_begin =
(uintptr_t) _Heap_Block_of_alloc_area( alloc_begin, page_size );
uintptr_t const free_size = alloc_block_begin - block_begin;
200daa0: 90 10 00 18 mov %i0, %o0
200daa4: a6 20 40 12 sub %g1, %l2, %l3
200daa8: 92 10 00 1d mov %i5, %o1
200daac: 40 00 30 68 call 2019c4c <.urem>
200dab0: a6 04 c0 18 add %l3, %i0, %l3
if ( free_size >= min_block_size || free_size == 0 ) {
200dab4: 90 a4 c0 08 subcc %l3, %o0, %o0
200dab8: 02 bf ff b4 be 200d988 <_Heap_Allocate_aligned_with_boundary+0x4c>
200dabc: 80 a6 20 00 cmp %i0, 0
200dac0: 80 a5 c0 08 cmp %l7, %o0
200dac4: 18 bf ff b3 bgu 200d990 <_Heap_Allocate_aligned_with_boundary+0x54>
200dac8: 80 a6 20 00 cmp %i0, 0
boundary
);
}
}
if ( alloc_begin != 0 ) {
200dacc: 22 bf ff b2 be,a 200d994 <_Heap_Allocate_aligned_with_boundary+0x58><== NEVER TAKEN
200dad0: e4 04 a0 08 ld [ %l2 + 8 ], %l2 <== NOT EXECUTED
block = block->next;
}
if ( alloc_begin != 0 ) {
/* Statistics */
stats->searches += search_count;
200dad4: c2 04 20 4c ld [ %l0 + 0x4c ], %g1
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
200dad8: 92 10 00 12 mov %l2, %o1
block = block->next;
}
if ( alloc_begin != 0 ) {
/* Statistics */
stats->searches += search_count;
200dadc: 82 00 40 11 add %g1, %l1, %g1
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
200dae0: 96 10 00 19 mov %i1, %o3
block = block->next;
}
if ( alloc_begin != 0 ) {
/* Statistics */
stats->searches += search_count;
200dae4: c2 24 20 4c st %g1, [ %l0 + 0x4c ]
block = _Heap_Block_allocate( heap, block, alloc_begin, alloc_size );
200dae8: 90 10 00 10 mov %l0, %o0
200daec: 7f ff e8 0f call 2007b28 <_Heap_Block_allocate>
200daf0: 94 10 00 18 mov %i0, %o2
uintptr_t alloc_size,
uintptr_t alignment,
uintptr_t boundary
)
{
Heap_Statistics *const stats = &heap->stats;
200daf4: c2 04 20 44 ld [ %l0 + 0x44 ], %g1
200daf8: 80 a0 40 11 cmp %g1, %l1
200dafc: 1a 80 00 08 bcc 200db1c <_Heap_Allocate_aligned_with_boundary+0x1e0>
200db00: 01 00 00 00 nop
);
}
/* Statistics */
if ( stats->max_search < search_count ) {
stats->max_search = search_count;
200db04: e2 24 20 44 st %l1, [ %l0 + 0x44 ]
200db08: 81 c7 e0 08 ret
200db0c: 81 e8 00 00 restore
/* Integer overflow occured */
return NULL;
}
if ( boundary != 0 ) {
if ( boundary < alloc_size ) {
200db10: 08 80 00 07 bleu 200db2c <_Heap_Allocate_aligned_with_boundary+0x1f0>
200db14: 80 a6 a0 00 cmp %i2, 0
);
}
/* Statistics */
if ( stats->max_search < search_count ) {
stats->max_search = search_count;
200db18: b0 10 20 00 clr %i0
}
return (void *) alloc_begin;
}
200db1c: 81 c7 e0 08 ret
200db20: 81 e8 00 00 restore
if ( alignment == 0 ) {
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200db24: 10 bf ff f4 b 200daf4 <_Heap_Allocate_aligned_with_boundary+0x1b8>
200db28: b0 10 20 00 clr %i0
if ( boundary != 0 ) {
if ( boundary < alloc_size ) {
return NULL;
}
if ( alignment == 0 ) {
200db2c: 22 bf ff 8e be,a 200d964 <_Heap_Allocate_aligned_with_boundary+0x28>
200db30: b4 10 00 1d mov %i5, %i2
alignment = page_size;
}
}
while ( block != free_list_tail ) {
200db34: 10 bf ff 8d b 200d968 <_Heap_Allocate_aligned_with_boundary+0x2c>
200db38: 80 a4 00 12 cmp %l0, %l2
02012590 <_Heap_Extend>:
Heap_Control *heap,
void *area_begin_ptr,
uintptr_t area_size,
uintptr_t *amount_extended
)
{
2012590: 9d e3 bf a0 save %sp, -96, %sp
Heap_Statistics *const stats = &heap->stats;
uintptr_t const area_begin = (uintptr_t) area_begin_ptr;
uintptr_t const heap_area_begin = heap->area_begin;
uintptr_t const heap_area_end = heap->area_end;
2012594: c2 06 20 1c ld [ %i0 + 0x1c ], %g1
Heap_Control *heap,
void *area_begin_ptr,
uintptr_t area_size,
uintptr_t *amount_extended
)
{
2012598: a0 10 00 18 mov %i0, %l0
* 5. non-contiguous higher address (NOT SUPPORTED)
*
* As noted, this code only supports (4).
*/
if ( area_begin >= heap_area_begin && area_begin < heap_area_end ) {
201259c: 80 a6 40 01 cmp %i1, %g1
20125a0: 0a 80 00 2a bcs 2012648 <_Heap_Extend+0xb8>
20125a4: e2 06 20 24 ld [ %i0 + 0x24 ], %l1
return HEAP_EXTEND_ERROR; /* case 3 */
} else if ( area_begin != heap_area_end ) {
20125a8: 80 a6 40 01 cmp %i1, %g1
20125ac: 12 80 00 25 bne 2012640 <_Heap_Extend+0xb0>
20125b0: b0 10 20 02 mov 2, %i0
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Align_down(
uintptr_t value,
uintptr_t alignment
)
{
return value - (value % alignment);
20125b4: d2 04 20 10 ld [ %l0 + 0x10 ], %o1
{
Heap_Statistics *const stats = &heap->stats;
uintptr_t const area_begin = (uintptr_t) area_begin_ptr;
uintptr_t const heap_area_begin = heap->area_begin;
uintptr_t const heap_area_end = heap->area_end;
uintptr_t const new_heap_area_end = heap_area_end + area_size;
20125b8: b4 06 40 1a add %i1, %i2, %i2
* block and free it.
*/
heap->area_end = new_heap_area_end;
extend_size = new_heap_area_end
20125bc: b2 26 80 11 sub %i2, %l1, %i1
* Currently only case 4 should make it to this point.
* The basic trick is to make the extend area look like a used
* block and free it.
*/
heap->area_end = new_heap_area_end;
20125c0: f4 24 20 1c st %i2, [ %l0 + 0x1c ]
extend_size = new_heap_area_end
20125c4: b2 06 7f f8 add %i1, -8, %i1
20125c8: 7f ff c7 71 call 200438c <.urem>
20125cc: 90 10 00 19 mov %i1, %o0
20125d0: 90 26 40 08 sub %i1, %o0, %o0
- (uintptr_t) last_block - HEAP_BLOCK_HEADER_SIZE;
extend_size = _Heap_Align_down( extend_size, heap->page_size );
*amount_extended = extend_size;
20125d4: d0 26 c0 00 st %o0, [ %i3 ]
if( extend_size >= heap->min_block_size ) {
20125d8: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
20125dc: 80 a0 40 08 cmp %g1, %o0
20125e0: 18 80 00 18 bgu 2012640 <_Heap_Extend+0xb0> <== NEVER TAKEN
20125e4: b0 10 20 00 clr %i0
uintptr_t size
)
{
uintptr_t flag = block->size_and_flag & HEAP_PREV_BLOCK_USED;
block->size_and_flag = size | flag;
20125e8: c2 04 60 04 ld [ %l1 + 4 ], %g1
Heap_Block *const new_last_block = _Heap_Block_at( last_block, extend_size );
_Heap_Block_set_size( last_block, extend_size );
new_last_block->size_and_flag =
20125ec: c4 04 20 20 ld [ %l0 + 0x20 ], %g2
20125f0: 82 08 60 01 and %g1, 1, %g1
20125f4: 82 12 00 01 or %o0, %g1, %g1
20125f8: c2 24 60 04 st %g1, [ %l1 + 4 ]
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
20125fc: 82 02 00 11 add %o0, %l1, %g1
2012600: 84 20 80 01 sub %g2, %g1, %g2
2012604: 84 10 a0 01 or %g2, 1, %g2
2012608: c4 20 60 04 st %g2, [ %g1 + 4 ]
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
++stats->used_blocks;
201260c: c6 04 20 40 ld [ %l0 + 0x40 ], %g3
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
2012610: f2 04 20 2c ld [ %l0 + 0x2c ], %i1
++stats->used_blocks;
--stats->frees; /* Do not count subsequent call as actual free() */
2012614: c4 04 20 50 ld [ %l0 + 0x50 ], %g2
new_last_block->size_and_flag =
((uintptr_t) heap->first_block - (uintptr_t) new_last_block)
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
2012618: c2 24 20 24 st %g1, [ %l0 + 0x24 ]
/* Statistics */
stats->size += extend_size;
++stats->used_blocks;
201261c: 82 00 e0 01 add %g3, 1, %g1
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
2012620: 90 06 40 08 add %i1, %o0, %o0
++stats->used_blocks;
2012624: c2 24 20 40 st %g1, [ %l0 + 0x40 ]
--stats->frees; /* Do not count subsequent call as actual free() */
2012628: 82 00 bf ff add %g2, -1, %g1
| HEAP_PREV_BLOCK_USED;
heap->last_block = new_last_block;
/* Statistics */
stats->size += extend_size;
201262c: d0 24 20 2c st %o0, [ %l0 + 0x2c ]
++stats->used_blocks;
--stats->frees; /* Do not count subsequent call as actual free() */
2012630: c2 24 20 50 st %g1, [ %l0 + 0x50 ]
_Heap_Free( heap, (void *) _Heap_Alloc_area_of_block( last_block ));
2012634: 90 10 00 10 mov %l0, %o0
2012638: 7f ff e4 93 call 200b884 <_Heap_Free>
201263c: 92 04 60 08 add %l1, 8, %o1
}
return HEAP_EXTEND_SUCCESSFUL;
}
2012640: 81 c7 e0 08 ret
2012644: 81 e8 00 00 restore
uintptr_t *amount_extended
)
{
Heap_Statistics *const stats = &heap->stats;
uintptr_t const area_begin = (uintptr_t) area_begin_ptr;
uintptr_t const heap_area_begin = heap->area_begin;
2012648: c4 06 20 18 ld [ %i0 + 0x18 ], %g2
201264c: 80 a6 40 02 cmp %i1, %g2
2012650: 0a bf ff d6 bcs 20125a8 <_Heap_Extend+0x18>
2012654: b0 10 20 01 mov 1, %i0
_Heap_Free( heap, (void *) _Heap_Alloc_area_of_block( last_block ));
}
return HEAP_EXTEND_SUCCESSFUL;
}
2012658: 81 c7 e0 08 ret
201265c: 81 e8 00 00 restore
0200db3c <_Heap_Free>:
#include <rtems/system.h>
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
{
200db3c: 9d e3 bf a0 save %sp, -96, %sp
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
200db40: d2 06 20 10 ld [ %i0 + 0x10 ], %o1
200db44: 40 00 30 42 call 2019c4c <.urem>
200db48: 90 10 00 19 mov %i1, %o0
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
200db4c: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
200db50: b2 06 7f f8 add %i1, -8, %i1
200db54: 90 26 40 08 sub %i1, %o0, %o0
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200db58: 80 a2 00 01 cmp %o0, %g1
200db5c: 0a 80 00 36 bcs 200dc34 <_Heap_Free+0xf8>
200db60: 01 00 00 00 nop
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
200db64: c6 06 20 24 ld [ %i0 + 0x24 ], %g3
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200db68: 80 a2 00 03 cmp %o0, %g3
200db6c: 18 80 00 32 bgu 200dc34 <_Heap_Free+0xf8>
200db70: 01 00 00 00 nop
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
200db74: da 02 20 04 ld [ %o0 + 4 ], %o5
200db78: 88 0b 7f fe and %o5, -2, %g4
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
200db7c: 84 02 00 04 add %o0, %g4, %g2
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200db80: 80 a0 40 02 cmp %g1, %g2
200db84: 18 80 00 2c bgu 200dc34 <_Heap_Free+0xf8> <== NEVER TAKEN
200db88: 80 a0 c0 02 cmp %g3, %g2
200db8c: 0a 80 00 2a bcs 200dc34 <_Heap_Free+0xf8> <== NEVER TAKEN
200db90: 01 00 00 00 nop
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
200db94: d8 00 a0 04 ld [ %g2 + 4 ], %o4
if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {
_HAssert( false );
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
200db98: 80 8b 20 01 btst 1, %o4
200db9c: 02 80 00 26 be 200dc34 <_Heap_Free+0xf8> <== NEVER TAKEN
200dba0: 96 0b 3f fe and %o4, -2, %o3
_HAssert( false );
return false;
}
next_block_size = _Heap_Block_size( next_block );
next_is_free = next_block != heap->last_block
200dba4: 80 a0 c0 02 cmp %g3, %g2
200dba8: 02 80 00 06 be 200dbc0 <_Heap_Free+0x84>
200dbac: 98 10 20 00 clr %o4
#include <rtems/system.h>
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
200dbb0: 98 00 80 0b add %g2, %o3, %o4
200dbb4: d8 03 20 04 ld [ %o4 + 4 ], %o4
200dbb8: 98 0b 20 01 and %o4, 1, %o4
200dbbc: 98 1b 20 01 xor %o4, 1, %o4
next_block_size = _Heap_Block_size( next_block );
next_is_free = next_block != heap->last_block
&& !_Heap_Is_prev_used( _Heap_Block_at( next_block, next_block_size ));
if ( !_Heap_Is_prev_used( block ) ) {
200dbc0: 80 8b 60 01 btst 1, %o5
200dbc4: 12 80 00 1e bne 200dc3c <_Heap_Free+0x100>
200dbc8: 80 8b 20 ff btst 0xff, %o4
uintptr_t const prev_size = block->prev_size;
200dbcc: d4 02 00 00 ld [ %o0 ], %o2
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
200dbd0: 9a 22 00 0a sub %o0, %o2, %o5
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
200dbd4: 80 a0 40 0d cmp %g1, %o5
200dbd8: 18 80 00 17 bgu 200dc34 <_Heap_Free+0xf8> <== NEVER TAKEN
200dbdc: 80 a0 c0 0d cmp %g3, %o5
200dbe0: 0a 80 00 15 bcs 200dc34 <_Heap_Free+0xf8> <== NEVER TAKEN
200dbe4: 01 00 00 00 nop
return( false );
}
/* As we always coalesce free blocks, the block that preceedes prev_block
must have been used. */
if ( !_Heap_Is_prev_used ( prev_block) ) {
200dbe8: c2 03 60 04 ld [ %o5 + 4 ], %g1
200dbec: 80 88 60 01 btst 1, %g1
200dbf0: 02 80 00 11 be 200dc34 <_Heap_Free+0xf8> <== NEVER TAKEN
200dbf4: 80 8b 20 ff btst 0xff, %o4
_HAssert( false );
return( false );
}
if ( next_is_free ) { /* coalesce both */
200dbf8: 22 80 00 3a be,a 200dce0 <_Heap_Free+0x1a4>
200dbfc: 94 01 00 0a add %g4, %o2, %o2
uintptr_t const size = block_size + prev_size + next_block_size;
_Heap_Free_list_remove( next_block );
stats->free_blocks -= 1;
200dc00: c6 06 20 38 ld [ %i0 + 0x38 ], %g3
}
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
Heap_Block *prev = block->prev;
200dc04: c2 00 a0 0c ld [ %g2 + 0xc ], %g1
return _Heap_Free_list_tail(heap)->prev;
}
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
200dc08: c4 00 a0 08 ld [ %g2 + 8 ], %g2
200dc0c: 86 00 ff ff add %g3, -1, %g3
200dc10: c6 26 20 38 st %g3, [ %i0 + 0x38 ]
_HAssert( false );
return( false );
}
if ( next_is_free ) { /* coalesce both */
uintptr_t const size = block_size + prev_size + next_block_size;
200dc14: 96 01 00 0b add %g4, %o3, %o3
Heap_Block *prev = block->prev;
prev->next = next;
next->prev = prev;
200dc18: c2 20 a0 0c st %g1, [ %g2 + 0xc ]
200dc1c: 94 02 c0 0a add %o3, %o2, %o2
RTEMS_INLINE_ROUTINE void _Heap_Free_list_remove( Heap_Block *block )
{
Heap_Block *next = block->next;
Heap_Block *prev = block->prev;
prev->next = next;
200dc20: c4 20 60 08 st %g2, [ %g1 + 8 ]
_Heap_Free_list_remove( next_block );
stats->free_blocks -= 1;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block = _Heap_Block_at( prev_block, size );
_HAssert(!_Heap_Is_prev_used( next_block));
next_block->prev_size = size;
200dc24: d4 23 40 0a st %o2, [ %o5 + %o2 ]
if ( next_is_free ) { /* coalesce both */
uintptr_t const size = block_size + prev_size + next_block_size;
_Heap_Free_list_remove( next_block );
stats->free_blocks -= 1;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
200dc28: 94 12 a0 01 or %o2, 1, %o2
200dc2c: 10 80 00 10 b 200dc6c <_Heap_Free+0x130>
200dc30: d4 23 60 04 st %o2, [ %o5 + 4 ]
--stats->used_blocks;
++stats->frees;
stats->free_size += block_size;
return( true );
}
200dc34: 81 c7 e0 08 ret
200dc38: 91 e8 20 00 restore %g0, 0, %o0
uintptr_t const size = block_size + prev_size;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
next_block->prev_size = size;
}
} else if ( next_is_free ) { /* coalesce next */
200dc3c: 02 80 00 17 be 200dc98 <_Heap_Free+0x15c>
200dc40: 82 11 20 01 or %g4, 1, %g1
Heap_Block *old_block,
Heap_Block *new_block
)
{
Heap_Block *next = old_block->next;
Heap_Block *prev = old_block->prev;
200dc44: c2 00 a0 0c ld [ %g2 + 0xc ], %g1
RTEMS_INLINE_ROUTINE void _Heap_Free_list_replace(
Heap_Block *old_block,
Heap_Block *new_block
)
{
Heap_Block *next = old_block->next;
200dc48: c4 00 a0 08 ld [ %g2 + 8 ], %g2
Heap_Block *prev = old_block->prev;
new_block->next = next;
new_block->prev = prev;
200dc4c: c2 22 20 0c st %g1, [ %o0 + 0xc ]
)
{
Heap_Block *next = old_block->next;
Heap_Block *prev = old_block->prev;
new_block->next = next;
200dc50: c4 22 20 08 st %g2, [ %o0 + 8 ]
uintptr_t const size = block_size + next_block_size;
200dc54: 96 02 c0 04 add %o3, %g4, %o3
new_block->prev = prev;
next->prev = new_block;
200dc58: d0 20 a0 0c st %o0, [ %g2 + 0xc ]
_Heap_Free_list_replace( next_block, block );
block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block = _Heap_Block_at( block, size );
next_block->prev_size = size;
200dc5c: d6 22 00 0b st %o3, [ %o0 + %o3 ]
prev->next = new_block;
200dc60: d0 20 60 08 st %o0, [ %g1 + 8 ]
next_block->prev_size = size;
}
} else if ( next_is_free ) { /* coalesce next */
uintptr_t const size = block_size + next_block_size;
_Heap_Free_list_replace( next_block, block );
block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
200dc64: 96 12 e0 01 or %o3, 1, %o3
200dc68: d6 22 20 04 st %o3, [ %o0 + 4 ]
stats->max_free_blocks = stats->free_blocks;
}
}
/* Statistics */
--stats->used_blocks;
200dc6c: c4 06 20 40 ld [ %i0 + 0x40 ], %g2
++stats->frees;
200dc70: c2 06 20 50 ld [ %i0 + 0x50 ], %g1
stats->free_size += block_size;
200dc74: c6 06 20 30 ld [ %i0 + 0x30 ], %g3
stats->max_free_blocks = stats->free_blocks;
}
}
/* Statistics */
--stats->used_blocks;
200dc78: 84 00 bf ff add %g2, -1, %g2
++stats->frees;
stats->free_size += block_size;
200dc7c: 88 00 c0 04 add %g3, %g4, %g4
stats->max_free_blocks = stats->free_blocks;
}
}
/* Statistics */
--stats->used_blocks;
200dc80: c4 26 20 40 st %g2, [ %i0 + 0x40 ]
++stats->frees;
stats->free_size += block_size;
200dc84: c8 26 20 30 st %g4, [ %i0 + 0x30 ]
}
}
/* Statistics */
--stats->used_blocks;
++stats->frees;
200dc88: 82 00 60 01 inc %g1
200dc8c: c2 26 20 50 st %g1, [ %i0 + 0x50 ]
stats->free_size += block_size;
return( true );
200dc90: 81 c7 e0 08 ret
200dc94: 91 e8 20 01 restore %g0, 1, %o0
next_block->prev_size = size;
} else { /* no coalesce */
/* Add 'block' to the head of the free blocks list as it tends to
produce less fragmentation than adding to the tail. */
_Heap_Free_list_insert_after( _Heap_Free_list_head( heap), block );
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
200dc98: c2 22 20 04 st %g1, [ %o0 + 4 ]
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200dc9c: c2 00 a0 04 ld [ %g2 + 4 ], %g1
RTEMS_INLINE_ROUTINE void _Heap_Free_list_insert_after(
Heap_Block *block_before,
Heap_Block *new_block
)
{
Heap_Block *next = block_before->next;
200dca0: c6 06 20 08 ld [ %i0 + 8 ], %g3
200dca4: 82 08 7f fe and %g1, -2, %g1
next_block->prev_size = block_size;
200dca8: c8 22 00 04 st %g4, [ %o0 + %g4 ]
} else { /* no coalesce */
/* Add 'block' to the head of the free blocks list as it tends to
produce less fragmentation than adding to the tail. */
_Heap_Free_list_insert_after( _Heap_Free_list_head( heap), block );
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200dcac: c2 20 a0 04 st %g1, [ %g2 + 4 ]
next_block->prev_size = block_size;
/* Statistics */
++stats->free_blocks;
200dcb0: c2 06 20 38 ld [ %i0 + 0x38 ], %g1
new_block->next = next;
200dcb4: c6 22 20 08 st %g3, [ %o0 + 8 ]
new_block->prev = block_before;
200dcb8: f0 22 20 0c st %i0, [ %o0 + 0xc ]
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
{
Heap_Statistics *const stats = &heap->stats;
200dcbc: c4 06 20 3c ld [ %i0 + 0x3c ], %g2
block->size_and_flag = block_size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
next_block->prev_size = block_size;
/* Statistics */
++stats->free_blocks;
200dcc0: 82 00 60 01 inc %g1
block_before->next = new_block;
next->prev = new_block;
200dcc4: d0 20 e0 0c st %o0, [ %g3 + 0xc ]
{
Heap_Block *next = block_before->next;
new_block->next = next;
new_block->prev = block_before;
block_before->next = new_block;
200dcc8: d0 26 20 08 st %o0, [ %i0 + 8 ]
#include <rtems/score/sysstate.h>
#include <rtems/score/heap.h>
bool _Heap_Free( Heap_Control *heap, void *alloc_begin_ptr )
{
Heap_Statistics *const stats = &heap->stats;
200dccc: 80 a0 40 02 cmp %g1, %g2
200dcd0: 08 bf ff e7 bleu 200dc6c <_Heap_Free+0x130>
200dcd4: c2 26 20 38 st %g1, [ %i0 + 0x38 ]
next_block->prev_size = block_size;
/* Statistics */
++stats->free_blocks;
if ( stats->max_free_blocks < stats->free_blocks ) {
stats->max_free_blocks = stats->free_blocks;
200dcd8: 10 bf ff e5 b 200dc6c <_Heap_Free+0x130>
200dcdc: c2 26 20 3c st %g1, [ %i0 + 0x3c ]
next_block = _Heap_Block_at( prev_block, size );
_HAssert(!_Heap_Is_prev_used( next_block));
next_block->prev_size = size;
} else { /* coalesce prev */
uintptr_t const size = block_size + prev_size;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
200dce0: 82 12 a0 01 or %o2, 1, %g1
200dce4: c2 23 60 04 st %g1, [ %o5 + 4 ]
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200dce8: c2 00 a0 04 ld [ %g2 + 4 ], %g1
next_block->prev_size = size;
200dcec: d4 22 00 04 st %o2, [ %o0 + %g4 ]
_HAssert(!_Heap_Is_prev_used( next_block));
next_block->prev_size = size;
} else { /* coalesce prev */
uintptr_t const size = block_size + prev_size;
prev_block->size_and_flag = size | HEAP_PREV_BLOCK_USED;
next_block->size_and_flag &= ~HEAP_PREV_BLOCK_USED;
200dcf0: 82 08 7f fe and %g1, -2, %g1
200dcf4: 10 bf ff de b 200dc6c <_Heap_Free+0x130>
200dcf8: c2 20 a0 04 st %g1, [ %g2 + 4 ]
020300ec <_Heap_Get_free_information>:
void _Heap_Get_free_information(
Heap_Control *the_heap,
Heap_Information *info
)
{
20300ec: 9d e3 bf a0 save %sp, -96, %sp
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
20300f0: c2 06 20 08 ld [ %i0 + 8 ], %g1
Heap_Block *the_block;
Heap_Block *const tail = _Heap_Free_list_tail(the_heap);
info->number = 0;
20300f4: c0 26 40 00 clr [ %i1 ]
info->largest = 0;
20300f8: c0 26 60 04 clr [ %i1 + 4 ]
info->total = 0;
for(the_block = _Heap_Free_list_first(the_heap);
20300fc: 80 a6 00 01 cmp %i0, %g1
2030100: 02 80 00 13 be 203014c <_Heap_Get_free_information+0x60> <== NEVER TAKEN
2030104: c0 26 60 08 clr [ %i1 + 8 ]
2030108: 88 10 20 01 mov 1, %g4
203010c: 10 80 00 03 b 2030118 <_Heap_Get_free_information+0x2c>
2030110: 86 10 20 00 clr %g3
2030114: 88 10 00 02 mov %g2, %g4
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2030118: c4 00 60 04 ld [ %g1 + 4 ], %g2
/* As we always coalesce free blocks, prev block must have been used. */
_HAssert(_Heap_Is_prev_used(the_block));
info->number++;
info->total += the_size;
if ( info->largest < the_size )
203011c: da 06 60 04 ld [ %i1 + 4 ], %o5
2030120: 84 08 bf fe and %g2, -2, %g2
2030124: 80 a3 40 02 cmp %o5, %g2
2030128: 1a 80 00 03 bcc 2030134 <_Heap_Get_free_information+0x48>
203012c: 86 00 c0 02 add %g3, %g2, %g3
info->largest = the_size;
2030130: c4 26 60 04 st %g2, [ %i1 + 4 ]
info->largest = 0;
info->total = 0;
for(the_block = _Heap_Free_list_first(the_heap);
the_block != tail;
the_block = the_block->next)
2030134: c2 00 60 08 ld [ %g1 + 8 ], %g1
info->number = 0;
info->largest = 0;
info->total = 0;
for(the_block = _Heap_Free_list_first(the_heap);
2030138: 80 a6 00 01 cmp %i0, %g1
203013c: 12 bf ff f6 bne 2030114 <_Heap_Get_free_information+0x28>
2030140: 84 01 20 01 add %g4, 1, %g2
2030144: c6 26 60 08 st %g3, [ %i1 + 8 ]
2030148: c8 26 40 00 st %g4, [ %i1 ]
203014c: 81 c7 e0 08 ret
2030150: 81 e8 00 00 restore
02045efc <_Heap_Get_information>:
void _Heap_Get_information(
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
2045efc: 9d e3 bf a0 save %sp, -96, %sp
Heap_Block *the_block = the_heap->first_block;
Heap_Block *const end = the_heap->last_block;
2045f00: c4 06 20 24 ld [ %i0 + 0x24 ], %g2
void _Heap_Get_information(
Heap_Control *the_heap,
Heap_Information_block *the_info
)
{
Heap_Block *the_block = the_heap->first_block;
2045f04: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
Heap_Block *const end = the_heap->last_block;
_HAssert(the_block->prev_size == the_heap->page_size);
_HAssert(_Heap_Is_prev_used(the_block));
the_info->Free.number = 0;
2045f08: c0 26 40 00 clr [ %i1 ]
the_info->Free.total = 0;
2045f0c: c0 26 60 08 clr [ %i1 + 8 ]
the_info->Free.largest = 0;
2045f10: c0 26 60 04 clr [ %i1 + 4 ]
the_info->Used.number = 0;
2045f14: c0 26 60 0c clr [ %i1 + 0xc ]
the_info->Used.total = 0;
2045f18: c0 26 60 14 clr [ %i1 + 0x14 ]
the_info->Used.largest = 0;
2045f1c: c0 26 60 10 clr [ %i1 + 0x10 ]
while ( the_block != end ) {
2045f20: 80 a0 40 02 cmp %g1, %g2
2045f24: 02 80 00 1a be 2045f8c <_Heap_Get_information+0x90> <== NEVER TAKEN
2045f28: 86 10 20 08 mov 8, %g3
2045f2c: da 00 60 04 ld [ %g1 + 4 ], %o5
uintptr_t const the_size = _Heap_Block_size(the_block);
Heap_Block *const next_block = _Heap_Block_at(the_block, the_size);
Heap_Information *info;
if ( _Heap_Is_prev_used(next_block) )
info = &the_info->Used;
2045f30: 92 06 60 0c add %i1, 0xc, %o1
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2045f34: 88 0b 7f fe and %o5, -2, %g4
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
2045f38: 82 00 40 04 add %g1, %g4, %g1
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
2045f3c: da 00 60 04 ld [ %g1 + 4 ], %o5
while ( the_block != end ) {
uintptr_t const the_size = _Heap_Block_size(the_block);
Heap_Block *const next_block = _Heap_Block_at(the_block, the_size);
Heap_Information *info;
if ( _Heap_Is_prev_used(next_block) )
2045f40: 80 8b 60 01 btst 1, %o5
2045f44: 12 80 00 03 bne 2045f50 <_Heap_Get_information+0x54>
2045f48: 86 10 00 09 mov %o1, %g3
2045f4c: 86 10 00 19 mov %i1, %g3
info = &the_info->Used;
else
info = &the_info->Free;
info->number++;
2045f50: d4 00 c0 00 ld [ %g3 ], %o2
info->total += the_size;
2045f54: d6 00 e0 08 ld [ %g3 + 8 ], %o3
if ( info->largest < the_size )
2045f58: d8 00 e0 04 ld [ %g3 + 4 ], %o4
if ( _Heap_Is_prev_used(next_block) )
info = &the_info->Used;
else
info = &the_info->Free;
info->number++;
2045f5c: 94 02 a0 01 inc %o2
info->total += the_size;
2045f60: 96 02 c0 04 add %o3, %g4, %o3
if ( _Heap_Is_prev_used(next_block) )
info = &the_info->Used;
else
info = &the_info->Free;
info->number++;
2045f64: d4 20 c0 00 st %o2, [ %g3 ]
info->total += the_size;
if ( info->largest < the_size )
2045f68: 80 a3 00 04 cmp %o4, %g4
2045f6c: 1a 80 00 03 bcc 2045f78 <_Heap_Get_information+0x7c>
2045f70: d6 20 e0 08 st %o3, [ %g3 + 8 ]
info->largest = the_size;
2045f74: c8 20 e0 04 st %g4, [ %g3 + 4 ]
the_info->Free.largest = 0;
the_info->Used.number = 0;
the_info->Used.total = 0;
the_info->Used.largest = 0;
while ( the_block != end ) {
2045f78: 80 a0 80 01 cmp %g2, %g1
2045f7c: 12 bf ff ef bne 2045f38 <_Heap_Get_information+0x3c>
2045f80: 88 0b 7f fe and %o5, -2, %g4
2045f84: c6 06 60 14 ld [ %i1 + 0x14 ], %g3
2045f88: 86 00 e0 08 add %g3, 8, %g3
/*
* Handle the last dummy block. Don't consider this block to be
* "used" as client never allocated it. Make 'Used.total' contain this
* blocks' overhead though.
*/
the_info->Used.total += HEAP_BLOCK_HEADER_SIZE;
2045f8c: c6 26 60 14 st %g3, [ %i1 + 0x14 ]
}
2045f90: 81 c7 e0 08 ret
2045f94: 81 e8 00 00 restore
0201b678 <_Heap_Size_of_alloc_area>:
bool _Heap_Size_of_alloc_area(
Heap_Control *heap,
void *alloc_begin_ptr,
uintptr_t *alloc_size
)
{
201b678: 9d e3 bf a0 save %sp, -96, %sp
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
201b67c: d2 06 20 10 ld [ %i0 + 0x10 ], %o1
201b680: 7f ff f9 73 call 2019c4c <.urem>
201b684: 90 10 00 19 mov %i1, %o0
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
201b688: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_of_alloc_area(
uintptr_t alloc_begin,
uintptr_t page_size
)
{
return (Heap_Block *) (_Heap_Align_down( alloc_begin, page_size )
201b68c: 84 06 7f f8 add %i1, -8, %g2
201b690: 84 20 80 08 sub %g2, %o0, %g2
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
201b694: 80 a0 80 01 cmp %g2, %g1
201b698: 0a 80 00 16 bcs 201b6f0 <_Heap_Size_of_alloc_area+0x78>
201b69c: 01 00 00 00 nop
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
201b6a0: c6 06 20 24 ld [ %i0 + 0x24 ], %g3
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
201b6a4: 80 a0 80 03 cmp %g2, %g3
201b6a8: 18 80 00 12 bgu 201b6f0 <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201b6ac: 01 00 00 00 nop
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
201b6b0: c8 00 a0 04 ld [ %g2 + 4 ], %g4
201b6b4: 88 09 3f fe and %g4, -2, %g4
201b6b8: 84 00 80 04 add %g2, %g4, %g2
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
201b6bc: 80 a0 40 02 cmp %g1, %g2
201b6c0: 18 80 00 0c bgu 201b6f0 <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201b6c4: 80 a0 c0 02 cmp %g3, %g2
201b6c8: 0a 80 00 0a bcs 201b6f0 <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201b6cc: 01 00 00 00 nop
}
block_size = _Heap_Block_size( block );
next_block = _Heap_Block_at( block, block_size );
if (
201b6d0: c2 00 a0 04 ld [ %g2 + 4 ], %g1
201b6d4: 80 88 60 01 btst 1, %g1
201b6d8: 02 80 00 06 be 201b6f0 <_Heap_Size_of_alloc_area+0x78> <== NEVER TAKEN
201b6dc: 84 20 80 19 sub %g2, %i1, %g2
|| !_Heap_Is_prev_used( next_block )
) {
return false;
}
*alloc_size = (uintptr_t) next_block + HEAP_BLOCK_SIZE_OFFSET - alloc_begin;
201b6e0: 84 00 a0 04 add %g2, 4, %g2
201b6e4: c4 26 80 00 st %g2, [ %i2 ]
return true;
201b6e8: 81 c7 e0 08 ret
201b6ec: 91 e8 20 01 restore %g0, 1, %o0
}
201b6f0: 81 c7 e0 08 ret
201b6f4: 91 e8 20 00 restore %g0, 0, %o0
02008a88 <_Heap_Walk>:
bool _Heap_Walk(
Heap_Control *heap,
int source,
bool dump
)
{
2008a88: 9d e3 bf 80 save %sp, -128, %sp
uintptr_t const page_size = heap->page_size;
uintptr_t const min_block_size = heap->min_block_size;
Heap_Block *const last_block = heap->last_block;
Heap_Block *block = heap->first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
2008a8c: 25 00 80 24 sethi %hi(0x2009000), %l2
2008a90: 80 8e a0 ff btst 0xff, %i2
2008a94: a4 14 a0 b8 or %l2, 0xb8, %l2
Heap_Control *heap,
int source,
bool dump
)
{
uintptr_t const page_size = heap->page_size;
2008a98: ea 06 20 10 ld [ %i0 + 0x10 ], %l5
uintptr_t const min_block_size = heap->min_block_size;
2008a9c: e6 06 20 14 ld [ %i0 + 0x14 ], %l3
Heap_Block *const last_block = heap->last_block;
2008aa0: e8 06 20 24 ld [ %i0 + 0x24 ], %l4
Heap_Block *block = heap->first_block;
Heap_Walk_printer printer = dump ?
_Heap_Walk_print : _Heap_Walk_print_nothing;
2008aa4: 12 80 00 04 bne 2008ab4 <_Heap_Walk+0x2c>
2008aa8: e0 06 20 20 ld [ %i0 + 0x20 ], %l0
2008aac: 25 00 80 22 sethi %hi(0x2008800), %l2
2008ab0: a4 14 a2 80 or %l2, 0x280, %l2 ! 2008a80 <_Heap_Walk_print_nothing>
if ( !_System_state_Is_up( _System_state_Get() ) ) {
2008ab4: 03 00 80 81 sethi %hi(0x2020400), %g1
2008ab8: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 20206f0 <_System_state_Current>
2008abc: 80 a0 60 03 cmp %g1, 3
2008ac0: 22 80 00 04 be,a 2008ad0 <_Heap_Walk+0x48>
2008ac4: da 06 20 18 ld [ %i0 + 0x18 ], %o5
block = next_block;
}
return true;
}
2008ac8: 81 c7 e0 08 ret
2008acc: 91 e8 20 01 restore %g0, 1, %o0
Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
Heap_Block *const first_block = heap->first_block;
Heap_Block *const last_block = heap->last_block;
(*printer)(
2008ad0: c6 06 20 1c ld [ %i0 + 0x1c ], %g3
2008ad4: c4 06 20 08 ld [ %i0 + 8 ], %g2
2008ad8: c2 06 20 0c ld [ %i0 + 0xc ], %g1
2008adc: 90 10 00 19 mov %i1, %o0
2008ae0: c6 23 a0 5c st %g3, [ %sp + 0x5c ]
2008ae4: c4 23 a0 68 st %g2, [ %sp + 0x68 ]
2008ae8: c2 23 a0 6c st %g1, [ %sp + 0x6c ]
2008aec: e0 23 a0 60 st %l0, [ %sp + 0x60 ]
2008af0: e8 23 a0 64 st %l4, [ %sp + 0x64 ]
2008af4: 92 10 20 00 clr %o1
2008af8: 15 00 80 75 sethi %hi(0x201d400), %o2
2008afc: 96 10 00 15 mov %l5, %o3
2008b00: 94 12 a2 80 or %o2, 0x280, %o2
2008b04: 9f c4 80 00 call %l2
2008b08: 98 10 00 13 mov %l3, %o4
heap->area_begin, heap->area_end,
first_block, last_block,
first_free_block, last_free_block
);
if ( page_size == 0 ) {
2008b0c: 80 a5 60 00 cmp %l5, 0
2008b10: 02 80 00 36 be 2008be8 <_Heap_Walk+0x160>
2008b14: 80 8d 60 07 btst 7, %l5
(*printer)( source, true, "page size is zero\n" );
return false;
}
if ( !_Addresses_Is_aligned( (void *) page_size ) ) {
2008b18: 12 80 00 3c bne 2008c08 <_Heap_Walk+0x180>
2008b1c: 90 10 00 13 mov %l3, %o0
);
return false;
}
if ( !_Heap_Is_aligned( min_block_size, page_size ) ) {
2008b20: 7f ff e3 e9 call 2001ac4 <.urem>
2008b24: 92 10 00 15 mov %l5, %o1
2008b28: 80 a2 20 00 cmp %o0, 0
2008b2c: 12 80 00 40 bne 2008c2c <_Heap_Walk+0x1a4>
2008b30: 90 04 20 08 add %l0, 8, %o0
);
return false;
}
if (
2008b34: 7f ff e3 e4 call 2001ac4 <.urem>
2008b38: 92 10 00 15 mov %l5, %o1
2008b3c: 80 a2 20 00 cmp %o0, 0
2008b40: 32 80 00 44 bne,a 2008c50 <_Heap_Walk+0x1c8>
2008b44: 90 10 00 19 mov %i1, %o0
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
2008b48: ec 04 20 04 ld [ %l0 + 4 ], %l6
);
return false;
}
if ( !_Heap_Is_prev_used( first_block ) ) {
2008b4c: ba 8d a0 01 andcc %l6, 1, %i5
2008b50: 22 80 00 48 be,a 2008c70 <_Heap_Walk+0x1e8>
2008b54: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( first_block->prev_size != page_size ) {
2008b58: d6 04 00 00 ld [ %l0 ], %o3
2008b5c: 80 a5 40 0b cmp %l5, %o3
2008b60: 32 80 00 1a bne,a 2008bc8 <_Heap_Walk+0x140>
2008b64: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( _Heap_Is_free( last_block ) ) {
2008b68: c2 05 20 04 ld [ %l4 + 4 ], %g1
2008b6c: 82 08 7f fe and %g1, -2, %g1
2008b70: 82 05 00 01 add %l4, %g1, %g1
2008b74: c2 00 60 04 ld [ %g1 + 4 ], %g1
2008b78: 80 88 60 01 btst 1, %g1
2008b7c: 22 80 01 2e be,a 2009034 <_Heap_Walk+0x5ac>
2008b80: 90 10 00 19 mov %i1, %o0
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008b84: ee 06 20 08 ld [ %i0 + 8 ], %l7
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
2008b88: 80 a6 00 17 cmp %i0, %l7
2008b8c: 02 80 00 79 be 2008d70 <_Heap_Walk+0x2e8>
2008b90: f8 06 20 10 ld [ %i0 + 0x10 ], %i4
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
&& (uintptr_t) block <= (uintptr_t) heap->last_block;
2008b94: f6 06 20 20 ld [ %i0 + 0x20 ], %i3
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
2008b98: 80 a6 c0 17 cmp %i3, %l7
2008b9c: 28 80 00 3c bleu,a 2008c8c <_Heap_Walk+0x204> <== ALWAYS TAKEN
2008ba0: f4 06 20 24 ld [ %i0 + 0x24 ], %i2
if ( !_Heap_Is_block_in_heap( heap, free_block ) ) {
(*printer)(
2008ba4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2008ba8: 96 10 00 17 mov %l7, %o3
2008bac: 92 10 20 01 mov 1, %o1
2008bb0: 15 00 80 76 sethi %hi(0x201d800), %o2
2008bb4: b0 10 20 00 clr %i0
2008bb8: 9f c4 80 00 call %l2
2008bbc: 94 12 a0 28 or %o2, 0x28, %o2
2008bc0: 81 c7 e0 08 ret
2008bc4: 81 e8 00 00 restore
return false;
}
if ( first_block->prev_size != page_size ) {
(*printer)(
2008bc8: 98 10 00 15 mov %l5, %o4
2008bcc: 92 10 20 01 mov 1, %o1
2008bd0: 15 00 80 75 sethi %hi(0x201d400), %o2
2008bd4: b0 10 20 00 clr %i0
2008bd8: 9f c4 80 00 call %l2
2008bdc: 94 12 a3 e0 or %o2, 0x3e0, %o2
2008be0: 81 c7 e0 08 ret
2008be4: 81 e8 00 00 restore
first_block, last_block,
first_free_block, last_free_block
);
if ( page_size == 0 ) {
(*printer)( source, true, "page size is zero\n" );
2008be8: 90 10 00 19 mov %i1, %o0
2008bec: 92 10 20 01 mov 1, %o1
2008bf0: 15 00 80 75 sethi %hi(0x201d400), %o2
2008bf4: b0 10 20 00 clr %i0
2008bf8: 9f c4 80 00 call %l2
2008bfc: 94 12 a3 18 or %o2, 0x318, %o2
2008c00: 81 c7 e0 08 ret
2008c04: 81 e8 00 00 restore
return false;
}
if ( !_Addresses_Is_aligned( (void *) page_size ) ) {
(*printer)(
2008c08: 90 10 00 19 mov %i1, %o0
2008c0c: 96 10 00 15 mov %l5, %o3
2008c10: 92 10 20 01 mov 1, %o1
2008c14: 15 00 80 75 sethi %hi(0x201d400), %o2
2008c18: b0 10 20 00 clr %i0
2008c1c: 9f c4 80 00 call %l2
2008c20: 94 12 a3 30 or %o2, 0x330, %o2
2008c24: 81 c7 e0 08 ret
2008c28: 81 e8 00 00 restore
return false;
}
if ( !_Heap_Is_aligned( min_block_size, page_size ) ) {
(*printer)(
2008c2c: 90 10 00 19 mov %i1, %o0
2008c30: 96 10 00 13 mov %l3, %o3
2008c34: 92 10 20 01 mov 1, %o1
2008c38: 15 00 80 75 sethi %hi(0x201d400), %o2
2008c3c: b0 10 20 00 clr %i0
2008c40: 9f c4 80 00 call %l2
2008c44: 94 12 a3 50 or %o2, 0x350, %o2
2008c48: 81 c7 e0 08 ret
2008c4c: 81 e8 00 00 restore
}
if (
!_Heap_Is_aligned( _Heap_Alloc_area_of_block( first_block ), page_size )
) {
(*printer)(
2008c50: 96 10 00 10 mov %l0, %o3
2008c54: 92 10 20 01 mov 1, %o1
2008c58: 15 00 80 75 sethi %hi(0x201d400), %o2
2008c5c: b0 10 20 00 clr %i0
2008c60: 9f c4 80 00 call %l2
2008c64: 94 12 a3 78 or %o2, 0x378, %o2
2008c68: 81 c7 e0 08 ret
2008c6c: 81 e8 00 00 restore
return false;
}
if ( !_Heap_Is_prev_used( first_block ) ) {
(*printer)(
2008c70: 92 10 20 01 mov 1, %o1
2008c74: 15 00 80 75 sethi %hi(0x201d400), %o2
2008c78: b0 10 20 00 clr %i0
2008c7c: 9f c4 80 00 call %l2
2008c80: 94 12 a3 b0 or %o2, 0x3b0, %o2
2008c84: 81 c7 e0 08 ret
2008c88: 81 e8 00 00 restore
2008c8c: 80 a5 c0 1a cmp %l7, %i2
2008c90: 18 bf ff c6 bgu 2008ba8 <_Heap_Walk+0x120> <== NEVER TAKEN
2008c94: 90 10 00 19 mov %i1, %o0
);
return false;
}
if (
2008c98: 90 05 e0 08 add %l7, 8, %o0
2008c9c: 7f ff e3 8a call 2001ac4 <.urem>
2008ca0: 92 10 00 1c mov %i4, %o1
2008ca4: 80 a2 20 00 cmp %o0, 0
2008ca8: 12 80 00 ea bne 2009050 <_Heap_Walk+0x5c8> <== NEVER TAKEN
2008cac: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( _Heap_Is_used( free_block ) ) {
2008cb0: c2 05 e0 04 ld [ %l7 + 4 ], %g1
2008cb4: 82 08 7f fe and %g1, -2, %g1
2008cb8: 82 05 c0 01 add %l7, %g1, %g1
2008cbc: c2 00 60 04 ld [ %g1 + 4 ], %g1
2008cc0: 80 88 60 01 btst 1, %g1
2008cc4: 12 80 00 f5 bne 2009098 <_Heap_Walk+0x610> <== NEVER TAKEN
2008cc8: 01 00 00 00 nop
);
return false;
}
if ( free_block->prev != prev_block ) {
2008ccc: e2 05 e0 0c ld [ %l7 + 0xc ], %l1
2008cd0: 80 a4 40 18 cmp %l1, %i0
2008cd4: 12 80 00 e9 bne 2009078 <_Heap_Walk+0x5f0> <== NEVER TAKEN
2008cd8: 96 10 00 17 mov %l7, %o3
2008cdc: fa 27 bf fc st %i5, [ %fp + -4 ]
2008ce0: ba 10 00 15 mov %l5, %i5
2008ce4: aa 10 00 13 mov %l3, %l5
2008ce8: a6 10 00 10 mov %l0, %l3
2008cec: 10 80 00 18 b 2008d4c <_Heap_Walk+0x2c4>
2008cf0: a0 10 00 1c mov %i4, %l0
2008cf4: 18 bf ff ad bgu 2008ba8 <_Heap_Walk+0x120>
2008cf8: 90 10 00 19 mov %i1, %o0
2008cfc: 80 a5 c0 1a cmp %l7, %i2
2008d00: 18 bf ff ab bgu 2008bac <_Heap_Walk+0x124> <== NEVER TAKEN
2008d04: 96 10 00 17 mov %l7, %o3
);
return false;
}
if (
2008d08: 90 05 e0 08 add %l7, 8, %o0
2008d0c: 7f ff e3 6e call 2001ac4 <.urem>
2008d10: 92 10 00 10 mov %l0, %o1
2008d14: 80 a2 20 00 cmp %o0, 0
2008d18: 32 80 00 ce bne,a 2009050 <_Heap_Walk+0x5c8>
2008d1c: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( _Heap_Is_used( free_block ) ) {
2008d20: c2 05 e0 04 ld [ %l7 + 4 ], %g1
2008d24: 82 08 7f fe and %g1, -2, %g1
2008d28: 82 00 40 17 add %g1, %l7, %g1
2008d2c: c2 00 60 04 ld [ %g1 + 4 ], %g1
2008d30: 80 88 60 01 btst 1, %g1
2008d34: 32 80 00 d9 bne,a 2009098 <_Heap_Walk+0x610>
2008d38: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( free_block->prev != prev_block ) {
2008d3c: c2 05 e0 0c ld [ %l7 + 0xc ], %g1
2008d40: 80 a7 00 01 cmp %i4, %g1
2008d44: 32 80 00 cb bne,a 2009070 <_Heap_Walk+0x5e8>
2008d48: a2 10 00 01 mov %g1, %l1
(*printer)(
2008d4c: b8 10 00 17 mov %l7, %i4
return false;
}
prev_block = free_block;
free_block = free_block->next;
2008d50: ee 05 e0 08 ld [ %l7 + 8 ], %l7
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
2008d54: 80 a4 40 17 cmp %l1, %l7
2008d58: 12 bf ff e7 bne 2008cf4 <_Heap_Walk+0x26c>
2008d5c: 80 a6 c0 17 cmp %i3, %l7
2008d60: a0 10 00 13 mov %l3, %l0
2008d64: a6 10 00 15 mov %l5, %l3
2008d68: aa 10 00 1d mov %i5, %l5
2008d6c: fa 07 bf fc ld [ %fp + -4 ], %i5
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
}
while ( block != last_block ) {
2008d70: 80 a5 00 10 cmp %l4, %l0
2008d74: 02 bf ff 55 be 2008ac8 <_Heap_Walk+0x40> <== NEVER TAKEN
2008d78: 37 00 80 76 sethi %hi(0x201d800), %i3
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
2008d7c: 35 00 80 76 sethi %hi(0x201d800), %i2
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
2008d80: 39 00 80 76 sethi %hi(0x201d800), %i4
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008d84: 82 10 00 1d mov %i5, %g1
bool const prev_used = _Heap_Is_prev_used( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
uintptr_t const next_block_begin = (uintptr_t) next_block;
if ( prev_used ) {
(*printer)(
2008d88: b6 16 e0 d0 or %i3, 0xd0, %i3
2008d8c: ba 10 00 15 mov %l5, %i5
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
2008d90: b4 16 a0 e8 or %i2, 0xe8, %i2
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
2008d94: b8 17 21 e8 or %i4, 0x1e8, %i4
2008d98: aa 10 00 14 mov %l4, %l5
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2008d9c: ac 0d bf fe and %l6, -2, %l6
uintptr_t const block_size = _Heap_Block_size( block );
bool const prev_used = _Heap_Is_prev_used( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
uintptr_t const next_block_begin = (uintptr_t) next_block;
if ( prev_used ) {
2008da0: 80 a0 60 00 cmp %g1, 0
2008da4: 02 80 00 16 be 2008dfc <_Heap_Walk+0x374>
2008da8: a2 05 80 10 add %l6, %l0, %l1
(*printer)(
2008dac: 90 10 00 19 mov %i1, %o0
2008db0: 92 10 20 00 clr %o1
2008db4: 94 10 00 1b mov %i3, %o2
2008db8: 96 10 00 10 mov %l0, %o3
2008dbc: 9f c4 80 00 call %l2
2008dc0: 98 10 00 16 mov %l6, %o4
RTEMS_INLINE_ROUTINE bool _Heap_Is_block_in_heap(
const Heap_Control *heap,
const Heap_Block *block
)
{
return (uintptr_t) block >= (uintptr_t) heap->first_block
2008dc4: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
2008dc8: 80 a0 40 11 cmp %g1, %l1
2008dcc: 28 80 00 18 bleu,a 2008e2c <_Heap_Walk+0x3a4> <== ALWAYS TAKEN
2008dd0: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
block->prev_size
);
}
if ( !_Heap_Is_block_in_heap( heap, next_block ) ) {
(*printer)(
2008dd4: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
2008dd8: 96 10 00 10 mov %l0, %o3
2008ddc: 98 10 00 11 mov %l1, %o4
2008de0: 92 10 20 01 mov 1, %o1
2008de4: 15 00 80 76 sethi %hi(0x201d800), %o2
2008de8: b0 10 20 00 clr %i0
2008dec: 9f c4 80 00 call %l2
2008df0: 94 12 a1 10 or %o2, 0x110, %o2
"block 0x%08x: next block 0x%08x not in heap\n",
block,
next_block
);
return false;
2008df4: 81 c7 e0 08 ret
2008df8: 81 e8 00 00 restore
"block 0x%08x: size %u\n",
block,
block_size
);
} else {
(*printer)(
2008dfc: da 04 00 00 ld [ %l0 ], %o5
2008e00: 90 10 00 19 mov %i1, %o0
2008e04: 92 10 20 00 clr %o1
2008e08: 94 10 00 1a mov %i2, %o2
2008e0c: 96 10 00 10 mov %l0, %o3
2008e10: 9f c4 80 00 call %l2
2008e14: 98 10 00 16 mov %l6, %o4
2008e18: c2 06 20 20 ld [ %i0 + 0x20 ], %g1
2008e1c: 80 a0 40 11 cmp %g1, %l1
2008e20: 18 bf ff ee bgu 2008dd8 <_Heap_Walk+0x350> <== NEVER TAKEN
2008e24: 90 10 00 19 mov %i1, %o0
2008e28: c2 06 20 24 ld [ %i0 + 0x24 ], %g1
2008e2c: 80 a0 40 11 cmp %g1, %l1
2008e30: 0a bf ff ea bcs 2008dd8 <_Heap_Walk+0x350>
2008e34: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( !_Heap_Is_aligned( block_size, page_size ) ) {
2008e38: 90 10 00 16 mov %l6, %o0
2008e3c: 7f ff e3 22 call 2001ac4 <.urem>
2008e40: 92 10 00 1d mov %i5, %o1
2008e44: 80 a2 20 00 cmp %o0, 0
2008e48: 12 80 00 5d bne 2008fbc <_Heap_Walk+0x534>
2008e4c: 80 a4 c0 16 cmp %l3, %l6
);
return false;
}
if ( block_size < min_block_size ) {
2008e50: 18 80 00 65 bgu 2008fe4 <_Heap_Walk+0x55c>
2008e54: 80 a4 00 11 cmp %l0, %l1
);
return false;
}
if ( next_block_begin <= block_begin ) {
2008e58: 3a 80 00 6e bcc,a 2009010 <_Heap_Walk+0x588>
2008e5c: 90 10 00 19 mov %i1, %o0
);
return false;
}
if ( !_Heap_Is_prev_used( next_block ) ) {
2008e60: c2 04 60 04 ld [ %l1 + 4 ], %g1
2008e64: 80 88 60 01 btst 1, %g1
2008e68: 12 80 00 40 bne 2008f68 <_Heap_Walk+0x4e0>
2008e6c: 80 a5 40 11 cmp %l5, %l1
block->size_and_flag = size | flag;
}
RTEMS_INLINE_ROUTINE bool _Heap_Is_prev_used( const Heap_Block *block )
{
return block->size_and_flag & HEAP_PREV_BLOCK_USED;
2008e70: e8 04 20 04 ld [ %l0 + 4 ], %l4
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
2008e74: d8 04 20 0c ld [ %l0 + 0xc ], %o4
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008e78: c2 06 20 08 ld [ %i0 + 8 ], %g1
- HEAP_BLOCK_HEADER_SIZE);
}
RTEMS_INLINE_ROUTINE uintptr_t _Heap_Block_size( const Heap_Block *block )
{
return block->size_and_flag & ~HEAP_PREV_BLOCK_USED;
2008e7c: ac 0d 3f fe and %l4, -2, %l6
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008e80: 1b 00 80 76 sethi %hi(0x201d800), %o5
2008e84: 80 a0 40 0c cmp %g1, %o4
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_last( Heap_Control *heap )
{
return _Heap_Free_list_tail(heap)->prev;
2008e88: c6 06 20 0c ld [ %i0 + 0xc ], %g3
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at(
const Heap_Block *block,
uintptr_t offset
)
{
return (Heap_Block *) ((uintptr_t) block + offset);
2008e8c: ae 04 00 16 add %l0, %l6, %l7
return &heap->free_list;
}
RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Free_list_first( Heap_Control *heap )
{
return _Heap_Free_list_head(heap)->next;
2008e90: 02 80 00 07 be 2008eac <_Heap_Walk+0x424>
2008e94: 9a 13 61 d8 or %o5, 0x1d8, %o5
"block 0x%08x: prev 0x%08x%s, next 0x%08x%s\n",
block,
block->prev,
block->prev == first_free_block ?
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
2008e98: 1b 00 80 76 sethi %hi(0x201d800), %o5
2008e9c: 80 a3 00 18 cmp %o4, %i0
2008ea0: 02 80 00 03 be 2008eac <_Heap_Walk+0x424>
2008ea4: 9a 13 61 f0 or %o5, 0x1f0, %o5
2008ea8: 9a 10 00 1c mov %i4, %o5
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
2008eac: c2 04 20 08 ld [ %l0 + 8 ], %g1
2008eb0: 05 00 80 76 sethi %hi(0x201d800), %g2
2008eb4: 80 a0 c0 01 cmp %g3, %g1
2008eb8: 02 80 00 07 be 2008ed4 <_Heap_Walk+0x44c>
2008ebc: 84 10 a2 00 or %g2, 0x200, %g2
" (= first)"
: (block->prev == free_list_head ? " (= head)" : ""),
block->next,
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
2008ec0: 05 00 80 76 sethi %hi(0x201d800), %g2
2008ec4: 80 a0 40 18 cmp %g1, %i0
2008ec8: 02 80 00 03 be 2008ed4 <_Heap_Walk+0x44c>
2008ecc: 84 10 a2 10 or %g2, 0x210, %g2
2008ed0: 84 10 00 1c mov %i4, %g2
Heap_Block *const last_free_block = _Heap_Free_list_last( heap );
bool const prev_used = _Heap_Is_prev_used( block );
uintptr_t const block_size = _Heap_Block_size( block );
Heap_Block *const next_block = _Heap_Block_at( block, block_size );
(*printer)(
2008ed4: c2 23 a0 5c st %g1, [ %sp + 0x5c ]
2008ed8: c4 23 a0 60 st %g2, [ %sp + 0x60 ]
2008edc: 90 10 00 19 mov %i1, %o0
2008ee0: 92 10 20 00 clr %o1
2008ee4: 15 00 80 76 sethi %hi(0x201d800), %o2
2008ee8: 96 10 00 10 mov %l0, %o3
2008eec: 9f c4 80 00 call %l2
2008ef0: 94 12 a2 20 or %o2, 0x220, %o2
block->next == last_free_block ?
" (= last)"
: (block->next == free_list_tail ? " (= tail)" : "")
);
if ( block_size != next_block->prev_size ) {
2008ef4: da 05 c0 00 ld [ %l7 ], %o5
2008ef8: 80 a5 80 0d cmp %l6, %o5
2008efc: 02 80 00 0c be 2008f2c <_Heap_Walk+0x4a4>
2008f00: 90 10 00 19 mov %i1, %o0
(*printer)(
2008f04: ee 23 a0 5c st %l7, [ %sp + 0x5c ]
2008f08: 96 10 00 10 mov %l0, %o3
2008f0c: 98 10 00 16 mov %l6, %o4
2008f10: 92 10 20 01 mov 1, %o1
2008f14: 15 00 80 76 sethi %hi(0x201d800), %o2
2008f18: b0 10 20 00 clr %i0
2008f1c: 9f c4 80 00 call %l2
2008f20: 94 12 a2 50 or %o2, 0x250, %o2
2008f24: 81 c7 e0 08 ret
2008f28: 81 e8 00 00 restore
);
return false;
}
if ( !prev_used ) {
2008f2c: 80 8d 20 01 btst 1, %l4
2008f30: 02 80 00 1c be 2008fa0 <_Heap_Walk+0x518>
2008f34: 96 10 00 10 mov %l0, %o3
2008f38: c2 06 20 08 ld [ %i0 + 8 ], %g1
)
{
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *free_block = _Heap_Free_list_first( heap );
while ( free_block != free_list_tail ) {
2008f3c: 80 a0 40 18 cmp %g1, %i0
2008f40: 12 80 00 07 bne 2008f5c <_Heap_Walk+0x4d4> <== ALWAYS TAKEN
2008f44: 80 a0 40 10 cmp %g1, %l0
return false;
}
if ( !_Heap_Walk_is_in_free_list( heap, block ) ) {
(*printer)(
2008f48: 10 80 00 0f b 2008f84 <_Heap_Walk+0x4fc> <== NOT EXECUTED
2008f4c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED
)
{
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *free_block = _Heap_Free_list_first( heap );
while ( free_block != free_list_tail ) {
2008f50: 80 a0 40 18 cmp %g1, %i0
2008f54: 02 80 00 0a be 2008f7c <_Heap_Walk+0x4f4>
2008f58: 80 a0 40 10 cmp %g1, %l0
if ( free_block == block ) {
2008f5c: 32 bf ff fd bne,a 2008f50 <_Heap_Walk+0x4c8>
2008f60: c2 00 60 08 ld [ %g1 + 8 ], %g1
if ( !_Heap_Walk_check_control( source, printer, heap ) ) {
return false;
}
while ( block != last_block ) {
2008f64: 80 a5 40 11 cmp %l5, %l1
2008f68: 02 bf fe d8 be 2008ac8 <_Heap_Walk+0x40>
2008f6c: a0 10 00 11 mov %l1, %l0
const Heap_Block *const free_list_tail = _Heap_Free_list_tail( heap );
const Heap_Block *const first_free_block = _Heap_Free_list_first( heap );
const Heap_Block *prev_block = free_list_tail;
const Heap_Block *free_block = first_free_block;
while ( free_block != free_list_tail ) {
2008f70: ec 04 60 04 ld [ %l1 + 4 ], %l6
2008f74: 10 bf ff 8a b 2008d9c <_Heap_Walk+0x314>
2008f78: 82 0d a0 01 and %l6, 1, %g1
return false;
}
if ( !_Heap_Walk_is_in_free_list( heap, block ) ) {
(*printer)(
2008f7c: 90 10 00 19 mov %i1, %o0
2008f80: 96 10 00 10 mov %l0, %o3
2008f84: 92 10 20 01 mov 1, %o1
2008f88: 15 00 80 76 sethi %hi(0x201d800), %o2
2008f8c: b0 10 20 00 clr %i0
2008f90: 9f c4 80 00 call %l2
2008f94: 94 12 a2 c0 or %o2, 0x2c0, %o2
2008f98: 81 c7 e0 08 ret
2008f9c: 81 e8 00 00 restore
return false;
}
if ( !prev_used ) {
(*printer)(
2008fa0: 92 10 20 01 mov 1, %o1
2008fa4: 15 00 80 76 sethi %hi(0x201d800), %o2
2008fa8: b0 10 20 00 clr %i0
2008fac: 9f c4 80 00 call %l2
2008fb0: 94 12 a2 90 or %o2, 0x290, %o2
2008fb4: 81 c7 e0 08 ret
2008fb8: 81 e8 00 00 restore
return false;
}
if ( !_Heap_Is_aligned( block_size, page_size ) ) {
(*printer)(
2008fbc: 90 10 00 19 mov %i1, %o0
2008fc0: 96 10 00 10 mov %l0, %o3
2008fc4: 98 10 00 16 mov %l6, %o4
2008fc8: 92 10 20 01 mov 1, %o1
2008fcc: 15 00 80 76 sethi %hi(0x201d800), %o2
2008fd0: b0 10 20 00 clr %i0
2008fd4: 9f c4 80 00 call %l2
2008fd8: 94 12 a1 40 or %o2, 0x140, %o2
"block 0x%08x: block size %u not page aligned\n",
block,
block_size
);
return false;
2008fdc: 81 c7 e0 08 ret
2008fe0: 81 e8 00 00 restore
}
if ( block_size < min_block_size ) {
(*printer)(
2008fe4: 90 10 00 19 mov %i1, %o0
2008fe8: 96 10 00 10 mov %l0, %o3
2008fec: 98 10 00 16 mov %l6, %o4
2008ff0: 9a 10 00 13 mov %l3, %o5
2008ff4: 92 10 20 01 mov 1, %o1
2008ff8: 15 00 80 76 sethi %hi(0x201d800), %o2
2008ffc: b0 10 20 00 clr %i0
2009000: 9f c4 80 00 call %l2
2009004: 94 12 a1 70 or %o2, 0x170, %o2
block,
block_size,
min_block_size
);
return false;
2009008: 81 c7 e0 08 ret
200900c: 81 e8 00 00 restore
}
if ( next_block_begin <= block_begin ) {
(*printer)(
2009010: 96 10 00 10 mov %l0, %o3
2009014: 98 10 00 11 mov %l1, %o4
2009018: 92 10 20 01 mov 1, %o1
200901c: 15 00 80 76 sethi %hi(0x201d800), %o2
2009020: b0 10 20 00 clr %i0
2009024: 9f c4 80 00 call %l2
2009028: 94 12 a1 a0 or %o2, 0x1a0, %o2
"block 0x%08x: next block 0x%08x is not a successor\n",
block,
next_block
);
return false;
200902c: 81 c7 e0 08 ret
2009030: 81 e8 00 00 restore
return false;
}
if ( _Heap_Is_free( last_block ) ) {
(*printer)(
2009034: 92 10 20 01 mov 1, %o1
2009038: 15 00 80 76 sethi %hi(0x201d800), %o2
200903c: b0 10 20 00 clr %i0
2009040: 9f c4 80 00 call %l2
2009044: 94 12 a0 10 or %o2, 0x10, %o2
2009048: 81 c7 e0 08 ret
200904c: 81 e8 00 00 restore
}
if (
!_Heap_Is_aligned( _Heap_Alloc_area_of_block( free_block ), page_size )
) {
(*printer)(
2009050: 96 10 00 17 mov %l7, %o3
2009054: 92 10 20 01 mov 1, %o1
2009058: 15 00 80 76 sethi %hi(0x201d800), %o2
200905c: b0 10 20 00 clr %i0
2009060: 9f c4 80 00 call %l2
2009064: 94 12 a0 48 or %o2, 0x48, %o2
2009068: 81 c7 e0 08 ret
200906c: 81 e8 00 00 restore
return false;
}
if ( free_block->prev != prev_block ) {
(*printer)(
2009070: 90 10 00 19 mov %i1, %o0
2009074: 96 10 00 17 mov %l7, %o3
2009078: 98 10 00 11 mov %l1, %o4
200907c: 92 10 20 01 mov 1, %o1
2009080: 15 00 80 76 sethi %hi(0x201d800), %o2
2009084: b0 10 20 00 clr %i0
2009088: 9f c4 80 00 call %l2
200908c: 94 12 a0 98 or %o2, 0x98, %o2
2009090: 81 c7 e0 08 ret
2009094: 81 e8 00 00 restore
return false;
}
if ( _Heap_Is_used( free_block ) ) {
(*printer)(
2009098: 96 10 00 17 mov %l7, %o3
200909c: 92 10 20 01 mov 1, %o1
20090a0: 15 00 80 76 sethi %hi(0x201d800), %o2
20090a4: b0 10 20 00 clr %i0
20090a8: 9f c4 80 00 call %l2
20090ac: 94 12 a0 78 or %o2, 0x78, %o2
20090b0: 81 c7 e0 08 ret
20090b4: 81 e8 00 00 restore
02006f74 <_IO_Initialize_all_drivers>:
*
* Output Parameters: NONE
*/
void _IO_Initialize_all_drivers( void )
{
2006f74: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_major_number major;
for ( major=0 ; major < _IO_Number_of_drivers ; major ++ )
2006f78: 23 00 80 77 sethi %hi(0x201dc00), %l1
2006f7c: c2 04 62 70 ld [ %l1 + 0x270 ], %g1 ! 201de70 <_IO_Number_of_drivers>
2006f80: 80 a0 60 00 cmp %g1, 0
2006f84: 02 80 00 0c be 2006fb4 <_IO_Initialize_all_drivers+0x40> <== NEVER TAKEN
2006f88: a2 14 62 70 or %l1, 0x270, %l1
2006f8c: a0 10 20 00 clr %l0
(void) rtems_io_initialize( major, 0, NULL );
2006f90: 90 10 00 10 mov %l0, %o0
2006f94: 92 10 20 00 clr %o1
2006f98: 40 00 19 96 call 200d5f0 <rtems_io_initialize>
2006f9c: 94 10 20 00 clr %o2
void _IO_Initialize_all_drivers( void )
{
rtems_device_major_number major;
for ( major=0 ; major < _IO_Number_of_drivers ; major ++ )
2006fa0: c2 04 40 00 ld [ %l1 ], %g1
2006fa4: a0 04 20 01 inc %l0
2006fa8: 80 a0 40 10 cmp %g1, %l0
2006fac: 18 bf ff fa bgu 2006f94 <_IO_Initialize_all_drivers+0x20>
2006fb0: 90 10 00 10 mov %l0, %o0
2006fb4: 81 c7 e0 08 ret
2006fb8: 81 e8 00 00 restore
02006fbc <_IO_Manager_initialization>:
* workspace.
*
*/
void _IO_Manager_initialization(void)
{
2006fbc: 9d e3 bf a0 save %sp, -96, %sp
uint32_t index;
rtems_driver_address_table *driver_table;
uint32_t drivers_in_table;
uint32_t number_of_drivers;
driver_table = Configuration.Device_driver_table;
2006fc0: 03 00 80 74 sethi %hi(0x201d000), %g1
2006fc4: 82 10 60 f8 or %g1, 0xf8, %g1 ! 201d0f8 <Configuration>
drivers_in_table = Configuration.number_of_device_drivers;
number_of_drivers = Configuration.maximum_drivers;
2006fc8: e6 00 60 2c ld [ %g1 + 0x2c ], %l3
rtems_driver_address_table *driver_table;
uint32_t drivers_in_table;
uint32_t number_of_drivers;
driver_table = Configuration.Device_driver_table;
drivers_in_table = Configuration.number_of_device_drivers;
2006fcc: e2 00 60 30 ld [ %g1 + 0x30 ], %l1
/*
* If the user claims there are less drivers than are actually in
* the table, then let's just go with the table's count.
*/
if ( number_of_drivers <= drivers_in_table )
2006fd0: 80 a4 40 13 cmp %l1, %l3
2006fd4: 0a 80 00 08 bcs 2006ff4 <_IO_Manager_initialization+0x38>
2006fd8: e0 00 60 34 ld [ %g1 + 0x34 ], %l0
* If the maximum number of driver is the same as the number in the
* table, then we do not have to copy the driver table. They can't
* register any dynamically.
*/
if ( number_of_drivers == drivers_in_table ) {
_IO_Driver_address_table = driver_table;
2006fdc: 03 00 80 77 sethi %hi(0x201dc00), %g1
2006fe0: e0 20 62 74 st %l0, [ %g1 + 0x274 ] ! 201de74 <_IO_Driver_address_table>
_IO_Number_of_drivers = number_of_drivers;
2006fe4: 03 00 80 77 sethi %hi(0x201dc00), %g1
2006fe8: e2 20 62 70 st %l1, [ %g1 + 0x270 ] ! 201de70 <_IO_Number_of_drivers>
return;
2006fec: 81 c7 e0 08 ret
2006ff0: 81 e8 00 00 restore
* have to allocate a new driver table and copy theirs to it.
*/
_IO_Driver_address_table = (rtems_driver_address_table *)
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
2006ff4: 83 2c e0 03 sll %l3, 3, %g1
2006ff8: a5 2c e0 05 sll %l3, 5, %l2
2006ffc: a4 24 80 01 sub %l2, %g1, %l2
/*
* The application requested extra slots in the driver table, so we
* have to allocate a new driver table and copy theirs to it.
*/
_IO_Driver_address_table = (rtems_driver_address_table *)
2007000: 40 00 0c 97 call 200a25c <_Workspace_Allocate_or_fatal_error>
2007004: 90 10 00 12 mov %l2, %o0
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
_IO_Number_of_drivers = number_of_drivers;
2007008: 03 00 80 77 sethi %hi(0x201dc00), %g1
memset(
200700c: 94 10 00 12 mov %l2, %o2
_IO_Driver_address_table = (rtems_driver_address_table *)
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
_IO_Number_of_drivers = number_of_drivers;
2007010: e6 20 62 70 st %l3, [ %g1 + 0x270 ]
/*
* The application requested extra slots in the driver table, so we
* have to allocate a new driver table and copy theirs to it.
*/
_IO_Driver_address_table = (rtems_driver_address_table *)
2007014: 25 00 80 77 sethi %hi(0x201dc00), %l2
_Workspace_Allocate_or_fatal_error(
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
_IO_Number_of_drivers = number_of_drivers;
memset(
2007018: 92 10 20 00 clr %o1
200701c: 40 00 27 88 call 2010e3c <memset>
2007020: d0 24 a2 74 st %o0, [ %l2 + 0x274 ]
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007024: 80 a4 60 00 cmp %l1, 0
2007028: 02 bf ff f1 be 2006fec <_IO_Manager_initialization+0x30> <== NEVER TAKEN
200702c: da 04 a2 74 ld [ %l2 + 0x274 ], %o5
2007030: 82 10 20 00 clr %g1
2007034: 88 10 20 00 clr %g4
_IO_Driver_address_table[index] = driver_table[index];
2007038: c4 04 00 01 ld [ %l0 + %g1 ], %g2
200703c: 86 04 00 01 add %l0, %g1, %g3
2007040: c4 23 40 01 st %g2, [ %o5 + %g1 ]
2007044: d8 00 e0 04 ld [ %g3 + 4 ], %o4
2007048: 84 03 40 01 add %o5, %g1, %g2
200704c: d8 20 a0 04 st %o4, [ %g2 + 4 ]
2007050: d8 00 e0 08 ld [ %g3 + 8 ], %o4
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007054: 88 01 20 01 inc %g4
_IO_Driver_address_table[index] = driver_table[index];
2007058: d8 20 a0 08 st %o4, [ %g2 + 8 ]
200705c: d8 00 e0 0c ld [ %g3 + 0xc ], %o4
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007060: 82 00 60 18 add %g1, 0x18, %g1
_IO_Driver_address_table[index] = driver_table[index];
2007064: d8 20 a0 0c st %o4, [ %g2 + 0xc ]
2007068: d8 00 e0 10 ld [ %g3 + 0x10 ], %o4
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
200706c: 80 a4 40 04 cmp %l1, %g4
_IO_Driver_address_table[index] = driver_table[index];
2007070: d8 20 a0 10 st %o4, [ %g2 + 0x10 ]
2007074: c6 00 e0 14 ld [ %g3 + 0x14 ], %g3
memset(
_IO_Driver_address_table, 0,
sizeof( rtems_driver_address_table ) * ( number_of_drivers )
);
for ( index = 0 ; index < drivers_in_table ; index++ )
2007078: 18 bf ff f0 bgu 2007038 <_IO_Manager_initialization+0x7c>
200707c: c6 20 a0 14 st %g3, [ %g2 + 0x14 ]
2007080: 81 c7 e0 08 ret
2007084: 81 e8 00 00 restore
020012c0 <_Message_queue_Manager_initialization>:
#include <rtems/score/wkspace.h>
#include <rtems/score/interr.h>
void _Message_queue_Manager_initialization(void)
{
}
20012c0: 81 c3 e0 08 retl
02007d28 <_Objects_Allocate>:
*/
Objects_Control *_Objects_Allocate(
Objects_Information *information
)
{
2007d28: 9d e3 bf a0 save %sp, -96, %sp
* If the application is using the optional manager stubs and
* still attempts to create the object, the information block
* should be all zeroed out because it is in the BSS. So let's
* check that code for this manager is even present.
*/
if ( information->size == 0 )
2007d2c: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
*/
Objects_Control *_Objects_Allocate(
Objects_Information *information
)
{
2007d30: a0 10 00 18 mov %i0, %l0
* If the application is using the optional manager stubs and
* still attempts to create the object, the information block
* should be all zeroed out because it is in the BSS. So let's
* check that code for this manager is even present.
*/
if ( information->size == 0 )
2007d34: 80 a0 60 00 cmp %g1, 0
2007d38: 02 80 00 19 be 2007d9c <_Objects_Allocate+0x74> <== NEVER TAKEN
2007d3c: b0 10 20 00 clr %i0
/*
* OK. The manager should be initialized and configured to have objects.
* With any luck, it is safe to attempt to allocate an object.
*/
the_object = (Objects_Control *) _Chain_Get( &information->Inactive );
2007d40: a2 04 20 20 add %l0, 0x20, %l1
2007d44: 7f ff fd 6d call 20072f8 <_Chain_Get>
2007d48: 90 10 00 11 mov %l1, %o0
if ( information->auto_extend ) {
2007d4c: c2 0c 20 12 ldub [ %l0 + 0x12 ], %g1
2007d50: 80 a0 60 00 cmp %g1, 0
2007d54: 02 80 00 12 be 2007d9c <_Objects_Allocate+0x74>
2007d58: b0 10 00 08 mov %o0, %i0
/*
* If the list is empty then we are out of objects and need to
* extend information base.
*/
if ( !the_object ) {
2007d5c: 80 a2 20 00 cmp %o0, 0
2007d60: 02 80 00 11 be 2007da4 <_Objects_Allocate+0x7c>
2007d64: 01 00 00 00 nop
}
if ( the_object ) {
uint32_t block;
block = (uint32_t) _Objects_Get_index( the_object->id ) -
2007d68: c2 14 20 0a lduh [ %l0 + 0xa ], %g1
2007d6c: d0 16 20 0a lduh [ %i0 + 0xa ], %o0
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007d70: d2 14 20 14 lduh [ %l0 + 0x14 ], %o1
2007d74: 40 00 47 0a call 201999c <.udiv>
2007d78: 90 22 00 01 sub %o0, %g1, %o0
2007d7c: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
2007d80: 91 2a 20 02 sll %o0, 2, %o0
information->inactive--;
2007d84: c6 14 20 2c lduh [ %l0 + 0x2c ], %g3
block = (uint32_t) _Objects_Get_index( the_object->id ) -
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007d88: c4 00 40 08 ld [ %g1 + %o0 ], %g2
information->inactive--;
2007d8c: 86 00 ff ff add %g3, -1, %g3
block = (uint32_t) _Objects_Get_index( the_object->id ) -
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007d90: 84 00 bf ff add %g2, -1, %g2
information->inactive--;
2007d94: c6 34 20 2c sth %g3, [ %l0 + 0x2c ]
block = (uint32_t) _Objects_Get_index( the_object->id ) -
_Objects_Get_index( information->minimum_id );
block /= information->allocation_size;
information->inactive_per_block[ block ]--;
2007d98: c4 20 40 08 st %g2, [ %g1 + %o0 ]
information->inactive--;
}
}
return the_object;
}
2007d9c: 81 c7 e0 08 ret
2007da0: 81 e8 00 00 restore
* If the list is empty then we are out of objects and need to
* extend information base.
*/
if ( !the_object ) {
_Objects_Extend_information( information );
2007da4: 40 00 00 11 call 2007de8 <_Objects_Extend_information>
2007da8: 90 10 00 10 mov %l0, %o0
the_object = (Objects_Control *) _Chain_Get( &information->Inactive );
2007dac: 7f ff fd 53 call 20072f8 <_Chain_Get>
2007db0: 90 10 00 11 mov %l1, %o0
}
if ( the_object ) {
2007db4: b0 92 20 00 orcc %o0, 0, %i0
2007db8: 32 bf ff ed bne,a 2007d6c <_Objects_Allocate+0x44>
2007dbc: c2 14 20 0a lduh [ %l0 + 0xa ], %g1
information->inactive--;
}
}
return the_object;
}
2007dc0: 81 c7 e0 08 ret
2007dc4: 81 e8 00 00 restore
02007de8 <_Objects_Extend_information>:
*/
void _Objects_Extend_information(
Objects_Information *information
)
{
2007de8: 9d e3 bf 90 save %sp, -112, %sp
minimum_index = _Objects_Get_index( information->minimum_id );
index_base = minimum_index;
block = 0;
/* if ( information->maximum < minimum_index ) */
if ( information->object_blocks == NULL )
2007dec: e8 06 20 34 ld [ %i0 + 0x34 ], %l4
2007df0: 80 a5 20 00 cmp %l4, 0
2007df4: 02 80 00 ab be 20080a0 <_Objects_Extend_information+0x2b8>
2007df8: e6 16 20 0a lduh [ %i0 + 0xa ], %l3
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
2007dfc: ea 16 20 10 lduh [ %i0 + 0x10 ], %l5
2007e00: e4 16 20 14 lduh [ %i0 + 0x14 ], %l2
2007e04: ab 2d 60 10 sll %l5, 0x10, %l5
2007e08: 92 10 00 12 mov %l2, %o1
2007e0c: 40 00 46 e4 call 201999c <.udiv>
2007e10: 91 35 60 10 srl %l5, 0x10, %o0
2007e14: 91 2a 20 10 sll %o0, 0x10, %o0
2007e18: b9 32 20 10 srl %o0, 0x10, %i4
for ( ; block < block_count; block++ ) {
2007e1c: 80 a7 20 00 cmp %i4, 0
2007e20: 02 80 00 a7 be 20080bc <_Objects_Extend_information+0x2d4><== NEVER TAKEN
2007e24: 90 10 00 12 mov %l2, %o0
if ( information->object_blocks[ block ] == NULL )
2007e28: c2 05 00 00 ld [ %l4 ], %g1
2007e2c: 80 a0 60 00 cmp %g1, 0
2007e30: 02 80 00 a4 be 20080c0 <_Objects_Extend_information+0x2d8><== NEVER TAKEN
2007e34: a2 10 00 13 mov %l3, %l1
2007e38: 10 80 00 06 b 2007e50 <_Objects_Extend_information+0x68>
2007e3c: a0 10 20 00 clr %l0
2007e40: c2 05 00 01 ld [ %l4 + %g1 ], %g1
2007e44: 80 a0 60 00 cmp %g1, 0
2007e48: 22 80 00 08 be,a 2007e68 <_Objects_Extend_information+0x80>
2007e4c: ab 35 60 10 srl %l5, 0x10, %l5
if ( information->object_blocks == NULL )
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
for ( ; block < block_count; block++ ) {
2007e50: a0 04 20 01 inc %l0
if ( information->object_blocks[ block ] == NULL )
break;
else
index_base += information->allocation_size;
2007e54: a2 04 40 12 add %l1, %l2, %l1
if ( information->object_blocks == NULL )
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
for ( ; block < block_count; block++ ) {
2007e58: 80 a7 00 10 cmp %i4, %l0
2007e5c: 18 bf ff f9 bgu 2007e40 <_Objects_Extend_information+0x58>
2007e60: 83 2c 20 02 sll %l0, 2, %g1
else
index_base += information->allocation_size;
}
}
maximum = (uint32_t) information->maximum + information->allocation_size;
2007e64: ab 35 60 10 srl %l5, 0x10, %l5
/*
* We need to limit the number of objects to the maximum number
* representable in the index portion of the object Id. In the
* case of 16-bit Ids, this is only 256 object instances.
*/
if ( maximum > OBJECTS_ID_FINAL_INDEX ) {
2007e68: 03 00 00 3f sethi %hi(0xfc00), %g1
else
index_base += information->allocation_size;
}
}
maximum = (uint32_t) information->maximum + information->allocation_size;
2007e6c: aa 05 40 08 add %l5, %o0, %l5
/*
* We need to limit the number of objects to the maximum number
* representable in the index portion of the object Id. In the
* case of 16-bit Ids, this is only 256 object instances.
*/
if ( maximum > OBJECTS_ID_FINAL_INDEX ) {
2007e70: 82 10 63 ff or %g1, 0x3ff, %g1
2007e74: 80 a5 40 01 cmp %l5, %g1
2007e78: 18 80 00 96 bgu 20080d0 <_Objects_Extend_information+0x2e8><== NEVER TAKEN
2007e7c: 01 00 00 00 nop
/*
* Allocate the name table, and the objects and if it fails either return or
* generate a fatal error depending on auto-extending being active.
*/
block_size = information->allocation_size * information->size;
2007e80: 40 00 46 8d call 20198b4 <.umul>
2007e84: d2 06 20 18 ld [ %i0 + 0x18 ], %o1
if ( information->auto_extend ) {
2007e88: c2 0e 20 12 ldub [ %i0 + 0x12 ], %g1
2007e8c: 80 a0 60 00 cmp %g1, 0
2007e90: 12 80 00 6d bne 2008044 <_Objects_Extend_information+0x25c>
2007e94: 01 00 00 00 nop
new_object_block = _Workspace_Allocate( block_size );
if ( !new_object_block )
return;
} else {
new_object_block = _Workspace_Allocate_or_fatal_error( block_size );
2007e98: 40 00 08 f1 call 200a25c <_Workspace_Allocate_or_fatal_error>
2007e9c: 01 00 00 00 nop
2007ea0: a4 10 00 08 mov %o0, %l2
}
/*
* If the index_base is the maximum we need to grow the tables.
*/
if (index_base >= information->maximum ) {
2007ea4: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
2007ea8: 80 a4 40 01 cmp %l1, %g1
2007eac: 2a 80 00 43 bcs,a 2007fb8 <_Objects_Extend_information+0x1d0>
2007eb0: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
*/
/*
* Up the block count and maximum
*/
block_count++;
2007eb4: a8 07 20 01 add %i4, 1, %l4
* Allocate the tables and break it up.
*/
block_size = block_count *
(sizeof(void *) + sizeof(uint32_t) + sizeof(Objects_Name *)) +
((maximum + minimum_index) * sizeof(Objects_Control *));
object_blocks = (void**) _Workspace_Allocate( block_size );
2007eb8: 91 2d 20 01 sll %l4, 1, %o0
2007ebc: 90 02 00 14 add %o0, %l4, %o0
2007ec0: 90 05 40 08 add %l5, %o0, %o0
2007ec4: 90 02 00 13 add %o0, %l3, %o0
2007ec8: 40 00 08 f4 call 200a298 <_Workspace_Allocate>
2007ecc: 91 2a 20 02 sll %o0, 2, %o0
if ( !object_blocks ) {
2007ed0: ac 92 20 00 orcc %o0, 0, %l6
2007ed4: 02 80 00 7d be 20080c8 <_Objects_Extend_information+0x2e0>
2007ed8: a9 2d 20 02 sll %l4, 2, %l4
* Take the block count down. Saves all the (block_count - 1)
* in the copies.
*/
block_count--;
if ( information->maximum > minimum_index ) {
2007edc: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
2007ee0: 80 a4 c0 01 cmp %l3, %g1
RTEMS_INLINE_ROUTINE void *_Addresses_Add_offset (
const void *base,
uintptr_t offset
)
{
return (void *)((uintptr_t)base + offset);
2007ee4: ae 05 80 14 add %l6, %l4, %l7
2007ee8: 0a 80 00 5e bcs 2008060 <_Objects_Extend_information+0x278>
2007eec: a8 05 c0 14 add %l7, %l4, %l4
} else {
/*
* Deal with the special case of the 0 to minimum_index
*/
for ( index = 0; index < minimum_index; index++ ) {
2007ef0: 80 a4 e0 00 cmp %l3, 0
information->object_blocks,
block_count * sizeof(void*) );
memcpy( inactive_per_block,
information->inactive_per_block,
block_count * sizeof(uint32_t) );
memcpy( local_table,
2007ef4: 82 10 20 00 clr %g1
} else {
/*
* Deal with the special case of the 0 to minimum_index
*/
for ( index = 0; index < minimum_index; index++ ) {
2007ef8: 02 80 00 08 be 2007f18 <_Objects_Extend_information+0x130><== NEVER TAKEN
2007efc: bb 2f 20 02 sll %i4, 2, %i5
local_table[ index ] = NULL;
2007f00: 85 28 60 02 sll %g1, 2, %g2
} else {
/*
* Deal with the special case of the 0 to minimum_index
*/
for ( index = 0; index < minimum_index; index++ ) {
2007f04: 82 00 60 01 inc %g1
2007f08: 80 a4 c0 01 cmp %l3, %g1
2007f0c: 18 bf ff fd bgu 2007f00 <_Objects_Extend_information+0x118><== NEVER TAKEN
2007f10: c0 20 80 14 clr [ %g2 + %l4 ]
2007f14: bb 2f 20 02 sll %i4, 2, %i5
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
index < ( information->allocation_size + index_base );
2007f18: c6 16 20 14 lduh [ %i0 + 0x14 ], %g3
/*
* Initialise the new entries in the table.
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
2007f1c: c0 25 c0 1d clr [ %l7 + %i5 ]
for ( index=index_base ;
index < ( information->allocation_size + index_base );
2007f20: 86 04 40 03 add %l1, %g3, %g3
* Initialise the new entries in the table.
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
2007f24: 80 a4 40 03 cmp %l1, %g3
2007f28: 1a 80 00 0a bcc 2007f50 <_Objects_Extend_information+0x168><== NEVER TAKEN
2007f2c: c0 25 80 1d clr [ %l6 + %i5 ]
2007f30: 85 2c 60 02 sll %l1, 2, %g2
2007f34: 82 10 00 11 mov %l1, %g1
2007f38: 84 05 00 02 add %l4, %g2, %g2
index < ( information->allocation_size + index_base );
index++ ) {
local_table[ index ] = NULL;
2007f3c: c0 20 80 00 clr [ %g2 ]
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
index < ( information->allocation_size + index_base );
index++ ) {
2007f40: 82 00 60 01 inc %g1
* Initialise the new entries in the table.
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
2007f44: 80 a0 c0 01 cmp %g3, %g1
2007f48: 18 bf ff fd bgu 2007f3c <_Objects_Extend_information+0x154>
2007f4c: 84 00 a0 04 add %g2, 4, %g2
index < ( information->allocation_size + index_base );
index++ ) {
local_table[ index ] = NULL;
}
_ISR_Disable( level );
2007f50: 7f ff e8 55 call 20020a4 <sparc_disable_interrupts>
2007f54: 01 00 00 00 nop
information->object_blocks = object_blocks;
information->inactive_per_block = inactive_per_block;
information->local_table = local_table;
information->maximum = (Objects_Maximum) maximum;
information->maximum_id = _Objects_Build_id(
2007f58: c6 06 00 00 ld [ %i0 ], %g3
2007f5c: c4 16 20 04 lduh [ %i0 + 4 ], %g2
old_tables = information->object_blocks;
information->object_blocks = object_blocks;
information->inactive_per_block = inactive_per_block;
information->local_table = local_table;
information->maximum = (Objects_Maximum) maximum;
2007f60: ea 36 20 10 sth %l5, [ %i0 + 0x10 ]
local_table[ index ] = NULL;
}
_ISR_Disable( level );
old_tables = information->object_blocks;
2007f64: e6 06 20 34 ld [ %i0 + 0x34 ], %l3
information->object_blocks = object_blocks;
information->inactive_per_block = inactive_per_block;
2007f68: ee 26 20 30 st %l7, [ %i0 + 0x30 ]
information->local_table = local_table;
2007f6c: e8 26 20 1c st %l4, [ %i0 + 0x1c ]
information->maximum = (Objects_Maximum) maximum;
information->maximum_id = _Objects_Build_id(
2007f70: 87 28 e0 18 sll %g3, 0x18, %g3
2007f74: 85 28 a0 1b sll %g2, 0x1b, %g2
_ISR_Disable( level );
old_tables = information->object_blocks;
information->object_blocks = object_blocks;
2007f78: ec 26 20 34 st %l6, [ %i0 + 0x34 ]
information->inactive_per_block = inactive_per_block;
information->local_table = local_table;
information->maximum = (Objects_Maximum) maximum;
information->maximum_id = _Objects_Build_id(
2007f7c: ab 2d 60 10 sll %l5, 0x10, %l5
2007f80: 03 00 00 40 sethi %hi(0x10000), %g1
2007f84: ab 35 60 10 srl %l5, 0x10, %l5
2007f88: 82 10 c0 01 or %g3, %g1, %g1
2007f8c: 82 10 40 02 or %g1, %g2, %g1
2007f90: 82 10 40 15 or %g1, %l5, %g1
2007f94: c2 26 20 0c st %g1, [ %i0 + 0xc ]
information->the_class,
_Objects_Local_node,
information->maximum
);
_ISR_Enable( level );
2007f98: 7f ff e8 47 call 20020b4 <sparc_enable_interrupts>
2007f9c: 01 00 00 00 nop
if ( old_tables )
2007fa0: 80 a4 e0 00 cmp %l3, 0
2007fa4: 22 80 00 05 be,a 2007fb8 <_Objects_Extend_information+0x1d0>
2007fa8: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
_Workspace_Free( old_tables );
2007fac: 40 00 08 c4 call 200a2bc <_Workspace_Free>
2007fb0: 90 10 00 13 mov %l3, %o0
}
/*
* Assign the new object block to the object block table.
*/
information->object_blocks[ block ] = new_object_block;
2007fb4: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
/*
* Initialize objects .. add to a local chain first.
*/
_Chain_Initialize(
2007fb8: d4 16 20 14 lduh [ %i0 + 0x14 ], %o2
2007fbc: d6 06 20 18 ld [ %i0 + 0x18 ], %o3
2007fc0: 92 10 00 12 mov %l2, %o1
}
/*
* Assign the new object block to the object block table.
*/
information->object_blocks[ block ] = new_object_block;
2007fc4: a1 2c 20 02 sll %l0, 2, %l0
information->the_class,
_Objects_Local_node,
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
2007fc8: a6 06 20 20 add %i0, 0x20, %l3
}
/*
* Assign the new object block to the object block table.
*/
information->object_blocks[ block ] = new_object_block;
2007fcc: e4 20 40 10 st %l2, [ %g1 + %l0 ]
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
the_object->id = _Objects_Build_id(
2007fd0: 29 00 00 40 sethi %hi(0x10000), %l4
information->object_blocks[ block ] = new_object_block;
/*
* Initialize objects .. add to a local chain first.
*/
_Chain_Initialize(
2007fd4: a4 07 bf f4 add %fp, -12, %l2
2007fd8: 40 00 15 9d call 200d64c <_Chain_Initialize>
2007fdc: 90 10 00 12 mov %l2, %o0
/*
* Move from the local chain, initialise, then append to the inactive chain
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
2007fe0: 30 80 00 0c b,a 2008010 <_Objects_Extend_information+0x228>
the_object->id = _Objects_Build_id(
2007fe4: c4 16 20 04 lduh [ %i0 + 4 ], %g2
2007fe8: 83 28 60 18 sll %g1, 0x18, %g1
2007fec: 85 28 a0 1b sll %g2, 0x1b, %g2
2007ff0: 82 10 40 14 or %g1, %l4, %g1
2007ff4: 82 10 40 02 or %g1, %g2, %g1
2007ff8: 82 10 40 11 or %g1, %l1, %g1
information->the_class,
_Objects_Local_node,
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
2007ffc: 92 10 00 08 mov %o0, %o1
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
the_object->id = _Objects_Build_id(
2008000: c2 22 20 08 st %g1, [ %o0 + 8 ]
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
index++;
2008004: a2 04 60 01 inc %l1
information->the_class,
_Objects_Local_node,
index
);
_Chain_Append( &information->Inactive, &the_object->Node );
2008008: 7f ff fc a6 call 20072a0 <_Chain_Append>
200800c: 90 10 00 13 mov %l3, %o0
/*
* Move from the local chain, initialise, then append to the inactive chain
*/
index = index_base;
while ((the_object = (Objects_Control *) _Chain_Get( &Inactive )) != NULL ) {
2008010: 7f ff fc ba call 20072f8 <_Chain_Get>
2008014: 90 10 00 12 mov %l2, %o0
2008018: 80 a2 20 00 cmp %o0, 0
200801c: 32 bf ff f2 bne,a 2007fe4 <_Objects_Extend_information+0x1fc>
2008020: c2 06 00 00 ld [ %i0 ], %g1
index++;
}
information->inactive_per_block[ block ] = information->allocation_size;
information->inactive =
2008024: c2 16 20 2c lduh [ %i0 + 0x2c ], %g1
_Chain_Append( &information->Inactive, &the_object->Node );
index++;
}
information->inactive_per_block[ block ] = information->allocation_size;
2008028: c8 16 20 14 lduh [ %i0 + 0x14 ], %g4
200802c: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
information->inactive =
2008030: 82 01 00 01 add %g4, %g1, %g1
_Chain_Append( &information->Inactive, &the_object->Node );
index++;
}
information->inactive_per_block[ block ] = information->allocation_size;
2008034: c8 20 80 10 st %g4, [ %g2 + %l0 ]
information->inactive =
2008038: c2 36 20 2c sth %g1, [ %i0 + 0x2c ]
200803c: 81 c7 e0 08 ret
2008040: 81 e8 00 00 restore
* Allocate the name table, and the objects and if it fails either return or
* generate a fatal error depending on auto-extending being active.
*/
block_size = information->allocation_size * information->size;
if ( information->auto_extend ) {
new_object_block = _Workspace_Allocate( block_size );
2008044: 40 00 08 95 call 200a298 <_Workspace_Allocate>
2008048: 01 00 00 00 nop
if ( !new_object_block )
200804c: a4 92 20 00 orcc %o0, 0, %l2
2008050: 32 bf ff 96 bne,a 2007ea8 <_Objects_Extend_information+0xc0>
2008054: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
2008058: 81 c7 e0 08 ret
200805c: 81 e8 00 00 restore
/*
* Copy each section of the table over. This has to be performed as
* separate parts as size of each block has changed.
*/
memcpy( object_blocks,
2008060: d2 06 20 34 ld [ %i0 + 0x34 ], %o1
information->object_blocks,
block_count * sizeof(void*) );
2008064: bb 2f 20 02 sll %i4, 2, %i5
/*
* Copy each section of the table over. This has to be performed as
* separate parts as size of each block has changed.
*/
memcpy( object_blocks,
2008068: 40 00 23 36 call 2010d40 <memcpy>
200806c: 94 10 00 1d mov %i5, %o2
information->object_blocks,
block_count * sizeof(void*) );
memcpy( inactive_per_block,
2008070: d2 06 20 30 ld [ %i0 + 0x30 ], %o1
2008074: 94 10 00 1d mov %i5, %o2
2008078: 40 00 23 32 call 2010d40 <memcpy>
200807c: 90 10 00 17 mov %l7, %o0
information->inactive_per_block,
block_count * sizeof(uint32_t) );
memcpy( local_table,
2008080: d4 16 20 10 lduh [ %i0 + 0x10 ], %o2
2008084: d2 06 20 1c ld [ %i0 + 0x1c ], %o1
2008088: 94 04 c0 0a add %l3, %o2, %o2
200808c: 90 10 00 14 mov %l4, %o0
2008090: 40 00 23 2c call 2010d40 <memcpy>
2008094: 95 2a a0 02 sll %o2, 2, %o2
*/
object_blocks[block_count] = NULL;
inactive_per_block[block_count] = 0;
for ( index=index_base ;
index < ( information->allocation_size + index_base );
2008098: 10 bf ff a1 b 2007f1c <_Objects_Extend_information+0x134>
200809c: c6 16 20 14 lduh [ %i0 + 0x14 ], %g3
minimum_index = _Objects_Get_index( information->minimum_id );
index_base = minimum_index;
block = 0;
/* if ( information->maximum < minimum_index ) */
if ( information->object_blocks == NULL )
20080a0: ea 16 20 10 lduh [ %i0 + 0x10 ], %l5
20080a4: d0 16 20 14 lduh [ %i0 + 0x14 ], %o0
20080a8: ab 2d 60 10 sll %l5, 0x10, %l5
20080ac: a2 10 00 13 mov %l3, %l1
20080b0: a0 10 20 00 clr %l0
20080b4: 10 bf ff 6c b 2007e64 <_Objects_Extend_information+0x7c>
20080b8: b8 10 20 00 clr %i4
block_count = 0;
else {
block_count = information->maximum / information->allocation_size;
for ( ; block < block_count; block++ ) {
if ( information->object_blocks[ block ] == NULL )
20080bc: a2 10 00 13 mov %l3, %l1 <== NOT EXECUTED
20080c0: 10 bf ff 69 b 2007e64 <_Objects_Extend_information+0x7c> <== NOT EXECUTED
20080c4: a0 10 20 00 clr %l0 <== NOT EXECUTED
(sizeof(void *) + sizeof(uint32_t) + sizeof(Objects_Name *)) +
((maximum + minimum_index) * sizeof(Objects_Control *));
object_blocks = (void**) _Workspace_Allocate( block_size );
if ( !object_blocks ) {
_Workspace_Free( new_object_block );
20080c8: 40 00 08 7d call 200a2bc <_Workspace_Free>
20080cc: 90 10 00 12 mov %l2, %o0
return;
20080d0: 81 c7 e0 08 ret
20080d4: 81 e8 00 00 restore
02008184 <_Objects_Get_information>:
Objects_Information *_Objects_Get_information(
Objects_APIs the_api,
uint32_t the_class
)
{
2008184: 9d e3 bf a0 save %sp, -96, %sp
Objects_Information *info;
int the_class_api_maximum;
if ( !the_class )
2008188: 80 a6 60 00 cmp %i1, 0
200818c: 12 80 00 04 bne 200819c <_Objects_Get_information+0x18>
2008190: 01 00 00 00 nop
if ( info->maximum == 0 )
return NULL;
#endif
return info;
}
2008194: 81 c7 e0 08 ret
2008198: 91 e8 20 00 restore %g0, 0, %o0
/*
* This call implicitly validates the_api so we do not call
* _Objects_Is_api_valid above here.
*/
the_class_api_maximum = _Objects_API_maximum_class( the_api );
200819c: 40 00 16 d8 call 200dcfc <_Objects_API_maximum_class>
20081a0: 90 10 00 18 mov %i0, %o0
if ( the_class_api_maximum == 0 )
20081a4: 80 a2 20 00 cmp %o0, 0
20081a8: 22 80 00 15 be,a 20081fc <_Objects_Get_information+0x78>
20081ac: b0 10 20 00 clr %i0
return NULL;
if ( the_class > (uint32_t) the_class_api_maximum )
20081b0: 80 a6 40 08 cmp %i1, %o0
20081b4: 38 80 00 12 bgu,a 20081fc <_Objects_Get_information+0x78>
20081b8: b0 10 20 00 clr %i0
return NULL;
if ( !_Objects_Information_table[ the_api ] )
20081bc: b1 2e 20 02 sll %i0, 2, %i0
20081c0: 03 00 80 76 sethi %hi(0x201d800), %g1
20081c4: 82 10 63 10 or %g1, 0x310, %g1 ! 201db10 <_Objects_Information_table>
20081c8: c2 00 40 18 ld [ %g1 + %i0 ], %g1
20081cc: 80 a0 60 00 cmp %g1, 0
20081d0: 02 80 00 0b be 20081fc <_Objects_Get_information+0x78> <== NEVER TAKEN
20081d4: b0 10 20 00 clr %i0
return NULL;
info = _Objects_Information_table[ the_api ][ the_class ];
20081d8: b3 2e 60 02 sll %i1, 2, %i1
20081dc: f0 00 40 19 ld [ %g1 + %i1 ], %i0
if ( !info )
20081e0: 80 a6 20 00 cmp %i0, 0
20081e4: 02 80 00 06 be 20081fc <_Objects_Get_information+0x78> <== NEVER TAKEN
20081e8: 01 00 00 00 nop
* In a multprocessing configuration, we may access remote objects.
* Thus we may have 0 local instances and still have a valid object
* pointer.
*/
#if !defined(RTEMS_MULTIPROCESSING)
if ( info->maximum == 0 )
20081ec: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1
20081f0: 80 a0 60 00 cmp %g1, 0
20081f4: 22 80 00 02 be,a 20081fc <_Objects_Get_information+0x78>
20081f8: b0 10 20 00 clr %i0
return NULL;
#endif
return info;
}
20081fc: 81 c7 e0 08 ret
2008200: 81 e8 00 00 restore
02017488 <_Objects_Get_name_as_string>:
char *_Objects_Get_name_as_string(
Objects_Id id,
size_t length,
char *name
)
{
2017488: 9d e3 bf 90 save %sp, -112, %sp
char lname[5];
Objects_Control *the_object;
Objects_Locations location;
Objects_Id tmpId;
if ( length == 0 )
201748c: 80 a6 60 00 cmp %i1, 0
2017490: 12 80 00 05 bne 20174a4 <_Objects_Get_name_as_string+0x1c>
2017494: 80 a6 a0 00 cmp %i2, 0
}
}
*d = '\0';
_Thread_Enable_dispatch();
return name;
2017498: b4 10 20 00 clr %i2
}
return NULL; /* unreachable path */
}
201749c: 81 c7 e0 08 ret
20174a0: 91 e8 00 1a restore %g0, %i2, %o0
Objects_Id tmpId;
if ( length == 0 )
return NULL;
if ( name == NULL )
20174a4: 02 bf ff fe be 201749c <_Objects_Get_name_as_string+0x14>
20174a8: 80 a6 20 00 cmp %i0, 0
return NULL;
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
20174ac: 12 80 00 04 bne 20174bc <_Objects_Get_name_as_string+0x34>
20174b0: 03 00 80 c1 sethi %hi(0x2030400), %g1
20174b4: c2 00 62 30 ld [ %g1 + 0x230 ], %g1 ! 2030630 <_Thread_Executing>
20174b8: f0 00 60 08 ld [ %g1 + 8 ], %i0
information = _Objects_Get_information_id( tmpId );
20174bc: 7f ff db ae call 200e374 <_Objects_Get_information_id>
20174c0: 90 10 00 18 mov %i0, %o0
if ( !information )
20174c4: 80 a2 20 00 cmp %o0, 0
20174c8: 22 bf ff f5 be,a 201749c <_Objects_Get_name_as_string+0x14>
20174cc: b4 10 20 00 clr %i2
return NULL;
the_object = _Objects_Get( information, tmpId, &location );
20174d0: 92 10 00 18 mov %i0, %o1
20174d4: 7f ff db ec call 200e484 <_Objects_Get>
20174d8: 94 07 bf fc add %fp, -4, %o2
switch ( location ) {
20174dc: c2 07 bf fc ld [ %fp + -4 ], %g1
20174e0: 80 a0 60 00 cmp %g1, 0
20174e4: 32 bf ff ee bne,a 201749c <_Objects_Get_name_as_string+0x14>
20174e8: b4 10 20 00 clr %i2
if ( information->is_string ) {
s = the_object->name.name_p;
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
20174ec: c2 02 20 0c ld [ %o0 + 0xc ], %g1
lname[ 0 ] = (u32_name >> 24) & 0xff;
lname[ 1 ] = (u32_name >> 16) & 0xff;
lname[ 2 ] = (u32_name >> 8) & 0xff;
lname[ 3 ] = (u32_name >> 0) & 0xff;
lname[ 4 ] = '\0';
20174f0: c0 2f bf f4 clrb [ %fp + -12 ]
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
20174f4: 87 30 60 18 srl %g1, 0x18, %g3
lname[ 1 ] = (u32_name >> 16) & 0xff;
20174f8: 85 30 60 10 srl %g1, 0x10, %g2
lname[ 2 ] = (u32_name >> 8) & 0xff;
lname[ 3 ] = (u32_name >> 0) & 0xff;
20174fc: c2 2f bf f3 stb %g1, [ %fp + -13 ]
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
lname[ 1 ] = (u32_name >> 16) & 0xff;
2017500: c4 2f bf f1 stb %g2, [ %fp + -15 ]
lname[ 2 ] = (u32_name >> 8) & 0xff;
2017504: 83 30 60 08 srl %g1, 8, %g1
} else
#endif
{
uint32_t u32_name = (uint32_t) the_object->name.name_u32;
lname[ 0 ] = (u32_name >> 24) & 0xff;
2017508: c6 2f bf f0 stb %g3, [ %fp + -16 ]
lname[ 1 ] = (u32_name >> 16) & 0xff;
lname[ 2 ] = (u32_name >> 8) & 0xff;
201750c: c2 2f bf f2 stb %g1, [ %fp + -14 ]
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
2017510: b2 86 7f ff addcc %i1, -1, %i1
2017514: 02 80 00 1d be 2017588 <_Objects_Get_name_as_string+0x100><== NEVER TAKEN
2017518: 84 10 00 03 mov %g3, %g2
201751c: 80 a0 e0 00 cmp %g3, 0
2017520: 02 80 00 1a be 2017588 <_Objects_Get_name_as_string+0x100>
2017524: 17 00 80 bd sethi %hi(0x202f400), %o3
2017528: 86 10 00 1a mov %i2, %g3
201752c: 96 12 e1 28 or %o3, 0x128, %o3
2017530: 82 10 20 00 clr %g1
2017534: 10 80 00 06 b 201754c <_Objects_Get_name_as_string+0xc4>
2017538: 98 07 bf f0 add %fp, -16, %o4
201753c: c8 4b 00 01 ldsb [ %o4 + %g1 ], %g4
2017540: 80 a1 20 00 cmp %g4, 0
2017544: 02 80 00 0e be 201757c <_Objects_Get_name_as_string+0xf4>
2017548: c4 0b 00 01 ldub [ %o4 + %g1 ], %g2
*d = (isprint((unsigned char)*s)) ? *s : '*';
201754c: da 02 c0 00 ld [ %o3 ], %o5
2017550: 88 08 a0 ff and %g2, 0xff, %g4
2017554: 88 03 40 04 add %o5, %g4, %g4
2017558: c8 49 20 01 ldsb [ %g4 + 1 ], %g4
201755c: 80 89 20 97 btst 0x97, %g4
2017560: 12 80 00 03 bne 201756c <_Objects_Get_name_as_string+0xe4>
2017564: 82 00 60 01 inc %g1
2017568: 84 10 20 2a mov 0x2a, %g2
201756c: c4 28 c0 00 stb %g2, [ %g3 ]
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
2017570: 80 a0 40 19 cmp %g1, %i1
2017574: 0a bf ff f2 bcs 201753c <_Objects_Get_name_as_string+0xb4>
2017578: 86 00 e0 01 inc %g3
*d = (isprint((unsigned char)*s)) ? *s : '*';
}
}
*d = '\0';
_Thread_Enable_dispatch();
201757c: 7f ff de 87 call 200ef98 <_Thread_Enable_dispatch>
2017580: c0 28 c0 00 clrb [ %g3 ]
return name;
2017584: 30 bf ff c6 b,a 201749c <_Objects_Get_name_as_string+0x14>
s = lname;
}
d = name;
if ( s ) {
for ( i=0 ; i<(length-1) && *s ; i++, s++, d++ ) {
2017588: 10 bf ff fd b 201757c <_Objects_Get_name_as_string+0xf4>
201758c: 86 10 00 1a mov %i2, %g3
020195e8 <_Objects_Get_no_protection>:
/*
* You can't just extract the index portion or you can get tricked
* by a value between 1 and maximum.
*/
index = id - information->minimum_id + 1;
20195e8: c4 02 20 08 ld [ %o0 + 8 ], %g2
if ( information->maximum >= index ) {
20195ec: c2 12 20 10 lduh [ %o0 + 0x10 ], %g1
/*
* You can't just extract the index portion or you can get tricked
* by a value between 1 and maximum.
*/
index = id - information->minimum_id + 1;
20195f0: 84 22 40 02 sub %o1, %g2, %g2
20195f4: 84 00 a0 01 inc %g2
if ( information->maximum >= index ) {
20195f8: 80 a0 80 01 cmp %g2, %g1
20195fc: 18 80 00 09 bgu 2019620 <_Objects_Get_no_protection+0x38>
2019600: 85 28 a0 02 sll %g2, 2, %g2
if ( (the_object = information->local_table[ index ]) != NULL ) {
2019604: c2 02 20 1c ld [ %o0 + 0x1c ], %g1
2019608: d0 00 40 02 ld [ %g1 + %g2 ], %o0
201960c: 80 a2 20 00 cmp %o0, 0
2019610: 02 80 00 05 be 2019624 <_Objects_Get_no_protection+0x3c> <== NEVER TAKEN
2019614: 82 10 20 01 mov 1, %g1
*location = OBJECTS_LOCAL;
return the_object;
2019618: 81 c3 e0 08 retl
201961c: c0 22 80 00 clr [ %o2 ]
/*
* This isn't supported or required yet for Global objects so
* if it isn't local, we don't find it.
*/
*location = OBJECTS_ERROR;
2019620: 82 10 20 01 mov 1, %g1
2019624: 90 10 20 00 clr %o0
return NULL;
}
2019628: 81 c3 e0 08 retl
201962c: c2 22 80 00 st %g1, [ %o2 ]
0200e4f8 <_Objects_Id_to_name>:
*/
Objects_Name_or_id_lookup_errors _Objects_Id_to_name (
Objects_Id id,
Objects_Name *name
)
{
200e4f8: 9d e3 bf 98 save %sp, -104, %sp
/*
* Caller is trusted for name != NULL.
*/
tmpId = (id == OBJECTS_ID_OF_SELF) ? _Thread_Executing->Object.id : id;
200e4fc: 92 96 20 00 orcc %i0, 0, %o1
200e500: 12 80 00 06 bne 200e518 <_Objects_Id_to_name+0x20>
200e504: 83 32 60 18 srl %o1, 0x18, %g1
200e508: 03 00 80 c1 sethi %hi(0x2030400), %g1
200e50c: c2 00 62 30 ld [ %g1 + 0x230 ], %g1 ! 2030630 <_Thread_Executing>
200e510: d2 00 60 08 ld [ %g1 + 8 ], %o1
*/
RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API(
Objects_Id id
)
{
return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS);
200e514: 83 32 60 18 srl %o1, 0x18, %g1
200e518: 82 08 60 07 and %g1, 7, %g1
*/
RTEMS_INLINE_ROUTINE bool _Objects_Is_api_valid(
uint32_t the_api
)
{
if ( !the_api || the_api > OBJECTS_APIS_LAST )
200e51c: 84 00 7f ff add %g1, -1, %g2
200e520: 80 a0 a0 03 cmp %g2, 3
200e524: 18 80 00 18 bgu 200e584 <_Objects_Id_to_name+0x8c>
200e528: 83 28 60 02 sll %g1, 2, %g1
the_api = _Objects_Get_API( tmpId );
if ( !_Objects_Is_api_valid( the_api ) )
return OBJECTS_INVALID_ID;
if ( !_Objects_Information_table[ the_api ] )
200e52c: 05 00 80 c1 sethi %hi(0x2030400), %g2
200e530: 84 10 a0 d0 or %g2, 0xd0, %g2 ! 20304d0 <_Objects_Information_table>
200e534: c2 00 80 01 ld [ %g2 + %g1 ], %g1
200e538: 80 a0 60 00 cmp %g1, 0
200e53c: 02 80 00 12 be 200e584 <_Objects_Id_to_name+0x8c>
200e540: 85 32 60 1b srl %o1, 0x1b, %g2
return OBJECTS_INVALID_ID;
the_class = _Objects_Get_class( tmpId );
information = _Objects_Information_table[ the_api ][ the_class ];
200e544: 85 28 a0 02 sll %g2, 2, %g2
200e548: d0 00 40 02 ld [ %g1 + %g2 ], %o0
if ( !information )
200e54c: 80 a2 20 00 cmp %o0, 0
200e550: 02 80 00 0d be 200e584 <_Objects_Id_to_name+0x8c> <== NEVER TAKEN
200e554: 01 00 00 00 nop
#if defined(RTEMS_SCORE_OBJECT_ENABLE_STRING_NAMES)
if ( information->is_string )
return OBJECTS_INVALID_ID;
#endif
the_object = _Objects_Get( information, tmpId, &ignored_location );
200e558: 7f ff ff cb call 200e484 <_Objects_Get>
200e55c: 94 07 bf fc add %fp, -4, %o2
if ( !the_object )
200e560: 80 a2 20 00 cmp %o0, 0
200e564: 02 80 00 08 be 200e584 <_Objects_Id_to_name+0x8c>
200e568: 01 00 00 00 nop
return OBJECTS_INVALID_ID;
*name = the_object->name;
200e56c: c2 02 20 0c ld [ %o0 + 0xc ], %g1
_Thread_Enable_dispatch();
200e570: b0 10 20 00 clr %i0
200e574: 40 00 02 89 call 200ef98 <_Thread_Enable_dispatch>
200e578: c2 26 40 00 st %g1, [ %i1 ]
return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL;
200e57c: 81 c7 e0 08 ret
200e580: 81 e8 00 00 restore
}
200e584: 81 c7 e0 08 ret
200e588: 91 e8 20 03 restore %g0, 3, %o0
020082ec <_Objects_Initialize_information>:
,
bool supports_global,
Objects_Thread_queue_Extract_callout extract
#endif
)
{
20082ec: 9d e3 bf a0 save %sp, -96, %sp
information->maximum = 0;
/*
* Register this Object Class in the Object Information Table.
*/
_Objects_Information_table[ the_api ][ the_class ] = information;
20082f0: 05 00 80 76 sethi %hi(0x201d800), %g2
20082f4: 83 2e 60 02 sll %i1, 2, %g1
20082f8: 84 10 a3 10 or %g2, 0x310, %g2
20082fc: c2 00 80 01 ld [ %g2 + %g1 ], %g1
uint32_t index;
#endif
information->the_api = the_api;
information->the_class = the_class;
information->size = size;
2008300: 85 2f 20 10 sll %i4, 0x10, %g2
2008304: 85 30 a0 10 srl %g2, 0x10, %g2
information->maximum = 0;
/*
* Register this Object Class in the Object Information Table.
*/
_Objects_Information_table[ the_api ][ the_class ] = information;
2008308: 87 2e a0 02 sll %i2, 2, %g3
uint32_t index;
#endif
information->the_api = the_api;
information->the_class = the_class;
information->size = size;
200830c: c4 26 20 18 st %g2, [ %i0 + 0x18 ]
information->maximum = 0;
/*
* Register this Object Class in the Object Information Table.
*/
_Objects_Information_table[ the_api ][ the_class ] = information;
2008310: f0 20 40 03 st %i0, [ %g1 + %g3 ]
/*
* Are we operating in limited or unlimited (e.g. auto-extend) mode.
*/
information->auto_extend =
(maximum & OBJECTS_UNLIMITED_OBJECTS) ? true : false;
2008314: 85 36 e0 1f srl %i3, 0x1f, %g2
maximum_per_allocation = maximum & ~OBJECTS_UNLIMITED_OBJECTS;
2008318: 03 20 00 00 sethi %hi(0x80000000), %g1
uint32_t maximum_per_allocation;
#if defined(RTEMS_MULTIPROCESSING)
uint32_t index;
#endif
information->the_api = the_api;
200831c: f2 26 00 00 st %i1, [ %i0 ]
information->the_class = the_class;
2008320: f4 36 20 04 sth %i2, [ %i0 + 4 ]
information->size = size;
information->local_table = 0;
2008324: c0 26 20 1c clr [ %i0 + 0x1c ]
information->inactive_per_block = 0;
2008328: c0 26 20 30 clr [ %i0 + 0x30 ]
information->object_blocks = 0;
200832c: c0 26 20 34 clr [ %i0 + 0x34 ]
information->inactive = 0;
2008330: c0 36 20 2c clrh [ %i0 + 0x2c ]
/*
* Set the maximum value to 0. It will be updated when objects are
* added to the inactive set from _Objects_Extend_information()
*/
information->maximum = 0;
2008334: c0 36 20 10 clrh [ %i0 + 0x10 ]
_Objects_Information_table[ the_api ][ the_class ] = information;
/*
* Are we operating in limited or unlimited (e.g. auto-extend) mode.
*/
information->auto_extend =
2008338: c4 2e 20 12 stb %g2, [ %i0 + 0x12 ]
(maximum & OBJECTS_UNLIMITED_OBJECTS) ? true : false;
maximum_per_allocation = maximum & ~OBJECTS_UNLIMITED_OBJECTS;
200833c: b6 2e c0 01 andn %i3, %g1, %i3
/*
* Unlimited and maximum of zero is illogical.
*/
if ( information->auto_extend && maximum_per_allocation == 0) {
2008340: 80 a0 a0 00 cmp %g2, 0
2008344: 02 80 00 05 be 2008358 <_Objects_Initialize_information+0x6c>
2008348: c2 07 a0 5c ld [ %fp + 0x5c ], %g1
200834c: 80 a6 e0 00 cmp %i3, 0
2008350: 02 80 00 28 be 20083f0 <_Objects_Initialize_information+0x104>
2008354: 90 10 20 00 clr %o0
information->allocation_size = maximum_per_allocation;
/*
* Provide a null local table entry for the case of any empty table.
*/
information->local_table = &null_local_table;
2008358: 07 00 80 76 sethi %hi(0x201d800), %g3
200835c: 86 10 e0 58 or %g3, 0x58, %g3 ! 201d858 <null_local_table.3567>
/*
* Calculate minimum and maximum Id's
*/
minimum_index = (maximum_per_allocation == 0) ? 0 : 1;
information->minimum_id =
2008360: 80 a0 00 1b cmp %g0, %i3
2008364: b3 2e 60 18 sll %i1, 0x18, %i1
2008368: 84 40 20 00 addx %g0, 0, %g2
200836c: b5 2e a0 1b sll %i2, 0x1b, %i2
information->allocation_size = maximum_per_allocation;
/*
* Provide a null local table entry for the case of any empty table.
*/
information->local_table = &null_local_table;
2008370: c6 26 20 1c st %g3, [ %i0 + 0x1c ]
}
/*
* The allocation unit is the maximum value
*/
information->allocation_size = maximum_per_allocation;
2008374: f6 36 20 14 sth %i3, [ %i0 + 0x14 ]
/*
* Calculate minimum and maximum Id's
*/
minimum_index = (maximum_per_allocation == 0) ? 0 : 1;
information->minimum_id =
2008378: 07 00 00 40 sethi %hi(0x10000), %g3
200837c: b2 16 40 03 or %i1, %g3, %i1
2008380: b4 16 40 1a or %i1, %i2, %i2
2008384: b4 16 80 02 or %i2, %g2, %i2
2008388: f4 26 20 08 st %i2, [ %i0 + 8 ]
* Calculate the maximum name length
*/
name_length = maximum_name_length;
if ( name_length & (OBJECTS_NAME_ALIGNMENT-1) )
name_length = (name_length + OBJECTS_NAME_ALIGNMENT) &
200838c: 84 00 60 04 add %g1, 4, %g2
/*
* Calculate the maximum name length
*/
name_length = maximum_name_length;
if ( name_length & (OBJECTS_NAME_ALIGNMENT-1) )
2008390: 80 88 60 03 btst 3, %g1
2008394: 02 80 00 0c be 20083c4 <_Objects_Initialize_information+0xd8><== ALWAYS TAKEN
2008398: 84 08 bf fc and %g2, -4, %g2
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200839c: 82 06 20 24 add %i0, 0x24, %g1 <== NOT EXECUTED
name_length = (name_length + OBJECTS_NAME_ALIGNMENT) &
~(OBJECTS_NAME_ALIGNMENT-1);
information->name_length = name_length;
20083a0: c4 36 20 38 sth %g2, [ %i0 + 0x38 ] <== NOT EXECUTED
20083a4: c2 26 20 20 st %g1, [ %i0 + 0x20 ] <== NOT EXECUTED
the_chain->permanent_null = NULL;
20083a8: c0 26 20 24 clr [ %i0 + 0x24 ] <== NOT EXECUTED
the_chain->last = _Chain_Head(the_chain);
20083ac: 82 06 20 20 add %i0, 0x20, %g1 <== NOT EXECUTED
_Chain_Initialize_empty( &information->Inactive );
/*
* Initialize objects .. if there are any
*/
if ( maximum_per_allocation ) {
20083b0: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
20083b4: 12 80 00 0d bne 20083e8 <_Objects_Initialize_information+0xfc><== NOT EXECUTED
20083b8: c2 26 20 28 st %g1, [ %i0 + 0x28 ] <== NOT EXECUTED
20083bc: 81 c7 e0 08 ret
20083c0: 81 e8 00 00 restore
/*
* Calculate the maximum name length
*/
name_length = maximum_name_length;
if ( name_length & (OBJECTS_NAME_ALIGNMENT-1) )
20083c4: 84 10 00 01 mov %g1, %g2
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
20083c8: 82 06 20 24 add %i0, 0x24, %g1
name_length = (name_length + OBJECTS_NAME_ALIGNMENT) &
~(OBJECTS_NAME_ALIGNMENT-1);
information->name_length = name_length;
20083cc: c4 36 20 38 sth %g2, [ %i0 + 0x38 ]
20083d0: c2 26 20 20 st %g1, [ %i0 + 0x20 ]
the_chain->permanent_null = NULL;
20083d4: c0 26 20 24 clr [ %i0 + 0x24 ]
the_chain->last = _Chain_Head(the_chain);
20083d8: 82 06 20 20 add %i0, 0x20, %g1
_Chain_Initialize_empty( &information->Inactive );
/*
* Initialize objects .. if there are any
*/
if ( maximum_per_allocation ) {
20083dc: 80 a6 e0 00 cmp %i3, 0
20083e0: 02 bf ff f7 be 20083bc <_Objects_Initialize_information+0xd0>
20083e4: c2 26 20 28 st %g1, [ %i0 + 0x28 ]
/*
* Always have the maximum size available so the current performance
* figures are create are met. If the user moves past the maximum
* number then a performance hit is taken.
*/
_Objects_Extend_information( information );
20083e8: 7f ff fe 80 call 2007de8 <_Objects_Extend_information>
20083ec: 81 e8 00 00 restore
/*
* Unlimited and maximum of zero is illogical.
*/
if ( information->auto_extend && maximum_per_allocation == 0) {
_Internal_error_Occurred(
20083f0: 92 10 20 01 mov 1, %o1
20083f4: 7f ff fe 1e call 2007c6c <_Internal_error_Occurred>
20083f8: 94 10 20 14 mov 0x14, %o2
020084c0 <_Objects_Shrink_information>:
*/
void _Objects_Shrink_information(
Objects_Information *information
)
{
20084c0: 9d e3 bf a0 save %sp, -96, %sp
/*
* Search the list to find block or chunk with all objects inactive.
*/
index_base = _Objects_Get_index( information->minimum_id );
20084c4: e0 16 20 0a lduh [ %i0 + 0xa ], %l0
block_count = (information->maximum - index_base) /
20084c8: e2 16 20 14 lduh [ %i0 + 0x14 ], %l1
20084cc: d0 16 20 10 lduh [ %i0 + 0x10 ], %o0
20084d0: 92 10 00 11 mov %l1, %o1
20084d4: 40 00 45 32 call 201999c <.udiv>
20084d8: 90 22 00 10 sub %o0, %l0, %o0
information->allocation_size;
for ( block = 0; block < block_count; block++ ) {
20084dc: 80 a2 20 00 cmp %o0, 0
20084e0: 02 80 00 12 be 2008528 <_Objects_Shrink_information+0x68> <== NEVER TAKEN
20084e4: a4 10 20 04 mov 4, %l2
if ( information->inactive_per_block[ block ] ==
20084e8: c6 06 20 30 ld [ %i0 + 0x30 ], %g3
20084ec: c4 00 c0 00 ld [ %g3 ], %g2
20084f0: 80 a4 40 02 cmp %l1, %g2
20084f4: 12 80 00 09 bne 2008518 <_Objects_Shrink_information+0x58><== ALWAYS TAKEN
20084f8: 82 10 20 00 clr %g1
20084fc: 10 80 00 0d b 2008530 <_Objects_Shrink_information+0x70> <== NOT EXECUTED
2008500: a4 10 20 00 clr %l2 <== NOT EXECUTED
information->inactive -= information->allocation_size;
return;
}
index_base += information->allocation_size;
2008504: a0 04 00 11 add %l0, %l1, %l0
index_base = _Objects_Get_index( information->minimum_id );
block_count = (information->maximum - index_base) /
information->allocation_size;
for ( block = 0; block < block_count; block++ ) {
if ( information->inactive_per_block[ block ] ==
2008508: 80 a4 40 02 cmp %l1, %g2
200850c: 02 80 00 09 be 2008530 <_Objects_Shrink_information+0x70>
2008510: 84 04 a0 04 add %l2, 4, %g2
2008514: a4 10 00 02 mov %g2, %l2
index_base = _Objects_Get_index( information->minimum_id );
block_count = (information->maximum - index_base) /
information->allocation_size;
for ( block = 0; block < block_count; block++ ) {
2008518: 82 00 60 01 inc %g1
200851c: 80 a2 00 01 cmp %o0, %g1
2008520: 38 bf ff f9 bgu,a 2008504 <_Objects_Shrink_information+0x44>
2008524: c4 00 c0 12 ld [ %g3 + %l2 ], %g2
2008528: 81 c7 e0 08 ret
200852c: 81 e8 00 00 restore
information->allocation_size ) {
/*
* Assume the Inactive chain is never empty at this point
*/
the_object = (Objects_Control *) information->Inactive.first;
2008530: 10 80 00 06 b 2008548 <_Objects_Shrink_information+0x88>
2008534: d0 06 20 20 ld [ %i0 + 0x20 ], %o0
if ((index >= index_base) &&
(index < (index_base + information->allocation_size))) {
_Chain_Extract( &extract_me->Node );
}
}
while ( the_object );
2008538: 80 a4 60 00 cmp %l1, 0
200853c: 22 80 00 12 be,a 2008584 <_Objects_Shrink_information+0xc4>
2008540: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
2008544: 90 10 00 11 mov %l1, %o0
* Assume the Inactive chain is never empty at this point
*/
the_object = (Objects_Control *) information->Inactive.first;
do {
index = _Objects_Get_index( the_object->id );
2008548: c2 12 20 0a lduh [ %o0 + 0xa ], %g1
/*
* Get the next node before the node is extracted
*/
extract_me = the_object;
the_object = (Objects_Control *) the_object->Node.next;
if ((index >= index_base) &&
200854c: 80 a0 40 10 cmp %g1, %l0
2008550: 0a bf ff fa bcs 2008538 <_Objects_Shrink_information+0x78>
2008554: e2 02 00 00 ld [ %o0 ], %l1
(index < (index_base + information->allocation_size))) {
2008558: c4 16 20 14 lduh [ %i0 + 0x14 ], %g2
200855c: 84 04 00 02 add %l0, %g2, %g2
2008560: 80 a0 40 02 cmp %g1, %g2
2008564: 1a bf ff f6 bcc 200853c <_Objects_Shrink_information+0x7c>
2008568: 80 a4 60 00 cmp %l1, 0
_Chain_Extract( &extract_me->Node );
200856c: 7f ff fb 59 call 20072d0 <_Chain_Extract>
2008570: 01 00 00 00 nop
}
}
while ( the_object );
2008574: 80 a4 60 00 cmp %l1, 0
2008578: 12 bf ff f4 bne 2008548 <_Objects_Shrink_information+0x88><== ALWAYS TAKEN
200857c: 90 10 00 11 mov %l1, %o0
/*
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
2008580: c2 06 20 34 ld [ %i0 + 0x34 ], %g1 <== NOT EXECUTED
2008584: 40 00 07 4e call 200a2bc <_Workspace_Free>
2008588: d0 00 40 12 ld [ %g1 + %l2 ], %o0
information->object_blocks[ block ] = NULL;
information->inactive_per_block[ block ] = 0;
information->inactive -= information->allocation_size;
200858c: c6 16 20 2c lduh [ %i0 + 0x2c ], %g3
/*
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
information->object_blocks[ block ] = NULL;
2008590: c2 06 20 34 ld [ %i0 + 0x34 ], %g1
information->inactive_per_block[ block ] = 0;
2008594: c8 06 20 30 ld [ %i0 + 0x30 ], %g4
information->inactive -= information->allocation_size;
2008598: c4 16 20 14 lduh [ %i0 + 0x14 ], %g2
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
information->object_blocks[ block ] = NULL;
information->inactive_per_block[ block ] = 0;
200859c: c0 21 00 12 clr [ %g4 + %l2 ]
information->inactive -= information->allocation_size;
20085a0: 84 20 c0 02 sub %g3, %g2, %g2
/*
* Free the memory and reset the structures in the object' information
*/
_Workspace_Free( information->object_blocks[ block ] );
information->object_blocks[ block ] = NULL;
20085a4: c0 20 40 12 clr [ %g1 + %l2 ]
information->inactive_per_block[ block ] = 0;
information->inactive -= information->allocation_size;
20085a8: c4 36 20 2c sth %g2, [ %i0 + 0x2c ]
return;
20085ac: 81 c7 e0 08 ret
20085b0: 81 e8 00 00 restore
020012c8 <_Partition_Manager_initialization>:
#include <rtems/score/thread.h>
#include <rtems/score/interr.h>
void _Partition_Manager_initialization(void)
{
}
20012c8: 81 c3 e0 08 retl
02006ca8 <_RTEMS_tasks_Initialize_user_tasks_body>:
*
* Output parameters: NONE
*/
void _RTEMS_tasks_Initialize_user_tasks_body( void )
{
2006ca8: 9d e3 bf 98 save %sp, -104, %sp
rtems_initialization_tasks_table *user_tasks;
/*
* Move information into local variables
*/
user_tasks = Configuration_RTEMS_API.User_initialization_tasks_table;
2006cac: 03 00 80 74 sethi %hi(0x201d000), %g1
2006cb0: 82 10 60 c0 or %g1, 0xc0, %g1 ! 201d0c0 <Configuration_RTEMS_API>
2006cb4: e0 00 60 2c ld [ %g1 + 0x2c ], %l0
maximum = Configuration_RTEMS_API.number_of_initialization_tasks;
/*
* Verify that we have a set of user tasks to iterate
*/
if ( !user_tasks )
2006cb8: 80 a4 20 00 cmp %l0, 0
2006cbc: 02 80 00 1a be 2006d24 <_RTEMS_tasks_Initialize_user_tasks_body+0x7c>
2006cc0: e4 00 60 28 ld [ %g1 + 0x28 ], %l2
return;
/*
* Now iterate over the initialization tasks and create/start them.
*/
for ( index=0 ; index < maximum ; index++ ) {
2006cc4: 80 a4 a0 00 cmp %l2, 0
2006cc8: 02 80 00 17 be 2006d24 <_RTEMS_tasks_Initialize_user_tasks_body+0x7c><== NEVER TAKEN
2006ccc: a2 10 20 00 clr %l1
2006cd0: a6 07 bf fc add %fp, -4, %l3
return_value = rtems_task_create(
2006cd4: d0 04 00 00 ld [ %l0 ], %o0
2006cd8: d2 04 20 08 ld [ %l0 + 8 ], %o1
2006cdc: d4 04 20 04 ld [ %l0 + 4 ], %o2
2006ce0: d6 04 20 14 ld [ %l0 + 0x14 ], %o3
2006ce4: d8 04 20 0c ld [ %l0 + 0xc ], %o4
2006ce8: 7f ff ff 6e call 2006aa0 <rtems_task_create>
2006cec: 9a 10 00 13 mov %l3, %o5
user_tasks[ index ].stack_size,
user_tasks[ index ].mode_set,
user_tasks[ index ].attribute_set,
&id
);
if ( !rtems_is_status_successful( return_value ) )
2006cf0: 80 a2 20 00 cmp %o0, 0
2006cf4: 12 80 00 0f bne 2006d30 <_RTEMS_tasks_Initialize_user_tasks_body+0x88>
2006cf8: 94 10 00 08 mov %o0, %o2
_Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, true, return_value );
return_value = rtems_task_start(
2006cfc: d0 07 bf fc ld [ %fp + -4 ], %o0
2006d00: d2 04 20 10 ld [ %l0 + 0x10 ], %o1
2006d04: 40 00 00 0f call 2006d40 <rtems_task_start>
2006d08: d4 04 20 18 ld [ %l0 + 0x18 ], %o2
id,
user_tasks[ index ].entry_point,
user_tasks[ index ].argument
);
if ( !rtems_is_status_successful( return_value ) )
2006d0c: 80 a2 20 00 cmp %o0, 0
2006d10: 12 80 00 07 bne 2006d2c <_RTEMS_tasks_Initialize_user_tasks_body+0x84>
2006d14: a2 04 60 01 inc %l1
return;
/*
* Now iterate over the initialization tasks and create/start them.
*/
for ( index=0 ; index < maximum ; index++ ) {
2006d18: 80 a4 80 11 cmp %l2, %l1
2006d1c: 18 bf ff ee bgu 2006cd4 <_RTEMS_tasks_Initialize_user_tasks_body+0x2c><== NEVER TAKEN
2006d20: a0 04 20 1c add %l0, 0x1c, %l0
2006d24: 81 c7 e0 08 ret
2006d28: 81 e8 00 00 restore
id,
user_tasks[ index ].entry_point,
user_tasks[ index ].argument
);
if ( !rtems_is_status_successful( return_value ) )
_Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, true, return_value );
2006d2c: 94 10 00 08 mov %o0, %o2
2006d30: 92 10 20 01 mov 1, %o1
2006d34: 40 00 03 ce call 2007c6c <_Internal_error_Occurred>
2006d38: 90 10 20 01 mov 1, %o0
0200d3fc <_RTEMS_tasks_Post_switch_extension>:
*/
void _RTEMS_tasks_Post_switch_extension(
Thread_Control *executing
)
{
200d3fc: 9d e3 bf 98 save %sp, -104, %sp
RTEMS_API_Control *api;
ASR_Information *asr;
rtems_signal_set signal_set;
Modes_Control prev_mode;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
200d400: e0 06 21 60 ld [ %i0 + 0x160 ], %l0
if ( !api )
200d404: 80 a4 20 00 cmp %l0, 0
200d408: 02 80 00 1f be 200d484 <_RTEMS_tasks_Post_switch_extension+0x88><== NEVER TAKEN
200d40c: 01 00 00 00 nop
* Signal Processing
*/
asr = &api->Signal;
_ISR_Disable( level );
200d410: 7f ff d3 25 call 20020a4 <sparc_disable_interrupts>
200d414: 01 00 00 00 nop
signal_set = asr->signals_posted;
200d418: e2 04 20 14 ld [ %l0 + 0x14 ], %l1
asr->signals_posted = 0;
200d41c: c0 24 20 14 clr [ %l0 + 0x14 ]
_ISR_Enable( level );
200d420: 7f ff d3 25 call 20020b4 <sparc_enable_interrupts>
200d424: 01 00 00 00 nop
if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */
200d428: 80 a4 60 00 cmp %l1, 0
200d42c: 32 80 00 04 bne,a 200d43c <_RTEMS_tasks_Post_switch_extension+0x40><== ALWAYS TAKEN
200d430: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200d434: 81 c7 e0 08 ret <== NOT EXECUTED
200d438: 81 e8 00 00 restore <== NOT EXECUTED
return;
asr->nest_level += 1;
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
200d43c: d0 04 20 10 ld [ %l0 + 0x10 ], %o0
if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */
return;
asr->nest_level += 1;
200d440: 82 00 60 01 inc %g1
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
200d444: a4 07 bf fc add %fp, -4, %l2
if ( !signal_set ) /* similar to _ASR_Are_signals_pending( asr ) */
return;
asr->nest_level += 1;
200d448: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
200d44c: 94 10 00 12 mov %l2, %o2
200d450: 27 00 00 3f sethi %hi(0xfc00), %l3
200d454: 40 00 0a 6b call 200fe00 <rtems_task_mode>
200d458: 92 14 e3 ff or %l3, 0x3ff, %o1 ! ffff <PROM_START+0xffff>
(*asr->handler)( signal_set );
200d45c: c2 04 20 0c ld [ %l0 + 0xc ], %g1
200d460: 9f c0 40 00 call %g1
200d464: 90 10 00 11 mov %l1, %o0
asr->nest_level -= 1;
200d468: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );
200d46c: d0 07 bf fc ld [ %fp + -4 ], %o0
asr->nest_level += 1;
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
(*asr->handler)( signal_set );
asr->nest_level -= 1;
200d470: 82 00 7f ff add %g1, -1, %g1
rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );
200d474: 92 14 e3 ff or %l3, 0x3ff, %o1
asr->nest_level += 1;
rtems_task_mode( asr->mode_set, RTEMS_ALL_MODE_MASKS, &prev_mode );
(*asr->handler)( signal_set );
asr->nest_level -= 1;
200d478: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
rtems_task_mode( prev_mode, RTEMS_ALL_MODE_MASKS, &prev_mode );
200d47c: 40 00 0a 61 call 200fe00 <rtems_task_mode>
200d480: 94 10 00 12 mov %l2, %o2
200d484: 81 c7 e0 08 ret
200d488: 81 e8 00 00 restore
0200d320 <_RTEMS_tasks_Switch_extension>:
/*
* Per Task Variables
*/
tvp = executing->task_variables;
200d320: c2 02 21 70 ld [ %o0 + 0x170 ], %g1
while (tvp) {
200d324: 80 a0 60 00 cmp %g1, 0
200d328: 22 80 00 0b be,a 200d354 <_RTEMS_tasks_Switch_extension+0x34>
200d32c: c2 02 61 70 ld [ %o1 + 0x170 ], %g1
tvp->tval = *tvp->ptr;
200d330: c4 00 60 04 ld [ %g1 + 4 ], %g2
*tvp->ptr = tvp->gval;
200d334: c6 00 60 08 ld [ %g1 + 8 ], %g3
* Per Task Variables
*/
tvp = executing->task_variables;
while (tvp) {
tvp->tval = *tvp->ptr;
200d338: c8 00 80 00 ld [ %g2 ], %g4
200d33c: c8 20 60 0c st %g4, [ %g1 + 0xc ]
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
200d340: c2 00 40 00 ld [ %g1 ], %g1
/*
* Per Task Variables
*/
tvp = executing->task_variables;
while (tvp) {
200d344: 80 a0 60 00 cmp %g1, 0
200d348: 12 bf ff fa bne 200d330 <_RTEMS_tasks_Switch_extension+0x10><== NEVER TAKEN
200d34c: c6 20 80 00 st %g3, [ %g2 ]
tvp->tval = *tvp->ptr;
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
200d350: c2 02 61 70 ld [ %o1 + 0x170 ], %g1
while (tvp) {
200d354: 80 a0 60 00 cmp %g1, 0
200d358: 02 80 00 0a be 200d380 <_RTEMS_tasks_Switch_extension+0x60>
200d35c: 01 00 00 00 nop
tvp->gval = *tvp->ptr;
200d360: c4 00 60 04 ld [ %g1 + 4 ], %g2
*tvp->ptr = tvp->tval;
200d364: c6 00 60 0c ld [ %g1 + 0xc ], %g3
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
while (tvp) {
tvp->gval = *tvp->ptr;
200d368: c8 00 80 00 ld [ %g2 ], %g4
200d36c: c8 20 60 08 st %g4, [ %g1 + 8 ]
*tvp->ptr = tvp->tval;
tvp = (rtems_task_variable_t *)tvp->next;
200d370: c2 00 40 00 ld [ %g1 ], %g1
*tvp->ptr = tvp->gval;
tvp = (rtems_task_variable_t *)tvp->next;
}
tvp = heir->task_variables;
while (tvp) {
200d374: 80 a0 60 00 cmp %g1, 0
200d378: 12 bf ff fa bne 200d360 <_RTEMS_tasks_Switch_extension+0x40><== NEVER TAKEN
200d37c: c6 20 80 00 st %g3, [ %g2 ]
200d380: 81 c3 e0 08 retl
020012e8 <_Rate_monotonic_Manager_initialization>:
#include <rtems/rtems/types.h>
#include <rtems/rtems/ratemon.h>
void _Rate_monotonic_Manager_initialization(void)
{
}
20012e8: 81 c3 e0 08 retl
02045a4c <_Rate_monotonic_Timeout>:
void _Rate_monotonic_Timeout(
Objects_Id id,
void *ignored
)
{
2045a4c: 9d e3 bf 98 save %sp, -104, %sp
2045a50: 11 00 81 cd sethi %hi(0x2073400), %o0
2045a54: 92 10 00 18 mov %i0, %o1
2045a58: 90 12 23 30 or %o0, 0x330, %o0
2045a5c: 7f ff 26 99 call 200f4c0 <_Objects_Get>
2045a60: 94 07 bf fc add %fp, -4, %o2
/*
* When we get here, the Timer is already off the chain so we do not
* have to worry about that -- hence no _Watchdog_Remove().
*/
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
2045a64: c2 07 bf fc ld [ %fp + -4 ], %g1
2045a68: 80 a0 60 00 cmp %g1, 0
2045a6c: 12 80 00 16 bne 2045ac4 <_Rate_monotonic_Timeout+0x78> <== NEVER TAKEN
2045a70: a0 10 00 08 mov %o0, %l0
case OBJECTS_LOCAL:
the_thread = the_period->owner;
2045a74: d0 02 20 40 ld [ %o0 + 0x40 ], %o0
if ( _States_Is_waiting_for_period( the_thread->current_state ) &&
2045a78: 03 00 00 10 sethi %hi(0x4000), %g1
2045a7c: c4 02 20 10 ld [ %o0 + 0x10 ], %g2
2045a80: 80 88 80 01 btst %g2, %g1
2045a84: 22 80 00 08 be,a 2045aa4 <_Rate_monotonic_Timeout+0x58>
2045a88: c2 04 20 38 ld [ %l0 + 0x38 ], %g1
the_thread->Wait.id == the_period->Object.id ) {
2045a8c: c4 02 20 20 ld [ %o0 + 0x20 ], %g2
2045a90: c2 04 20 08 ld [ %l0 + 8 ], %g1
2045a94: 80 a0 80 01 cmp %g2, %g1
2045a98: 02 80 00 19 be 2045afc <_Rate_monotonic_Timeout+0xb0>
2045a9c: 13 04 00 ff sethi %hi(0x1003fc00), %o1
_Thread_Unblock( the_thread );
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
2045aa0: c2 04 20 38 ld [ %l0 + 0x38 ], %g1
2045aa4: 80 a0 60 01 cmp %g1, 1
2045aa8: 02 80 00 09 be 2045acc <_Rate_monotonic_Timeout+0x80>
2045aac: 82 10 20 04 mov 4, %g1
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else
the_period->state = RATE_MONOTONIC_EXPIRED;
2045ab0: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
2045ab4: 03 00 81 cc sethi %hi(0x2073000), %g1
2045ab8: c4 00 62 b0 ld [ %g1 + 0x2b0 ], %g2 ! 20732b0 <_Thread_Dispatch_disable_level>
2045abc: 84 00 bf ff add %g2, -1, %g2
2045ac0: c4 20 62 b0 st %g2, [ %g1 + 0x2b0 ]
2045ac4: 81 c7 e0 08 ret
2045ac8: 81 e8 00 00 restore
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING;
2045acc: 82 10 20 03 mov 3, %g1
_Rate_monotonic_Initiate_statistics( the_period );
2045ad0: 90 10 00 10 mov %l0, %o0
_Rate_monotonic_Initiate_statistics( the_period );
_Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length );
} else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) {
the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING;
2045ad4: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
_Rate_monotonic_Initiate_statistics( the_period );
2045ad8: 7f ff fe e5 call 204566c <_Rate_monotonic_Initiate_statistics>
2045adc: 01 00 00 00 nop
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2045ae0: c2 04 20 3c ld [ %l0 + 0x3c ], %g1
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2045ae4: 92 04 20 10 add %l0, 0x10, %o1
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2045ae8: c2 24 20 1c st %g1, [ %l0 + 0x1c ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2045aec: 11 00 81 cc sethi %hi(0x2073000), %o0
2045af0: 7f ff 2d b6 call 20111c8 <_Watchdog_Insert>
2045af4: 90 12 23 90 or %o0, 0x390, %o0 ! 2073390 <_Watchdog_Ticks_chain>
2045af8: 30 bf ff ef b,a 2045ab4 <_Rate_monotonic_Timeout+0x68>
RTEMS_INLINE_ROUTINE void _Thread_Unblock (
Thread_Control *the_thread
)
{
_Thread_Clear_state( the_thread, STATES_BLOCKED );
2045afc: 7f ff 27 f3 call 200fac8 <_Thread_Clear_state>
2045b00: 92 12 63 f8 or %o1, 0x3f8, %o1
the_thread = the_period->owner;
if ( _States_Is_waiting_for_period( the_thread->current_state ) &&
the_thread->Wait.id == the_period->Object.id ) {
_Thread_Unblock( the_thread );
_Rate_monotonic_Initiate_statistics( the_period );
2045b04: 10 bf ff f5 b 2045ad8 <_Rate_monotonic_Timeout+0x8c>
2045b08: 90 10 00 10 mov %l0, %o0
020012d0 <_Region_Manager_initialization>:
#include <rtems/score/thread.h>
#include <rtems/score/interr.h>
void _Region_Manager_initialization(void)
{
}
20012d0: 81 c3 e0 08 retl
0200782c <_TOD_Tickle_ticks>:
*
* Output parameters: NONE
*/
void _TOD_Tickle_ticks( void )
{
200782c: 9d e3 bf 98 save %sp, -104, %sp
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
2007830: 05 00 80 77 sethi %hi(0x201dc00), %g2
2007834: c6 00 a1 04 ld [ %g2 + 0x104 ], %g3 ! 201dd04 <_Watchdog_Ticks_since_boot>
{
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
2007838: 03 00 80 74 sethi %hi(0x201d000), %g1
200783c: c2 00 61 04 ld [ %g1 + 0x104 ], %g1 ! 201d104 <Configuration+0xc>
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
2007840: 86 00 e0 01 inc %g3
2007844: c6 20 a1 04 st %g3, [ %g2 + 0x104 ]
{
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
2007848: 87 28 60 07 sll %g1, 7, %g3
200784c: 85 28 60 02 sll %g1, 2, %g2
2007850: 84 20 c0 02 sub %g3, %g2, %g2
2007854: 82 00 80 01 add %g2, %g1, %g1
2007858: 83 28 60 03 sll %g1, 3, %g1
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
/* Update the timespec format uptime */
_Timestamp_Add_to( &_TOD_Uptime, &tick );
200785c: a0 07 bf f8 add %fp, -8, %l0
{
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
2007860: c2 27 bf fc st %g1, [ %fp + -4 ]
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
/* Update the timespec format uptime */
_Timestamp_Add_to( &_TOD_Uptime, &tick );
2007864: 92 10 00 10 mov %l0, %o1
{
Timestamp_Control tick;
uint32_t seconds;
/* Convert the tick quantum to a timestamp */
_Timestamp_Set( &tick, 0, rtems_configuration_get_nanoseconds_per_tick() );
2007868: c0 27 bf f8 clr [ %fp + -8 ]
/* Update the counter of ticks since boot */
_Watchdog_Ticks_since_boot += 1;
/* Update the timespec format uptime */
_Timestamp_Add_to( &_TOD_Uptime, &tick );
200786c: 11 00 80 77 sethi %hi(0x201dc00), %o0
2007870: 40 00 08 c5 call 2009b84 <_Timespec_Add_to>
2007874: 90 12 20 30 or %o0, 0x30, %o0 ! 201dc30 <_TOD_Uptime>
/* we do not care how much the uptime changed */
/* Update the timespec format TOD */
seconds = _Timestamp_Add_to_at_tick( &_TOD_Now, &tick );
2007878: 92 10 00 10 mov %l0, %o1
200787c: 11 00 80 77 sethi %hi(0x201dc00), %o0
2007880: 40 00 08 c1 call 2009b84 <_Timespec_Add_to>
2007884: 90 12 20 44 or %o0, 0x44, %o0 ! 201dc44 <_TOD_Now>
while ( seconds ) {
2007888: a0 92 20 00 orcc %o0, 0, %l0
200788c: 02 80 00 08 be 20078ac <_TOD_Tickle_ticks+0x80>
2007890: 23 00 80 77 sethi %hi(0x201dc00), %l1
*/
RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_seconds( void )
{
_Watchdog_Tickle( &_Watchdog_Seconds_chain );
2007894: a2 14 60 84 or %l1, 0x84, %l1 ! 201dc84 <_Watchdog_Seconds_chain>
2007898: 40 00 0a 47 call 200a1b4 <_Watchdog_Tickle>
200789c: 90 10 00 11 mov %l1, %o0
20078a0: a0 84 3f ff addcc %l0, -1, %l0
20078a4: 12 bf ff fd bne 2007898 <_TOD_Tickle_ticks+0x6c> <== NEVER TAKEN
20078a8: 01 00 00 00 nop
20078ac: 81 c7 e0 08 ret
20078b0: 81 e8 00 00 restore
02007958 <_TOD_Validate>:
*/
bool _TOD_Validate(
const rtems_time_of_day *the_tod
)
{
2007958: 9d e3 bf a0 save %sp, -96, %sp
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
200795c: 03 00 80 8e sethi %hi(0x2023800), %g1
if ((!the_tod) ||
2007960: 80 a6 20 00 cmp %i0, 0
2007964: 02 80 00 2e be 2007a1c <_TOD_Validate+0xc4> <== NEVER TAKEN
2007968: d2 00 60 f4 ld [ %g1 + 0xf4 ], %o1
200796c: 11 00 03 d0 sethi %hi(0xf4000), %o0
2007970: 40 00 5d 3f call 201ee6c <.udiv>
2007974: 90 12 22 40 or %o0, 0x240, %o0 ! f4240 <PROM_START+0xf4240>
(the_tod->ticks >= ticks_per_second) ||
2007978: c2 06 20 18 ld [ %i0 + 0x18 ], %g1
200797c: 80 a2 00 01 cmp %o0, %g1
2007980: 08 80 00 27 bleu 2007a1c <_TOD_Validate+0xc4>
2007984: 01 00 00 00 nop
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
2007988: c2 06 20 14 ld [ %i0 + 0x14 ], %g1
200798c: 80 a0 60 3b cmp %g1, 0x3b
2007990: 18 80 00 23 bgu 2007a1c <_TOD_Validate+0xc4>
2007994: 01 00 00 00 nop
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
2007998: c2 06 20 10 ld [ %i0 + 0x10 ], %g1
200799c: 80 a0 60 3b cmp %g1, 0x3b
20079a0: 18 80 00 1f bgu 2007a1c <_TOD_Validate+0xc4>
20079a4: 01 00 00 00 nop
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
20079a8: c2 06 20 0c ld [ %i0 + 0xc ], %g1
20079ac: 80 a0 60 17 cmp %g1, 0x17
20079b0: 18 80 00 1b bgu 2007a1c <_TOD_Validate+0xc4>
20079b4: 01 00 00 00 nop
(the_tod->month == 0) ||
20079b8: c2 06 20 04 ld [ %i0 + 4 ], %g1
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
20079bc: 80 a0 60 00 cmp %g1, 0
20079c0: 02 80 00 17 be 2007a1c <_TOD_Validate+0xc4> <== NEVER TAKEN
20079c4: 80 a0 60 0c cmp %g1, 0xc
20079c8: 18 80 00 15 bgu 2007a1c <_TOD_Validate+0xc4>
20079cc: 01 00 00 00 nop
(the_tod->second >= TOD_SECONDS_PER_MINUTE) ||
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
20079d0: c4 06 00 00 ld [ %i0 ], %g2
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
20079d4: 80 a0 a7 c3 cmp %g2, 0x7c3
20079d8: 08 80 00 11 bleu 2007a1c <_TOD_Validate+0xc4>
20079dc: 01 00 00 00 nop
(the_tod->minute >= TOD_MINUTES_PER_HOUR) ||
(the_tod->hour >= TOD_HOURS_PER_DAY) ||
(the_tod->month == 0) ||
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
(the_tod->day == 0) )
20079e0: c6 06 20 08 ld [ %i0 + 8 ], %g3
uint32_t days_in_month;
uint32_t ticks_per_second;
ticks_per_second = TOD_MICROSECONDS_PER_SECOND /
rtems_configuration_get_microseconds_per_tick();
if ((!the_tod) ||
20079e4: 80 a0 e0 00 cmp %g3, 0
20079e8: 02 80 00 0d be 2007a1c <_TOD_Validate+0xc4> <== NEVER TAKEN
20079ec: 80 88 a0 03 btst 3, %g2
(the_tod->month > TOD_MONTHS_PER_YEAR) ||
(the_tod->year < TOD_BASE_YEAR) ||
(the_tod->day == 0) )
return false;
if ( (the_tod->year % 4) == 0 )
20079f0: 32 80 00 0d bne,a 2007a24 <_TOD_Validate+0xcc>
20079f4: 83 28 60 02 sll %g1, 2, %g1
days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ];
20079f8: 82 00 60 0d add %g1, 0xd, %g1
20079fc: 05 00 80 87 sethi %hi(0x2021c00), %g2
2007a00: 83 28 60 02 sll %g1, 2, %g1
2007a04: 84 10 a3 f4 or %g2, 0x3f4, %g2
2007a08: c2 00 80 01 ld [ %g2 + %g1 ], %g1
* false - if the the_tod is invalid
*
* NOTE: This routine only works for leap-years through 2099.
*/
bool _TOD_Validate(
2007a0c: 80 a0 40 03 cmp %g1, %g3
2007a10: b0 60 3f ff subx %g0, -1, %i0
2007a14: 81 c7 e0 08 ret
2007a18: 81 e8 00 00 restore
if ( the_tod->day > days_in_month )
return false;
return true;
}
2007a1c: 81 c7 e0 08 ret
2007a20: 91 e8 20 00 restore %g0, 0, %o0
return false;
if ( (the_tod->year % 4) == 0 )
days_in_month = _TOD_Days_per_month[ 1 ][ the_tod->month ];
else
days_in_month = _TOD_Days_per_month[ 0 ][ the_tod->month ];
2007a24: 05 00 80 87 sethi %hi(0x2021c00), %g2
2007a28: 84 10 a3 f4 or %g2, 0x3f4, %g2 ! 2021ff4 <_TOD_Days_per_month>
2007a2c: 10 bf ff f8 b 2007a0c <_TOD_Validate+0xb4>
2007a30: c2 00 80 01 ld [ %g2 + %g1 ], %g1
02008680 <_Thread_Change_priority>:
void _Thread_Change_priority(
Thread_Control *the_thread,
Priority_Control new_priority,
bool prepend_it
)
{
2008680: 9d e3 bf a0 save %sp, -96, %sp
*/
/*
* Save original state
*/
original_state = the_thread->current_state;
2008684: e2 06 20 10 ld [ %i0 + 0x10 ], %l1
/*
* Set a transient state for the thread so it is pulled off the Ready chains.
* This will prevent it from being scheduled no matter what happens in an
* ISR.
*/
_Thread_Set_transient( the_thread );
2008688: 40 00 04 84 call 2009898 <_Thread_Set_transient>
200868c: 90 10 00 18 mov %i0, %o0
/*
* Do not bother recomputing all the priority related information if
* we are not REALLY changing priority.
*/
if ( the_thread->current_priority != new_priority )
2008690: c2 06 20 14 ld [ %i0 + 0x14 ], %g1
2008694: 80 a0 40 19 cmp %g1, %i1
2008698: 02 80 00 05 be 20086ac <_Thread_Change_priority+0x2c>
200869c: a0 10 00 18 mov %i0, %l0
_Thread_Set_priority( the_thread, new_priority );
20086a0: 92 10 00 19 mov %i1, %o1
20086a4: 40 00 04 01 call 20096a8 <_Thread_Set_priority>
20086a8: 90 10 00 18 mov %i0, %o0
_ISR_Disable( level );
20086ac: 7f ff e6 7e call 20020a4 <sparc_disable_interrupts>
20086b0: 01 00 00 00 nop
20086b4: b0 10 00 08 mov %o0, %i0
/*
* If the thread has more than STATES_TRANSIENT set, then it is blocked,
* If it is blocked on a thread queue, then we need to requeue it.
*/
state = the_thread->current_state;
20086b8: e4 04 20 10 ld [ %l0 + 0x10 ], %l2
if ( state != STATES_TRANSIENT ) {
20086bc: 80 a4 a0 04 cmp %l2, 4
20086c0: 02 80 00 18 be 2008720 <_Thread_Change_priority+0xa0>
20086c4: 80 8c 60 04 btst 4, %l1
/* Only clear the transient state if it wasn't set already */
if ( ! _States_Is_transient( original_state ) )
20086c8: 02 80 00 0b be 20086f4 <_Thread_Change_priority+0x74> <== ALWAYS TAKEN
20086cc: 82 0c bf fb and %l2, -5, %g1
the_thread->current_state = _States_Clear( STATES_TRANSIENT, state );
_ISR_Enable( level );
20086d0: 7f ff e6 79 call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
20086d4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED
if ( _States_Is_waiting_on_thread_queue( state ) ) {
20086d8: 03 00 00 ef sethi %hi(0x3bc00), %g1 <== NOT EXECUTED
20086dc: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 <PROM_START+0x3bee0><== NOT EXECUTED
20086e0: 80 8c 80 01 btst %l2, %g1 <== NOT EXECUTED
20086e4: 32 80 00 0d bne,a 2008718 <_Thread_Change_priority+0x98> <== NOT EXECUTED
20086e8: f0 04 20 44 ld [ %l0 + 0x44 ], %i0 <== NOT EXECUTED
20086ec: 81 c7 e0 08 ret
20086f0: 81 e8 00 00 restore
*/
state = the_thread->current_state;
if ( state != STATES_TRANSIENT ) {
/* Only clear the transient state if it wasn't set already */
if ( ! _States_Is_transient( original_state ) )
the_thread->current_state = _States_Clear( STATES_TRANSIENT, state );
20086f4: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
_ISR_Enable( level );
20086f8: 7f ff e6 6f call 20020b4 <sparc_enable_interrupts>
20086fc: 90 10 00 18 mov %i0, %o0
if ( _States_Is_waiting_on_thread_queue( state ) ) {
2008700: 03 00 00 ef sethi %hi(0x3bc00), %g1
2008704: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 <PROM_START+0x3bee0>
2008708: 80 8c 80 01 btst %l2, %g1
200870c: 02 bf ff f8 be 20086ec <_Thread_Change_priority+0x6c>
2008710: 01 00 00 00 nop
_Thread_queue_Requeue( the_thread->Wait.queue, the_thread );
2008714: f0 04 20 44 ld [ %l0 + 0x44 ], %i0
2008718: 40 00 03 b4 call 20095e8 <_Thread_queue_Requeue>
200871c: 93 e8 00 10 restore %g0, %l0, %o1
}
return;
}
/* Only clear the transient state if it wasn't set already */
if ( ! _States_Is_transient( original_state ) ) {
2008720: 12 80 00 14 bne 2008770 <_Thread_Change_priority+0xf0> <== NEVER TAKEN
2008724: 23 00 80 77 sethi %hi(0x201dc00), %l1
RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map (
Priority_Information *the_priority_map
)
{
*the_priority_map->minor |= the_priority_map->ready_minor;
2008728: c2 04 20 90 ld [ %l0 + 0x90 ], %g1
200872c: c4 14 20 96 lduh [ %l0 + 0x96 ], %g2
2008730: c6 10 40 00 lduh [ %g1 ], %g3
* Interrupts are STILL disabled.
* We now know the thread will be in the READY state when we remove
* the TRANSIENT state. So we have to place it on the appropriate
* Ready Queue with interrupts off.
*/
the_thread->current_state = _States_Clear( STATES_TRANSIENT, state );
2008734: c0 24 20 10 clr [ %l0 + 0x10 ]
2008738: 84 10 c0 02 or %g3, %g2, %g2
200873c: c4 30 40 00 sth %g2, [ %g1 ]
_Priority_Major_bit_map |= the_priority_map->ready_major;
2008740: c4 14 60 64 lduh [ %l1 + 0x64 ], %g2
2008744: c2 14 20 94 lduh [ %l0 + 0x94 ], %g1
_Priority_Add_to_bit_map( &the_thread->Priority_map );
if ( prepend_it )
2008748: 80 8e a0 ff btst 0xff, %i2
200874c: 82 10 80 01 or %g2, %g1, %g1
2008750: c2 34 60 64 sth %g1, [ %l1 + 0x64 ]
2008754: 02 80 00 48 be 2008874 <_Thread_Change_priority+0x1f4>
2008758: c2 04 20 8c ld [ %l0 + 0x8c ], %g1
)
{
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
200875c: c4 00 40 00 ld [ %g1 ], %g2
Chain_Node *the_node
)
{
Chain_Node *before_node;
the_node->previous = after_node;
2008760: c2 24 20 04 st %g1, [ %l0 + 4 ]
before_node = after_node->next;
after_node->next = the_node;
2008764: e0 20 40 00 st %l0, [ %g1 ]
the_node->next = before_node;
before_node->previous = the_node;
2008768: e0 20 a0 04 st %l0, [ %g2 + 4 ]
Chain_Node *before_node;
the_node->previous = after_node;
before_node = after_node->next;
after_node->next = the_node;
the_node->next = before_node;
200876c: c4 24 00 00 st %g2, [ %l0 ]
_Chain_Prepend_unprotected( the_thread->ready, &the_thread->Object.Node );
else
_Chain_Append_unprotected( the_thread->ready, &the_thread->Object.Node );
}
_ISR_Flash( level );
2008770: 7f ff e6 51 call 20020b4 <sparc_enable_interrupts>
2008774: 90 10 00 18 mov %i0, %o0
2008778: 7f ff e6 4b call 20020a4 <sparc_disable_interrupts>
200877c: 01 00 00 00 nop
RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void )
{
Priority_Bit_map_control minor;
Priority_Bit_map_control major;
_Bitfield_Find_first_bit( _Priority_Major_bit_map, major );
2008780: c2 14 60 64 lduh [ %l1 + 0x64 ], %g1
*/
RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void )
{
_Thread_Heir = (Thread_Control *)
_Thread_Ready_chain[ _Priority_Get_highest() ].first;
2008784: 05 00 80 76 sethi %hi(0x201d800), %g2
2008788: 83 28 60 10 sll %g1, 0x10, %g1
200878c: da 00 a3 04 ld [ %g2 + 0x304 ], %o5
2008790: 85 30 60 10 srl %g1, 0x10, %g2
2008794: 80 a0 a0 ff cmp %g2, 0xff
2008798: 08 80 00 27 bleu 2008834 <_Thread_Change_priority+0x1b4>
200879c: 07 00 80 70 sethi %hi(0x201c000), %g3
20087a0: 83 30 60 18 srl %g1, 0x18, %g1
20087a4: 86 10 e0 78 or %g3, 0x78, %g3
20087a8: c4 08 c0 01 ldub [ %g3 + %g1 ], %g2
_Bitfield_Find_first_bit( _Priority_Bit_map[major], minor );
20087ac: 09 00 80 77 sethi %hi(0x201dc00), %g4
20087b0: 85 28 a0 10 sll %g2, 0x10, %g2
20087b4: 88 11 20 e0 or %g4, 0xe0, %g4
20087b8: 83 30 a0 0f srl %g2, 0xf, %g1
20087bc: c2 11 00 01 lduh [ %g4 + %g1 ], %g1
20087c0: 83 28 60 10 sll %g1, 0x10, %g1
20087c4: 89 30 60 10 srl %g1, 0x10, %g4
20087c8: 80 a1 20 ff cmp %g4, 0xff
20087cc: 18 80 00 28 bgu 200886c <_Thread_Change_priority+0x1ec>
20087d0: 83 30 60 18 srl %g1, 0x18, %g1
20087d4: c2 08 c0 04 ldub [ %g3 + %g4 ], %g1
20087d8: 82 00 60 08 add %g1, 8, %g1
* ready thread.
*/
RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void )
{
_Thread_Heir = (Thread_Control *)
20087dc: 85 30 a0 0c srl %g2, 0xc, %g2
20087e0: 83 28 60 10 sll %g1, 0x10, %g1
20087e4: 83 30 60 10 srl %g1, 0x10, %g1
20087e8: 82 00 40 02 add %g1, %g2, %g1
20087ec: 85 28 60 04 sll %g1, 4, %g2
20087f0: 83 28 60 02 sll %g1, 2, %g1
20087f4: 82 20 80 01 sub %g2, %g1, %g1
20087f8: c2 03 40 01 ld [ %o5 + %g1 ], %g1
* is also the heir thread, and false otherwise.
*/
RTEMS_INLINE_ROUTINE bool _Thread_Is_executing_also_the_heir( void )
{
return ( _Thread_Executing == _Thread_Heir );
20087fc: 05 00 80 77 sethi %hi(0x201dc00), %g2
2008800: c4 00 a0 70 ld [ %g2 + 0x70 ], %g2 ! 201dc70 <_Thread_Executing>
* ready thread.
*/
RTEMS_INLINE_ROUTINE void _Thread_Calculate_heir( void )
{
_Thread_Heir = (Thread_Control *)
2008804: 07 00 80 77 sethi %hi(0x201dc00), %g3
* We altered the set of thread priorities. So let's figure out
* who is the heir and if we need to switch to them.
*/
_Thread_Calculate_heir();
if ( !_Thread_Is_executing_also_the_heir() &&
2008808: 80 a0 40 02 cmp %g1, %g2
200880c: 02 80 00 08 be 200882c <_Thread_Change_priority+0x1ac>
2008810: c2 20 e0 40 st %g1, [ %g3 + 0x40 ]
_Thread_Executing->is_preemptible )
2008814: c2 08 a0 75 ldub [ %g2 + 0x75 ], %g1
2008818: 80 a0 60 00 cmp %g1, 0
200881c: 02 80 00 04 be 200882c <_Thread_Change_priority+0x1ac>
2008820: 84 10 20 01 mov 1, %g2
_Context_Switch_necessary = true;
2008824: 03 00 80 77 sethi %hi(0x201dc00), %g1
2008828: c4 28 60 80 stb %g2, [ %g1 + 0x80 ] ! 201dc80 <_Context_Switch_necessary>
_ISR_Enable( level );
200882c: 7f ff e6 22 call 20020b4 <sparc_enable_interrupts>
2008830: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void )
{
Priority_Bit_map_control minor;
Priority_Bit_map_control major;
_Bitfield_Find_first_bit( _Priority_Major_bit_map, major );
2008834: 86 10 e0 78 or %g3, 0x78, %g3
2008838: c4 08 c0 02 ldub [ %g3 + %g2 ], %g2
_Bitfield_Find_first_bit( _Priority_Bit_map[major], minor );
200883c: 09 00 80 77 sethi %hi(0x201dc00), %g4
RTEMS_INLINE_ROUTINE Priority_Control _Priority_Get_highest( void )
{
Priority_Bit_map_control minor;
Priority_Bit_map_control major;
_Bitfield_Find_first_bit( _Priority_Major_bit_map, major );
2008840: 84 00 a0 08 add %g2, 8, %g2
_Bitfield_Find_first_bit( _Priority_Bit_map[major], minor );
2008844: 88 11 20 e0 or %g4, 0xe0, %g4
2008848: 85 28 a0 10 sll %g2, 0x10, %g2
200884c: 83 30 a0 0f srl %g2, 0xf, %g1
2008850: c2 11 00 01 lduh [ %g4 + %g1 ], %g1
2008854: 83 28 60 10 sll %g1, 0x10, %g1
2008858: 89 30 60 10 srl %g1, 0x10, %g4
200885c: 80 a1 20 ff cmp %g4, 0xff
2008860: 28 bf ff de bleu,a 20087d8 <_Thread_Change_priority+0x158>
2008864: c2 08 c0 04 ldub [ %g3 + %g4 ], %g1
2008868: 83 30 60 18 srl %g1, 0x18, %g1
200886c: 10 bf ff dc b 20087dc <_Thread_Change_priority+0x15c>
2008870: c2 08 c0 01 ldub [ %g3 + %g1 ], %g1
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
2008874: 84 00 60 04 add %g1, 4, %g2
2008878: c4 24 00 00 st %g2, [ %l0 ]
old_last_node = the_chain->last;
200887c: c4 00 60 08 ld [ %g1 + 8 ], %g2
the_chain->last = the_node;
2008880: e0 20 60 08 st %l0, [ %g1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
2008884: c4 24 20 04 st %g2, [ %l0 + 4 ]
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
2008888: 10 bf ff ba b 2008770 <_Thread_Change_priority+0xf0>
200888c: e0 20 80 00 st %l0, [ %g2 ]
02008890 <_Thread_Clear_state>:
void _Thread_Clear_state(
Thread_Control *the_thread,
States_Control state
)
{
2008890: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
States_Control current_state;
_ISR_Disable( level );
2008894: 7f ff e6 04 call 20020a4 <sparc_disable_interrupts>
2008898: a0 10 00 18 mov %i0, %l0
200889c: b0 10 00 08 mov %o0, %i0
current_state = the_thread->current_state;
20088a0: c2 04 20 10 ld [ %l0 + 0x10 ], %g1
if ( current_state & state ) {
20088a4: 80 8e 40 01 btst %i1, %g1
20088a8: 02 80 00 06 be 20088c0 <_Thread_Clear_state+0x30>
20088ac: 01 00 00 00 nop
RTEMS_INLINE_ROUTINE States_Control _States_Clear (
States_Control states_to_clear,
States_Control current_state
)
{
return (current_state & ~states_to_clear);
20088b0: b2 28 40 19 andn %g1, %i1, %i1
current_state =
the_thread->current_state = _States_Clear( state, current_state );
if ( _States_Is_ready( current_state ) ) {
20088b4: 80 a6 60 00 cmp %i1, 0
20088b8: 02 80 00 04 be 20088c8 <_Thread_Clear_state+0x38>
20088bc: f2 24 20 10 st %i1, [ %l0 + 0x10 ]
the_thread->current_priority == 0 )
_Context_Switch_necessary = true;
}
}
}
_ISR_Enable( level );
20088c0: 7f ff e5 fd call 20020b4 <sparc_enable_interrupts>
20088c4: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map (
Priority_Information *the_priority_map
)
{
*the_priority_map->minor |= the_priority_map->ready_minor;
20088c8: c4 04 20 90 ld [ %l0 + 0x90 ], %g2
if ( _States_Is_ready( current_state ) ) {
_Priority_Add_to_bit_map( &the_thread->Priority_map );
_Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node);
20088cc: c2 04 20 8c ld [ %l0 + 0x8c ], %g1
20088d0: c8 10 80 00 lduh [ %g2 ], %g4
20088d4: c6 14 20 96 lduh [ %l0 + 0x96 ], %g3
20088d8: 86 11 00 03 or %g4, %g3, %g3
20088dc: c6 30 80 00 sth %g3, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
20088e0: 84 00 60 04 add %g1, 4, %g2
_Priority_Major_bit_map |= the_priority_map->ready_major;
20088e4: c8 14 20 94 lduh [ %l0 + 0x94 ], %g4
20088e8: c4 24 00 00 st %g2, [ %l0 ]
20088ec: 07 00 80 77 sethi %hi(0x201dc00), %g3
old_last_node = the_chain->last;
20088f0: c4 00 60 08 ld [ %g1 + 8 ], %g2
20088f4: da 10 e0 64 lduh [ %g3 + 0x64 ], %o5
the_chain->last = the_node;
20088f8: e0 20 60 08 st %l0, [ %g1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
20088fc: c4 24 20 04 st %g2, [ %l0 + 4 ]
2008900: 82 13 40 04 or %o5, %g4, %g1
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
2008904: e0 20 80 00 st %l0, [ %g2 ]
2008908: c2 30 e0 64 sth %g1, [ %g3 + 0x64 ]
_ISR_Flash( level );
200890c: 7f ff e5 ea call 20020b4 <sparc_enable_interrupts>
2008910: 01 00 00 00 nop
2008914: 7f ff e5 e4 call 20020a4 <sparc_disable_interrupts>
2008918: 01 00 00 00 nop
* a context switch.
* Pseudo-ISR case:
* Even if the thread isn't preemptible, if the new heir is
* a pseudo-ISR system task, we need to do a context switch.
*/
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
200891c: 03 00 80 77 sethi %hi(0x201dc00), %g1
2008920: c6 00 60 40 ld [ %g1 + 0x40 ], %g3 ! 201dc40 <_Thread_Heir>
2008924: c4 04 20 14 ld [ %l0 + 0x14 ], %g2
2008928: c6 00 e0 14 ld [ %g3 + 0x14 ], %g3
200892c: 80 a0 80 03 cmp %g2, %g3
2008930: 1a bf ff e4 bcc 20088c0 <_Thread_Clear_state+0x30>
2008934: 07 00 80 77 sethi %hi(0x201dc00), %g3
_Thread_Heir = the_thread;
if ( _Thread_Executing->is_preemptible ||
2008938: c6 00 e0 70 ld [ %g3 + 0x70 ], %g3 ! 201dc70 <_Thread_Executing>
* Pseudo-ISR case:
* Even if the thread isn't preemptible, if the new heir is
* a pseudo-ISR system task, we need to do a context switch.
*/
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
_Thread_Heir = the_thread;
200893c: e0 20 60 40 st %l0, [ %g1 + 0x40 ]
if ( _Thread_Executing->is_preemptible ||
2008940: c2 08 e0 75 ldub [ %g3 + 0x75 ], %g1
2008944: 80 a0 60 00 cmp %g1, 0
2008948: 32 80 00 05 bne,a 200895c <_Thread_Clear_state+0xcc>
200894c: 84 10 20 01 mov 1, %g2
2008950: 80 a0 a0 00 cmp %g2, 0
2008954: 12 bf ff db bne 20088c0 <_Thread_Clear_state+0x30> <== ALWAYS TAKEN
2008958: 84 10 20 01 mov 1, %g2
the_thread->current_priority == 0 )
_Context_Switch_necessary = true;
200895c: 03 00 80 77 sethi %hi(0x201dc00), %g1
2008960: c4 28 60 80 stb %g2, [ %g1 + 0x80 ] ! 201dc80 <_Context_Switch_necessary>
}
}
}
_ISR_Enable( level );
2008964: 7f ff e5 d4 call 20020b4 <sparc_enable_interrupts>
2008968: 81 e8 00 00 restore
02008b18 <_Thread_Delay_ended>:
void _Thread_Delay_ended(
Objects_Id id,
void *ignored __attribute__((unused))
)
{
2008b18: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
2008b1c: 90 10 00 18 mov %i0, %o0
2008b20: 40 00 00 84 call 2008d30 <_Thread_Get>
2008b24: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2008b28: c2 07 bf fc ld [ %fp + -4 ], %g1
2008b2c: 80 a0 60 00 cmp %g1, 0
2008b30: 12 80 00 08 bne 2008b50 <_Thread_Delay_ended+0x38> <== NEVER TAKEN
2008b34: 13 04 00 00 sethi %hi(0x10000000), %o1
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_Clear_state(
2008b38: 7f ff ff 56 call 2008890 <_Thread_Clear_state>
2008b3c: 92 12 60 18 or %o1, 0x18, %o1 ! 10000018 <RAM_END+0xdc00018>
2008b40: 03 00 80 76 sethi %hi(0x201d800), %g1
2008b44: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201dbb0 <_Thread_Dispatch_disable_level>
2008b48: 84 00 bf ff add %g2, -1, %g2
2008b4c: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
2008b50: 81 c7 e0 08 ret
2008b54: 81 e8 00 00 restore
02008b58 <_Thread_Dispatch>:
* dispatch thread
* no dispatch thread
*/
void _Thread_Dispatch( void )
{
2008b58: 9d e3 bf 90 save %sp, -112, %sp
Thread_Control *executing;
Thread_Control *heir;
ISR_Level level;
executing = _Thread_Executing;
2008b5c: 2b 00 80 77 sethi %hi(0x201dc00), %l5
_ISR_Disable( level );
2008b60: 7f ff e5 51 call 20020a4 <sparc_disable_interrupts>
2008b64: e0 05 60 70 ld [ %l5 + 0x70 ], %l0 ! 201dc70 <_Thread_Executing>
while ( _Context_Switch_necessary == true ) {
2008b68: 2d 00 80 77 sethi %hi(0x201dc00), %l6
2008b6c: c2 0d a0 80 ldub [ %l6 + 0x80 ], %g1 ! 201dc80 <_Context_Switch_necessary>
2008b70: 80 a0 60 00 cmp %g1, 0
2008b74: 02 80 00 50 be 2008cb4 <_Thread_Dispatch+0x15c>
2008b78: 33 00 80 77 sethi %hi(0x201dc00), %i1
2008b7c: 25 00 80 77 sethi %hi(0x201dc00), %l2
2008b80: 35 00 80 77 sethi %hi(0x201dc00), %i2
2008b84: a4 14 a0 78 or %l2, 0x78, %l2
#if __RTEMS_ADA__
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
2008b88: 31 00 80 76 sethi %hi(0x201d800), %i0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
RTEMS_INLINE_ROUTINE bool _Thread_Is_allocated_fp (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Allocated_fp );
2008b8c: 2f 00 80 77 sethi %hi(0x201dc00), %l7
2008b90: 03 00 80 76 sethi %hi(0x201d800), %g1
2008b94: ac 15 a0 80 or %l6, 0x80, %l6
2008b98: aa 15 60 70 or %l5, 0x70, %l5
2008b9c: b2 16 60 40 or %i1, 0x40, %i1
2008ba0: b4 16 a0 3c or %i2, 0x3c, %i2
2008ba4: b0 16 23 08 or %i0, 0x308, %i0
2008ba8: ae 15 e0 38 or %l7, 0x38, %l7
2008bac: b6 10 63 b0 or %g1, 0x3b0, %i3
2008bb0: a8 07 bf f8 add %fp, -8, %l4
2008bb4: a6 07 bf f0 add %fp, -16, %l3
executing = _Thread_Executing;
_ISR_Disable( level );
while ( _Context_Switch_necessary == true ) {
heir = _Thread_Heir;
_Thread_Dispatch_disable_level = 1;
2008bb8: b8 10 20 01 mov 1, %i4
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
{
Timestamp_Control uptime, ran;
_TOD_Get_uptime( &uptime );
_Timestamp_Subtract(
2008bbc: 10 80 00 34 b 2008c8c <_Thread_Dispatch+0x134>
2008bc0: ba 10 00 12 mov %l2, %i5
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
_ISR_Enable( level );
2008bc4: 7f ff e5 3c call 20020b4 <sparc_enable_interrupts>
2008bc8: 01 00 00 00 nop
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
{
Timestamp_Control uptime, ran;
_TOD_Get_uptime( &uptime );
2008bcc: 40 00 13 3d call 200d8c0 <_TOD_Get_uptime>
2008bd0: 90 10 00 14 mov %l4, %o0
_Timestamp_Subtract(
2008bd4: 90 10 00 1d mov %i5, %o0
2008bd8: 92 10 00 14 mov %l4, %o1
2008bdc: 40 00 04 03 call 2009be8 <_Timespec_Subtract>
2008be0: 94 10 00 13 mov %l3, %o2
&_Thread_Time_of_last_context_switch,
&uptime,
&ran
);
_Timestamp_Add_to( &executing->cpu_time_used, &ran );
2008be4: 92 10 00 13 mov %l3, %o1
2008be8: 40 00 03 e7 call 2009b84 <_Timespec_Add_to>
2008bec: 90 04 20 84 add %l0, 0x84, %o0
_Thread_Time_of_last_context_switch = uptime;
2008bf0: c4 07 bf f8 ld [ %fp + -8 ], %g2
#endif
/*
* Switch libc's task specific data.
*/
if ( _Thread_libc_reent ) {
2008bf4: c2 06 80 00 ld [ %i2 ], %g1
&_Thread_Time_of_last_context_switch,
&uptime,
&ran
);
_Timestamp_Add_to( &executing->cpu_time_used, &ran );
_Thread_Time_of_last_context_switch = uptime;
2008bf8: c4 24 80 00 st %g2, [ %l2 ]
2008bfc: c4 07 bf fc ld [ %fp + -4 ], %g2
if ( _Thread_libc_reent ) {
executing->libc_reent = *_Thread_libc_reent;
*_Thread_libc_reent = heir->libc_reent;
}
_User_extensions_Thread_switch( executing, heir );
2008c00: 90 10 00 10 mov %l0, %o0
&_Thread_Time_of_last_context_switch,
&uptime,
&ran
);
_Timestamp_Add_to( &executing->cpu_time_used, &ran );
_Thread_Time_of_last_context_switch = uptime;
2008c04: c4 24 a0 04 st %g2, [ %l2 + 4 ]
#endif
/*
* Switch libc's task specific data.
*/
if ( _Thread_libc_reent ) {
2008c08: 80 a0 60 00 cmp %g1, 0
2008c0c: 02 80 00 06 be 2008c24 <_Thread_Dispatch+0xcc> <== NEVER TAKEN
2008c10: 92 10 00 11 mov %l1, %o1
executing->libc_reent = *_Thread_libc_reent;
2008c14: c4 00 40 00 ld [ %g1 ], %g2
2008c18: c4 24 21 5c st %g2, [ %l0 + 0x15c ]
*_Thread_libc_reent = heir->libc_reent;
2008c1c: c4 04 61 5c ld [ %l1 + 0x15c ], %g2
2008c20: c4 20 40 00 st %g2, [ %g1 ]
}
_User_extensions_Thread_switch( executing, heir );
2008c24: 40 00 04 b3 call 2009ef0 <_User_extensions_Thread_switch>
2008c28: 01 00 00 00 nop
if ( executing->fp_context != NULL )
_Context_Save_fp( &executing->fp_context );
#endif
#endif
_Context_Switch( &executing->Registers, &heir->Registers );
2008c2c: 92 04 60 d0 add %l1, 0xd0, %o1
2008c30: 40 00 06 00 call 200a430 <_CPU_Context_switch>
2008c34: 90 04 20 d0 add %l0, 0xd0, %o0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
#if ( CPU_USE_DEFERRED_FP_SWITCH == TRUE )
if ( (executing->fp_context != NULL) &&
2008c38: c2 04 21 58 ld [ %l0 + 0x158 ], %g1
2008c3c: 80 a0 60 00 cmp %g1, 0
2008c40: 02 80 00 0d be 2008c74 <_Thread_Dispatch+0x11c>
2008c44: 01 00 00 00 nop
2008c48: d0 05 c0 00 ld [ %l7 ], %o0
2008c4c: 80 a4 00 08 cmp %l0, %o0
2008c50: 02 80 00 09 be 2008c74 <_Thread_Dispatch+0x11c>
2008c54: 80 a2 20 00 cmp %o0, 0
!_Thread_Is_allocated_fp( executing ) ) {
if ( _Thread_Allocated_fp != NULL )
2008c58: 02 80 00 04 be 2008c68 <_Thread_Dispatch+0x110>
2008c5c: 01 00 00 00 nop
_Context_Save_fp( &_Thread_Allocated_fp->fp_context );
2008c60: 40 00 05 ba call 200a348 <_CPU_Context_save_fp>
2008c64: 90 02 21 58 add %o0, 0x158, %o0
_Context_Restore_fp( &executing->fp_context );
2008c68: 40 00 05 d5 call 200a3bc <_CPU_Context_restore_fp>
2008c6c: 90 04 21 58 add %l0, 0x158, %o0
_Thread_Allocated_fp = executing;
2008c70: e0 25 c0 00 st %l0, [ %l7 ]
#endif
#endif
executing = _Thread_Executing;
_ISR_Disable( level );
2008c74: 7f ff e5 0c call 20020a4 <sparc_disable_interrupts>
2008c78: e0 05 40 00 ld [ %l5 ], %l0
Thread_Control *heir;
ISR_Level level;
executing = _Thread_Executing;
_ISR_Disable( level );
while ( _Context_Switch_necessary == true ) {
2008c7c: c2 0d 80 00 ldub [ %l6 ], %g1
2008c80: 80 a0 60 00 cmp %g1, 0
2008c84: 02 80 00 0d be 2008cb8 <_Thread_Dispatch+0x160>
2008c88: 03 00 80 76 sethi %hi(0x201d800), %g1
heir = _Thread_Heir;
2008c8c: e2 06 40 00 ld [ %i1 ], %l1
_Thread_Dispatch_disable_level = 1;
2008c90: f8 26 c0 00 st %i4, [ %i3 ]
_Thread_Executing = heir;
#if __RTEMS_ADA__
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
2008c94: c2 04 60 7c ld [ %l1 + 0x7c ], %g1
executing = _Thread_Executing;
_ISR_Disable( level );
while ( _Context_Switch_necessary == true ) {
heir = _Thread_Heir;
_Thread_Dispatch_disable_level = 1;
_Context_Switch_necessary = false;
2008c98: c0 2d 80 00 clrb [ %l6 ]
_Thread_Executing = heir;
#if __RTEMS_ADA__
executing->rtems_ada_self = rtems_ada_self;
rtems_ada_self = heir->rtems_ada_self;
#endif
if ( heir->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE )
2008c9c: 80 a0 60 01 cmp %g1, 1
2008ca0: 12 bf ff c9 bne 2008bc4 <_Thread_Dispatch+0x6c>
2008ca4: e2 25 40 00 st %l1, [ %l5 ]
heir->cpu_time_budget = _Thread_Ticks_per_timeslice;
2008ca8: c2 06 00 00 ld [ %i0 ], %g1
2008cac: 10 bf ff c6 b 2008bc4 <_Thread_Dispatch+0x6c>
2008cb0: c2 24 60 78 st %g1, [ %l1 + 0x78 ]
executing = _Thread_Executing;
_ISR_Disable( level );
}
_Thread_Dispatch_disable_level = 0;
2008cb4: 03 00 80 76 sethi %hi(0x201d800), %g1
2008cb8: c0 20 63 b0 clr [ %g1 + 0x3b0 ] ! 201dbb0 <_Thread_Dispatch_disable_level>
_ISR_Enable( level );
2008cbc: 7f ff e4 fe call 20020b4 <sparc_enable_interrupts>
2008cc0: 01 00 00 00 nop
if ( _Thread_Do_post_task_switch_extension ||
2008cc4: 03 00 80 77 sethi %hi(0x201dc00), %g1
2008cc8: c2 00 60 54 ld [ %g1 + 0x54 ], %g1 ! 201dc54 <_Thread_Do_post_task_switch_extension>
2008ccc: 80 a0 60 00 cmp %g1, 0
2008cd0: 12 80 00 06 bne 2008ce8 <_Thread_Dispatch+0x190> <== NEVER TAKEN
2008cd4: 01 00 00 00 nop
executing->do_post_task_switch_extension ) {
2008cd8: c2 0c 20 74 ldub [ %l0 + 0x74 ], %g1
2008cdc: 80 a0 60 00 cmp %g1, 0
2008ce0: 02 80 00 04 be 2008cf0 <_Thread_Dispatch+0x198>
2008ce4: 01 00 00 00 nop
executing->do_post_task_switch_extension = false;
_API_extensions_Run_postswitch();
2008ce8: 7f ff f9 1b call 2007154 <_API_extensions_Run_postswitch>
2008cec: c0 2c 20 74 clrb [ %l0 + 0x74 ]
2008cf0: 81 c7 e0 08 ret
2008cf4: 81 e8 00 00 restore
02010184 <_Thread_Evaluate_mode>:
bool _Thread_Evaluate_mode( void )
{
Thread_Control *executing;
executing = _Thread_Executing;
2010184: 03 00 80 77 sethi %hi(0x201dc00), %g1
2010188: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 201dc70 <_Thread_Executing>
if ( !_States_Is_ready( executing->current_state ) ||
201018c: c4 00 60 10 ld [ %g1 + 0x10 ], %g2
2010190: 80 a0 a0 00 cmp %g2, 0
2010194: 12 80 00 0b bne 20101c0 <_Thread_Evaluate_mode+0x3c> <== NEVER TAKEN
2010198: 84 10 20 01 mov 1, %g2
201019c: 05 00 80 77 sethi %hi(0x201dc00), %g2
20101a0: c4 00 a0 40 ld [ %g2 + 0x40 ], %g2 ! 201dc40 <_Thread_Heir>
20101a4: 80 a0 40 02 cmp %g1, %g2
20101a8: 02 80 00 0b be 20101d4 <_Thread_Evaluate_mode+0x50>
20101ac: 01 00 00 00 nop
( !_Thread_Is_heir( executing ) && executing->is_preemptible ) ) {
20101b0: c2 08 60 75 ldub [ %g1 + 0x75 ], %g1
20101b4: 80 a0 60 00 cmp %g1, 0
20101b8: 02 80 00 07 be 20101d4 <_Thread_Evaluate_mode+0x50> <== NEVER TAKEN
20101bc: 84 10 20 01 mov 1, %g2
_Context_Switch_necessary = true;
20101c0: 03 00 80 77 sethi %hi(0x201dc00), %g1
20101c4: 90 10 20 01 mov 1, %o0
20101c8: c4 28 60 80 stb %g2, [ %g1 + 0x80 ]
return true;
20101cc: 81 c3 e0 08 retl
20101d0: 01 00 00 00 nop
}
return false;
}
20101d4: 81 c3 e0 08 retl
20101d8: 90 10 20 00 clr %o0 ! 0 <PROM_START>
020101dc <_Thread_Handler>:
*
* Output parameters: NONE
*/
void _Thread_Handler( void )
{
20101dc: 9d e3 bf a0 save %sp, -96, %sp
#if defined(EXECUTE_GLOBAL_CONSTRUCTORS)
static char doneConstructors;
char doneCons;
#endif
executing = _Thread_Executing;
20101e0: 03 00 80 77 sethi %hi(0x201dc00), %g1
20101e4: e0 00 60 70 ld [ %g1 + 0x70 ], %l0 ! 201dc70 <_Thread_Executing>
/*
* Some CPUs need to tinker with the call frame or registers when the
* thread actually begins to execute for the first time. This is a
* hook point where the port gets a shot at doing whatever it requires.
*/
_Context_Initialization_at_thread_begin();
20101e8: 3f 00 80 40 sethi %hi(0x2010000), %i7
20101ec: be 17 e1 dc or %i7, 0x1dc, %i7 ! 20101dc <_Thread_Handler>
/*
* have to put level into a register for those cpu's that use
* inline asm here
*/
level = executing->Start.isr_level;
20101f0: d0 04 20 b8 ld [ %l0 + 0xb8 ], %o0
_ISR_Set_level(level);
20101f4: 7f ff c7 b0 call 20020b4 <sparc_enable_interrupts>
20101f8: 91 2a 20 08 sll %o0, 8, %o0
#if defined(EXECUTE_GLOBAL_CONSTRUCTORS)
doneCons = doneConstructors;
20101fc: 03 00 80 76 sethi %hi(0x201d800), %g1
doneConstructors = 1;
2010200: 84 10 20 01 mov 1, %g2
level = executing->Start.isr_level;
_ISR_Set_level(level);
#if defined(EXECUTE_GLOBAL_CONSTRUCTORS)
doneCons = doneConstructors;
2010204: e4 08 60 66 ldub [ %g1 + 0x66 ], %l2
doneConstructors = 1;
2010208: c4 28 60 66 stb %g2, [ %g1 + 0x66 ]
#endif
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
#if ( CPU_USE_DEFERRED_FP_SWITCH == TRUE )
if ( (executing->fp_context != NULL) &&
201020c: c2 04 21 58 ld [ %l0 + 0x158 ], %g1
2010210: 80 a0 60 00 cmp %g1, 0
2010214: 02 80 00 0b be 2010240 <_Thread_Handler+0x64>
2010218: 23 00 80 77 sethi %hi(0x201dc00), %l1
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
RTEMS_INLINE_ROUTINE bool _Thread_Is_allocated_fp (
const Thread_Control *the_thread
)
{
return ( the_thread == _Thread_Allocated_fp );
201021c: d0 04 60 38 ld [ %l1 + 0x38 ], %o0 ! 201dc38 <_Thread_Allocated_fp>
2010220: 80 a4 00 08 cmp %l0, %o0
2010224: 02 80 00 07 be 2010240 <_Thread_Handler+0x64>
2010228: 80 a2 20 00 cmp %o0, 0
!_Thread_Is_allocated_fp( executing ) ) {
if ( _Thread_Allocated_fp != NULL )
201022c: 22 80 00 05 be,a 2010240 <_Thread_Handler+0x64>
2010230: e0 24 60 38 st %l0, [ %l1 + 0x38 ]
_Context_Save_fp( &_Thread_Allocated_fp->fp_context );
2010234: 7f ff e8 45 call 200a348 <_CPU_Context_save_fp>
2010238: 90 02 21 58 add %o0, 0x158, %o0
_Thread_Allocated_fp = executing;
201023c: e0 24 60 38 st %l0, [ %l1 + 0x38 ]
/*
* Take care that 'begin' extensions get to complete before
* 'switch' extensions can run. This means must keep dispatch
* disabled until all 'begin' extensions complete.
*/
_User_extensions_Thread_begin( executing );
2010240: 7f ff e6 ae call 2009cf8 <_User_extensions_Thread_begin>
2010244: 90 10 00 10 mov %l0, %o0
/*
* At this point, the dispatch disable level BETTER be 1.
*/
_Thread_Enable_dispatch();
2010248: 7f ff e2 ac call 2008cf8 <_Thread_Enable_dispatch>
201024c: a5 2c a0 18 sll %l2, 0x18, %l2
/*
* _init could be a weak symbol and we SHOULD test it but it isn't
* in any configuration I know of and it generates a warning on every
* RTEMS target configuration. --joel (12 May 2007)
*/
if (!doneCons) /* && (volatile void *)_init) */ {
2010250: 80 a4 a0 00 cmp %l2, 0
2010254: 02 80 00 0c be 2010284 <_Thread_Handler+0xa8>
2010258: 01 00 00 00 nop
INIT_NAME ();
}
#endif
if ( executing->Start.prototype == THREAD_START_NUMERIC ) {
201025c: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
2010260: 80 a0 60 00 cmp %g1, 0
2010264: 22 80 00 0f be,a 20102a0 <_Thread_Handler+0xc4> <== ALWAYS TAKEN
2010268: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
* was placed in return_argument. This assumed that if it returned
* anything (which is not supporting in all APIs), then it would be
* able to fit in a (void *).
*/
_User_extensions_Thread_exitted( executing );
201026c: 7f ff e6 b7 call 2009d48 <_User_extensions_Thread_exitted>
2010270: 90 10 00 10 mov %l0, %o0
_Internal_error_Occurred(
2010274: 90 10 20 00 clr %o0
2010278: 92 10 20 01 mov 1, %o1
201027c: 7f ff de 7c call 2007c6c <_Internal_error_Occurred>
2010280: 94 10 20 06 mov 6, %o2
* _init could be a weak symbol and we SHOULD test it but it isn't
* in any configuration I know of and it generates a warning on every
* RTEMS target configuration. --joel (12 May 2007)
*/
if (!doneCons) /* && (volatile void *)_init) */ {
INIT_NAME ();
2010284: 40 00 33 5d call 201cff8 <_init>
2010288: 01 00 00 00 nop
}
#endif
if ( executing->Start.prototype == THREAD_START_NUMERIC ) {
201028c: c2 04 20 a0 ld [ %l0 + 0xa0 ], %g1
2010290: 80 a0 60 00 cmp %g1, 0
2010294: 12 bf ff f6 bne 201026c <_Thread_Handler+0x90> <== NEVER TAKEN
2010298: 01 00 00 00 nop
executing->Wait.return_argument =
(*(Thread_Entry_numeric) executing->Start.entry_point)(
201029c: c2 04 20 9c ld [ %l0 + 0x9c ], %g1
20102a0: 9f c0 40 00 call %g1
20102a4: d0 04 20 a8 ld [ %l0 + 0xa8 ], %o0
INIT_NAME ();
}
#endif
if ( executing->Start.prototype == THREAD_START_NUMERIC ) {
executing->Wait.return_argument =
20102a8: 10 bf ff f1 b 201026c <_Thread_Handler+0x90>
20102ac: d0 24 20 28 st %o0, [ %l0 + 0x28 ]
02008ddc <_Thread_Initialize>:
Thread_CPU_budget_algorithms budget_algorithm,
Thread_CPU_budget_algorithm_callout budget_callout,
uint32_t isr_level,
Objects_Name name
)
{
2008ddc: 9d e3 bf a0 save %sp, -96, %sp
2008de0: c2 07 a0 6c ld [ %fp + 0x6c ], %g1
/*
* Zero out all the allocated memory fields
*/
for ( i=0 ; i <= THREAD_API_LAST ; i++ )
the_thread->API_Extensions[i] = NULL;
2008de4: c0 26 61 60 clr [ %i1 + 0x160 ]
Thread_CPU_budget_algorithms budget_algorithm,
Thread_CPU_budget_algorithm_callout budget_callout,
uint32_t isr_level,
Objects_Name name
)
{
2008de8: e2 00 40 00 ld [ %g1 ], %l1
/*
* Zero out all the allocated memory fields
*/
for ( i=0 ; i <= THREAD_API_LAST ; i++ )
the_thread->API_Extensions[i] = NULL;
2008dec: c0 26 61 64 clr [ %i1 + 0x164 ]
2008df0: c0 26 61 68 clr [ %i1 + 0x168 ]
extensions_area = NULL;
the_thread->libc_reent = NULL;
2008df4: c0 26 61 5c clr [ %i1 + 0x15c ]
Thread_CPU_budget_algorithms budget_algorithm,
Thread_CPU_budget_algorithm_callout budget_callout,
uint32_t isr_level,
Objects_Name name
)
{
2008df8: e0 0f a0 5f ldub [ %fp + 0x5f ], %l0
/*
* Allocate and Initialize the stack for this thread.
*/
#if !defined(RTEMS_SCORE_THREAD_ENABLE_USER_PROVIDED_STACK_VIA_API)
actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
2008dfc: 90 10 00 19 mov %i1, %o0
2008e00: 40 00 02 ca call 2009928 <_Thread_Stack_Allocate>
2008e04: 92 10 00 1b mov %i3, %o1
if ( !actual_stack_size || actual_stack_size < stack_size )
2008e08: 80 a6 c0 08 cmp %i3, %o0
2008e0c: 18 80 00 5a bgu 2008f74 <_Thread_Initialize+0x198>
2008e10: 80 a2 20 00 cmp %o0, 0
2008e14: 02 80 00 58 be 2008f74 <_Thread_Initialize+0x198> <== NEVER TAKEN
2008e18: 80 8f 20 ff btst 0xff, %i4
Stack_Control *the_stack,
void *starting_address,
size_t size
)
{
the_stack->area = starting_address;
2008e1c: c2 06 60 cc ld [ %i1 + 0xcc ], %g1
the_stack->size = size;
2008e20: d0 26 60 c0 st %o0, [ %i1 + 0xc0 ]
Stack_Control *the_stack,
void *starting_address,
size_t size
)
{
the_stack->area = starting_address;
2008e24: c2 26 60 c4 st %g1, [ %i1 + 0xc4 ]
/*
* Allocate the floating point area for this thread
*/
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
if ( is_fp ) {
2008e28: 82 10 20 00 clr %g1
2008e2c: 12 80 00 54 bne 2008f7c <_Thread_Initialize+0x1a0>
2008e30: a4 10 20 00 clr %l2
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2008e34: 27 00 80 77 sethi %hi(0x201dc00), %l3
2008e38: c4 04 e0 50 ld [ %l3 + 0x50 ], %g2 ! 201dc50 <_Thread_Maximum_extensions>
if ( !fp_area )
goto failed;
fp_area = _Context_Fp_start( fp_area, 0 );
}
the_thread->fp_context = fp_area;
the_thread->Start.fp_context = fp_area;
2008e3c: c2 26 60 c8 st %g1, [ %i1 + 0xc8 ]
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE );
if ( !fp_area )
goto failed;
fp_area = _Context_Fp_start( fp_area, 0 );
}
the_thread->fp_context = fp_area;
2008e40: c2 26 61 58 st %g1, [ %i1 + 0x158 ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2008e44: c0 26 60 50 clr [ %i1 + 0x50 ]
the_watchdog->routine = routine;
2008e48: c0 26 60 64 clr [ %i1 + 0x64 ]
the_watchdog->id = id;
2008e4c: c0 26 60 68 clr [ %i1 + 0x68 ]
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2008e50: 80 a0 a0 00 cmp %g2, 0
2008e54: 12 80 00 5a bne 2008fbc <_Thread_Initialize+0x1e0>
2008e58: c0 26 60 6c clr [ %i1 + 0x6c ]
(_Thread_Maximum_extensions + 1) * sizeof( void * )
);
if ( !extensions_area )
goto failed;
}
the_thread->extensions = (void **) extensions_area;
2008e5c: c0 26 61 6c clr [ %i1 + 0x16c ]
2008e60: b6 10 20 00 clr %i3
/*
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
the_thread->Start.budget_algorithm = budget_algorithm;
2008e64: c2 07 a0 60 ld [ %fp + 0x60 ], %g1
#if defined(RTEMS_ITRON_API)
the_thread->suspend_count = 0;
#endif
the_thread->real_priority = priority;
the_thread->Start.initial_priority = priority;
_Thread_Set_priority( the_thread, priority );
2008e68: 92 10 00 1d mov %i5, %o1
/*
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
the_thread->Start.budget_algorithm = budget_algorithm;
2008e6c: c2 26 60 b0 st %g1, [ %i1 + 0xb0 ]
the_thread->Start.budget_callout = budget_callout;
2008e70: c2 07 a0 64 ld [ %fp + 0x64 ], %g1
#if defined(RTEMS_ITRON_API)
the_thread->suspend_count = 0;
#endif
the_thread->real_priority = priority;
the_thread->Start.initial_priority = priority;
_Thread_Set_priority( the_thread, priority );
2008e74: 90 10 00 19 mov %i1, %o0
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
the_thread->Start.budget_algorithm = budget_algorithm;
the_thread->Start.budget_callout = budget_callout;
2008e78: c2 26 60 b4 st %g1, [ %i1 + 0xb4 ]
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:
break;
#endif
}
the_thread->Start.isr_level = isr_level;
2008e7c: c2 07 a0 68 ld [ %fp + 0x68 ], %g1
/*
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
2008e80: e0 2e 60 ac stb %l0, [ %i1 + 0xac ]
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT:
break;
#endif
}
the_thread->Start.isr_level = isr_level;
2008e84: c2 26 60 b8 st %g1, [ %i1 + 0xb8 ]
the_thread->current_state = STATES_DORMANT;
2008e88: 82 10 20 01 mov 1, %g1
the_thread->Wait.queue = NULL;
2008e8c: c0 26 60 44 clr [ %i1 + 0x44 ]
#endif
}
the_thread->Start.isr_level = isr_level;
the_thread->current_state = STATES_DORMANT;
2008e90: c2 26 60 10 st %g1, [ %i1 + 0x10 ]
the_thread->Wait.queue = NULL;
the_thread->resource_count = 0;
2008e94: c0 26 60 1c clr [ %i1 + 0x1c ]
#if defined(RTEMS_ITRON_API)
the_thread->suspend_count = 0;
#endif
the_thread->real_priority = priority;
2008e98: fa 26 60 18 st %i5, [ %i1 + 0x18 ]
the_thread->Start.initial_priority = priority;
_Thread_Set_priority( the_thread, priority );
2008e9c: 40 00 02 03 call 20096a8 <_Thread_Set_priority>
2008ea0: fa 26 60 bc st %i5, [ %i1 + 0xbc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2008ea4: c2 16 60 0a lduh [ %i1 + 0xa ], %g1
2008ea8: c4 06 20 1c ld [ %i0 + 0x1c ], %g2
2008eac: 83 28 60 02 sll %g1, 2, %g1
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
2008eb0: e2 26 60 0c st %l1, [ %i1 + 0xc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
2008eb4: f2 20 80 01 st %i1, [ %g2 + %g1 ]
/*
* Initialize the CPU usage statistics
*/
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
_Timestamp_Set_to_zero( &the_thread->cpu_time_used );
2008eb8: c0 26 60 84 clr [ %i1 + 0x84 ]
2008ebc: c0 26 60 88 clr [ %i1 + 0x88 ]
* enabled when we get here. We want to be able to run the
* user extensions with dispatching enabled. The Allocator
* Mutex provides sufficient protection to let the user extensions
* run safely.
*/
extension_status = _User_extensions_Thread_create( the_thread );
2008ec0: 90 10 00 19 mov %i1, %o0
2008ec4: 40 00 03 c8 call 2009de4 <_User_extensions_Thread_create>
2008ec8: b0 10 20 01 mov 1, %i0
if ( extension_status )
2008ecc: 80 8a 20 ff btst 0xff, %o0
2008ed0: 12 80 00 27 bne 2008f6c <_Thread_Initialize+0x190>
2008ed4: 01 00 00 00 nop
return true;
failed:
if ( the_thread->libc_reent )
2008ed8: d0 06 61 5c ld [ %i1 + 0x15c ], %o0
2008edc: 80 a2 20 00 cmp %o0, 0
2008ee0: 22 80 00 05 be,a 2008ef4 <_Thread_Initialize+0x118>
2008ee4: d0 06 61 60 ld [ %i1 + 0x160 ], %o0
_Workspace_Free( the_thread->libc_reent );
2008ee8: 40 00 04 f5 call 200a2bc <_Workspace_Free>
2008eec: 01 00 00 00 nop
for ( i=0 ; i <= THREAD_API_LAST ; i++ )
if ( the_thread->API_Extensions[i] )
2008ef0: d0 06 61 60 ld [ %i1 + 0x160 ], %o0
2008ef4: 80 a2 20 00 cmp %o0, 0
2008ef8: 22 80 00 05 be,a 2008f0c <_Thread_Initialize+0x130>
2008efc: d0 06 61 64 ld [ %i1 + 0x164 ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2008f00: 40 00 04 ef call 200a2bc <_Workspace_Free>
2008f04: 01 00 00 00 nop
failed:
if ( the_thread->libc_reent )
_Workspace_Free( the_thread->libc_reent );
for ( i=0 ; i <= THREAD_API_LAST ; i++ )
if ( the_thread->API_Extensions[i] )
2008f08: d0 06 61 64 ld [ %i1 + 0x164 ], %o0
2008f0c: 80 a2 20 00 cmp %o0, 0
2008f10: 22 80 00 05 be,a 2008f24 <_Thread_Initialize+0x148> <== ALWAYS TAKEN
2008f14: d0 06 61 68 ld [ %i1 + 0x168 ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2008f18: 40 00 04 e9 call 200a2bc <_Workspace_Free> <== NOT EXECUTED
2008f1c: 01 00 00 00 nop <== NOT EXECUTED
failed:
if ( the_thread->libc_reent )
_Workspace_Free( the_thread->libc_reent );
for ( i=0 ; i <= THREAD_API_LAST ; i++ )
if ( the_thread->API_Extensions[i] )
2008f20: d0 06 61 68 ld [ %i1 + 0x168 ], %o0 <== NOT EXECUTED
2008f24: 80 a2 20 00 cmp %o0, 0
2008f28: 02 80 00 05 be 2008f3c <_Thread_Initialize+0x160> <== ALWAYS TAKEN
2008f2c: 80 a6 e0 00 cmp %i3, 0
_Workspace_Free( the_thread->API_Extensions[i] );
2008f30: 40 00 04 e3 call 200a2bc <_Workspace_Free> <== NOT EXECUTED
2008f34: 01 00 00 00 nop <== NOT EXECUTED
if ( extensions_area )
2008f38: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2008f3c: 02 80 00 05 be 2008f50 <_Thread_Initialize+0x174>
2008f40: 80 a4 a0 00 cmp %l2, 0
(void) _Workspace_Free( extensions_area );
2008f44: 40 00 04 de call 200a2bc <_Workspace_Free>
2008f48: 90 10 00 1b mov %i3, %o0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
if ( fp_area )
2008f4c: 80 a4 a0 00 cmp %l2, 0
2008f50: 02 80 00 05 be 2008f64 <_Thread_Initialize+0x188>
2008f54: 90 10 00 19 mov %i1, %o0
(void) _Workspace_Free( fp_area );
2008f58: 40 00 04 d9 call 200a2bc <_Workspace_Free>
2008f5c: 90 10 00 12 mov %l2, %o0
#endif
_Thread_Stack_Free( the_thread );
2008f60: 90 10 00 19 mov %i1, %o0
2008f64: 40 00 02 8c call 2009994 <_Thread_Stack_Free>
2008f68: b0 10 20 00 clr %i0
return false;
}
2008f6c: 81 c7 e0 08 ret
2008f70: 81 e8 00 00 restore
/*
* Allocate and Initialize the stack for this thread.
*/
#if !defined(RTEMS_SCORE_THREAD_ENABLE_USER_PROVIDED_STACK_VIA_API)
actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
if ( !actual_stack_size || actual_stack_size < stack_size )
2008f74: 81 c7 e0 08 ret
2008f78: 91 e8 20 00 restore %g0, 0, %o0
/*
* Allocate the floating point area for this thread
*/
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE )
if ( is_fp ) {
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE );
2008f7c: 40 00 04 c7 call 200a298 <_Workspace_Allocate>
2008f80: 90 10 20 88 mov 0x88, %o0
if ( !fp_area )
2008f84: b6 10 20 00 clr %i3
2008f88: a4 92 20 00 orcc %o0, 0, %l2
2008f8c: 02 bf ff d3 be 2008ed8 <_Thread_Initialize+0xfc>
2008f90: 82 10 00 12 mov %l2, %g1
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2008f94: 27 00 80 77 sethi %hi(0x201dc00), %l3
2008f98: c4 04 e0 50 ld [ %l3 + 0x50 ], %g2 ! 201dc50 <_Thread_Maximum_extensions>
if ( !fp_area )
goto failed;
fp_area = _Context_Fp_start( fp_area, 0 );
}
the_thread->fp_context = fp_area;
the_thread->Start.fp_context = fp_area;
2008f9c: c2 26 60 c8 st %g1, [ %i1 + 0xc8 ]
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE );
if ( !fp_area )
goto failed;
fp_area = _Context_Fp_start( fp_area, 0 );
}
the_thread->fp_context = fp_area;
2008fa0: c2 26 61 58 st %g1, [ %i1 + 0x158 ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2008fa4: c0 26 60 50 clr [ %i1 + 0x50 ]
the_watchdog->routine = routine;
2008fa8: c0 26 60 64 clr [ %i1 + 0x64 ]
the_watchdog->id = id;
2008fac: c0 26 60 68 clr [ %i1 + 0x68 ]
#endif
/*
* Allocate the extensions area for this thread
*/
if ( _Thread_Maximum_extensions ) {
2008fb0: 80 a0 a0 00 cmp %g2, 0
2008fb4: 02 bf ff aa be 2008e5c <_Thread_Initialize+0x80>
2008fb8: c0 26 60 6c clr [ %i1 + 0x6c ]
extensions_area = _Workspace_Allocate(
2008fbc: 84 00 a0 01 inc %g2
2008fc0: 40 00 04 b6 call 200a298 <_Workspace_Allocate>
2008fc4: 91 28 a0 02 sll %g2, 2, %o0
(_Thread_Maximum_extensions + 1) * sizeof( void * )
);
if ( !extensions_area )
2008fc8: b6 92 20 00 orcc %o0, 0, %i3
2008fcc: 02 bf ff c3 be 2008ed8 <_Thread_Initialize+0xfc>
2008fd0: c8 04 e0 50 ld [ %l3 + 0x50 ], %g4
goto failed;
}
the_thread->extensions = (void **) extensions_area;
2008fd4: f6 26 61 6c st %i3, [ %i1 + 0x16c ]
2008fd8: 86 10 00 1b mov %i3, %g3
* create the extension long after tasks have been created
* so they cannot rely on the thread create user extension
* call.
*/
if ( the_thread->extensions ) {
for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2008fdc: 84 10 20 00 clr %g2
2008fe0: 10 80 00 03 b 2008fec <_Thread_Initialize+0x210>
2008fe4: 82 10 20 00 clr %g1
2008fe8: c6 06 61 6c ld [ %i1 + 0x16c ], %g3
the_thread->extensions[i] = NULL;
2008fec: 85 28 a0 02 sll %g2, 2, %g2
2008ff0: c0 20 c0 02 clr [ %g3 + %g2 ]
* create the extension long after tasks have been created
* so they cannot rely on the thread create user extension
* call.
*/
if ( the_thread->extensions ) {
for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2008ff4: 82 00 60 01 inc %g1
2008ff8: 80 a1 00 01 cmp %g4, %g1
2008ffc: 1a bf ff fb bcc 2008fe8 <_Thread_Initialize+0x20c>
2009000: 84 10 00 01 mov %g1, %g2
/*
* General initialization
*/
the_thread->Start.is_preemptible = is_preemptible;
the_thread->Start.budget_algorithm = budget_algorithm;
2009004: 10 bf ff 99 b 2008e68 <_Thread_Initialize+0x8c>
2009008: c2 07 a0 60 ld [ %fp + 0x60 ], %g1
0200e128 <_Thread_Reset_timeslice>:
* ready chain
* select heir
*/
void _Thread_Reset_timeslice( void )
{
200e128: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Thread_Control *executing;
Chain_Control *ready;
executing = _Thread_Executing;
200e12c: 03 00 80 77 sethi %hi(0x201dc00), %g1
200e130: e0 00 60 70 ld [ %g1 + 0x70 ], %l0 ! 201dc70 <_Thread_Executing>
ready = executing->ready;
_ISR_Disable( level );
200e134: 7f ff cf dc call 20020a4 <sparc_disable_interrupts>
200e138: e2 04 20 8c ld [ %l0 + 0x8c ], %l1
200e13c: b0 10 00 08 mov %o0, %i0
if ( _Chain_Has_only_one_node( ready ) ) {
200e140: c4 04 40 00 ld [ %l1 ], %g2
200e144: c2 04 60 08 ld [ %l1 + 8 ], %g1
200e148: 80 a0 80 01 cmp %g2, %g1
200e14c: 02 80 00 17 be 200e1a8 <_Thread_Reset_timeslice+0x80>
200e150: 86 04 60 04 add %l1, 4, %g3
)
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
200e154: c2 04 00 00 ld [ %l0 ], %g1
previous = the_node->previous;
200e158: c4 04 20 04 ld [ %l0 + 4 ], %g2
next->previous = previous;
previous->next = next;
200e15c: c2 20 80 00 st %g1, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
200e160: c6 24 00 00 st %g3, [ %l0 ]
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
next->previous = previous;
200e164: c4 20 60 04 st %g2, [ %g1 + 4 ]
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
200e168: c2 04 60 08 ld [ %l1 + 8 ], %g1
the_chain->last = the_node;
200e16c: e0 24 60 08 st %l0, [ %l1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
200e170: c2 24 20 04 st %g1, [ %l0 + 4 ]
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
200e174: e0 20 40 00 st %l0, [ %g1 ]
return;
}
_Chain_Extract_unprotected( &executing->Object.Node );
_Chain_Append_unprotected( ready, &executing->Object.Node );
_ISR_Flash( level );
200e178: 7f ff cf cf call 20020b4 <sparc_enable_interrupts>
200e17c: 01 00 00 00 nop
200e180: 7f ff cf c9 call 20020a4 <sparc_disable_interrupts>
200e184: 01 00 00 00 nop
if ( _Thread_Is_heir( executing ) )
200e188: 03 00 80 77 sethi %hi(0x201dc00), %g1
200e18c: c4 00 60 40 ld [ %g1 + 0x40 ], %g2 ! 201dc40 <_Thread_Heir>
200e190: 80 a4 00 02 cmp %l0, %g2
200e194: 22 80 00 07 be,a 200e1b0 <_Thread_Reset_timeslice+0x88> <== ALWAYS TAKEN
200e198: c4 04 40 00 ld [ %l1 ], %g2
_Thread_Heir = (Thread_Control *) ready->first;
_Context_Switch_necessary = true;
200e19c: 84 10 20 01 mov 1, %g2
200e1a0: 03 00 80 77 sethi %hi(0x201dc00), %g1
200e1a4: c4 28 60 80 stb %g2, [ %g1 + 0x80 ] ! 201dc80 <_Context_Switch_necessary>
_ISR_Enable( level );
200e1a8: 7f ff cf c3 call 20020b4 <sparc_enable_interrupts>
200e1ac: 81 e8 00 00 restore
_Chain_Append_unprotected( ready, &executing->Object.Node );
_ISR_Flash( level );
if ( _Thread_Is_heir( executing ) )
_Thread_Heir = (Thread_Control *) ready->first;
200e1b0: 10 bf ff fb b 200e19c <_Thread_Reset_timeslice+0x74>
200e1b4: c4 20 60 40 st %g2, [ %g1 + 0x40 ]
0200d0a0 <_Thread_Resume>:
void _Thread_Resume(
Thread_Control *the_thread,
bool force
)
{
200d0a0: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
States_Control current_state;
_ISR_Disable( level );
200d0a4: 7f ff d4 50 call 20021e4 <sparc_disable_interrupts>
200d0a8: a0 10 00 18 mov %i0, %l0
200d0ac: b0 10 00 08 mov %o0, %i0
_ISR_Enable( level );
return;
}
#endif
current_state = the_thread->current_state;
200d0b0: c2 04 20 10 ld [ %l0 + 0x10 ], %g1
if ( current_state & STATES_SUSPENDED ) {
200d0b4: 80 88 60 02 btst 2, %g1
200d0b8: 02 80 00 05 be 200d0cc <_Thread_Resume+0x2c> <== NEVER TAKEN
200d0bc: 82 08 7f fd and %g1, -3, %g1
current_state =
the_thread->current_state = _States_Clear(STATES_SUSPENDED, current_state);
if ( _States_Is_ready( current_state ) ) {
200d0c0: 80 a0 60 00 cmp %g1, 0
200d0c4: 02 80 00 04 be 200d0d4 <_Thread_Resume+0x34>
200d0c8: c2 24 20 10 st %g1, [ %l0 + 0x10 ]
_Context_Switch_necessary = true;
}
}
}
_ISR_Enable( level );
200d0cc: 7f ff d4 4a call 20021f4 <sparc_enable_interrupts>
200d0d0: 81 e8 00 00 restore
RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map (
Priority_Information *the_priority_map
)
{
*the_priority_map->minor |= the_priority_map->ready_minor;
200d0d4: c4 04 20 90 ld [ %l0 + 0x90 ], %g2
if ( _States_Is_ready( current_state ) ) {
_Priority_Add_to_bit_map( &the_thread->Priority_map );
_Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node);
200d0d8: c2 04 20 8c ld [ %l0 + 0x8c ], %g1
200d0dc: c8 10 80 00 lduh [ %g2 ], %g4
200d0e0: c6 14 20 96 lduh [ %l0 + 0x96 ], %g3
200d0e4: 86 11 00 03 or %g4, %g3, %g3
200d0e8: c6 30 80 00 sth %g3, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
200d0ec: 84 00 60 04 add %g1, 4, %g2
_Priority_Major_bit_map |= the_priority_map->ready_major;
200d0f0: c8 14 20 94 lduh [ %l0 + 0x94 ], %g4
200d0f4: c4 24 00 00 st %g2, [ %l0 ]
200d0f8: 07 00 80 86 sethi %hi(0x2021800), %g3
old_last_node = the_chain->last;
200d0fc: c4 00 60 08 ld [ %g1 + 8 ], %g2
200d100: da 10 e1 f4 lduh [ %g3 + 0x1f4 ], %o5
the_chain->last = the_node;
200d104: e0 20 60 08 st %l0, [ %g1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
200d108: c4 24 20 04 st %g2, [ %l0 + 4 ]
200d10c: 82 13 40 04 or %o5, %g4, %g1
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
200d110: e0 20 80 00 st %l0, [ %g2 ]
200d114: c2 30 e1 f4 sth %g1, [ %g3 + 0x1f4 ]
_ISR_Flash( level );
200d118: 7f ff d4 37 call 20021f4 <sparc_enable_interrupts>
200d11c: 01 00 00 00 nop
200d120: 7f ff d4 31 call 20021e4 <sparc_disable_interrupts>
200d124: 01 00 00 00 nop
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
200d128: 03 00 80 86 sethi %hi(0x2021800), %g1
200d12c: c6 00 61 d0 ld [ %g1 + 0x1d0 ], %g3 ! 20219d0 <_Thread_Heir>
200d130: c4 04 20 14 ld [ %l0 + 0x14 ], %g2
200d134: c6 00 e0 14 ld [ %g3 + 0x14 ], %g3
200d138: 80 a0 80 03 cmp %g2, %g3
200d13c: 1a bf ff e4 bcc 200d0cc <_Thread_Resume+0x2c>
200d140: 07 00 80 86 sethi %hi(0x2021800), %g3
_Thread_Heir = the_thread;
if ( _Thread_Executing->is_preemptible ||
200d144: c6 00 e2 00 ld [ %g3 + 0x200 ], %g3 ! 2021a00 <_Thread_Executing>
_Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node);
_ISR_Flash( level );
if ( the_thread->current_priority < _Thread_Heir->current_priority ) {
_Thread_Heir = the_thread;
200d148: e0 20 61 d0 st %l0, [ %g1 + 0x1d0 ]
if ( _Thread_Executing->is_preemptible ||
200d14c: c2 08 e0 75 ldub [ %g3 + 0x75 ], %g1
200d150: 80 a0 60 00 cmp %g1, 0
200d154: 32 80 00 05 bne,a 200d168 <_Thread_Resume+0xc8>
200d158: 84 10 20 01 mov 1, %g2
200d15c: 80 a0 a0 00 cmp %g2, 0
200d160: 12 bf ff db bne 200d0cc <_Thread_Resume+0x2c> <== ALWAYS TAKEN
200d164: 84 10 20 01 mov 1, %g2
the_thread->current_priority == 0 )
_Context_Switch_necessary = true;
200d168: 03 00 80 86 sethi %hi(0x2021800), %g1
200d16c: c4 28 62 10 stb %g2, [ %g1 + 0x210 ] ! 2021a10 <_Context_Switch_necessary>
}
}
}
_ISR_Enable( level );
200d170: 7f ff d4 21 call 20021f4 <sparc_enable_interrupts>
200d174: 81 e8 00 00 restore
02009ad8 <_Thread_Yield_processor>:
* ready chain
* select heir
*/
void _Thread_Yield_processor( void )
{
2009ad8: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Thread_Control *executing;
Chain_Control *ready;
executing = _Thread_Executing;
2009adc: 03 00 80 77 sethi %hi(0x201dc00), %g1
2009ae0: e0 00 60 70 ld [ %g1 + 0x70 ], %l0 ! 201dc70 <_Thread_Executing>
ready = executing->ready;
_ISR_Disable( level );
2009ae4: 7f ff e1 70 call 20020a4 <sparc_disable_interrupts>
2009ae8: e2 04 20 8c ld [ %l0 + 0x8c ], %l1
2009aec: b0 10 00 08 mov %o0, %i0
if ( !_Chain_Has_only_one_node( ready ) ) {
2009af0: c4 04 40 00 ld [ %l1 ], %g2
2009af4: c2 04 60 08 ld [ %l1 + 8 ], %g1
2009af8: 80 a0 80 01 cmp %g2, %g1
2009afc: 02 80 00 19 be 2009b60 <_Thread_Yield_processor+0x88>
2009b00: 86 04 60 04 add %l1, 4, %g3
)
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
2009b04: c2 04 00 00 ld [ %l0 ], %g1
previous = the_node->previous;
2009b08: c4 04 20 04 ld [ %l0 + 4 ], %g2
next->previous = previous;
previous->next = next;
2009b0c: c2 20 80 00 st %g1, [ %g2 ]
Chain_Node *the_node
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
2009b10: c6 24 00 00 st %g3, [ %l0 ]
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
next->previous = previous;
2009b14: c4 20 60 04 st %g2, [ %g1 + 4 ]
)
{
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
2009b18: c2 04 60 08 ld [ %l1 + 8 ], %g1
the_chain->last = the_node;
2009b1c: e0 24 60 08 st %l0, [ %l1 + 8 ]
old_last_node->next = the_node;
the_node->previous = old_last_node;
2009b20: c2 24 20 04 st %g1, [ %l0 + 4 ]
Chain_Node *old_last_node;
the_node->next = _Chain_Tail(the_chain);
old_last_node = the_chain->last;
the_chain->last = the_node;
old_last_node->next = the_node;
2009b24: e0 20 40 00 st %l0, [ %g1 ]
_Chain_Extract_unprotected( &executing->Object.Node );
_Chain_Append_unprotected( ready, &executing->Object.Node );
_ISR_Flash( level );
2009b28: 7f ff e1 63 call 20020b4 <sparc_enable_interrupts>
2009b2c: 01 00 00 00 nop
2009b30: 7f ff e1 5d call 20020a4 <sparc_disable_interrupts>
2009b34: 01 00 00 00 nop
if ( _Thread_Is_heir( executing ) )
2009b38: 03 00 80 77 sethi %hi(0x201dc00), %g1
2009b3c: c4 00 60 40 ld [ %g1 + 0x40 ], %g2 ! 201dc40 <_Thread_Heir>
2009b40: 80 a4 00 02 cmp %l0, %g2
2009b44: 22 80 00 0e be,a 2009b7c <_Thread_Yield_processor+0xa4> <== ALWAYS TAKEN
2009b48: c4 04 40 00 ld [ %l1 ], %g2
_Thread_Heir = (Thread_Control *) ready->first;
_Context_Switch_necessary = true;
}
else if ( !_Thread_Is_heir( executing ) )
_Context_Switch_necessary = true;
2009b4c: 84 10 20 01 mov 1, %g2
2009b50: 03 00 80 77 sethi %hi(0x201dc00), %g1
2009b54: c4 28 60 80 stb %g2, [ %g1 + 0x80 ] ! 201dc80 <_Context_Switch_necessary>
_ISR_Enable( level );
2009b58: 7f ff e1 57 call 20020b4 <sparc_enable_interrupts>
2009b5c: 81 e8 00 00 restore
if ( _Thread_Is_heir( executing ) )
_Thread_Heir = (Thread_Control *) ready->first;
_Context_Switch_necessary = true;
}
else if ( !_Thread_Is_heir( executing ) )
2009b60: 03 00 80 77 sethi %hi(0x201dc00), %g1
2009b64: c2 00 60 40 ld [ %g1 + 0x40 ], %g1 ! 201dc40 <_Thread_Heir>
2009b68: 80 a4 00 01 cmp %l0, %g1
2009b6c: 32 bf ff f9 bne,a 2009b50 <_Thread_Yield_processor+0x78> <== NEVER TAKEN
2009b70: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED
_Context_Switch_necessary = true;
_ISR_Enable( level );
2009b74: 7f ff e1 50 call 20020b4 <sparc_enable_interrupts>
2009b78: 81 e8 00 00 restore
_Chain_Append_unprotected( ready, &executing->Object.Node );
_ISR_Flash( level );
if ( _Thread_Is_heir( executing ) )
_Thread_Heir = (Thread_Control *) ready->first;
2009b7c: 10 bf ff f4 b 2009b4c <_Thread_Yield_processor+0x74>
2009b80: c4 20 60 40 st %g2, [ %g1 + 0x40 ]
0200932c <_Thread_queue_Enqueue_priority>:
Thread_blocking_operation_States _Thread_queue_Enqueue_priority (
Thread_queue_Control *the_thread_queue,
Thread_Control *the_thread,
ISR_Level *level_p
)
{
200932c: 9d e3 bf a0 save %sp, -96, %sp
Priority_Control priority;
States_Control block_state;
_Chain_Initialize_empty( &the_thread->Wait.Block2n );
priority = the_thread->current_priority;
2009330: e0 06 60 14 ld [ %i1 + 0x14 ], %l0
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2009334: 82 06 60 3c add %i1, 0x3c, %g1
the_chain->permanent_null = NULL;
2009338: c0 26 60 3c clr [ %i1 + 0x3c ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
200933c: c2 26 60 38 st %g1, [ %i1 + 0x38 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2009340: 82 06 60 38 add %i1, 0x38, %g1
2009344: c2 26 60 40 st %g1, [ %i1 + 0x40 ]
2009348: 2d 00 80 74 sethi %hi(0x201d000), %l6
header_index = _Thread_queue_Header_number( priority );
header = &the_thread_queue->Queues.Priority[ header_index ];
200934c: 83 34 20 06 srl %l0, 6, %g1
block_state = the_thread_queue->state;
if ( _Thread_queue_Is_reverse_search( priority ) )
2009350: 80 8c 20 20 btst 0x20, %l0
_Chain_Initialize_empty( &the_thread->Wait.Block2n );
priority = the_thread->current_priority;
header_index = _Thread_queue_Header_number( priority );
header = &the_thread_queue->Queues.Priority[ header_index ];
2009354: ab 28 60 04 sll %g1, 4, %l5
2009358: ac 15 a0 f4 or %l6, 0xf4, %l6
200935c: 83 28 60 02 sll %g1, 2, %g1
block_state = the_thread_queue->state;
2009360: e8 06 20 38 ld [ %i0 + 0x38 ], %l4
_Chain_Initialize_empty( &the_thread->Wait.Block2n );
priority = the_thread->current_priority;
header_index = _Thread_queue_Header_number( priority );
header = &the_thread_queue->Queues.Priority[ header_index ];
2009364: aa 25 40 01 sub %l5, %g1, %l5
block_state = the_thread_queue->state;
if ( _Thread_queue_Is_reverse_search( priority ) )
2009368: 12 80 00 24 bne 20093f8 <_Thread_queue_Enqueue_priority+0xcc>
200936c: aa 06 00 15 add %i0, %l5, %l5
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2009370: ac 05 60 04 add %l5, 4, %l6
goto restart_reverse_search;
restart_forward_search:
search_priority = PRIORITY_MINIMUM - 1;
_ISR_Disable( level );
2009374: 7f ff e3 4c call 20020a4 <sparc_disable_interrupts>
2009378: 01 00 00 00 nop
200937c: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->first;
2009380: c2 05 40 00 ld [ %l5 ], %g1
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
2009384: 80 a0 40 16 cmp %g1, %l6
2009388: 02 80 00 3a be 2009470 <_Thread_queue_Enqueue_priority+0x144>
200938c: a2 10 00 01 mov %g1, %l1
search_priority = search_thread->current_priority;
2009390: e6 00 60 14 ld [ %g1 + 0x14 ], %l3
if ( priority <= search_priority )
2009394: 80 a4 00 13 cmp %l0, %l3
2009398: 18 80 00 0b bgu 20093c4 <_Thread_queue_Enqueue_priority+0x98>
200939c: 01 00 00 00 nop
}
search_thread =
(Thread_Control *)search_thread->Object.Node.next;
}
if ( the_thread_queue->sync_state !=
20093a0: 10 80 00 36 b 2009478 <_Thread_queue_Enqueue_priority+0x14c>
20093a4: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
restart_forward_search:
search_priority = PRIORITY_MINIMUM - 1;
_ISR_Disable( level );
search_thread = (Thread_Control *) header->first;
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
20093a8: 80 a4 40 16 cmp %l1, %l6
20093ac: 02 80 00 32 be 2009474 <_Thread_queue_Enqueue_priority+0x148>
20093b0: 82 10 00 11 mov %l1, %g1
search_priority = search_thread->current_priority;
20093b4: e6 04 60 14 ld [ %l1 + 0x14 ], %l3
if ( priority <= search_priority )
20093b8: 80 a4 00 13 cmp %l0, %l3
20093bc: 28 80 00 2f bleu,a 2009478 <_Thread_queue_Enqueue_priority+0x14c>
20093c0: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
break;
search_priority = search_thread->current_priority;
if ( priority <= search_priority )
break;
#endif
_ISR_Flash( level );
20093c4: 7f ff e3 3c call 20020b4 <sparc_enable_interrupts>
20093c8: 90 10 00 12 mov %l2, %o0
20093cc: 7f ff e3 36 call 20020a4 <sparc_disable_interrupts>
20093d0: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
20093d4: c2 04 60 10 ld [ %l1 + 0x10 ], %g1
20093d8: 80 8d 00 01 btst %l4, %g1
20093dc: 32 bf ff f3 bne,a 20093a8 <_Thread_queue_Enqueue_priority+0x7c><== ALWAYS TAKEN
20093e0: e2 04 40 00 ld [ %l1 ], %l1
_ISR_Enable( level );
20093e4: 7f ff e3 34 call 20020b4 <sparc_enable_interrupts> <== NOT EXECUTED
20093e8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
goto restart_forward_search;
20093ec: 30 bf ff e2 b,a 2009374 <_Thread_queue_Enqueue_priority+0x48><== NOT EXECUTED
if ( priority >= search_priority )
break;
#endif
_ISR_Flash( level );
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
_ISR_Enable( level );
20093f0: 7f ff e3 31 call 20020b4 <sparc_enable_interrupts>
20093f4: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
_ISR_Disable( level );
20093f8: 7f ff e3 2b call 20020a4 <sparc_disable_interrupts>
20093fc: e6 0d 80 00 ldub [ %l6 ], %l3
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
2009400: a6 04 e0 01 inc %l3
_ISR_Disable( level );
2009404: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->last;
2009408: c2 05 60 08 ld [ %l5 + 8 ], %g1
while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
200940c: 80 a0 40 15 cmp %g1, %l5
2009410: 02 80 00 20 be 2009490 <_Thread_queue_Enqueue_priority+0x164>
2009414: a2 10 00 01 mov %g1, %l1
search_priority = search_thread->current_priority;
2009418: e6 00 60 14 ld [ %g1 + 0x14 ], %l3
if ( priority >= search_priority )
200941c: 80 a4 00 13 cmp %l0, %l3
2009420: 0a 80 00 0b bcs 200944c <_Thread_queue_Enqueue_priority+0x120>
2009424: 01 00 00 00 nop
}
search_thread = (Thread_Control *)
search_thread->Object.Node.previous;
}
if ( the_thread_queue->sync_state !=
2009428: 10 80 00 1b b 2009494 <_Thread_queue_Enqueue_priority+0x168>
200942c: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
restart_reverse_search:
search_priority = PRIORITY_MAXIMUM + 1;
_ISR_Disable( level );
search_thread = (Thread_Control *) header->last;
while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
2009430: 80 a4 40 15 cmp %l1, %l5
2009434: 02 80 00 17 be 2009490 <_Thread_queue_Enqueue_priority+0x164>
2009438: 82 10 00 11 mov %l1, %g1
search_priority = search_thread->current_priority;
200943c: e6 04 60 14 ld [ %l1 + 0x14 ], %l3
if ( priority >= search_priority )
2009440: 80 a4 00 13 cmp %l0, %l3
2009444: 3a 80 00 14 bcc,a 2009494 <_Thread_queue_Enqueue_priority+0x168>
2009448: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
break;
search_priority = search_thread->current_priority;
if ( priority >= search_priority )
break;
#endif
_ISR_Flash( level );
200944c: 7f ff e3 1a call 20020b4 <sparc_enable_interrupts>
2009450: 90 10 00 12 mov %l2, %o0
2009454: 7f ff e3 14 call 20020a4 <sparc_disable_interrupts>
2009458: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
200945c: c2 04 60 10 ld [ %l1 + 0x10 ], %g1
2009460: 80 8d 00 01 btst %l4, %g1
2009464: 32 bf ff f3 bne,a 2009430 <_Thread_queue_Enqueue_priority+0x104>
2009468: e2 04 60 04 ld [ %l1 + 4 ], %l1
200946c: 30 bf ff e1 b,a 20093f0 <_Thread_queue_Enqueue_priority+0xc4>
restart_forward_search:
search_priority = PRIORITY_MINIMUM - 1;
_ISR_Disable( level );
search_thread = (Thread_Control *) header->first;
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
2009470: a6 10 3f ff mov -1, %l3
}
search_thread =
(Thread_Control *)search_thread->Object.Node.next;
}
if ( the_thread_queue->sync_state !=
2009474: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
2009478: 80 a0 a0 01 cmp %g2, 1
200947c: 02 80 00 17 be 20094d8 <_Thread_queue_Enqueue_priority+0x1ac>
2009480: 80 a4 00 13 cmp %l0, %l3
* For example, the blocking thread could have been given
* the mutex by an ISR or timed out.
*
* WARNING! Returning with interrupts disabled!
*/
*level_p = level;
2009484: e4 26 80 00 st %l2, [ %i2 ]
return the_thread_queue->sync_state;
}
2009488: 81 c7 e0 08 ret
200948c: 91 e8 00 02 restore %g0, %g2, %o0
}
search_thread = (Thread_Control *)
search_thread->Object.Node.previous;
}
if ( the_thread_queue->sync_state !=
2009490: c4 06 20 30 ld [ %i0 + 0x30 ], %g2
2009494: 80 a0 a0 01 cmp %g2, 1
2009498: 32 bf ff fc bne,a 2009488 <_Thread_queue_Enqueue_priority+0x15c>
200949c: e4 26 80 00 st %l2, [ %i2 ]
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
if ( priority == search_priority )
20094a0: 80 a4 00 13 cmp %l0, %l3
20094a4: 02 80 00 1a be 200950c <_Thread_queue_Enqueue_priority+0x1e0>
20094a8: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority;
search_node = (Chain_Node *) search_thread;
next_node = search_node->next;
20094ac: c4 00 40 00 ld [ %g1 ], %g2
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
the_node->previous = search_node;
20094b0: c2 26 60 04 st %g1, [ %i1 + 4 ]
search_node = (Chain_Node *) search_thread;
next_node = search_node->next;
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
20094b4: c4 26 40 00 st %g2, [ %i1 ]
the_node->previous = search_node;
search_node->next = the_node;
next_node->previous = the_node;
the_thread->Wait.queue = the_thread_queue;
20094b8: f0 26 60 44 st %i0, [ %i1 + 0x44 ]
next_node = search_node->next;
the_node = (Chain_Node *) the_thread;
the_node->next = next_node;
the_node->previous = search_node;
search_node->next = the_node;
20094bc: f2 20 40 00 st %i1, [ %g1 ]
next_node->previous = the_node;
20094c0: f2 20 a0 04 st %i1, [ %g2 + 4 ]
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
20094c4: b0 10 20 01 mov 1, %i0
20094c8: 7f ff e2 fb call 20020b4 <sparc_enable_interrupts>
20094cc: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
20094d0: 81 c7 e0 08 ret
20094d4: 81 e8 00 00 restore
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED )
goto synchronize;
the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED;
if ( priority == search_priority )
20094d8: 02 80 00 0d be 200950c <_Thread_queue_Enqueue_priority+0x1e0>
20094dc: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority;
search_node = (Chain_Node *) search_thread;
previous_node = search_node->previous;
20094e0: c4 00 60 04 ld [ %g1 + 4 ], %g2
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
20094e4: c2 26 40 00 st %g1, [ %i1 ]
the_node->previous = previous_node;
20094e8: c4 26 60 04 st %g2, [ %i1 + 4 ]
previous_node->next = the_node;
search_node->previous = the_node;
the_thread->Wait.queue = the_thread_queue;
20094ec: f0 26 60 44 st %i0, [ %i1 + 0x44 ]
previous_node = search_node->previous;
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
the_node->previous = previous_node;
previous_node->next = the_node;
20094f0: f2 20 80 00 st %i1, [ %g2 ]
search_node->previous = the_node;
20094f4: f2 20 60 04 st %i1, [ %g1 + 4 ]
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
20094f8: b0 10 20 01 mov 1, %i0
20094fc: 7f ff e2 ee call 20020b4 <sparc_enable_interrupts>
2009500: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2009504: 81 c7 e0 08 ret
2009508: 81 e8 00 00 restore
200950c: a2 04 60 3c add %l1, 0x3c, %l1
_ISR_Enable( level );
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
equal_priority: /* add at end of priority group */
search_node = _Chain_Tail( &search_thread->Wait.Block2n );
previous_node = search_node->previous;
2009510: c2 04 60 04 ld [ %l1 + 4 ], %g1
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
2009514: e2 26 40 00 st %l1, [ %i1 ]
the_node->previous = previous_node;
2009518: c2 26 60 04 st %g1, [ %i1 + 4 ]
previous_node->next = the_node;
search_node->previous = the_node;
the_thread->Wait.queue = the_thread_queue;
200951c: f0 26 60 44 st %i0, [ %i1 + 0x44 ]
previous_node = search_node->previous;
the_node = (Chain_Node *) the_thread;
the_node->next = search_node;
the_node->previous = previous_node;
previous_node->next = the_node;
2009520: f2 20 40 00 st %i1, [ %g1 ]
search_node->previous = the_node;
2009524: f2 24 60 04 st %i1, [ %l1 + 4 ]
the_thread->Wait.queue = the_thread_queue;
_ISR_Enable( level );
2009528: b0 10 20 01 mov 1, %i0
200952c: 7f ff e2 e2 call 20020b4 <sparc_enable_interrupts>
2009530: 90 10 00 12 mov %l2, %o0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2009534: 81 c7 e0 08 ret
2009538: 81 e8 00 00 restore
020095e8 <_Thread_queue_Requeue>:
void _Thread_queue_Requeue(
Thread_queue_Control *the_thread_queue,
Thread_Control *the_thread
)
{
20095e8: 9d e3 bf 98 save %sp, -104, %sp
/*
* Just in case the thread really wasn't blocked on a thread queue
* when we get here.
*/
if ( !the_thread_queue )
20095ec: 80 a6 20 00 cmp %i0, 0
20095f0: 02 80 00 13 be 200963c <_Thread_queue_Requeue+0x54> <== NEVER TAKEN
20095f4: 01 00 00 00 nop
/*
* If queueing by FIFO, there is nothing to do. This only applies to
* priority blocking discipline.
*/
if ( the_thread_queue->discipline == THREAD_QUEUE_DISCIPLINE_PRIORITY ) {
20095f8: e2 06 20 34 ld [ %i0 + 0x34 ], %l1
20095fc: 80 a4 60 01 cmp %l1, 1
2009600: 02 80 00 04 be 2009610 <_Thread_queue_Requeue+0x28> <== ALWAYS TAKEN
2009604: 01 00 00 00 nop
2009608: 81 c7 e0 08 ret <== NOT EXECUTED
200960c: 81 e8 00 00 restore <== NOT EXECUTED
Thread_queue_Control *tq = the_thread_queue;
ISR_Level level;
ISR_Level level_ignored;
_ISR_Disable( level );
2009610: 7f ff e2 a5 call 20020a4 <sparc_disable_interrupts>
2009614: 01 00 00 00 nop
2009618: a0 10 00 08 mov %o0, %l0
if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
200961c: c4 06 60 10 ld [ %i1 + 0x10 ], %g2
2009620: 03 00 00 ef sethi %hi(0x3bc00), %g1
2009624: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 <PROM_START+0x3bee0>
2009628: 80 88 80 01 btst %g2, %g1
200962c: 12 80 00 06 bne 2009644 <_Thread_queue_Requeue+0x5c> <== ALWAYS TAKEN
2009630: 90 10 00 18 mov %i0, %o0
_Thread_queue_Enter_critical_section( tq );
_Thread_queue_Extract_priority_helper( tq, the_thread, true );
(void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored );
}
_ISR_Enable( level );
2009634: 7f ff e2 a0 call 20020b4 <sparc_enable_interrupts>
2009638: 90 10 00 10 mov %l0, %o0
200963c: 81 c7 e0 08 ret
2009640: 81 e8 00 00 restore
ISR_Level level_ignored;
_ISR_Disable( level );
if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) {
_Thread_queue_Enter_critical_section( tq );
_Thread_queue_Extract_priority_helper( tq, the_thread, true );
2009644: 92 10 00 19 mov %i1, %o1
2009648: e2 26 20 30 st %l1, [ %i0 + 0x30 ]
200964c: 40 00 12 17 call 200dea8 <_Thread_queue_Extract_priority_helper>
2009650: 94 10 20 01 mov 1, %o2
(void) _Thread_queue_Enqueue_priority( tq, the_thread, &level_ignored );
2009654: 90 10 00 18 mov %i0, %o0
2009658: 92 10 00 19 mov %i1, %o1
200965c: 7f ff ff 34 call 200932c <_Thread_queue_Enqueue_priority>
2009660: 94 07 bf fc add %fp, -4, %o2
2009664: 30 bf ff f4 b,a 2009634 <_Thread_queue_Requeue+0x4c>
02009668 <_Thread_queue_Timeout>:
void _Thread_queue_Timeout(
Objects_Id id,
void *ignored __attribute__((unused))
)
{
2009668: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
the_thread = _Thread_Get( id, &location );
200966c: 90 10 00 18 mov %i0, %o0
2009670: 7f ff fd b0 call 2008d30 <_Thread_Get>
2009674: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2009678: c2 07 bf fc ld [ %fp + -4 ], %g1
200967c: 80 a0 60 00 cmp %g1, 0
2009680: 12 80 00 08 bne 20096a0 <_Thread_queue_Timeout+0x38> <== NEVER TAKEN
2009684: 01 00 00 00 nop
#if defined(RTEMS_MULTIPROCESSING)
case OBJECTS_REMOTE: /* impossible */
#endif
break;
case OBJECTS_LOCAL:
_Thread_queue_Process_timeout( the_thread );
2009688: 40 00 12 41 call 200df8c <_Thread_queue_Process_timeout>
200968c: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void )
{
RTEMS_COMPILER_MEMORY_BARRIER();
_Thread_Dispatch_disable_level -= 1;
2009690: 03 00 80 76 sethi %hi(0x201d800), %g1
2009694: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201dbb0 <_Thread_Dispatch_disable_level>
2009698: 84 00 bf ff add %g2, -1, %g2
200969c: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
20096a0: 81 c7 e0 08 ret
20096a4: 81 e8 00 00 restore
020012e0 <_Timer_Manager_initialization>:
#include <rtems/rtems/types.h>
#include <rtems/rtems/timer.h>
void _Timer_Manager_initialization(void)
{
}
20012e0: 81 c3 e0 08 retl
02016f7c <_Timer_server_Body>:
* @a arg points to the corresponding timer server control block.
*/
static rtems_task _Timer_server_Body(
rtems_task_argument arg
)
{
2016f7c: 9d e3 bf 88 save %sp, -120, %sp
2016f80: 2d 00 80 fd sethi %hi(0x203f400), %l6
2016f84: ba 07 bf f4 add %fp, -12, %i5
2016f88: a8 07 bf f8 add %fp, -8, %l4
2016f8c: a4 07 bf e8 add %fp, -24, %l2
2016f90: ae 07 bf ec add %fp, -20, %l7
2016f94: 2b 00 80 fd sethi %hi(0x203f400), %l5
2016f98: 39 00 80 fc sethi %hi(0x203f000), %i4
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2016f9c: c0 27 bf f8 clr [ %fp + -8 ]
2016fa0: c0 27 bf ec clr [ %fp + -20 ]
the_chain->last = _Chain_Head(the_chain);
2016fa4: fa 27 bf fc st %i5, [ %fp + -4 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2016fa8: e8 27 bf f4 st %l4, [ %fp + -12 ]
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2016fac: e4 27 bf f0 st %l2, [ %fp + -16 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2016fb0: ee 27 bf e8 st %l7, [ %fp + -24 ]
2016fb4: ac 15 a0 d4 or %l6, 0xd4, %l6
2016fb8: aa 15 60 14 or %l5, 0x14, %l5
2016fbc: b8 17 23 80 or %i4, 0x380, %i4
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fc0: a2 06 20 30 add %i0, 0x30, %l1
/*
* This path is for normal forward movement and cases where the
* TOD has been set forward.
*/
delta = snapshot - last_snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fc4: a6 06 20 68 add %i0, 0x68, %l3
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2016fc8: b2 06 20 08 add %i0, 8, %i1
static void _Timer_server_Stop_tod_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
2016fcc: b4 06 20 40 add %i0, 0x40, %i2
_Thread_Set_state( ts->thread, STATES_DELAYING );
_Timer_server_Reset_interval_system_watchdog( ts );
_Timer_server_Reset_tod_system_watchdog( ts );
_Thread_Enable_dispatch();
ts->active = true;
2016fd0: b6 10 20 01 mov 1, %i3
{
/*
* Afterwards all timer inserts are directed to this chain and the interval
* and TOD chains will be no more modified by other parties.
*/
ts->insert_chain = insert_chain;
2016fd4: fa 26 20 78 st %i5, [ %i0 + 0x78 ]
static void _Timer_server_Process_interval_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
2016fd8: c2 05 80 00 ld [ %l6 ], %g1
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
2016fdc: d2 06 20 3c ld [ %i0 + 0x3c ], %o1
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fe0: 90 10 00 11 mov %l1, %o0
2016fe4: 92 20 40 09 sub %g1, %o1, %o1
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
2016fe8: c2 26 20 3c st %g1, [ %i0 + 0x3c ]
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2016fec: 40 00 12 22 call 201b874 <_Watchdog_Adjust_to_chain>
2016ff0: 94 10 00 12 mov %l2, %o2
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
2016ff4: d2 06 20 74 ld [ %i0 + 0x74 ], %o1
static void _Timer_server_Process_tod_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
2016ff8: e0 05 40 00 ld [ %l5 ], %l0
/*
* Process the seconds chain. Start by checking that the Time
* of Day (TOD) has not been set backwards. If it has then
* we want to adjust the watchdogs->Chain to indicate this.
*/
if ( snapshot > last_snapshot ) {
2016ffc: 80 a4 00 09 cmp %l0, %o1
2017000: 38 80 00 2f bgu,a 20170bc <_Timer_server_Body+0x140>
2017004: 92 24 00 09 sub %l0, %o1, %o1
* TOD has been set forward.
*/
delta = snapshot - last_snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
} else if ( snapshot < last_snapshot ) {
2017008: 80 a4 00 09 cmp %l0, %o1
201700c: 0a 80 00 30 bcs 20170cc <_Timer_server_Body+0x150>
2017010: 94 22 40 10 sub %o1, %l0, %o2
*/
delta = last_snapshot - snapshot;
_Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta );
}
watchdogs->last_snapshot = snapshot;
2017014: e0 26 20 74 st %l0, [ %i0 + 0x74 ]
}
static void _Timer_server_Process_insertions( Timer_server_Control *ts )
{
while ( true ) {
Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
2017018: d0 06 20 78 ld [ %i0 + 0x78 ], %o0
201701c: 40 00 02 94 call 2017a6c <_Chain_Get>
2017020: 01 00 00 00 nop
if ( timer == NULL ) {
2017024: 80 a2 20 00 cmp %o0, 0
2017028: 02 80 00 10 be 2017068 <_Timer_server_Body+0xec>
201702c: 01 00 00 00 nop
static void _Timer_server_Insert_timer(
Timer_server_Control *ts,
Timer_Control *timer
)
{
if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
2017030: c2 02 20 38 ld [ %o0 + 0x38 ], %g1
2017034: 80 a0 60 01 cmp %g1, 1
2017038: 02 80 00 29 be 20170dc <_Timer_server_Body+0x160>
201703c: 80 a0 60 03 cmp %g1, 3
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
} else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) {
2017040: 12 bf ff f6 bne 2017018 <_Timer_server_Body+0x9c> <== NEVER TAKEN
2017044: 92 02 20 10 add %o0, 0x10, %o1
_Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
2017048: 40 00 12 41 call 201b94c <_Watchdog_Insert>
201704c: 90 10 00 13 mov %l3, %o0
}
static void _Timer_server_Process_insertions( Timer_server_Control *ts )
{
while ( true ) {
Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
2017050: d0 06 20 78 ld [ %i0 + 0x78 ], %o0
2017054: 40 00 02 86 call 2017a6c <_Chain_Get>
2017058: 01 00 00 00 nop
if ( timer == NULL ) {
201705c: 80 a2 20 00 cmp %o0, 0
2017060: 32 bf ff f5 bne,a 2017034 <_Timer_server_Body+0xb8> <== NEVER TAKEN
2017064: c2 02 20 38 ld [ %o0 + 0x38 ], %g1 <== NOT EXECUTED
* of zero it will be processed in the next iteration of the timer server
* body loop.
*/
_Timer_server_Process_insertions( ts );
_ISR_Disable( level );
2017068: 7f ff e0 f4 call 200f438 <sparc_disable_interrupts>
201706c: 01 00 00 00 nop
if ( _Chain_Is_empty( insert_chain ) ) {
2017070: c2 07 bf f4 ld [ %fp + -12 ], %g1
2017074: 80 a5 00 01 cmp %l4, %g1
2017078: 02 80 00 1d be 20170ec <_Timer_server_Body+0x170> <== ALWAYS TAKEN
201707c: 01 00 00 00 nop
ts->insert_chain = NULL;
_ISR_Enable( level );
break;
} else {
_ISR_Enable( level );
2017080: 7f ff e0 f2 call 200f448 <sparc_enable_interrupts> <== NOT EXECUTED
2017084: 01 00 00 00 nop <== NOT EXECUTED
static void _Timer_server_Process_interval_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
2017088: c2 05 80 00 ld [ %l6 ], %g1 <== NOT EXECUTED
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
201708c: d2 06 20 3c ld [ %i0 + 0x3c ], %o1 <== NOT EXECUTED
watchdogs->last_snapshot = snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2017090: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED
2017094: 92 20 40 09 sub %g1, %o1, %o1 <== NOT EXECUTED
/*
* We assume adequate unsigned arithmetic here.
*/
Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
watchdogs->last_snapshot = snapshot;
2017098: c2 26 20 3c st %g1, [ %i0 + 0x3c ] <== NOT EXECUTED
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
201709c: 40 00 11 f6 call 201b874 <_Watchdog_Adjust_to_chain> <== NOT EXECUTED
20170a0: 94 10 00 12 mov %l2, %o2 <== NOT EXECUTED
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
20170a4: d2 06 20 74 ld [ %i0 + 0x74 ], %o1 <== NOT EXECUTED
static void _Timer_server_Process_tod_watchdogs(
Timer_server_Watchdogs *watchdogs,
Chain_Control *fire_chain
)
{
Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
20170a8: e0 05 40 00 ld [ %l5 ], %l0 <== NOT EXECUTED
/*
* Process the seconds chain. Start by checking that the Time
* of Day (TOD) has not been set backwards. If it has then
* we want to adjust the watchdogs->Chain to indicate this.
*/
if ( snapshot > last_snapshot ) {
20170ac: 80 a4 00 09 cmp %l0, %o1 <== NOT EXECUTED
20170b0: 08 bf ff d7 bleu 201700c <_Timer_server_Body+0x90> <== NOT EXECUTED
20170b4: 01 00 00 00 nop <== NOT EXECUTED
/*
* This path is for normal forward movement and cases where the
* TOD has been set forward.
*/
delta = snapshot - last_snapshot;
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20170b8: 92 24 00 09 sub %l0, %o1, %o1 <== NOT EXECUTED
20170bc: 90 10 00 13 mov %l3, %o0
20170c0: 40 00 11 ed call 201b874 <_Watchdog_Adjust_to_chain>
20170c4: 94 10 00 12 mov %l2, %o2
20170c8: 30 bf ff d3 b,a 2017014 <_Timer_server_Body+0x98>
/*
* The current TOD is before the last TOD which indicates that
* TOD has been set backwards.
*/
delta = last_snapshot - snapshot;
_Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta );
20170cc: 90 10 00 13 mov %l3, %o0
20170d0: 40 00 11 b9 call 201b7b4 <_Watchdog_Adjust>
20170d4: 92 10 20 01 mov 1, %o1
20170d8: 30 bf ff cf b,a 2017014 <_Timer_server_Body+0x98>
Timer_server_Control *ts,
Timer_Control *timer
)
{
if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
20170dc: 92 02 20 10 add %o0, 0x10, %o1
20170e0: 40 00 12 1b call 201b94c <_Watchdog_Insert>
20170e4: 90 10 00 11 mov %l1, %o0
20170e8: 30 bf ff cc b,a 2017018 <_Timer_server_Body+0x9c>
*/
_Timer_server_Process_insertions( ts );
_ISR_Disable( level );
if ( _Chain_Is_empty( insert_chain ) ) {
ts->insert_chain = NULL;
20170ec: c0 26 20 78 clr [ %i0 + 0x78 ]
_ISR_Enable( level );
20170f0: 7f ff e0 d6 call 200f448 <sparc_enable_interrupts>
20170f4: 01 00 00 00 nop
_Chain_Initialize_empty( &fire_chain );
while ( true ) {
_Timer_server_Get_watchdogs_that_fire_now( ts, &insert_chain, &fire_chain );
if ( !_Chain_Is_empty( &fire_chain ) ) {
20170f8: c2 07 bf e8 ld [ %fp + -24 ], %g1
20170fc: 80 a5 c0 01 cmp %l7, %g1
2017100: 12 80 00 0c bne 2017130 <_Timer_server_Body+0x1b4>
2017104: 01 00 00 00 nop
2017108: 30 80 00 13 b,a 2017154 <_Timer_server_Body+0x1d8>
* service routine may remove a watchdog from the chain.
*/
_ISR_Disable( level );
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
if ( watchdog != NULL ) {
watchdog->state = WATCHDOG_INACTIVE;
201710c: c0 24 20 08 clr [ %l0 + 8 ]
Chain_Node *return_node;
Chain_Node *new_first;
return_node = the_chain->first;
new_first = return_node->next;
the_chain->first = new_first;
2017110: c2 27 bf e8 st %g1, [ %fp + -24 ]
new_first->previous = _Chain_Head(the_chain);
2017114: e4 20 60 04 st %l2, [ %g1 + 4 ]
_ISR_Enable( level );
2017118: 7f ff e0 cc call 200f448 <sparc_enable_interrupts>
201711c: 01 00 00 00 nop
/*
* The timer server may block here and wait for resources or time.
* The system watchdogs are inactive and will remain inactive since
* the active flag of the timer server is true.
*/
(*watchdog->routine)( watchdog->id, watchdog->user_data );
2017120: d2 04 20 24 ld [ %l0 + 0x24 ], %o1
2017124: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
2017128: 9f c0 40 00 call %g1
201712c: d0 04 20 20 ld [ %l0 + 0x20 ], %o0
/*
* It is essential that interrupts are disable here since an interrupt
* service routine may remove a watchdog from the chain.
*/
_ISR_Disable( level );
2017130: 7f ff e0 c2 call 200f438 <sparc_disable_interrupts>
2017134: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
2017138: e0 07 bf e8 ld [ %fp + -24 ], %l0
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected(
Chain_Control *the_chain
)
{
if ( !_Chain_Is_empty(the_chain))
201713c: 80 a5 c0 10 cmp %l7, %l0
2017140: 32 bf ff f3 bne,a 201710c <_Timer_server_Body+0x190>
2017144: c2 04 00 00 ld [ %l0 ], %g1
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain );
if ( watchdog != NULL ) {
watchdog->state = WATCHDOG_INACTIVE;
_ISR_Enable( level );
} else {
_ISR_Enable( level );
2017148: 7f ff e0 c0 call 200f448 <sparc_enable_interrupts>
201714c: 01 00 00 00 nop
2017150: 30 bf ff a1 b,a 2016fd4 <_Timer_server_Body+0x58>
* the active flag of the timer server is true.
*/
(*watchdog->routine)( watchdog->id, watchdog->user_data );
}
} else {
ts->active = false;
2017154: c0 2e 20 7c clrb [ %i0 + 0x7c ]
2017158: c2 07 00 00 ld [ %i4 ], %g1
201715c: 82 00 60 01 inc %g1
2017160: c2 27 00 00 st %g1, [ %i4 ]
/*
* Block until there is something to do.
*/
_Thread_Disable_dispatch();
_Thread_Set_state( ts->thread, STATES_DELAYING );
2017164: d0 06 00 00 ld [ %i0 ], %o0
2017168: 40 00 0e ed call 201ad1c <_Thread_Set_state>
201716c: 92 10 20 08 mov 8, %o1
_Timer_server_Reset_interval_system_watchdog( ts );
2017170: 7f ff ff 59 call 2016ed4 <_Timer_server_Reset_interval_system_watchdog>
2017174: 90 10 00 18 mov %i0, %o0
_Timer_server_Reset_tod_system_watchdog( ts );
2017178: 7f ff ff 6c call 2016f28 <_Timer_server_Reset_tod_system_watchdog>
201717c: 90 10 00 18 mov %i0, %o0
_Thread_Enable_dispatch();
2017180: 40 00 0b f1 call 201a144 <_Thread_Enable_dispatch>
2017184: 01 00 00 00 nop
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2017188: 90 10 00 19 mov %i1, %o0
_Thread_Set_state( ts->thread, STATES_DELAYING );
_Timer_server_Reset_interval_system_watchdog( ts );
_Timer_server_Reset_tod_system_watchdog( ts );
_Thread_Enable_dispatch();
ts->active = true;
201718c: f6 2e 20 7c stb %i3, [ %i0 + 0x7c ]
static void _Timer_server_Stop_interval_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2017190: 40 00 12 58 call 201baf0 <_Watchdog_Remove>
2017194: 01 00 00 00 nop
static void _Timer_server_Stop_tod_system_watchdog(
Timer_server_Control *ts
)
{
_Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
2017198: 40 00 12 56 call 201baf0 <_Watchdog_Remove>
201719c: 90 10 00 1a mov %i2, %o0
20171a0: 30 bf ff 8d b,a 2016fd4 <_Timer_server_Body+0x58>
02009b84 <_Timespec_Add_to>:
uint32_t _Timespec_Add_to(
struct timespec *time,
const struct timespec *add
)
{
2009b84: 9d e3 bf a0 save %sp, -96, %sp
2009b88: 82 10 00 18 mov %i0, %g1
uint32_t seconds = add->tv_sec;
/* Add the basics */
time->tv_sec += add->tv_sec;
time->tv_nsec += add->tv_nsec;
2009b8c: c8 06 60 04 ld [ %i1 + 4 ], %g4
uint32_t _Timespec_Add_to(
struct timespec *time,
const struct timespec *add
)
{
uint32_t seconds = add->tv_sec;
2009b90: f0 06 40 00 ld [ %i1 ], %i0
/* Add the basics */
time->tv_sec += add->tv_sec;
2009b94: c6 00 40 00 ld [ %g1 ], %g3
time->tv_nsec += add->tv_nsec;
2009b98: c4 00 60 04 ld [ %g1 + 4 ], %g2
)
{
uint32_t seconds = add->tv_sec;
/* Add the basics */
time->tv_sec += add->tv_sec;
2009b9c: 86 00 c0 18 add %g3, %i0, %g3
time->tv_nsec += add->tv_nsec;
2009ba0: 84 01 00 02 add %g4, %g2, %g2
)
{
uint32_t seconds = add->tv_sec;
/* Add the basics */
time->tv_sec += add->tv_sec;
2009ba4: c6 20 40 00 st %g3, [ %g1 ]
time->tv_nsec += add->tv_nsec;
/* Now adjust it so nanoseconds is in range */
while ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
2009ba8: 1b 0e e6 b2 sethi %hi(0x3b9ac800), %o5
2009bac: 9a 13 61 ff or %o5, 0x1ff, %o5 ! 3b9ac9ff <RAM_END+0x395ac9ff>
2009bb0: 80 a0 80 0d cmp %g2, %o5
2009bb4: 08 80 00 0b bleu 2009be0 <_Timespec_Add_to+0x5c>
2009bb8: c4 20 60 04 st %g2, [ %g1 + 4 ]
time->tv_nsec -= TOD_NANOSECONDS_PER_SECOND;
2009bbc: 09 31 19 4d sethi %hi(0xc4653400), %g4
2009bc0: 88 11 22 00 or %g4, 0x200, %g4 ! c4653600 <RAM_END+0xc2253600>
2009bc4: 84 00 80 04 add %g2, %g4, %g2
*
* This routines adds two timespecs. The second argument is added
* to the first.
*/
uint32_t _Timespec_Add_to(
2009bc8: 86 00 e0 01 inc %g3
/* Add the basics */
time->tv_sec += add->tv_sec;
time->tv_nsec += add->tv_nsec;
/* Now adjust it so nanoseconds is in range */
while ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) {
2009bcc: 80 a0 80 0d cmp %g2, %o5
2009bd0: 18 bf ff fd bgu 2009bc4 <_Timespec_Add_to+0x40> <== NEVER TAKEN
2009bd4: b0 06 20 01 inc %i0
2009bd8: c6 20 40 00 st %g3, [ %g1 ]
2009bdc: c4 20 60 04 st %g2, [ %g1 + 4 ]
time->tv_sec++;
seconds++;
}
return seconds;
}
2009be0: 81 c7 e0 08 ret
2009be4: 81 e8 00 00 restore
02046100 <_Timespec_Greater_than>:
bool _Timespec_Greater_than(
const struct timespec *lhs,
const struct timespec *rhs
)
{
if ( lhs->tv_sec > rhs->tv_sec )
2046100: c6 02 00 00 ld [ %o0 ], %g3
2046104: c4 02 40 00 ld [ %o1 ], %g2
bool _Timespec_Greater_than(
const struct timespec *lhs,
const struct timespec *rhs
)
{
2046108: 82 10 00 08 mov %o0, %g1
if ( lhs->tv_sec > rhs->tv_sec )
204610c: 80 a0 c0 02 cmp %g3, %g2
2046110: 14 80 00 0a bg 2046138 <_Timespec_Greater_than+0x38>
2046114: 90 10 20 01 mov 1, %o0
return true;
if ( lhs->tv_sec < rhs->tv_sec )
2046118: 80 a0 c0 02 cmp %g3, %g2
204611c: 06 80 00 07 bl 2046138 <_Timespec_Greater_than+0x38> <== NEVER TAKEN
2046120: 90 10 20 00 clr %o0
#include <rtems/system.h>
#include <rtems/score/timespec.h>
#include <rtems/score/tod.h>
bool _Timespec_Greater_than(
2046124: c4 00 60 04 ld [ %g1 + 4 ], %g2
2046128: c2 02 60 04 ld [ %o1 + 4 ], %g1
204612c: 80 a0 80 01 cmp %g2, %g1
2046130: 04 80 00 04 ble 2046140 <_Timespec_Greater_than+0x40>
2046134: 90 10 20 01 mov 1, %o0
/* ASSERT: lhs->tv_sec == rhs->tv_sec */
if ( lhs->tv_nsec > rhs->tv_nsec )
return true;
return false;
}
2046138: 81 c3 e0 08 retl
204613c: 01 00 00 00 nop
2046140: 81 c3 e0 08 retl
2046144: 90 10 20 00 clr %o0 ! 0 <PROM_START>
02009d94 <_User_extensions_Fatal>:
void _User_extensions_Fatal (
Internal_errors_Source the_source,
bool is_internal,
Internal_errors_t the_error
)
{
2009d94: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009d98: 23 00 80 77 sethi %hi(0x201dc00), %l1
2009d9c: a2 14 61 e8 or %l1, 0x1e8, %l1 ! 201dde8 <_User_extensions_List>
2009da0: e0 04 60 08 ld [ %l1 + 8 ], %l0
2009da4: 80 a4 00 11 cmp %l0, %l1
2009da8: 02 80 00 0d be 2009ddc <_User_extensions_Fatal+0x48> <== NEVER TAKEN
2009dac: b2 0e 60 ff and %i1, 0xff, %i1
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.fatal != NULL )
2009db0: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
2009db4: 80 a0 60 00 cmp %g1, 0
2009db8: 02 80 00 05 be 2009dcc <_User_extensions_Fatal+0x38>
2009dbc: 90 10 00 18 mov %i0, %o0
(*the_extension->Callouts.fatal)( the_source, is_internal, the_error );
2009dc0: 92 10 00 19 mov %i1, %o1
2009dc4: 9f c0 40 00 call %g1
2009dc8: 94 10 00 1a mov %i2, %o2
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
2009dcc: e0 04 20 04 ld [ %l0 + 4 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009dd0: 80 a4 00 11 cmp %l0, %l1
2009dd4: 32 bf ff f8 bne,a 2009db4 <_User_extensions_Fatal+0x20>
2009dd8: c2 04 20 30 ld [ %l0 + 0x30 ], %g1
2009ddc: 81 c7 e0 08 ret
2009de0: 81 e8 00 00 restore
02009c40 <_User_extensions_Handler_initialization>:
#include <rtems/score/userext.h>
#include <rtems/score/wkspace.h>
#include <string.h>
void _User_extensions_Handler_initialization(void)
{
2009c40: 9d e3 bf a0 save %sp, -96, %sp
User_extensions_Control *extension;
uint32_t i;
uint32_t number_of_extensions;
User_extensions_Table *initial_extensions;
number_of_extensions = Configuration.number_of_initial_extensions;
2009c44: 07 00 80 74 sethi %hi(0x201d000), %g3
2009c48: 86 10 e0 f8 or %g3, 0xf8, %g3 ! 201d0f8 <Configuration>
initial_extensions = Configuration.User_extension_table;
2009c4c: e6 00 e0 3c ld [ %g3 + 0x3c ], %l3
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2009c50: 1b 00 80 77 sethi %hi(0x201dc00), %o5
2009c54: 09 00 80 76 sethi %hi(0x201d800), %g4
2009c58: 84 13 61 e8 or %o5, 0x1e8, %g2
2009c5c: 82 11 23 b4 or %g4, 0x3b4, %g1
the_chain->permanent_null = NULL;
the_chain->last = _Chain_Head(the_chain);
2009c60: c4 20 a0 08 st %g2, [ %g2 + 8 ]
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2009c64: c0 20 a0 04 clr [ %g2 + 4 ]
the_chain->last = _Chain_Head(the_chain);
2009c68: c2 20 60 08 st %g1, [ %g1 + 8 ]
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
the_chain->permanent_null = NULL;
2009c6c: c0 20 60 04 clr [ %g1 + 4 ]
*/
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty(
Chain_Control *the_chain
)
{
the_chain->first = _Chain_Tail(the_chain);
2009c70: 84 00 a0 04 add %g2, 4, %g2
2009c74: 82 00 60 04 add %g1, 4, %g1
2009c78: c4 23 61 e8 st %g2, [ %o5 + 0x1e8 ]
2009c7c: c2 21 23 b4 st %g1, [ %g4 + 0x3b4 ]
_Chain_Initialize_empty( &_User_extensions_List );
_Chain_Initialize_empty( &_User_extensions_Switches_list );
if ( initial_extensions ) {
2009c80: 80 a4 e0 00 cmp %l3, 0
2009c84: 02 80 00 1b be 2009cf0 <_User_extensions_Handler_initialization+0xb0>
2009c88: e4 00 e0 38 ld [ %g3 + 0x38 ], %l2
extension = (User_extensions_Control *)
_Workspace_Allocate_or_fatal_error(
number_of_extensions * sizeof( User_extensions_Control )
2009c8c: 83 2c a0 02 sll %l2, 2, %g1
2009c90: a3 2c a0 04 sll %l2, 4, %l1
2009c94: a2 24 40 01 sub %l1, %g1, %l1
2009c98: a2 04 40 12 add %l1, %l2, %l1
2009c9c: a3 2c 60 02 sll %l1, 2, %l1
_Chain_Initialize_empty( &_User_extensions_List );
_Chain_Initialize_empty( &_User_extensions_Switches_list );
if ( initial_extensions ) {
extension = (User_extensions_Control *)
2009ca0: 40 00 01 6f call 200a25c <_Workspace_Allocate_or_fatal_error>
2009ca4: 90 10 00 11 mov %l1, %o0
_Workspace_Allocate_or_fatal_error(
number_of_extensions * sizeof( User_extensions_Control )
);
memset (
2009ca8: 94 10 00 11 mov %l1, %o2
_Chain_Initialize_empty( &_User_extensions_List );
_Chain_Initialize_empty( &_User_extensions_Switches_list );
if ( initial_extensions ) {
extension = (User_extensions_Control *)
2009cac: a0 10 00 08 mov %o0, %l0
_Workspace_Allocate_or_fatal_error(
number_of_extensions * sizeof( User_extensions_Control )
);
memset (
2009cb0: 40 00 1c 63 call 2010e3c <memset>
2009cb4: 92 10 20 00 clr %o1
extension,
0,
number_of_extensions * sizeof( User_extensions_Control )
);
for ( i = 0 ; i < number_of_extensions ; i++ ) {
2009cb8: 80 a4 a0 00 cmp %l2, 0
2009cbc: 02 80 00 0d be 2009cf0 <_User_extensions_Handler_initialization+0xb0><== NEVER TAKEN
2009cc0: a2 10 20 00 clr %l1
RTEMS_INLINE_ROUTINE void _User_extensions_Add_set_with_table(
User_extensions_Control *extension,
const User_extensions_Table *extension_table
)
{
extension->Callouts = *extension_table;
2009cc4: 93 2c 60 05 sll %l1, 5, %o1
2009cc8: 94 10 20 20 mov 0x20, %o2
2009ccc: 92 04 c0 09 add %l3, %o1, %o1
2009cd0: 40 00 1c 1c call 2010d40 <memcpy>
2009cd4: 90 04 20 14 add %l0, 0x14, %o0
_User_extensions_Add_set( extension );
2009cd8: 40 00 11 38 call 200e1b8 <_User_extensions_Add_set>
2009cdc: 90 10 00 10 mov %l0, %o0
2009ce0: a2 04 60 01 inc %l1
2009ce4: 80 a4 80 11 cmp %l2, %l1
2009ce8: 18 bf ff f7 bgu 2009cc4 <_User_extensions_Handler_initialization+0x84>
2009cec: a0 04 20 34 add %l0, 0x34, %l0
2009cf0: 81 c7 e0 08 ret
2009cf4: 81 e8 00 00 restore
02009cf8 <_User_extensions_Thread_begin>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_begin (
Thread_Control *executing
)
{
2009cf8: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009cfc: 23 00 80 77 sethi %hi(0x201dc00), %l1
2009d00: e0 04 61 e8 ld [ %l1 + 0x1e8 ], %l0 ! 201dde8 <_User_extensions_List>
2009d04: a2 14 61 e8 or %l1, 0x1e8, %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
2009d08: a2 04 60 04 add %l1, 4, %l1
2009d0c: 80 a4 00 11 cmp %l0, %l1
2009d10: 02 80 00 0c be 2009d40 <_User_extensions_Thread_begin+0x48><== NEVER TAKEN
2009d14: 01 00 00 00 nop
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_begin != NULL )
2009d18: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
2009d1c: 80 a0 60 00 cmp %g1, 0
2009d20: 02 80 00 04 be 2009d30 <_User_extensions_Thread_begin+0x38>
2009d24: 90 10 00 18 mov %i0, %o0
(*the_extension->Callouts.thread_begin)( executing );
2009d28: 9f c0 40 00 call %g1
2009d2c: 01 00 00 00 nop
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
2009d30: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009d34: 80 a4 00 11 cmp %l0, %l1
2009d38: 32 bf ff f9 bne,a 2009d1c <_User_extensions_Thread_begin+0x24>
2009d3c: c2 04 20 28 ld [ %l0 + 0x28 ], %g1
2009d40: 81 c7 e0 08 ret
2009d44: 81 e8 00 00 restore
02009de4 <_User_extensions_Thread_create>:
#include <rtems/score/userext.h>
bool _User_extensions_Thread_create (
Thread_Control *the_thread
)
{
2009de4: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
bool status;
for ( the_node = _User_extensions_List.first ;
2009de8: 23 00 80 77 sethi %hi(0x201dc00), %l1
2009dec: e0 04 61 e8 ld [ %l1 + 0x1e8 ], %l0 ! 201dde8 <_User_extensions_List>
2009df0: a2 14 61 e8 or %l1, 0x1e8, %l1
2009df4: a2 04 60 04 add %l1, 4, %l1
2009df8: 80 a4 00 11 cmp %l0, %l1
2009dfc: 02 80 00 10 be 2009e3c <_User_extensions_Thread_create+0x58><== NEVER TAKEN
2009e00: 25 00 80 77 sethi %hi(0x201dc00), %l2
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_create != NULL ) {
status = (*the_extension->Callouts.thread_create)(
2009e04: a4 14 a0 70 or %l2, 0x70, %l2 ! 201dc70 <_Thread_Executing>
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_create != NULL ) {
2009e08: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
2009e0c: 80 a0 60 00 cmp %g1, 0
2009e10: 02 80 00 07 be 2009e2c <_User_extensions_Thread_create+0x48>
2009e14: 92 10 00 18 mov %i0, %o1
status = (*the_extension->Callouts.thread_create)(
2009e18: 9f c0 40 00 call %g1
2009e1c: d0 04 80 00 ld [ %l2 ], %o0
_Thread_Executing,
the_thread
);
if ( !status )
2009e20: 80 8a 20 ff btst 0xff, %o0
2009e24: 02 80 00 08 be 2009e44 <_User_extensions_Thread_create+0x60>
2009e28: 01 00 00 00 nop
User_extensions_Control *the_extension;
bool status;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
2009e2c: e0 04 00 00 ld [ %l0 ], %l0
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
bool status;
for ( the_node = _User_extensions_List.first ;
2009e30: 80 a4 00 11 cmp %l0, %l1
2009e34: 32 bf ff f6 bne,a 2009e0c <_User_extensions_Thread_create+0x28>
2009e38: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
return false;
}
}
return true;
}
2009e3c: 81 c7 e0 08 ret
2009e40: 91 e8 20 01 restore %g0, 1, %o0
if ( the_extension->Callouts.thread_create != NULL ) {
status = (*the_extension->Callouts.thread_create)(
_Thread_Executing,
the_thread
);
if ( !status )
2009e44: 81 c7 e0 08 ret
2009e48: 91 e8 20 00 restore %g0, 0, %o0
02009e4c <_User_extensions_Thread_delete>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_delete (
Thread_Control *the_thread
)
{
2009e4c: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009e50: 23 00 80 77 sethi %hi(0x201dc00), %l1
2009e54: a2 14 61 e8 or %l1, 0x1e8, %l1 ! 201dde8 <_User_extensions_List>
2009e58: e0 04 60 08 ld [ %l1 + 8 ], %l0
2009e5c: 80 a4 00 11 cmp %l0, %l1
2009e60: 02 80 00 0d be 2009e94 <_User_extensions_Thread_delete+0x48><== NEVER TAKEN
2009e64: 25 00 80 77 sethi %hi(0x201dc00), %l2
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_delete != NULL )
(*the_extension->Callouts.thread_delete)(
2009e68: a4 14 a0 70 or %l2, 0x70, %l2 ! 201dc70 <_Thread_Executing>
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_delete != NULL )
2009e6c: c2 04 20 20 ld [ %l0 + 0x20 ], %g1
2009e70: 80 a0 60 00 cmp %g1, 0
2009e74: 02 80 00 04 be 2009e84 <_User_extensions_Thread_delete+0x38>
2009e78: 92 10 00 18 mov %i0, %o1
(*the_extension->Callouts.thread_delete)(
2009e7c: 9f c0 40 00 call %g1
2009e80: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
2009e84: e0 04 20 04 ld [ %l0 + 4 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009e88: 80 a4 00 11 cmp %l0, %l1
2009e8c: 32 bf ff f9 bne,a 2009e70 <_User_extensions_Thread_delete+0x24>
2009e90: c2 04 20 20 ld [ %l0 + 0x20 ], %g1
2009e94: 81 c7 e0 08 ret
2009e98: 81 e8 00 00 restore
02009d48 <_User_extensions_Thread_exitted>:
}
void _User_extensions_Thread_exitted (
Thread_Control *executing
)
{
2009d48: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009d4c: 23 00 80 77 sethi %hi(0x201dc00), %l1
2009d50: a2 14 61 e8 or %l1, 0x1e8, %l1 ! 201dde8 <_User_extensions_List>
2009d54: e0 04 60 08 ld [ %l1 + 8 ], %l0
2009d58: 80 a4 00 11 cmp %l0, %l1
2009d5c: 02 80 00 0c be 2009d8c <_User_extensions_Thread_exitted+0x44><== NEVER TAKEN
2009d60: 01 00 00 00 nop
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_exitted != NULL )
2009d64: c2 04 20 2c ld [ %l0 + 0x2c ], %g1
2009d68: 80 a0 60 00 cmp %g1, 0
2009d6c: 02 80 00 04 be 2009d7c <_User_extensions_Thread_exitted+0x34>
2009d70: 90 10 00 18 mov %i0, %o0
(*the_extension->Callouts.thread_exitted)( executing );
2009d74: 9f c0 40 00 call %g1
2009d78: 01 00 00 00 nop
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
!_Chain_Is_head( &_User_extensions_List, the_node ) ;
the_node = the_node->previous ) {
2009d7c: e0 04 20 04 ld [ %l0 + 4 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.last ;
2009d80: 80 a4 00 11 cmp %l0, %l1
2009d84: 32 bf ff f9 bne,a 2009d68 <_User_extensions_Thread_exitted+0x20>
2009d88: c2 04 20 2c ld [ %l0 + 0x2c ], %g1
2009d8c: 81 c7 e0 08 ret
2009d90: 81 e8 00 00 restore
0200aba4 <_User_extensions_Thread_restart>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_restart (
Thread_Control *the_thread
)
{
200aba4: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
200aba8: 23 00 80 89 sethi %hi(0x2022400), %l1
200abac: e0 04 63 a8 ld [ %l1 + 0x3a8 ], %l0 ! 20227a8 <_User_extensions_List>
200abb0: a2 14 63 a8 or %l1, 0x3a8, %l1
200abb4: a2 04 60 04 add %l1, 4, %l1
200abb8: 80 a4 00 11 cmp %l0, %l1
200abbc: 02 80 00 0d be 200abf0 <_User_extensions_Thread_restart+0x4c><== NEVER TAKEN
200abc0: 25 00 80 89 sethi %hi(0x2022400), %l2
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_restart != NULL )
(*the_extension->Callouts.thread_restart)(
200abc4: a4 14 a2 30 or %l2, 0x230, %l2 ! 2022630 <_Thread_Executing>
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_restart != NULL )
200abc8: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200abcc: 80 a0 60 00 cmp %g1, 0
200abd0: 02 80 00 04 be 200abe0 <_User_extensions_Thread_restart+0x3c>
200abd4: 92 10 00 18 mov %i0, %o1
(*the_extension->Callouts.thread_restart)(
200abd8: 9f c0 40 00 call %g1
200abdc: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
200abe0: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
200abe4: 80 a4 00 11 cmp %l0, %l1
200abe8: 32 bf ff f9 bne,a 200abcc <_User_extensions_Thread_restart+0x28>
200abec: c2 04 20 1c ld [ %l0 + 0x1c ], %g1
200abf0: 81 c7 e0 08 ret
200abf4: 81 e8 00 00 restore
02009e9c <_User_extensions_Thread_start>:
#include <rtems/score/userext.h>
void _User_extensions_Thread_start (
Thread_Control *the_thread
)
{
2009e9c: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009ea0: 23 00 80 77 sethi %hi(0x201dc00), %l1
2009ea4: e0 04 61 e8 ld [ %l1 + 0x1e8 ], %l0 ! 201dde8 <_User_extensions_List>
2009ea8: a2 14 61 e8 or %l1, 0x1e8, %l1
2009eac: a2 04 60 04 add %l1, 4, %l1
2009eb0: 80 a4 00 11 cmp %l0, %l1
2009eb4: 02 80 00 0d be 2009ee8 <_User_extensions_Thread_start+0x4c><== NEVER TAKEN
2009eb8: 25 00 80 77 sethi %hi(0x201dc00), %l2
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_start != NULL )
(*the_extension->Callouts.thread_start)(
2009ebc: a4 14 a0 70 or %l2, 0x70, %l2 ! 201dc70 <_Thread_Executing>
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
the_extension = (User_extensions_Control *) the_node;
if ( the_extension->Callouts.thread_start != NULL )
2009ec0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
2009ec4: 80 a0 60 00 cmp %g1, 0
2009ec8: 02 80 00 04 be 2009ed8 <_User_extensions_Thread_start+0x3c>
2009ecc: 92 10 00 18 mov %i0, %o1
(*the_extension->Callouts.thread_start)(
2009ed0: 9f c0 40 00 call %g1
2009ed4: d0 04 80 00 ld [ %l2 ], %o0
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
!_Chain_Is_tail( &_User_extensions_List, the_node ) ;
the_node = the_node->next ) {
2009ed8: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Control *the_extension;
for ( the_node = _User_extensions_List.first ;
2009edc: 80 a4 00 11 cmp %l0, %l1
2009ee0: 32 bf ff f9 bne,a 2009ec4 <_User_extensions_Thread_start+0x28>
2009ee4: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
2009ee8: 81 c7 e0 08 ret
2009eec: 81 e8 00 00 restore
02009ef0 <_User_extensions_Thread_switch>:
void _User_extensions_Thread_switch (
Thread_Control *executing,
Thread_Control *heir
)
{
2009ef0: 9d e3 bf a0 save %sp, -96, %sp
Chain_Node *the_node;
User_extensions_Switch_control *the_extension_switch;
for ( the_node = _User_extensions_Switches_list.first ;
2009ef4: 23 00 80 76 sethi %hi(0x201d800), %l1
2009ef8: e0 04 63 b4 ld [ %l1 + 0x3b4 ], %l0 ! 201dbb4 <_User_extensions_Switches_list>
2009efc: a2 14 63 b4 or %l1, 0x3b4, %l1
2009f00: a2 04 60 04 add %l1, 4, %l1
2009f04: 80 a4 00 11 cmp %l0, %l1
2009f08: 02 80 00 0a be 2009f30 <_User_extensions_Thread_switch+0x40><== NEVER TAKEN
2009f0c: 01 00 00 00 nop
!_Chain_Is_tail( &_User_extensions_Switches_list, the_node ) ;
the_node = the_node->next ) {
the_extension_switch = (User_extensions_Switch_control *) the_node;
(*the_extension_switch->thread_switch)( executing, heir );
2009f10: c2 04 20 08 ld [ %l0 + 8 ], %g1
2009f14: 90 10 00 18 mov %i0, %o0
2009f18: 9f c0 40 00 call %g1
2009f1c: 92 10 00 19 mov %i1, %o1
Chain_Node *the_node;
User_extensions_Switch_control *the_extension_switch;
for ( the_node = _User_extensions_Switches_list.first ;
!_Chain_Is_tail( &_User_extensions_Switches_list, the_node ) ;
the_node = the_node->next ) {
2009f20: e0 04 00 00 ld [ %l0 ], %l0
)
{
Chain_Node *the_node;
User_extensions_Switch_control *the_extension_switch;
for ( the_node = _User_extensions_Switches_list.first ;
2009f24: 80 a4 00 11 cmp %l0, %l1
2009f28: 32 bf ff fb bne,a 2009f14 <_User_extensions_Thread_switch+0x24>
2009f2c: c2 04 20 08 ld [ %l0 + 8 ], %g1
2009f30: 81 c7 e0 08 ret
2009f34: 81 e8 00 00 restore
0200c164 <_Watchdog_Adjust>:
void _Watchdog_Adjust(
Chain_Control *header,
Watchdog_Adjust_directions direction,
Watchdog_Interval units
)
{
200c164: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
_ISR_Disable( level );
200c168: 7f ff db ac call 2003018 <sparc_disable_interrupts>
200c16c: a0 10 00 18 mov %i0, %l0
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
200c170: c2 06 00 00 ld [ %i0 ], %g1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200c174: a2 06 20 04 add %i0, 4, %l1
* hence the compiler must not assume *header to remain
* unmodified across that call.
*
* Till Straumann, 7/2003
*/
if ( !_Chain_Is_empty( header ) ) {
200c178: 80 a0 40 11 cmp %g1, %l1
200c17c: 02 80 00 1f be 200c1f8 <_Watchdog_Adjust+0x94>
200c180: 80 a6 60 00 cmp %i1, 0
switch ( direction ) {
200c184: 12 80 00 1f bne 200c200 <_Watchdog_Adjust+0x9c>
200c188: 80 a6 60 01 cmp %i1, 1
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
break;
case WATCHDOG_FORWARD:
while ( units ) {
200c18c: 80 a6 a0 00 cmp %i2, 0
200c190: 02 80 00 1a be 200c1f8 <_Watchdog_Adjust+0x94> <== NEVER TAKEN
200c194: 01 00 00 00 nop
if ( units < _Watchdog_First( header )->delta_interval ) {
200c198: f2 00 60 10 ld [ %g1 + 0x10 ], %i1
200c19c: 80 a6 80 19 cmp %i2, %i1
200c1a0: 1a 80 00 0b bcc 200c1cc <_Watchdog_Adjust+0x68> <== ALWAYS TAKEN
200c1a4: a4 10 20 01 mov 1, %l2
_Watchdog_First( header )->delta_interval -= units;
200c1a8: 10 80 00 1d b 200c21c <_Watchdog_Adjust+0xb8> <== NOT EXECUTED
200c1ac: b4 26 40 1a sub %i1, %i2, %i2 <== NOT EXECUTED
switch ( direction ) {
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
break;
case WATCHDOG_FORWARD:
while ( units ) {
200c1b0: b4 a6 80 19 subcc %i2, %i1, %i2
200c1b4: 02 80 00 11 be 200c1f8 <_Watchdog_Adjust+0x94> <== NEVER TAKEN
200c1b8: 01 00 00 00 nop
if ( units < _Watchdog_First( header )->delta_interval ) {
200c1bc: f2 00 60 10 ld [ %g1 + 0x10 ], %i1
200c1c0: 80 a6 40 1a cmp %i1, %i2
200c1c4: 38 80 00 16 bgu,a 200c21c <_Watchdog_Adjust+0xb8>
200c1c8: b4 26 40 1a sub %i1, %i2, %i2
_Watchdog_First( header )->delta_interval -= units;
break;
} else {
units -= _Watchdog_First( header )->delta_interval;
_Watchdog_First( header )->delta_interval = 1;
200c1cc: e4 20 60 10 st %l2, [ %g1 + 0x10 ]
_ISR_Enable( level );
200c1d0: 7f ff db 96 call 2003028 <sparc_enable_interrupts>
200c1d4: 01 00 00 00 nop
_Watchdog_Tickle( header );
200c1d8: 40 00 00 b2 call 200c4a0 <_Watchdog_Tickle>
200c1dc: 90 10 00 10 mov %l0, %o0
_ISR_Disable( level );
200c1e0: 7f ff db 8e call 2003018 <sparc_disable_interrupts>
200c1e4: 01 00 00 00 nop
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
200c1e8: c4 04 00 00 ld [ %l0 ], %g2
if ( _Chain_Is_empty( header ) )
200c1ec: 80 a4 40 02 cmp %l1, %g2
200c1f0: 12 bf ff f0 bne 200c1b0 <_Watchdog_Adjust+0x4c>
200c1f4: 82 10 00 02 mov %g2, %g1
}
break;
}
}
_ISR_Enable( level );
200c1f8: 7f ff db 8c call 2003028 <sparc_enable_interrupts>
200c1fc: 91 e8 00 08 restore %g0, %o0, %o0
* unmodified across that call.
*
* Till Straumann, 7/2003
*/
if ( !_Chain_Is_empty( header ) ) {
switch ( direction ) {
200c200: 12 bf ff fe bne 200c1f8 <_Watchdog_Adjust+0x94> <== NEVER TAKEN
200c204: 01 00 00 00 nop
case WATCHDOG_BACKWARD:
_Watchdog_First( header )->delta_interval += units;
200c208: c4 00 60 10 ld [ %g1 + 0x10 ], %g2
200c20c: b4 00 80 1a add %g2, %i2, %i2
200c210: f4 20 60 10 st %i2, [ %g1 + 0x10 ]
}
break;
}
}
_ISR_Enable( level );
200c214: 7f ff db 85 call 2003028 <sparc_enable_interrupts>
200c218: 91 e8 00 08 restore %g0, %o0, %o0
break;
case WATCHDOG_FORWARD:
while ( units ) {
if ( units < _Watchdog_First( header )->delta_interval ) {
_Watchdog_First( header )->delta_interval -= units;
break;
200c21c: 10 bf ff f7 b 200c1f8 <_Watchdog_Adjust+0x94>
200c220: f4 20 60 10 st %i2, [ %g1 + 0x10 ]
0200a0dc <_Watchdog_Remove>:
*/
Watchdog_States _Watchdog_Remove(
Watchdog_Control *the_watchdog
)
{
200a0dc: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Watchdog_States previous_state;
Watchdog_Control *next_watchdog;
_ISR_Disable( level );
200a0e0: 7f ff df f1 call 20020a4 <sparc_disable_interrupts>
200a0e4: 01 00 00 00 nop
previous_state = the_watchdog->state;
200a0e8: e0 06 20 08 ld [ %i0 + 8 ], %l0
switch ( previous_state ) {
200a0ec: 80 a4 20 01 cmp %l0, 1
200a0f0: 02 80 00 2a be 200a198 <_Watchdog_Remove+0xbc>
200a0f4: 03 00 80 77 sethi %hi(0x201dc00), %g1
200a0f8: 1a 80 00 09 bcc 200a11c <_Watchdog_Remove+0x40>
200a0fc: 80 a4 20 03 cmp %l0, 3
_Watchdog_Sync_level = _ISR_Nest_level;
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a100: 03 00 80 77 sethi %hi(0x201dc00), %g1
200a104: c2 00 61 04 ld [ %g1 + 0x104 ], %g1 ! 201dd04 <_Watchdog_Ticks_since_boot>
200a108: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
_ISR_Enable( level );
200a10c: 7f ff df ea call 20020b4 <sparc_enable_interrupts>
200a110: b0 10 00 10 mov %l0, %i0
return( previous_state );
}
200a114: 81 c7 e0 08 ret
200a118: 81 e8 00 00 restore
Watchdog_States previous_state;
Watchdog_Control *next_watchdog;
_ISR_Disable( level );
previous_state = the_watchdog->state;
switch ( previous_state ) {
200a11c: 18 bf ff fa bgu 200a104 <_Watchdog_Remove+0x28> <== NEVER TAKEN
200a120: 03 00 80 77 sethi %hi(0x201dc00), %g1
RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_Next(
Watchdog_Control *the_watchdog
)
{
return ( (Watchdog_Control *) the_watchdog->Node.next );
200a124: c2 06 00 00 ld [ %i0 ], %g1
break;
case WATCHDOG_ACTIVE:
case WATCHDOG_REMOVE_IT:
the_watchdog->state = WATCHDOG_INACTIVE;
200a128: c0 26 20 08 clr [ %i0 + 8 ]
next_watchdog = _Watchdog_Next( the_watchdog );
if ( _Watchdog_Next(next_watchdog) )
200a12c: c4 00 40 00 ld [ %g1 ], %g2
200a130: 80 a0 a0 00 cmp %g2, 0
200a134: 02 80 00 07 be 200a150 <_Watchdog_Remove+0x74>
200a138: 05 00 80 77 sethi %hi(0x201dc00), %g2
next_watchdog->delta_interval += the_watchdog->delta_interval;
200a13c: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
200a140: c4 06 20 10 ld [ %i0 + 0x10 ], %g2
200a144: 84 00 c0 02 add %g3, %g2, %g2
200a148: c4 20 60 10 st %g2, [ %g1 + 0x10 ]
if ( _Watchdog_Sync_count )
200a14c: 05 00 80 77 sethi %hi(0x201dc00), %g2
200a150: c4 00 a1 00 ld [ %g2 + 0x100 ], %g2 ! 201dd00 <_Watchdog_Sync_count>
200a154: 80 a0 a0 00 cmp %g2, 0
200a158: 22 80 00 07 be,a 200a174 <_Watchdog_Remove+0x98>
200a15c: c4 06 20 04 ld [ %i0 + 4 ], %g2
_Watchdog_Sync_level = _ISR_Nest_level;
200a160: 05 00 80 77 sethi %hi(0x201dc00), %g2
200a164: c6 00 a0 4c ld [ %g2 + 0x4c ], %g3 ! 201dc4c <_ISR_Nest_level>
200a168: 05 00 80 77 sethi %hi(0x201dc00), %g2
200a16c: c6 20 a0 6c st %g3, [ %g2 + 0x6c ] ! 201dc6c <_Watchdog_Sync_level>
{
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
200a170: c4 06 20 04 ld [ %i0 + 4 ], %g2
next->previous = previous;
previous->next = next;
200a174: c2 20 80 00 st %g1, [ %g2 ]
Chain_Node *next;
Chain_Node *previous;
next = the_node->next;
previous = the_node->previous;
next->previous = previous;
200a178: c4 20 60 04 st %g2, [ %g1 + 4 ]
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a17c: 03 00 80 77 sethi %hi(0x201dc00), %g1
200a180: c2 00 61 04 ld [ %g1 + 0x104 ], %g1 ! 201dd04 <_Watchdog_Ticks_since_boot>
200a184: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
_ISR_Enable( level );
200a188: 7f ff df cb call 20020b4 <sparc_enable_interrupts>
200a18c: b0 10 00 10 mov %l0, %i0
return( previous_state );
}
200a190: 81 c7 e0 08 ret
200a194: 81 e8 00 00 restore
_Watchdog_Sync_level = _ISR_Nest_level;
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a198: c2 00 61 04 ld [ %g1 + 0x104 ], %g1
/*
* It is not actually on the chain so just change the state and
* the Insert operation we interrupted will be aborted.
*/
the_watchdog->state = WATCHDOG_INACTIVE;
200a19c: c0 26 20 08 clr [ %i0 + 8 ]
_Watchdog_Sync_level = _ISR_Nest_level;
_Chain_Extract_unprotected( &the_watchdog->Node );
break;
}
the_watchdog->stop_time = _Watchdog_Ticks_since_boot;
200a1a0: c2 26 20 18 st %g1, [ %i0 + 0x18 ]
_ISR_Enable( level );
200a1a4: 7f ff df c4 call 20020b4 <sparc_enable_interrupts>
200a1a8: b0 10 00 10 mov %l0, %i0
return( previous_state );
}
200a1ac: 81 c7 e0 08 ret
200a1b0: 81 e8 00 00 restore
0200b930 <_Watchdog_Report_chain>:
void _Watchdog_Report_chain(
const char *name,
Chain_Control *header
)
{
200b930: 9d e3 bf a0 save %sp, -96, %sp
ISR_Level level;
Chain_Node *node;
_ISR_Disable( level );
200b934: 7f ff dc 80 call 2002b34 <sparc_disable_interrupts>
200b938: a0 10 00 18 mov %i0, %l0
200b93c: b0 10 00 08 mov %o0, %i0
printk( "Watchdog Chain: %s %p\n", name, header );
200b940: 11 00 80 86 sethi %hi(0x2021800), %o0
200b944: 94 10 00 19 mov %i1, %o2
200b948: 90 12 22 40 or %o0, 0x240, %o0
200b94c: 7f ff e4 4f call 2004a88 <printk>
200b950: 92 10 00 10 mov %l0, %o1
*/
RTEMS_INLINE_ROUTINE bool _Chain_Is_empty(
Chain_Control *the_chain
)
{
return (the_chain->first == _Chain_Tail(the_chain));
200b954: e2 06 40 00 ld [ %i1 ], %l1
*/
RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail(
Chain_Control *the_chain
)
{
return (Chain_Node *) &the_chain->permanent_null;
200b958: b2 06 60 04 add %i1, 4, %i1
if ( !_Chain_Is_empty( header ) ) {
200b95c: 80 a4 40 19 cmp %l1, %i1
200b960: 02 80 00 0f be 200b99c <_Watchdog_Report_chain+0x6c>
200b964: 11 00 80 86 sethi %hi(0x2021800), %o0
node != _Chain_Tail(header) ;
node = node->next )
{
Watchdog_Control *watch = (Watchdog_Control *) node;
_Watchdog_Report( NULL, watch );
200b968: 92 10 00 11 mov %l1, %o1
200b96c: 40 00 00 11 call 200b9b0 <_Watchdog_Report>
200b970: 90 10 20 00 clr %o0
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
for ( node = header->first ;
node != _Chain_Tail(header) ;
node = node->next )
200b974: e2 04 40 00 ld [ %l1 ], %l1
Chain_Node *node;
_ISR_Disable( level );
printk( "Watchdog Chain: %s %p\n", name, header );
if ( !_Chain_Is_empty( header ) ) {
for ( node = header->first ;
200b978: 80 a4 40 19 cmp %l1, %i1
200b97c: 12 bf ff fc bne 200b96c <_Watchdog_Report_chain+0x3c> <== NEVER TAKEN
200b980: 92 10 00 11 mov %l1, %o1
{
Watchdog_Control *watch = (Watchdog_Control *) node;
_Watchdog_Report( NULL, watch );
}
printk( "== end of %s \n", name );
200b984: 92 10 00 10 mov %l0, %o1
200b988: 11 00 80 86 sethi %hi(0x2021800), %o0
200b98c: 7f ff e4 3f call 2004a88 <printk>
200b990: 90 12 22 58 or %o0, 0x258, %o0 ! 2021a58 <_Status_Object_name_errors_to_status+0x30>
} else {
printk( "Chain is empty\n" );
}
_ISR_Enable( level );
200b994: 7f ff dc 6c call 2002b44 <sparc_enable_interrupts>
200b998: 81 e8 00 00 restore
_Watchdog_Report( NULL, watch );
}
printk( "== end of %s \n", name );
} else {
printk( "Chain is empty\n" );
200b99c: 7f ff e4 3b call 2004a88 <printk>
200b9a0: 90 12 22 68 or %o0, 0x268, %o0
}
_ISR_Enable( level );
200b9a4: 7f ff dc 68 call 2002b44 <sparc_enable_interrupts>
200b9a8: 81 e8 00 00 restore
0200d0d0 <rtems_barrier_create>:
rtems_name name,
rtems_attribute attribute_set,
uint32_t maximum_waiters,
rtems_id *id
)
{
200d0d0: 9d e3 bf 98 save %sp, -104, %sp
Barrier_Control *the_barrier;
CORE_barrier_Attributes the_attributes;
if ( !rtems_is_name_valid( name ) )
200d0d4: a0 96 20 00 orcc %i0, 0, %l0
200d0d8: 02 80 00 23 be 200d164 <rtems_barrier_create+0x94>
200d0dc: b0 10 20 03 mov 3, %i0
return RTEMS_INVALID_NAME;
if ( !id )
200d0e0: 80 a6 e0 00 cmp %i3, 0
200d0e4: 02 80 00 20 be 200d164 <rtems_barrier_create+0x94>
200d0e8: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
/* Initialize core barrier attributes */
if ( _Attributes_Is_barrier_automatic( attribute_set ) ) {
200d0ec: 80 8e 60 10 btst 0x10, %i1
200d0f0: 02 80 00 1f be 200d16c <rtems_barrier_create+0x9c>
200d0f4: 80 a6 a0 00 cmp %i2, 0
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
if ( maximum_waiters == 0 )
200d0f8: 02 80 00 1b be 200d164 <rtems_barrier_create+0x94>
200d0fc: b0 10 20 0a mov 0xa, %i0
200d100: 03 00 80 76 sethi %hi(0x201d800), %g1
200d104: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201dbb0 <_Thread_Dispatch_disable_level>
if ( !id )
return RTEMS_INVALID_ADDRESS;
/* Initialize core barrier attributes */
if ( _Attributes_Is_barrier_automatic( attribute_set ) ) {
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
200d108: c0 27 bf f8 clr [ %fp + -8 ]
if ( maximum_waiters == 0 )
return RTEMS_INVALID_NUMBER;
} else
the_attributes.discipline = CORE_BARRIER_MANUAL_RELEASE;
the_attributes.maximum_count = maximum_waiters;
200d10c: f4 27 bf fc st %i2, [ %fp + -4 ]
200d110: 84 00 a0 01 inc %g2
200d114: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
* This function allocates a barrier control block from
* the inactive chain of free barrier control blocks.
*/
RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Allocate( void )
{
return (Barrier_Control *) _Objects_Allocate( &_Barrier_Information );
200d118: 25 00 80 77 sethi %hi(0x201dc00), %l2
200d11c: 7f ff eb 03 call 2007d28 <_Objects_Allocate>
200d120: 90 14 a2 2c or %l2, 0x22c, %o0 ! 201de2c <_Barrier_Information>
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _Barrier_Allocate();
if ( !the_barrier ) {
200d124: a2 92 20 00 orcc %o0, 0, %l1
200d128: 02 80 00 1e be 200d1a0 <rtems_barrier_create+0xd0> <== NEVER TAKEN
200d12c: 90 04 60 14 add %l1, 0x14, %o0
return RTEMS_TOO_MANY;
}
the_barrier->attribute_set = attribute_set;
_CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes );
200d130: 92 07 bf f8 add %fp, -8, %o1
200d134: 40 00 01 54 call 200d684 <_CORE_barrier_Initialize>
200d138: f2 24 60 10 st %i1, [ %l1 + 0x10 ]
200d13c: c2 14 60 0a lduh [ %l1 + 0xa ], %g1
200d140: c6 04 60 08 ld [ %l1 + 8 ], %g3
200d144: a4 14 a2 2c or %l2, 0x22c, %l2
200d148: c4 04 a0 1c ld [ %l2 + 0x1c ], %g2
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
200d14c: e0 24 60 0c st %l0, [ %l1 + 0xc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
200d150: 83 28 60 02 sll %g1, 2, %g1
&_Barrier_Information,
&the_barrier->Object,
(Objects_Name) name
);
*id = the_barrier->Object.id;
200d154: c6 26 c0 00 st %g3, [ %i3 ]
200d158: e2 20 80 01 st %l1, [ %g2 + %g1 ]
_Thread_Enable_dispatch();
200d15c: 7f ff ee e7 call 2008cf8 <_Thread_Enable_dispatch>
200d160: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
200d164: 81 c7 e0 08 ret
200d168: 81 e8 00 00 restore
if ( _Attributes_Is_barrier_automatic( attribute_set ) ) {
the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE;
if ( maximum_waiters == 0 )
return RTEMS_INVALID_NUMBER;
} else
the_attributes.discipline = CORE_BARRIER_MANUAL_RELEASE;
200d16c: 82 10 20 01 mov 1, %g1
200d170: c2 27 bf f8 st %g1, [ %fp + -8 ]
200d174: 03 00 80 76 sethi %hi(0x201d800), %g1
200d178: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 201dbb0 <_Thread_Dispatch_disable_level>
the_attributes.maximum_count = maximum_waiters;
200d17c: f4 27 bf fc st %i2, [ %fp + -4 ]
200d180: 84 00 a0 01 inc %g2
200d184: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ]
200d188: 25 00 80 77 sethi %hi(0x201dc00), %l2
200d18c: 7f ff ea e7 call 2007d28 <_Objects_Allocate>
200d190: 90 14 a2 2c or %l2, 0x22c, %o0 ! 201de2c <_Barrier_Information>
_Thread_Disable_dispatch(); /* prevents deletion */
the_barrier = _Barrier_Allocate();
if ( !the_barrier ) {
200d194: a2 92 20 00 orcc %o0, 0, %l1
200d198: 12 bf ff e6 bne 200d130 <rtems_barrier_create+0x60>
200d19c: 90 04 60 14 add %l1, 0x14, %o0
_Thread_Enable_dispatch();
200d1a0: 7f ff ee d6 call 2008cf8 <_Thread_Enable_dispatch>
200d1a4: b0 10 20 05 mov 5, %i0
return RTEMS_TOO_MANY;
200d1a8: 81 c7 e0 08 ret
200d1ac: 81 e8 00 00 restore
0200841c <rtems_io_register_driver>:
rtems_status_code rtems_io_register_driver(
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
200841c: 9d e3 bf a0 save %sp, -96, %sp
rtems_device_major_number major_limit = _IO_Number_of_drivers;
if ( rtems_interrupt_is_in_progress() )
2008420: 03 00 80 87 sethi %hi(0x2021c00), %g1
2008424: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 ! 2021c3c <_ISR_Nest_level>
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
rtems_device_major_number major_limit = _IO_Number_of_drivers;
2008428: 09 00 80 87 sethi %hi(0x2021c00), %g4
if ( rtems_interrupt_is_in_progress() )
200842c: 80 a0 60 00 cmp %g1, 0
2008430: 84 10 20 12 mov 0x12, %g2
rtems_status_code rtems_io_register_driver(
rtems_device_major_number major,
const rtems_driver_address_table *driver_table,
rtems_device_major_number *registered_major
)
{
2008434: 82 10 00 19 mov %i1, %g1
rtems_device_major_number major_limit = _IO_Number_of_drivers;
if ( rtems_interrupt_is_in_progress() )
2008438: 12 80 00 49 bne 200855c <rtems_io_register_driver+0x140>
200843c: c6 01 22 60 ld [ %g4 + 0x260 ], %g3
return RTEMS_CALLED_FROM_ISR;
if ( registered_major == NULL )
2008440: 80 a6 a0 00 cmp %i2, 0
2008444: 02 80 00 4b be 2008570 <rtems_io_register_driver+0x154>
2008448: 80 a6 60 00 cmp %i1, 0
return RTEMS_INVALID_ADDRESS;
/* Set it to an invalid value */
*registered_major = major_limit;
if ( driver_table == NULL )
200844c: 02 80 00 49 be 2008570 <rtems_io_register_driver+0x154>
2008450: c6 26 80 00 st %g3, [ %i2 ]
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
2008454: c4 06 40 00 ld [ %i1 ], %g2
2008458: 80 a0 a0 00 cmp %g2, 0
200845c: 22 80 00 42 be,a 2008564 <rtems_io_register_driver+0x148>
2008460: c4 06 60 04 ld [ %i1 + 4 ], %g2
return RTEMS_INVALID_ADDRESS;
if ( rtems_io_is_empty_table( driver_table ) )
return RTEMS_INVALID_ADDRESS;
if ( major >= major_limit )
2008464: 80 a0 c0 18 cmp %g3, %i0
2008468: 08 80 00 3d bleu 200855c <rtems_io_register_driver+0x140>
200846c: 84 10 20 0a mov 0xa, %g2
rtems_fatal_error_occurred( 99 );
}
}
#endif
_Thread_Dispatch_disable_level += 1;
2008470: 05 00 80 86 sethi %hi(0x2021800), %g2
2008474: c6 00 a3 a0 ld [ %g2 + 0x3a0 ], %g3 ! 2021ba0 <_Thread_Dispatch_disable_level>
2008478: 86 00 e0 01 inc %g3
200847c: c6 20 a3 a0 st %g3, [ %g2 + 0x3a0 ]
return RTEMS_INVALID_NUMBER;
_Thread_Disable_dispatch();
if ( major == 0 ) {
2008480: 80 a6 20 00 cmp %i0, 0
2008484: 12 80 00 2b bne 2008530 <rtems_io_register_driver+0x114>
2008488: 05 00 80 87 sethi %hi(0x2021c00), %g2
static rtems_status_code rtems_io_obtain_major_number(
rtems_device_major_number *major
)
{
rtems_device_major_number n = _IO_Number_of_drivers;
200848c: da 01 22 60 ld [ %g4 + 0x260 ], %o5
rtems_device_major_number m = 0;
/* major is error checked by caller */
for ( m = 0; m < n; ++m ) {
2008490: 80 a3 60 00 cmp %o5, 0
2008494: 02 80 00 3a be 200857c <rtems_io_register_driver+0x160> <== NEVER TAKEN
2008498: d8 00 a2 64 ld [ %g2 + 0x264 ], %o4
200849c: 10 80 00 05 b 20084b0 <rtems_io_register_driver+0x94>
20084a0: 86 10 00 0c mov %o4, %g3
20084a4: 80 a3 40 18 cmp %o5, %i0
20084a8: 08 80 00 0b bleu 20084d4 <rtems_io_register_driver+0xb8>
20084ac: 86 00 e0 18 add %g3, 0x18, %g3
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
20084b0: c8 00 c0 00 ld [ %g3 ], %g4
20084b4: 80 a1 20 00 cmp %g4, 0
20084b8: 32 bf ff fb bne,a 20084a4 <rtems_io_register_driver+0x88>
20084bc: b0 06 20 01 inc %i0
20084c0: c8 00 e0 04 ld [ %g3 + 4 ], %g4
20084c4: 80 a1 20 00 cmp %g4, 0
20084c8: 32 bf ff f7 bne,a 20084a4 <rtems_io_register_driver+0x88>
20084cc: b0 06 20 01 inc %i0
}
/* Assigns invalid value in case of failure */
*major = m;
if ( m != n )
20084d0: 80 a3 40 18 cmp %o5, %i0
20084d4: 02 80 00 2b be 2008580 <rtems_io_register_driver+0x164>
20084d8: f0 26 80 00 st %i0, [ %i2 ]
20084dc: 85 2e 20 03 sll %i0, 3, %g2
20084e0: 87 2e 20 05 sll %i0, 5, %g3
20084e4: 84 20 c0 02 sub %g3, %g2, %g2
20084e8: 84 03 00 02 add %o4, %g2, %g2
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
20084ec: c6 00 40 00 ld [ %g1 ], %g3
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
20084f0: b2 10 20 00 clr %i1
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
20084f4: c6 20 80 00 st %g3, [ %g2 ]
20084f8: c6 00 60 04 ld [ %g1 + 4 ], %g3
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
20084fc: b4 10 20 00 clr %i2
}
*registered_major = major;
}
_IO_Driver_address_table [major] = *driver_table;
2008500: c6 20 a0 04 st %g3, [ %g2 + 4 ]
2008504: c6 00 60 08 ld [ %g1 + 8 ], %g3
2008508: c6 20 a0 08 st %g3, [ %g2 + 8 ]
200850c: c6 00 60 0c ld [ %g1 + 0xc ], %g3
2008510: c6 20 a0 0c st %g3, [ %g2 + 0xc ]
2008514: c6 00 60 10 ld [ %g1 + 0x10 ], %g3
2008518: c6 20 a0 10 st %g3, [ %g2 + 0x10 ]
200851c: c2 00 60 14 ld [ %g1 + 0x14 ], %g1
_Thread_Enable_dispatch();
2008520: 40 00 07 2b call 200a1cc <_Thread_Enable_dispatch>
2008524: c2 20 a0 14 st %g1, [ %g2 + 0x14 ]
return rtems_io_initialize( major, 0, NULL );
2008528: 40 00 25 82 call 2011b30 <rtems_io_initialize>
200852c: 81 e8 00 00 restore
_Thread_Enable_dispatch();
return sc;
}
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
2008530: c6 00 a2 64 ld [ %g2 + 0x264 ], %g3
2008534: 89 2e 20 05 sll %i0, 5, %g4
2008538: 85 2e 20 03 sll %i0, 3, %g2
200853c: 84 21 00 02 sub %g4, %g2, %g2
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
2008540: c8 00 c0 02 ld [ %g3 + %g2 ], %g4
2008544: 80 a1 20 00 cmp %g4, 0
2008548: 02 80 00 12 be 2008590 <rtems_io_register_driver+0x174>
200854c: 84 00 c0 02 add %g3, %g2, %g2
major = *registered_major;
} else {
rtems_driver_address_table *const table = _IO_Driver_address_table + major;
if ( !rtems_io_is_empty_table( table ) ) {
_Thread_Enable_dispatch();
2008550: 40 00 07 1f call 200a1cc <_Thread_Enable_dispatch>
2008554: 01 00 00 00 nop
2008558: 84 10 20 0c mov 0xc, %g2 ! c <PROM_START+0xc>
_IO_Driver_address_table [major] = *driver_table;
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
}
200855c: 81 c7 e0 08 ret
2008560: 91 e8 00 02 restore %g0, %g2, %o0
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
2008564: 80 a0 a0 00 cmp %g2, 0
2008568: 12 bf ff c0 bne 2008468 <rtems_io_register_driver+0x4c>
200856c: 80 a0 c0 18 cmp %g3, %i0
_IO_Driver_address_table [major] = *driver_table;
_Thread_Enable_dispatch();
return rtems_io_initialize( major, 0, NULL );
2008570: 84 10 20 09 mov 9, %g2
}
2008574: 81 c7 e0 08 ret
2008578: 91 e8 00 02 restore %g0, %g2, %o0
if ( rtems_io_is_empty_table( table ) )
break;
}
/* Assigns invalid value in case of failure */
*major = m;
200857c: c0 26 80 00 clr [ %i2 ] <== NOT EXECUTED
if ( major == 0 ) {
rtems_status_code sc = rtems_io_obtain_major_number( registered_major );
if ( sc != RTEMS_SUCCESSFUL ) {
_Thread_Enable_dispatch();
2008580: 40 00 07 13 call 200a1cc <_Thread_Enable_dispatch>
2008584: 01 00 00 00 nop
return sc;
2008588: 10 bf ff f5 b 200855c <rtems_io_register_driver+0x140>
200858c: 84 10 20 05 mov 5, %g2 ! 5 <PROM_START+0x5>
static inline bool rtems_io_is_empty_table(
const rtems_driver_address_table *table
)
{
return table->initialization_entry == NULL && table->open_entry == NULL;
2008590: c6 00 a0 04 ld [ %g2 + 4 ], %g3
2008594: 80 a0 e0 00 cmp %g3, 0
2008598: 12 bf ff ee bne 2008550 <rtems_io_register_driver+0x134>
200859c: 01 00 00 00 nop
if ( !rtems_io_is_empty_table( table ) ) {
_Thread_Enable_dispatch();
return RTEMS_RESOURCE_IN_USE;
}
*registered_major = major;
20085a0: 10 bf ff d3 b 20084ec <rtems_io_register_driver+0xd0>
20085a4: f0 26 80 00 st %i0, [ %i2 ]
0200992c <rtems_iterate_over_all_threads>:
#include <rtems/system.h>
#include <rtems/score/thread.h>
void rtems_iterate_over_all_threads(rtems_per_thread_routine routine)
{
200992c: 9d e3 bf a0 save %sp, -96, %sp
uint32_t i;
uint32_t api_index;
Thread_Control *the_thread;
Objects_Information *information;
if ( !routine )
2009930: 80 a6 20 00 cmp %i0, 0
2009934: 02 80 00 23 be 20099c0 <rtems_iterate_over_all_threads+0x94><== NEVER TAKEN
2009938: 25 00 80 91 sethi %hi(0x2024400), %l2
200993c: a4 14 a3 14 or %l2, 0x314, %l2 ! 2024714 <_Objects_Information_table+0x4>
#endif
#include <rtems/system.h>
#include <rtems/score/thread.h>
void rtems_iterate_over_all_threads(rtems_per_thread_routine routine)
2009940: a6 04 a0 10 add %l2, 0x10, %l3
if ( !routine )
return;
for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
if ( !_Objects_Information_table[ api_index ] )
2009944: c2 04 80 00 ld [ %l2 ], %g1
2009948: 80 a0 60 00 cmp %g1, 0
200994c: 22 80 00 1a be,a 20099b4 <rtems_iterate_over_all_threads+0x88>
2009950: a4 04 a0 04 add %l2, 4, %l2
continue;
information = _Objects_Information_table[ api_index ][ 1 ];
2009954: e2 00 60 04 ld [ %g1 + 4 ], %l1
if ( !information )
2009958: 80 a4 60 00 cmp %l1, 0
200995c: 22 80 00 16 be,a 20099b4 <rtems_iterate_over_all_threads+0x88>
2009960: a4 04 a0 04 add %l2, 4, %l2
continue;
for ( i=1 ; i <= information->maximum ; i++ ) {
2009964: c2 14 60 10 lduh [ %l1 + 0x10 ], %g1
2009968: 84 90 60 00 orcc %g1, 0, %g2
200996c: 22 80 00 12 be,a 20099b4 <rtems_iterate_over_all_threads+0x88><== NEVER TAKEN
2009970: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED
2009974: a0 10 20 01 mov 1, %l0
the_thread = (Thread_Control *)information->local_table[ i ];
2009978: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
200997c: 83 2c 20 02 sll %l0, 2, %g1
2009980: c2 00 c0 01 ld [ %g3 + %g1 ], %g1
if ( !the_thread )
2009984: 90 90 60 00 orcc %g1, 0, %o0
2009988: 02 80 00 05 be 200999c <rtems_iterate_over_all_threads+0x70><== NEVER TAKEN
200998c: a0 04 20 01 inc %l0
continue;
(*routine)(the_thread);
2009990: 9f c6 00 00 call %i0
2009994: 01 00 00 00 nop
2009998: c4 14 60 10 lduh [ %l1 + 0x10 ], %g2
information = _Objects_Information_table[ api_index ][ 1 ];
if ( !information )
continue;
for ( i=1 ; i <= information->maximum ; i++ ) {
200999c: 83 28 a0 10 sll %g2, 0x10, %g1
20099a0: 83 30 60 10 srl %g1, 0x10, %g1
20099a4: 80 a0 40 10 cmp %g1, %l0
20099a8: 3a bf ff f5 bcc,a 200997c <rtems_iterate_over_all_threads+0x50>
20099ac: c6 04 60 1c ld [ %l1 + 0x1c ], %g3
20099b0: a4 04 a0 04 add %l2, 4, %l2
Objects_Information *information;
if ( !routine )
return;
for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; api_index++ ) {
20099b4: 80 a4 80 13 cmp %l2, %l3
20099b8: 32 bf ff e4 bne,a 2009948 <rtems_iterate_over_all_threads+0x1c>
20099bc: c2 04 80 00 ld [ %l2 ], %g1
20099c0: 81 c7 e0 08 ret
20099c4: 81 e8 00 00 restore
020084f8 <rtems_object_get_class_information>:
rtems_status_code rtems_object_get_class_information(
int the_api,
int the_class,
rtems_object_api_class_information *info
)
{
20084f8: 9d e3 bf a0 save %sp, -96, %sp
20084fc: 90 10 00 18 mov %i0, %o0
int i;
/*
* Validate parameters and look up information structure.
*/
if ( !info )
2008500: 80 a6 a0 00 cmp %i2, 0
2008504: 02 80 00 20 be 2008584 <rtems_object_get_class_information+0x8c>
2008508: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
obj_info = _Objects_Get_information( the_api, the_class );
200850c: 92 10 00 19 mov %i1, %o1
2008510: 40 00 07 55 call 200a264 <_Objects_Get_information>
2008514: b0 10 20 0a mov 0xa, %i0
if ( !obj_info )
2008518: 80 a2 20 00 cmp %o0, 0
200851c: 02 80 00 1a be 2008584 <rtems_object_get_class_information+0x8c>
2008520: 01 00 00 00 nop
return RTEMS_INVALID_NUMBER;
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
2008524: c2 02 20 08 ld [ %o0 + 8 ], %g1
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
2008528: c8 12 20 10 lduh [ %o0 + 0x10 ], %g4
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
200852c: c4 0a 20 12 ldub [ %o0 + 0x12 ], %g2
return RTEMS_INVALID_NUMBER;
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
2008530: c2 26 80 00 st %g1, [ %i2 ]
info->maximum_id = obj_info->maximum_id;
2008534: c2 02 20 0c ld [ %o0 + 0xc ], %g1
info->auto_extend = obj_info->auto_extend;
2008538: c4 2e a0 0c stb %g2, [ %i2 + 0xc ]
/*
* Return information about this object class to the user.
*/
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
200853c: c2 26 a0 04 st %g1, [ %i2 + 4 ]
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
2008540: c8 26 a0 08 st %g4, [ %i2 + 8 ]
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
2008544: 80 a1 20 00 cmp %g4, 0
2008548: 02 80 00 0d be 200857c <rtems_object_get_class_information+0x84><== NEVER TAKEN
200854c: 84 10 20 00 clr %g2
2008550: da 02 20 1c ld [ %o0 + 0x1c ], %o5
2008554: 86 10 20 01 mov 1, %g3
2008558: 82 10 20 01 mov 1, %g1
if ( !obj_info->local_table[i] )
200855c: 87 28 e0 02 sll %g3, 2, %g3
2008560: c6 03 40 03 ld [ %o5 + %g3 ], %g3
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
2008564: 82 00 60 01 inc %g1
if ( !obj_info->local_table[i] )
unallocated++;
2008568: 80 a0 00 03 cmp %g0, %g3
200856c: 84 60 bf ff subx %g2, -1, %g2
info->minimum_id = obj_info->minimum_id;
info->maximum_id = obj_info->maximum_id;
info->auto_extend = obj_info->auto_extend;
info->maximum = obj_info->maximum;
for ( unallocated=0, i=1 ; i <= info->maximum ; i++ )
2008570: 80 a1 00 01 cmp %g4, %g1
2008574: 1a bf ff fa bcc 200855c <rtems_object_get_class_information+0x64>
2008578: 86 10 00 01 mov %g1, %g3
if ( !obj_info->local_table[i] )
unallocated++;
info->unallocated = unallocated;
200857c: c4 26 a0 10 st %g2, [ %i2 + 0x10 ]
2008580: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
}
2008584: 81 c7 e0 08 ret
2008588: 81 e8 00 00 restore
02014734 <rtems_partition_create>:
uint32_t length,
uint32_t buffer_size,
rtems_attribute attribute_set,
rtems_id *id
)
{
2014734: 9d e3 bf a0 save %sp, -96, %sp
register Partition_Control *the_partition;
if ( !rtems_is_name_valid( name ) )
2014738: a0 96 20 00 orcc %i0, 0, %l0
201473c: 02 80 00 31 be 2014800 <rtems_partition_create+0xcc>
2014740: b0 10 20 03 mov 3, %i0
return RTEMS_INVALID_NAME;
if ( !starting_address )
2014744: 80 a6 60 00 cmp %i1, 0
2014748: 02 80 00 32 be 2014810 <rtems_partition_create+0xdc>
201474c: 80 a7 60 00 cmp %i5, 0
return RTEMS_INVALID_ADDRESS;
if ( !id )
2014750: 02 80 00 30 be 2014810 <rtems_partition_create+0xdc> <== NEVER TAKEN
2014754: 80 a6 e0 00 cmp %i3, 0
return RTEMS_INVALID_ADDRESS;
if ( length == 0 || buffer_size == 0 || length < buffer_size ||
2014758: 02 80 00 2c be 2014808 <rtems_partition_create+0xd4>
201475c: 80 a6 a0 00 cmp %i2, 0
2014760: 02 80 00 2a be 2014808 <rtems_partition_create+0xd4>
2014764: 80 a6 80 1b cmp %i2, %i3
2014768: 0a 80 00 28 bcs 2014808 <rtems_partition_create+0xd4>
201476c: 80 8e e0 07 btst 7, %i3
2014770: 12 80 00 26 bne 2014808 <rtems_partition_create+0xd4>
2014774: 80 8e 60 07 btst 7, %i1
!_Partition_Is_buffer_size_aligned( buffer_size ) )
return RTEMS_INVALID_SIZE;
if ( !_Addresses_Is_aligned( starting_address ) )
2014778: 12 80 00 26 bne 2014810 <rtems_partition_create+0xdc>
201477c: 03 00 80 fc sethi %hi(0x203f000), %g1
2014780: c4 00 63 80 ld [ %g1 + 0x380 ], %g2 ! 203f380 <_Thread_Dispatch_disable_level>
2014784: 84 00 a0 01 inc %g2
2014788: c4 20 63 80 st %g2, [ %g1 + 0x380 ]
* This function allocates a partition control block from
* the inactive chain of free partition control blocks.
*/
RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Allocate ( void )
{
return (Partition_Control *) _Objects_Allocate( &_Partition_Information );
201478c: 25 00 80 fc sethi %hi(0x203f000), %l2
2014790: 40 00 12 42 call 2019098 <_Objects_Allocate>
2014794: 90 14 a1 84 or %l2, 0x184, %o0 ! 203f184 <_Partition_Information>
_Thread_Disable_dispatch(); /* prevents deletion */
the_partition = _Partition_Allocate();
if ( !the_partition ) {
2014798: a2 92 20 00 orcc %o0, 0, %l1
201479c: 02 80 00 1f be 2014818 <rtems_partition_create+0xe4>
20147a0: 92 10 00 1b mov %i3, %o1
#endif
the_partition->starting_address = starting_address;
the_partition->length = length;
the_partition->buffer_size = buffer_size;
the_partition->attribute_set = attribute_set;
20147a4: f8 24 60 1c st %i4, [ %l1 + 0x1c ]
_Thread_Enable_dispatch();
return RTEMS_TOO_MANY;
}
#endif
the_partition->starting_address = starting_address;
20147a8: f2 24 60 10 st %i1, [ %l1 + 0x10 ]
the_partition->length = length;
20147ac: f4 24 60 14 st %i2, [ %l1 + 0x14 ]
the_partition->buffer_size = buffer_size;
20147b0: f6 24 60 18 st %i3, [ %l1 + 0x18 ]
the_partition->attribute_set = attribute_set;
the_partition->number_of_used_blocks = 0;
20147b4: c0 24 60 20 clr [ %l1 + 0x20 ]
_Chain_Initialize( &the_partition->Memory, starting_address,
20147b8: 40 00 66 f5 call 202e38c <.udiv>
20147bc: 90 10 00 1a mov %i2, %o0
20147c0: 92 10 00 19 mov %i1, %o1
20147c4: 94 10 00 08 mov %o0, %o2
20147c8: 96 10 00 1b mov %i3, %o3
20147cc: b8 04 60 24 add %l1, 0x24, %i4
20147d0: 40 00 0c ba call 2017ab8 <_Chain_Initialize>
20147d4: 90 10 00 1c mov %i4, %o0
20147d8: c2 14 60 0a lduh [ %l1 + 0xa ], %g1
20147dc: c6 04 60 08 ld [ %l1 + 8 ], %g3
20147e0: a4 14 a1 84 or %l2, 0x184, %l2
20147e4: c4 04 a0 1c ld [ %l2 + 0x1c ], %g2
information,
_Objects_Get_index( the_object->id ),
the_object
);
the_object->name = name;
20147e8: e0 24 60 0c st %l0, [ %l1 + 0xc ]
#if defined(RTEMS_DEBUG)
if ( index > information->maximum )
return;
#endif
information->local_table[ index ] = the_object;
20147ec: 83 28 60 02 sll %g1, 2, %g1
&_Partition_Information,
&the_partition->Object,
(Objects_Name) name
);
*id = the_partition->Object.id;
20147f0: c6 27 40 00 st %g3, [ %i5 ]
20147f4: e2 20 80 01 st %l1, [ %g2 + %g1 ]
name,
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
20147f8: 40 00 16 53 call 201a144 <_Thread_Enable_dispatch>
20147fc: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
2014800: 81 c7 e0 08 ret
2014804: 81 e8 00 00 restore
}
2014808: 81 c7 e0 08 ret
201480c: 91 e8 20 08 restore %g0, 8, %o0
0 /* Not used */
);
#endif
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
2014810: 81 c7 e0 08 ret
2014814: 91 e8 20 09 restore %g0, 9, %o0
_Thread_Disable_dispatch(); /* prevents deletion */
the_partition = _Partition_Allocate();
if ( !the_partition ) {
_Thread_Enable_dispatch();
2014818: 40 00 16 4b call 201a144 <_Thread_Enable_dispatch>
201481c: b0 10 20 05 mov 5, %i0
return RTEMS_TOO_MANY;
2014820: 81 c7 e0 08 ret
2014824: 81 e8 00 00 restore
02045888 <rtems_rate_monotonic_period>:
rtems_status_code rtems_rate_monotonic_period(
rtems_id id,
rtems_interval length
)
{
2045888: 9d e3 bf 98 save %sp, -104, %sp
204588c: 11 00 81 cd sethi %hi(0x2073400), %o0
2045890: 92 10 00 18 mov %i0, %o1
2045894: 90 12 23 30 or %o0, 0x330, %o0
2045898: 7f ff 27 0a call 200f4c0 <_Objects_Get>
204589c: 94 07 bf fc add %fp, -4, %o2
rtems_rate_monotonic_period_states local_state;
ISR_Level level;
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
20458a0: c2 07 bf fc ld [ %fp + -4 ], %g1
20458a4: 80 a0 60 00 cmp %g1, 0
20458a8: 02 80 00 04 be 20458b8 <rtems_rate_monotonic_period+0x30>
20458ac: a0 10 00 08 mov %o0, %l0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
20458b0: 81 c7 e0 08 ret
20458b4: 91 e8 20 04 restore %g0, 4, %o0
the_period = _Rate_monotonic_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
if ( !_Thread_Is_executing( the_period->owner ) ) {
20458b8: 23 00 81 cc sethi %hi(0x2073000), %l1
20458bc: c4 02 20 40 ld [ %o0 + 0x40 ], %g2
20458c0: c2 04 63 70 ld [ %l1 + 0x370 ], %g1
20458c4: 80 a0 80 01 cmp %g2, %g1
20458c8: 02 80 00 06 be 20458e0 <rtems_rate_monotonic_period+0x58>
20458cc: 80 a6 60 00 cmp %i1, 0
_Thread_Enable_dispatch();
20458d0: 7f ff 29 98 call 200ff30 <_Thread_Enable_dispatch>
20458d4: b0 10 20 17 mov 0x17, %i0
return RTEMS_NOT_OWNER_OF_RESOURCE;
20458d8: 81 c7 e0 08 ret
20458dc: 81 e8 00 00 restore
}
if ( length == RTEMS_PERIOD_STATUS ) {
20458e0: 12 80 00 0e bne 2045918 <rtems_rate_monotonic_period+0x90>
20458e4: 01 00 00 00 nop
switch ( the_period->state ) {
20458e8: c2 02 20 38 ld [ %o0 + 0x38 ], %g1
20458ec: 80 a0 60 04 cmp %g1, 4
20458f0: 18 80 00 06 bgu 2045908 <rtems_rate_monotonic_period+0x80><== NEVER TAKEN
20458f4: b0 10 20 00 clr %i0
20458f8: 83 28 60 02 sll %g1, 2, %g1
20458fc: 05 00 81 b5 sethi %hi(0x206d400), %g2
2045900: 84 10 a0 48 or %g2, 0x48, %g2 ! 206d448 <CSWTCH.48>
2045904: f0 00 80 01 ld [ %g2 + %g1 ], %i0
);
the_period->next_length = length;
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
2045908: 7f ff 29 8a call 200ff30 <_Thread_Enable_dispatch>
204590c: 01 00 00 00 nop
return RTEMS_SUCCESSFUL;
2045910: 81 c7 e0 08 ret
2045914: 81 e8 00 00 restore
}
_Thread_Enable_dispatch();
return( return_value );
}
_ISR_Disable( level );
2045918: 7f fe f8 42 call 2003a20 <sparc_disable_interrupts>
204591c: 01 00 00 00 nop
2045920: a6 10 00 08 mov %o0, %l3
switch ( the_period->state ) {
2045924: e4 04 20 38 ld [ %l0 + 0x38 ], %l2
2045928: 80 a4 a0 02 cmp %l2, 2
204592c: 02 80 00 1a be 2045994 <rtems_rate_monotonic_period+0x10c>
2045930: 80 a4 a0 04 cmp %l2, 4
2045934: 02 80 00 32 be 20459fc <rtems_rate_monotonic_period+0x174>
2045938: 80 a4 a0 00 cmp %l2, 0
204593c: 12 bf ff dd bne 20458b0 <rtems_rate_monotonic_period+0x28><== NEVER TAKEN
2045940: 01 00 00 00 nop
case RATE_MONOTONIC_INACTIVE: {
_ISR_Enable( level );
2045944: 7f fe f8 3b call 2003a30 <sparc_enable_interrupts>
2045948: 01 00 00 00 nop
/*
* Baseline statistics information for the beginning of a period.
*/
_Rate_monotonic_Initiate_statistics( the_period );
204594c: 7f ff ff 48 call 204566c <_Rate_monotonic_Initiate_statistics>
2045950: 90 10 00 10 mov %l0, %o0
the_period->state = RATE_MONOTONIC_ACTIVE;
2045954: 82 10 20 02 mov 2, %g1
2045958: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
204595c: 03 00 81 16 sethi %hi(0x2045800), %g1
2045960: 82 10 62 4c or %g1, 0x24c, %g1 ! 2045a4c <_Rate_monotonic_Timeout>
the_watchdog->id = id;
2045964: f0 24 20 30 st %i0, [ %l0 + 0x30 ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2045968: 92 04 20 10 add %l0, 0x10, %o1
204596c: 11 00 81 cc sethi %hi(0x2073000), %o0
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2045970: f2 24 20 1c st %i1, [ %l0 + 0x1c ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2045974: 90 12 23 90 or %o0, 0x390, %o0
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2045978: c0 24 20 18 clr [ %l0 + 0x18 ]
the_watchdog->routine = routine;
the_watchdog->id = id;
the_watchdog->user_data = user_data;
204597c: c0 24 20 34 clr [ %l0 + 0x34 ]
_Rate_monotonic_Timeout,
id,
NULL
);
the_period->next_length = length;
2045980: f2 24 20 3c st %i1, [ %l0 + 0x3c ]
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2045984: c2 24 20 2c st %g1, [ %l0 + 0x2c ]
)
{
the_watchdog->initial = units;
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2045988: 7f ff 2e 10 call 20111c8 <_Watchdog_Insert>
204598c: b0 10 20 00 clr %i0
2045990: 30 bf ff de b,a 2045908 <rtems_rate_monotonic_period+0x80>
case RATE_MONOTONIC_ACTIVE:
/*
* Update statistics from the concluding period.
*/
_Rate_monotonic_Update_statistics( the_period );
2045994: 7f ff ff 7d call 2045788 <_Rate_monotonic_Update_statistics>
2045998: 90 10 00 10 mov %l0, %o0
/*
* This tells the _Rate_monotonic_Timeout that this task is
* in the process of blocking on the period and that we
* may be changing the length of the next period.
*/
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
204599c: 82 10 20 01 mov 1, %g1
the_period->next_length = length;
20459a0: f2 24 20 3c st %i1, [ %l0 + 0x3c ]
/*
* This tells the _Rate_monotonic_Timeout that this task is
* in the process of blocking on the period and that we
* may be changing the length of the next period.
*/
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
20459a4: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
the_period->next_length = length;
_ISR_Enable( level );
20459a8: 7f fe f8 22 call 2003a30 <sparc_enable_interrupts>
20459ac: 90 10 00 13 mov %l3, %o0
_Thread_Executing->Wait.id = the_period->Object.id;
20459b0: c2 04 63 70 ld [ %l1 + 0x370 ], %g1
20459b4: c4 04 20 08 ld [ %l0 + 8 ], %g2
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
20459b8: 90 10 00 01 mov %g1, %o0
the_period->state = RATE_MONOTONIC_OWNER_IS_BLOCKING;
the_period->next_length = length;
_ISR_Enable( level );
_Thread_Executing->Wait.id = the_period->Object.id;
20459bc: c4 20 60 20 st %g2, [ %g1 + 0x20 ]
_Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
20459c0: 7f ff 2b f8 call 20109a0 <_Thread_Set_state>
20459c4: 13 00 00 10 sethi %hi(0x4000), %o1
/*
* Did the watchdog timer expire while we were actually blocking
* on it?
*/
_ISR_Disable( level );
20459c8: 7f fe f8 16 call 2003a20 <sparc_disable_interrupts>
20459cc: 01 00 00 00 nop
local_state = the_period->state;
20459d0: e6 04 20 38 ld [ %l0 + 0x38 ], %l3
the_period->state = RATE_MONOTONIC_ACTIVE;
20459d4: e4 24 20 38 st %l2, [ %l0 + 0x38 ]
_ISR_Enable( level );
20459d8: 7f fe f8 16 call 2003a30 <sparc_enable_interrupts>
20459dc: 01 00 00 00 nop
/*
* If it did, then we want to unblock ourself and continue as
* if nothing happen. The period was reset in the timeout routine.
*/
if ( local_state == RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING )
20459e0: 80 a4 e0 03 cmp %l3, 3
20459e4: 02 80 00 17 be 2045a40 <rtems_rate_monotonic_period+0x1b8>
20459e8: d0 04 63 70 ld [ %l1 + 0x370 ], %o0
_Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
_Thread_Enable_dispatch();
20459ec: 7f ff 29 51 call 200ff30 <_Thread_Enable_dispatch>
20459f0: b0 10 20 00 clr %i0
return RTEMS_SUCCESSFUL;
20459f4: 81 c7 e0 08 ret
20459f8: 81 e8 00 00 restore
case RATE_MONOTONIC_EXPIRED:
/*
* Update statistics from the concluding period
*/
_Rate_monotonic_Update_statistics( the_period );
20459fc: 7f ff ff 63 call 2045788 <_Rate_monotonic_Update_statistics>
2045a00: 90 10 00 10 mov %l0, %o0
_ISR_Enable( level );
2045a04: 7f fe f8 0b call 2003a30 <sparc_enable_interrupts>
2045a08: 90 10 00 13 mov %l3, %o0
the_period->state = RATE_MONOTONIC_ACTIVE;
2045a0c: 82 10 20 02 mov 2, %g1
2045a10: 92 04 20 10 add %l0, 0x10, %o1
2045a14: 11 00 81 cc sethi %hi(0x2073000), %o0
2045a18: 90 12 23 90 or %o0, 0x390, %o0 ! 2073390 <_Watchdog_Ticks_chain>
Watchdog_Control *the_watchdog,
Watchdog_Interval units
)
{
the_watchdog->initial = units;
2045a1c: f2 24 20 1c st %i1, [ %l0 + 0x1c ]
the_period->next_length = length;
2045a20: f2 24 20 3c st %i1, [ %l0 + 0x3c ]
*/
_Rate_monotonic_Update_statistics( the_period );
_ISR_Enable( level );
the_period->state = RATE_MONOTONIC_ACTIVE;
2045a24: c2 24 20 38 st %g1, [ %l0 + 0x38 ]
_Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog );
2045a28: 7f ff 2d e8 call 20111c8 <_Watchdog_Insert>
2045a2c: b0 10 20 06 mov 6, %i0
the_period->next_length = length;
_Watchdog_Insert_ticks( &the_period->Timer, length );
_Thread_Enable_dispatch();
2045a30: 7f ff 29 40 call 200ff30 <_Thread_Enable_dispatch>
2045a34: 01 00 00 00 nop
return RTEMS_TIMEOUT;
2045a38: 81 c7 e0 08 ret
2045a3c: 81 e8 00 00 restore
/*
* If it did, then we want to unblock ourself and continue as
* if nothing happen. The period was reset in the timeout routine.
*/
if ( local_state == RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING )
_Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD );
2045a40: 7f ff 28 22 call 200fac8 <_Thread_Clear_state>
2045a44: 13 00 00 10 sethi %hi(0x4000), %o1
2045a48: 30 bf ff e9 b,a 20459ec <rtems_rate_monotonic_period+0x164>
0202f098 <rtems_rate_monotonic_report_statistics_with_plugin>:
*/
void rtems_rate_monotonic_report_statistics_with_plugin(
void *context,
rtems_printk_plugin_t print
)
{
202f098: 9d e3 bf 30 save %sp, -208, %sp
rtems_id id;
rtems_rate_monotonic_period_statistics the_stats;
rtems_rate_monotonic_period_status the_status;
char name[5];
if ( !print )
202f09c: 80 a6 60 00 cmp %i1, 0
202f0a0: 02 80 00 4d be 202f1d4 <rtems_rate_monotonic_report_statistics_with_plugin+0x13c><== NEVER TAKEN
202f0a4: 90 10 00 18 mov %i0, %o0
return;
(*print)( context, "Period information by period\n" );
202f0a8: 13 00 81 a5 sethi %hi(0x2069400), %o1
202f0ac: 9f c6 40 00 call %i1
202f0b0: 92 12 63 c0 or %o1, 0x3c0, %o1 ! 20697c0 <_TOD_Days_per_month+0x6c>
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
(*print)( context, "--- CPU times are in seconds ---\n" );
202f0b4: 90 10 00 18 mov %i0, %o0
202f0b8: 13 00 81 a5 sethi %hi(0x2069400), %o1
202f0bc: 9f c6 40 00 call %i1
202f0c0: 92 12 63 e0 or %o1, 0x3e0, %o1 ! 20697e0 <_TOD_Days_per_month+0x8c>
(*print)( context, "--- Wall times are in seconds ---\n" );
202f0c4: 90 10 00 18 mov %i0, %o0
202f0c8: 13 00 81 a6 sethi %hi(0x2069800), %o1
202f0cc: 9f c6 40 00 call %i1
202f0d0: 92 12 60 08 or %o1, 8, %o1 ! 2069808 <_TOD_Days_per_month+0xb4>
Be sure to test the various cases.
(*print)( context,"\
1234567890123456789012345678901234567890123456789012345678901234567890123456789\
\n");
*/
(*print)( context, " ID OWNER COUNT MISSED "
202f0d4: 90 10 00 18 mov %i0, %o0
202f0d8: 13 00 81 a6 sethi %hi(0x2069800), %o1
202f0dc: 9f c6 40 00 call %i1
202f0e0: 92 12 60 30 or %o1, 0x30, %o1 ! 2069830 <_TOD_Days_per_month+0xdc>
#ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__
" "
#endif
" WALL TIME\n"
);
(*print)( context, " "
202f0e4: 90 10 00 18 mov %i0, %o0
202f0e8: 13 00 81 a6 sethi %hi(0x2069800), %o1
202f0ec: 9f c6 40 00 call %i1
202f0f0: 92 12 60 80 or %o1, 0x80, %o1 ! 2069880 <_TOD_Days_per_month+0x12c>
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f0f4: 23 00 81 cd sethi %hi(0x2073400), %l1
202f0f8: a2 14 63 30 or %l1, 0x330, %l1 ! 2073730 <_Rate_monotonic_Information>
202f0fc: e0 04 60 08 ld [ %l1 + 8 ], %l0
202f100: c2 04 60 0c ld [ %l1 + 0xc ], %g1
202f104: 80 a4 00 01 cmp %l0, %g1
202f108: 18 80 00 33 bgu 202f1d4 <rtems_rate_monotonic_report_statistics_with_plugin+0x13c><== NEVER TAKEN
202f10c: 3b 00 81 a6 sethi %hi(0x2069800), %i5
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
(*print)( context,
202f110: 39 00 81 a6 sethi %hi(0x2069800), %i4
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
(*print)( context,
202f114: 35 00 81 a6 sethi %hi(0x2069800), %i2
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
(*print)( context, "\n" );
202f118: 2f 00 81 a6 sethi %hi(0x2069800), %l7
rtems_object_get_name( the_status.owner, sizeof(name), name );
/*
* Print part of report line that is not dependent on granularity
*/
(*print)( context,
202f11c: ba 17 60 d0 or %i5, 0xd0, %i5
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
(*print)( context,
202f120: b8 17 20 f0 or %i4, 0xf0, %i4
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
(*print)( context,
202f124: b4 16 a1 10 or %i2, 0x110, %i2
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
(*print)( context, "\n" );
202f128: ae 15 e0 e8 or %l7, 0xe8, %l7
202f12c: a4 07 bf a0 add %fp, -96, %l2
status = rtems_rate_monotonic_get_statistics( id, &the_stats );
if ( status != RTEMS_SUCCESSFUL )
continue;
/* If the above passed, so should this but check it anyway */
status = rtems_rate_monotonic_get_status( id, &the_status );
202f130: ac 07 bf d8 add %fp, -40, %l6
#if defined(RTEMS_DEBUG)
if ( status != RTEMS_SUCCESSFUL )
continue;
#endif
rtems_object_get_name( the_status.owner, sizeof(name), name );
202f134: a6 07 bf f8 add %fp, -8, %l3
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
202f138: aa 07 bf b8 add %fp, -72, %l5
202f13c: 10 80 00 06 b 202f154 <rtems_rate_monotonic_report_statistics_with_plugin+0xbc>
202f140: a8 07 bf f0 add %fp, -16, %l4
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
202f144: a0 04 20 01 inc %l0
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f148: 80 a0 40 10 cmp %g1, %l0
202f14c: 0a 80 00 22 bcs 202f1d4 <rtems_rate_monotonic_report_statistics_with_plugin+0x13c>
202f150: 01 00 00 00 nop
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
status = rtems_rate_monotonic_get_statistics( id, &the_stats );
202f154: 90 10 00 10 mov %l0, %o0
202f158: 40 00 58 e5 call 20454ec <rtems_rate_monotonic_get_statistics>
202f15c: 92 10 00 12 mov %l2, %o1
if ( status != RTEMS_SUCCESSFUL )
202f160: 80 a2 20 00 cmp %o0, 0
202f164: 32 bf ff f8 bne,a 202f144 <rtems_rate_monotonic_report_statistics_with_plugin+0xac>
202f168: c2 04 60 0c ld [ %l1 + 0xc ], %g1
continue;
/* If the above passed, so should this but check it anyway */
status = rtems_rate_monotonic_get_status( id, &the_status );
202f16c: 92 10 00 16 mov %l6, %o1
202f170: 40 00 59 0e call 20455a8 <rtems_rate_monotonic_get_status>
202f174: 90 10 00 10 mov %l0, %o0
#if defined(RTEMS_DEBUG)
if ( status != RTEMS_SUCCESSFUL )
continue;
#endif
rtems_object_get_name( the_status.owner, sizeof(name), name );
202f178: d0 07 bf d8 ld [ %fp + -40 ], %o0
202f17c: 94 10 00 13 mov %l3, %o2
202f180: 7f ff 78 70 call 200d340 <rtems_object_get_name>
202f184: 92 10 20 05 mov 5, %o1
/*
* Print part of report line that is not dependent on granularity
*/
(*print)( context,
202f188: d8 1f bf a0 ldd [ %fp + -96 ], %o4
202f18c: 92 10 00 1d mov %i5, %o1
202f190: 94 10 00 10 mov %l0, %o2
202f194: 90 10 00 18 mov %i0, %o0
202f198: 9f c6 40 00 call %i1
202f19c: 96 10 00 13 mov %l3, %o3
);
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
202f1a0: c2 07 bf a0 ld [ %fp + -96 ], %g1
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
202f1a4: 94 10 00 14 mov %l4, %o2
202f1a8: 90 10 00 15 mov %l5, %o0
);
/*
* If the count is zero, don't print statistics
*/
if (the_stats.count == 0) {
202f1ac: 80 a0 60 00 cmp %g1, 0
202f1b0: 12 80 00 0b bne 202f1dc <rtems_rate_monotonic_report_statistics_with_plugin+0x144>
202f1b4: 92 10 00 17 mov %l7, %o1
(*print)( context, "\n" );
202f1b8: 9f c6 40 00 call %i1
202f1bc: 90 10 00 18 mov %i0, %o0
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f1c0: c2 04 60 0c ld [ %l1 + 0xc ], %g1
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
202f1c4: a0 04 20 01 inc %l0
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f1c8: 80 a0 40 10 cmp %g1, %l0
202f1cc: 1a bf ff e3 bcc 202f158 <rtems_rate_monotonic_report_statistics_with_plugin+0xc0><== ALWAYS TAKEN
202f1d0: 90 10 00 10 mov %l0, %o0
202f1d4: 81 c7 e0 08 ret
202f1d8: 81 e8 00 00 restore
struct timespec cpu_average;
struct timespec *min_cpu = &the_stats.min_cpu_time;
struct timespec *max_cpu = &the_stats.max_cpu_time;
struct timespec *total_cpu = &the_stats.total_cpu_time;
_Timespec_Divide_by_integer( total_cpu, the_stats.count, &cpu_average );
202f1dc: 40 00 05 b6 call 20308b4 <_Timespec_Divide_by_integer>
202f1e0: 92 10 00 01 mov %g1, %o1
(*print)( context,
202f1e4: d0 07 bf ac ld [ %fp + -84 ], %o0
202f1e8: 40 00 c7 c6 call 2061100 <.div>
202f1ec: 92 10 23 e8 mov 0x3e8, %o1
202f1f0: 96 10 00 08 mov %o0, %o3
202f1f4: d0 07 bf b4 ld [ %fp + -76 ], %o0
202f1f8: d6 27 bf 9c st %o3, [ %fp + -100 ]
202f1fc: 40 00 c7 c1 call 2061100 <.div>
202f200: 92 10 23 e8 mov 0x3e8, %o1
202f204: c2 07 bf f0 ld [ %fp + -16 ], %g1
202f208: b6 10 00 08 mov %o0, %i3
202f20c: d0 07 bf f4 ld [ %fp + -12 ], %o0
202f210: c2 23 a0 5c st %g1, [ %sp + 0x5c ]
202f214: 40 00 c7 bb call 2061100 <.div>
202f218: 92 10 23 e8 mov 0x3e8, %o1
202f21c: d8 07 bf b0 ld [ %fp + -80 ], %o4
202f220: d6 07 bf 9c ld [ %fp + -100 ], %o3
202f224: d4 07 bf a8 ld [ %fp + -88 ], %o2
202f228: 9a 10 00 1b mov %i3, %o5
202f22c: d0 23 a0 60 st %o0, [ %sp + 0x60 ]
202f230: 92 10 00 1c mov %i4, %o1
202f234: 9f c6 40 00 call %i1
202f238: 90 10 00 18 mov %i0, %o0
struct timespec wall_average;
struct timespec *min_wall = &the_stats.min_wall_time;
struct timespec *max_wall = &the_stats.max_wall_time;
struct timespec *total_wall = &the_stats.total_wall_time;
_Timespec_Divide_by_integer(total_wall, the_stats.count, &wall_average);
202f23c: d2 07 bf a0 ld [ %fp + -96 ], %o1
202f240: 94 10 00 14 mov %l4, %o2
202f244: 40 00 05 9c call 20308b4 <_Timespec_Divide_by_integer>
202f248: 90 07 bf d0 add %fp, -48, %o0
(*print)( context,
202f24c: d0 07 bf c4 ld [ %fp + -60 ], %o0
202f250: 40 00 c7 ac call 2061100 <.div>
202f254: 92 10 23 e8 mov 0x3e8, %o1
202f258: 96 10 00 08 mov %o0, %o3
202f25c: d0 07 bf cc ld [ %fp + -52 ], %o0
202f260: d6 27 bf 9c st %o3, [ %fp + -100 ]
202f264: 40 00 c7 a7 call 2061100 <.div>
202f268: 92 10 23 e8 mov 0x3e8, %o1
202f26c: c2 07 bf f0 ld [ %fp + -16 ], %g1
202f270: b6 10 00 08 mov %o0, %i3
202f274: d0 07 bf f4 ld [ %fp + -12 ], %o0
202f278: c2 23 a0 5c st %g1, [ %sp + 0x5c ]
202f27c: 40 00 c7 a1 call 2061100 <.div>
202f280: 92 10 23 e8 mov 0x3e8, %o1
202f284: d4 07 bf c0 ld [ %fp + -64 ], %o2
202f288: d6 07 bf 9c ld [ %fp + -100 ], %o3
202f28c: d8 07 bf c8 ld [ %fp + -56 ], %o4
202f290: d0 23 a0 60 st %o0, [ %sp + 0x60 ]
202f294: 9a 10 00 1b mov %i3, %o5
202f298: 90 10 00 18 mov %i0, %o0
202f29c: 9f c6 40 00 call %i1
202f2a0: 92 10 00 1a mov %i2, %o1
/*
* Cycle through all possible ids and try to report on each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f2a4: 10 bf ff a8 b 202f144 <rtems_rate_monotonic_report_statistics_with_plugin+0xac>
202f2a8: c2 04 60 0c ld [ %l1 + 0xc ], %g1
0202f2c8 <rtems_rate_monotonic_reset_all_statistics>:
/*
* rtems_rate_monotonic_reset_all_statistics
*/
void rtems_rate_monotonic_reset_all_statistics( void )
{
202f2c8: 9d e3 bf a0 save %sp, -96, %sp
202f2cc: 03 00 81 cc sethi %hi(0x2073000), %g1
202f2d0: c4 00 62 b0 ld [ %g1 + 0x2b0 ], %g2 ! 20732b0 <_Thread_Dispatch_disable_level>
202f2d4: 84 00 a0 01 inc %g2
202f2d8: c4 20 62 b0 st %g2, [ %g1 + 0x2b0 ]
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f2dc: 23 00 81 cd sethi %hi(0x2073400), %l1
202f2e0: a2 14 63 30 or %l1, 0x330, %l1 ! 2073730 <_Rate_monotonic_Information>
202f2e4: e0 04 60 08 ld [ %l1 + 8 ], %l0
202f2e8: c2 04 60 0c ld [ %l1 + 0xc ], %g1
202f2ec: 80 a4 00 01 cmp %l0, %g1
202f2f0: 18 80 00 09 bgu 202f314 <rtems_rate_monotonic_reset_all_statistics+0x4c><== NEVER TAKEN
202f2f4: 01 00 00 00 nop
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
status = rtems_rate_monotonic_reset_statistics( id );
202f2f8: 40 00 00 0a call 202f320 <rtems_rate_monotonic_reset_statistics>
202f2fc: 90 10 00 10 mov %l0, %o0
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f300: c2 04 60 0c ld [ %l1 + 0xc ], %g1
id <= _Rate_monotonic_Information.maximum_id ;
id++ ) {
202f304: a0 04 20 01 inc %l0
/*
* Cycle through all possible ids and try to reset each one. If it
* is a period that is inactive, we just get an error back. No big deal.
*/
for ( id=_Rate_monotonic_Information.minimum_id ;
202f308: 80 a0 40 10 cmp %g1, %l0
202f30c: 1a bf ff fb bcc 202f2f8 <rtems_rate_monotonic_reset_all_statistics+0x30>
202f310: 01 00 00 00 nop
}
/*
* Done so exit thread dispatching disabled critical section.
*/
_Thread_Enable_dispatch();
202f314: 7f ff 83 07 call 200ff30 <_Thread_Enable_dispatch>
202f318: 81 e8 00 00 restore
02015618 <rtems_region_get_segment_size>:
rtems_status_code rtems_region_get_segment_size(
rtems_id id,
void *segment,
uintptr_t *size
)
{
2015618: 9d e3 bf 98 save %sp, -104, %sp
Objects_Locations location;
rtems_status_code return_status = RTEMS_SUCCESSFUL;
register Region_Control *the_region;
if ( !segment )
201561c: 80 a6 60 00 cmp %i1, 0
2015620: 02 80 00 22 be 20156a8 <rtems_region_get_segment_size+0x90>
2015624: 80 a6 a0 00 cmp %i2, 0
return RTEMS_INVALID_ADDRESS;
if ( !size )
2015628: 02 80 00 20 be 20156a8 <rtems_region_get_segment_size+0x90>
201562c: 21 00 80 fd sethi %hi(0x203f400), %l0
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
2015630: 40 00 08 d7 call 201798c <_API_Mutex_Lock>
2015634: d0 04 20 38 ld [ %l0 + 0x38 ], %o0 ! 203f438 <_RTEMS_Allocator_Mutex>
2015638: 92 10 00 18 mov %i0, %o1
201563c: 11 00 80 fc sethi %hi(0x203f000), %o0
2015640: 94 07 bf fc add %fp, -4, %o2
2015644: 40 00 0f e9 call 20195e8 <_Objects_Get_no_protection>
2015648: 90 12 22 04 or %o0, 0x204, %o0
the_region = _Region_Get( id, &location );
switch ( location ) {
201564c: c2 07 bf fc ld [ %fp + -4 ], %g1
2015650: 80 a0 60 00 cmp %g1, 0
2015654: 12 80 00 0f bne 2015690 <rtems_region_get_segment_size+0x78>
2015658: 80 a0 60 01 cmp %g1, 1
case OBJECTS_LOCAL:
if ( !_Heap_Size_of_alloc_area( &the_region->Memory, segment, size ) )
201565c: 90 02 20 68 add %o0, 0x68, %o0
2015660: 92 10 00 19 mov %i1, %o1
2015664: 94 10 00 1a mov %i2, %o2
2015668: 40 00 0e 3d call 2018f5c <_Heap_Size_of_alloc_area>
201566c: b0 10 20 09 mov 9, %i0
2015670: 80 8a 20 ff btst 0xff, %o0
2015674: 02 80 00 03 be 2015680 <rtems_region_get_segment_size+0x68><== NEVER TAKEN
2015678: 01 00 00 00 nop
201567c: b0 10 20 00 clr %i0 ! 0 <PROM_START>
case OBJECTS_ERROR:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
2015680: 40 00 08 d9 call 20179e4 <_API_Mutex_Unlock>
2015684: d0 04 20 38 ld [ %l0 + 0x38 ], %o0
return return_status;
2015688: 81 c7 e0 08 ret
201568c: 81 e8 00 00 restore
return RTEMS_INVALID_ADDRESS;
_RTEMS_Lock_allocator();
the_region = _Region_Get( id, &location );
switch ( location ) {
2015690: 12 bf ff fb bne 201567c <rtems_region_get_segment_size+0x64><== NEVER TAKEN
2015694: b0 10 20 04 mov 4, %i0
case OBJECTS_ERROR:
return_status = RTEMS_INVALID_ID;
break;
}
_RTEMS_Unlock_allocator();
2015698: 40 00 08 d3 call 20179e4 <_API_Mutex_Unlock>
201569c: d0 04 20 38 ld [ %l0 + 0x38 ], %o0
return return_status;
20156a0: 81 c7 e0 08 ret
20156a4: 81 e8 00 00 restore
}
20156a8: 81 c7 e0 08 ret
20156ac: 91 e8 20 09 restore %g0, 9, %o0
02015d3c <rtems_signal_send>:
rtems_status_code rtems_signal_send(
rtems_id id,
rtems_signal_set signal_set
)
{
2015d3c: 9d e3 bf 98 save %sp, -104, %sp
register Thread_Control *the_thread;
Objects_Locations location;
RTEMS_API_Control *api;
ASR_Information *asr;
if ( !signal_set )
2015d40: 80 a6 60 00 cmp %i1, 0
2015d44: 12 80 00 04 bne 2015d54 <rtems_signal_send+0x18>
2015d48: 82 10 20 0a mov 0xa, %g1
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2015d4c: 81 c7 e0 08 ret
2015d50: 91 e8 00 01 restore %g0, %g1, %o0
ASR_Information *asr;
if ( !signal_set )
return RTEMS_INVALID_NUMBER;
the_thread = _Thread_Get( id, &location );
2015d54: 90 10 00 18 mov %i0, %o0
2015d58: 40 00 11 1f call 201a1d4 <_Thread_Get>
2015d5c: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
2015d60: c4 07 bf fc ld [ %fp + -4 ], %g2
ASR_Information *asr;
if ( !signal_set )
return RTEMS_INVALID_NUMBER;
the_thread = _Thread_Get( id, &location );
2015d64: a2 10 00 08 mov %o0, %l1
switch ( location ) {
2015d68: 80 a0 a0 00 cmp %g2, 0
2015d6c: 12 bf ff f8 bne 2015d4c <rtems_signal_send+0x10>
2015d70: 82 10 20 04 mov 4, %g1
case OBJECTS_LOCAL:
api = the_thread->API_Extensions[ THREAD_API_RTEMS ];
2015d74: e0 02 21 60 ld [ %o0 + 0x160 ], %l0
asr = &api->Signal;
2015d78: c2 04 20 0c ld [ %l0 + 0xc ], %g1
2015d7c: 80 a0 60 00 cmp %g1, 0
2015d80: 02 80 00 26 be 2015e18 <rtems_signal_send+0xdc>
2015d84: 01 00 00 00 nop
if ( ! _ASR_Is_null_handler( asr->handler ) ) {
if ( asr->is_enabled ) {
2015d88: c2 0c 20 08 ldub [ %l0 + 8 ], %g1
2015d8c: 80 a0 60 00 cmp %g1, 0
2015d90: 02 80 00 16 be 2015de8 <rtems_signal_send+0xac>
2015d94: 01 00 00 00 nop
rtems_signal_set *signal_set
)
{
ISR_Level _level;
_ISR_Disable( _level );
2015d98: 7f ff e5 a8 call 200f438 <sparc_disable_interrupts>
2015d9c: 01 00 00 00 nop
*signal_set |= signals;
2015da0: c2 04 20 14 ld [ %l0 + 0x14 ], %g1
2015da4: b2 10 40 19 or %g1, %i1, %i1
2015da8: f2 24 20 14 st %i1, [ %l0 + 0x14 ]
_ISR_Enable( _level );
2015dac: 7f ff e5 a7 call 200f448 <sparc_enable_interrupts>
2015db0: 01 00 00 00 nop
_ASR_Post_signals( signal_set, &asr->signals_posted );
the_thread->do_post_task_switch_extension = true;
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
2015db4: 03 00 80 fd sethi %hi(0x203f400), %g1
2015db8: c4 00 60 1c ld [ %g1 + 0x1c ], %g2 ! 203f41c <_ISR_Nest_level>
if ( ! _ASR_Is_null_handler( asr->handler ) ) {
if ( asr->is_enabled ) {
_ASR_Post_signals( signal_set, &asr->signals_posted );
the_thread->do_post_task_switch_extension = true;
2015dbc: 82 10 20 01 mov 1, %g1
if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) )
2015dc0: 80 a0 a0 00 cmp %g2, 0
2015dc4: 02 80 00 10 be 2015e04 <rtems_signal_send+0xc8>
2015dc8: c2 2c 60 74 stb %g1, [ %l1 + 0x74 ]
2015dcc: 05 00 80 fd sethi %hi(0x203f400), %g2
2015dd0: c4 00 a0 40 ld [ %g2 + 0x40 ], %g2 ! 203f440 <_Thread_Executing>
2015dd4: 80 a4 40 02 cmp %l1, %g2
2015dd8: 12 80 00 0b bne 2015e04 <rtems_signal_send+0xc8> <== NEVER TAKEN
2015ddc: 05 00 80 fd sethi %hi(0x203f400), %g2
_ISR_Signals_to_thread_executing = true;
2015de0: 10 80 00 09 b 2015e04 <rtems_signal_send+0xc8>
2015de4: c2 28 a0 d8 stb %g1, [ %g2 + 0xd8 ] ! 203f4d8 <_ISR_Signals_to_thread_executing>
rtems_signal_set *signal_set
)
{
ISR_Level _level;
_ISR_Disable( _level );
2015de8: 7f ff e5 94 call 200f438 <sparc_disable_interrupts>
2015dec: 01 00 00 00 nop
*signal_set |= signals;
2015df0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1
2015df4: b2 10 40 19 or %g1, %i1, %i1
2015df8: f2 24 20 18 st %i1, [ %l0 + 0x18 ]
_ISR_Enable( _level );
2015dfc: 7f ff e5 93 call 200f448 <sparc_enable_interrupts>
2015e00: 01 00 00 00 nop
} else {
_ASR_Post_signals( signal_set, &asr->signals_pending );
}
_Thread_Enable_dispatch();
2015e04: 40 00 10 d0 call 201a144 <_Thread_Enable_dispatch>
2015e08: 01 00 00 00 nop
2015e0c: 82 10 20 00 clr %g1 ! 0 <PROM_START>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2015e10: 81 c7 e0 08 ret
2015e14: 91 e8 00 01 restore %g0, %g1, %o0
_ASR_Post_signals( signal_set, &asr->signals_pending );
}
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
_Thread_Enable_dispatch();
2015e18: 40 00 10 cb call 201a144 <_Thread_Enable_dispatch>
2015e1c: 01 00 00 00 nop
return RTEMS_NOT_DEFINED;
2015e20: 10 bf ff cb b 2015d4c <rtems_signal_send+0x10>
2015e24: 82 10 20 0b mov 0xb, %g1 ! b <PROM_START+0xb>
0200fe00 <rtems_task_mode>:
rtems_status_code rtems_task_mode(
rtems_mode mode_set,
rtems_mode mask,
rtems_mode *previous_mode_set
)
{
200fe00: 9d e3 bf a0 save %sp, -96, %sp
ASR_Information *asr;
bool is_asr_enabled = false;
bool needs_asr_dispatching = false;
rtems_mode old_mode;
if ( !previous_mode_set )
200fe04: 80 a6 a0 00 cmp %i2, 0
200fe08: 02 80 00 44 be 200ff18 <rtems_task_mode+0x118>
200fe0c: 82 10 20 09 mov 9, %g1
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
200fe10: 03 00 80 77 sethi %hi(0x201dc00), %g1
200fe14: e0 00 60 70 ld [ %g1 + 0x70 ], %l0 ! 201dc70 <_Thread_Executing>
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
200fe18: c4 0c 20 75 ldub [ %l0 + 0x75 ], %g2
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
200fe1c: c2 04 20 7c ld [ %l0 + 0x7c ], %g1
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
200fe20: 80 a0 00 02 cmp %g0, %g2
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
200fe24: e2 04 21 60 ld [ %l0 + 0x160 ], %l1
asr = &api->Signal;
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
200fe28: a4 60 3f ff subx %g0, -1, %l2
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
200fe2c: 80 a0 60 00 cmp %g1, 0
200fe30: 12 80 00 3c bne 200ff20 <rtems_task_mode+0x120>
200fe34: a5 2c a0 08 sll %l2, 8, %l2
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200fe38: c2 0c 60 08 ldub [ %l1 + 8 ], %g1
200fe3c: 80 a0 00 01 cmp %g0, %g1
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
old_mode |= _ISR_Get_level();
200fe40: 7f ff ea 81 call 200a844 <_CPU_ISR_Get_level>
200fe44: a6 60 3f ff subx %g0, -1, %l3
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200fe48: a7 2c e0 0a sll %l3, 0xa, %l3
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
200fe4c: a6 14 c0 08 or %l3, %o0, %l3
old_mode |= _ISR_Get_level();
*previous_mode_set = old_mode;
200fe50: a4 14 c0 12 or %l3, %l2, %l2
/*
* These are generic thread scheduling characteristics.
*/
if ( mask & RTEMS_PREEMPT_MASK )
200fe54: 80 8e 61 00 btst 0x100, %i1
200fe58: 02 80 00 06 be 200fe70 <rtems_task_mode+0x70>
200fe5c: e4 26 80 00 st %l2, [ %i2 ]
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
200fe60: 83 36 20 08 srl %i0, 8, %g1
200fe64: 82 18 60 01 xor %g1, 1, %g1
200fe68: 82 08 60 01 and %g1, 1, %g1
200fe6c: c2 2c 20 75 stb %g1, [ %l0 + 0x75 ]
if ( mask & RTEMS_TIMESLICE_MASK ) {
200fe70: 80 8e 62 00 btst 0x200, %i1
200fe74: 02 80 00 0b be 200fea0 <rtems_task_mode+0xa0>
200fe78: 80 8e 60 0f btst 0xf, %i1
if ( _Modes_Is_timeslice(mode_set) ) {
200fe7c: 80 8e 22 00 btst 0x200, %i0
200fe80: 22 80 00 07 be,a 200fe9c <rtems_task_mode+0x9c>
200fe84: c0 24 20 7c clr [ %l0 + 0x7c ]
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
executing->cpu_time_budget = _Thread_Ticks_per_timeslice;
200fe88: 03 00 80 76 sethi %hi(0x201d800), %g1
200fe8c: c2 00 63 08 ld [ %g1 + 0x308 ], %g1 ! 201db08 <_Thread_Ticks_per_timeslice>
200fe90: c2 24 20 78 st %g1, [ %l0 + 0x78 ]
if ( mask & RTEMS_PREEMPT_MASK )
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
if ( mask & RTEMS_TIMESLICE_MASK ) {
if ( _Modes_Is_timeslice(mode_set) ) {
executing->budget_algorithm = THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE;
200fe94: 82 10 20 01 mov 1, %g1
200fe98: c2 24 20 7c st %g1, [ %l0 + 0x7c ]
/*
* Set the new interrupt level
*/
if ( mask & RTEMS_INTERRUPT_MASK )
200fe9c: 80 8e 60 0f btst 0xf, %i1
200fea0: 12 80 00 2d bne 200ff54 <rtems_task_mode+0x154>
200fea4: 01 00 00 00 nop
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
if ( mask & RTEMS_ASR_MASK ) {
200fea8: 80 8e 64 00 btst 0x400, %i1
200feac: 22 80 00 16 be,a 200ff04 <rtems_task_mode+0x104>
200feb0: a0 10 20 00 clr %l0
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200feb4: c2 0c 60 08 ldub [ %l1 + 8 ], %g1
* Output:
* *previous_mode_set - previous mode set
* always return RTEMS_SUCCESSFUL;
*/
rtems_status_code rtems_task_mode(
200feb8: b1 36 20 0a srl %i0, 0xa, %i0
200febc: b0 1e 20 01 xor %i0, 1, %i0
200fec0: b0 0e 20 01 and %i0, 1, %i0
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200fec4: 80 a0 40 18 cmp %g1, %i0
200fec8: 22 80 00 0f be,a 200ff04 <rtems_task_mode+0x104>
200fecc: a0 10 20 00 clr %l0
)
{
rtems_signal_set _signals;
ISR_Level _level;
_ISR_Disable( _level );
200fed0: 7f ff c8 75 call 20020a4 <sparc_disable_interrupts>
200fed4: f0 2c 60 08 stb %i0, [ %l1 + 8 ]
_signals = information->signals_pending;
200fed8: c4 04 60 18 ld [ %l1 + 0x18 ], %g2
information->signals_pending = information->signals_posted;
200fedc: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
information->signals_posted = _signals;
200fee0: c4 24 60 14 st %g2, [ %l1 + 0x14 ]
rtems_signal_set _signals;
ISR_Level _level;
_ISR_Disable( _level );
_signals = information->signals_pending;
information->signals_pending = information->signals_posted;
200fee4: c2 24 60 18 st %g1, [ %l1 + 0x18 ]
information->signals_posted = _signals;
_ISR_Enable( _level );
200fee8: 7f ff c8 73 call 20020b4 <sparc_enable_interrupts>
200feec: 01 00 00 00 nop
200fef0: c2 04 60 14 ld [ %l1 + 0x14 ], %g1
200fef4: 80 a0 60 00 cmp %g1, 0
200fef8: 12 80 00 28 bne 200ff98 <rtems_task_mode+0x198>
200fefc: 82 10 20 01 mov 1, %g1
if ( is_asr_enabled != asr->is_enabled ) {
asr->is_enabled = is_asr_enabled;
_ASR_Swap_signals( asr );
if ( _ASR_Are_signals_pending( asr ) ) {
needs_asr_dispatching = true;
executing->do_post_task_switch_extension = true;
200ff00: a0 10 20 00 clr %l0
}
}
}
if ( _System_state_Is_up( _System_state_Get() ) )
200ff04: 03 00 80 77 sethi %hi(0x201dc00), %g1
200ff08: c2 00 61 50 ld [ %g1 + 0x150 ], %g1 ! 201dd50 <_System_state_Current>
200ff0c: 80 a0 60 03 cmp %g1, 3
200ff10: 02 80 00 16 be 200ff68 <rtems_task_mode+0x168> <== ALWAYS TAKEN
200ff14: 82 10 20 00 clr %g1
if ( _Thread_Evaluate_mode() || needs_asr_dispatching )
_Thread_Dispatch();
return RTEMS_SUCCESSFUL;
}
200ff18: 81 c7 e0 08 ret
200ff1c: 91 e8 00 01 restore %g0, %g1, %o0
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200ff20: c2 0c 60 08 ldub [ %l1 + 8 ], %g1
old_mode = (executing->is_preemptible) ? RTEMS_PREEMPT : RTEMS_NO_PREEMPT;
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
200ff24: a4 14 a2 00 or %l2, 0x200, %l2
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200ff28: 80 a0 00 01 cmp %g0, %g1
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
old_mode |= _ISR_Get_level();
200ff2c: 7f ff ea 46 call 200a844 <_CPU_ISR_Get_level>
200ff30: a6 60 3f ff subx %g0, -1, %l3
if ( !previous_mode_set )
return RTEMS_INVALID_ADDRESS;
executing = _Thread_Executing;
api = executing->API_Extensions[ THREAD_API_RTEMS ];
asr = &api->Signal;
200ff34: a7 2c e0 0a sll %l3, 0xa, %l3
if ( executing->budget_algorithm == THREAD_CPU_BUDGET_ALGORITHM_NONE )
old_mode |= RTEMS_NO_TIMESLICE;
else
old_mode |= RTEMS_TIMESLICE;
old_mode |= (asr->is_enabled) ? RTEMS_ASR : RTEMS_NO_ASR;
200ff38: a6 14 c0 08 or %l3, %o0, %l3
old_mode |= _ISR_Get_level();
*previous_mode_set = old_mode;
200ff3c: a4 14 c0 12 or %l3, %l2, %l2
/*
* These are generic thread scheduling characteristics.
*/
if ( mask & RTEMS_PREEMPT_MASK )
200ff40: 80 8e 61 00 btst 0x100, %i1
200ff44: 02 bf ff cb be 200fe70 <rtems_task_mode+0x70>
200ff48: e4 26 80 00 st %l2, [ %i2 ]
executing->is_preemptible = _Modes_Is_preempt(mode_set) ? true : false;
200ff4c: 10 bf ff c6 b 200fe64 <rtems_task_mode+0x64>
200ff50: 83 36 20 08 srl %i0, 8, %g1
*/
RTEMS_INLINE_ROUTINE void _Modes_Set_interrupt_level (
Modes_Control mode_set
)
{
_ISR_Set_level( _Modes_Get_interrupt_level( mode_set ) );
200ff54: 90 0e 20 0f and %i0, 0xf, %o0
200ff58: 7f ff c8 57 call 20020b4 <sparc_enable_interrupts>
200ff5c: 91 2a 20 08 sll %o0, 8, %o0
*/
is_asr_enabled = false;
needs_asr_dispatching = false;
if ( mask & RTEMS_ASR_MASK ) {
200ff60: 10 bf ff d3 b 200feac <rtems_task_mode+0xac>
200ff64: 80 8e 64 00 btst 0x400, %i1
}
}
}
if ( _System_state_Is_up( _System_state_Get() ) )
if ( _Thread_Evaluate_mode() || needs_asr_dispatching )
200ff68: 40 00 00 87 call 2010184 <_Thread_Evaluate_mode>
200ff6c: 01 00 00 00 nop
200ff70: 80 8a 20 ff btst 0xff, %o0
200ff74: 12 80 00 04 bne 200ff84 <rtems_task_mode+0x184>
200ff78: 80 8c 20 ff btst 0xff, %l0
200ff7c: 02 bf ff e7 be 200ff18 <rtems_task_mode+0x118>
200ff80: 82 10 20 00 clr %g1
_Thread_Dispatch();
200ff84: 7f ff e2 f5 call 2008b58 <_Thread_Dispatch>
200ff88: 01 00 00 00 nop
200ff8c: 82 10 20 00 clr %g1 ! 0 <PROM_START>
return RTEMS_SUCCESSFUL;
}
200ff90: 81 c7 e0 08 ret
200ff94: 91 e8 00 01 restore %g0, %g1, %o0
if ( is_asr_enabled != asr->is_enabled ) {
asr->is_enabled = is_asr_enabled;
_ASR_Swap_signals( asr );
if ( _ASR_Are_signals_pending( asr ) ) {
needs_asr_dispatching = true;
executing->do_post_task_switch_extension = true;
200ff98: c2 2c 20 74 stb %g1, [ %l0 + 0x74 ]
200ff9c: 10 bf ff da b 200ff04 <rtems_task_mode+0x104>
200ffa0: a0 10 20 01 mov 1, %l0
0200b884 <rtems_task_set_priority>:
rtems_status_code rtems_task_set_priority(
rtems_id id,
rtems_task_priority new_priority,
rtems_task_priority *old_priority
)
{
200b884: 9d e3 bf 98 save %sp, -104, %sp
register Thread_Control *the_thread;
Objects_Locations location;
if ( new_priority != RTEMS_CURRENT_PRIORITY &&
200b888: 80 a6 60 00 cmp %i1, 0
200b88c: 02 80 00 07 be 200b8a8 <rtems_task_set_priority+0x24>
200b890: 90 10 00 18 mov %i0, %o0
*/
RTEMS_INLINE_ROUTINE bool _RTEMS_tasks_Priority_is_valid (
rtems_task_priority the_priority
)
{
return ( ( the_priority >= RTEMS_MINIMUM_PRIORITY ) &&
200b894: 03 00 80 87 sethi %hi(0x2021c00), %g1
200b898: c2 08 60 c4 ldub [ %g1 + 0xc4 ], %g1 ! 2021cc4 <rtems_maximum_priority>
200b89c: 80 a6 40 01 cmp %i1, %g1
200b8a0: 18 80 00 1c bgu 200b910 <rtems_task_set_priority+0x8c>
200b8a4: b0 10 20 13 mov 0x13, %i0
!_RTEMS_tasks_Priority_is_valid( new_priority ) )
return RTEMS_INVALID_PRIORITY;
if ( !old_priority )
200b8a8: 80 a6 a0 00 cmp %i2, 0
200b8ac: 02 80 00 19 be 200b910 <rtems_task_set_priority+0x8c>
200b8b0: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get( id, &location );
200b8b4: 40 00 08 9f call 200db30 <_Thread_Get>
200b8b8: 92 07 bf fc add %fp, -4, %o1
switch ( location ) {
200b8bc: c2 07 bf fc ld [ %fp + -4 ], %g1
200b8c0: 80 a0 60 00 cmp %g1, 0
200b8c4: 12 80 00 13 bne 200b910 <rtems_task_set_priority+0x8c>
200b8c8: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
/* XXX need helper to "convert" from core priority */
*old_priority = the_thread->current_priority;
200b8cc: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
if ( new_priority != RTEMS_CURRENT_PRIORITY ) {
200b8d0: 80 a6 60 00 cmp %i1, 0
200b8d4: 02 80 00 0d be 200b908 <rtems_task_set_priority+0x84>
200b8d8: c2 26 80 00 st %g1, [ %i2 ]
the_thread->real_priority = new_priority;
if ( the_thread->resource_count == 0 ||
200b8dc: c2 02 20 1c ld [ %o0 + 0x1c ], %g1
200b8e0: 80 a0 60 00 cmp %g1, 0
200b8e4: 02 80 00 06 be 200b8fc <rtems_task_set_priority+0x78>
200b8e8: f2 22 20 18 st %i1, [ %o0 + 0x18 ]
the_thread->current_priority > new_priority )
200b8ec: c2 02 20 14 ld [ %o0 + 0x14 ], %g1
200b8f0: 80 a6 40 01 cmp %i1, %g1
200b8f4: 1a 80 00 05 bcc 200b908 <rtems_task_set_priority+0x84> <== ALWAYS TAKEN
200b8f8: 01 00 00 00 nop
_Thread_Change_priority( the_thread, new_priority, false );
200b8fc: 92 10 00 19 mov %i1, %o1
200b900: 40 00 06 ca call 200d428 <_Thread_Change_priority>
200b904: 94 10 20 00 clr %o2
}
_Thread_Enable_dispatch();
200b908: 40 00 08 66 call 200daa0 <_Thread_Enable_dispatch>
200b90c: b0 10 20 00 clr %i0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
200b910: 81 c7 e0 08 ret
200b914: 81 e8 00 00 restore
0202f738 <rtems_task_variable_delete>:
rtems_status_code rtems_task_variable_delete(
rtems_id tid,
void **ptr
)
{
202f738: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp, *prev;
if ( !ptr )
202f73c: 80 a6 60 00 cmp %i1, 0
202f740: 02 80 00 09 be 202f764 <rtems_task_variable_delete+0x2c>
202f744: 82 10 20 09 mov 9, %g1
return RTEMS_INVALID_ADDRESS;
prev = NULL;
the_thread = _Thread_Get (tid, &location);
202f748: 90 10 00 18 mov %i0, %o0
202f74c: 7f ff 82 1d call 200ffc0 <_Thread_Get>
202f750: 92 07 bf fc add %fp, -4, %o1
switch (location) {
202f754: c4 07 bf fc ld [ %fp + -4 ], %g2
202f758: 80 a0 a0 00 cmp %g2, 0
202f75c: 02 80 00 04 be 202f76c <rtems_task_variable_delete+0x34>
202f760: 82 10 20 04 mov 4, %g1
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
202f764: 81 c7 e0 08 ret
202f768: 91 e8 00 01 restore %g0, %g1, %o0
the_thread = _Thread_Get (tid, &location);
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
202f76c: d2 02 21 70 ld [ %o0 + 0x170 ], %o1
while (tvp) {
202f770: 80 a2 60 00 cmp %o1, 0
202f774: 02 80 00 10 be 202f7b4 <rtems_task_variable_delete+0x7c>
202f778: 01 00 00 00 nop
if (tvp->ptr == ptr) {
202f77c: c2 02 60 04 ld [ %o1 + 4 ], %g1
202f780: 80 a0 40 19 cmp %g1, %i1
202f784: 12 80 00 08 bne 202f7a4 <rtems_task_variable_delete+0x6c>
202f788: 84 10 00 09 mov %o1, %g2
if (prev)
prev->next = tvp->next;
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
202f78c: 10 80 00 17 b 202f7e8 <rtems_task_variable_delete+0xb0>
202f790: c2 02 40 00 ld [ %o1 ], %g1
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
202f794: 80 a0 40 19 cmp %g1, %i1
202f798: 22 80 00 0c be,a 202f7c8 <rtems_task_variable_delete+0x90>
202f79c: c2 02 40 00 ld [ %o1 ], %g1
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
_RTEMS_Tasks_Invoke_task_variable_dtor( the_thread, tvp );
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
202f7a0: 84 10 00 09 mov %o1, %g2
}
prev = tvp;
tvp = (rtems_task_variable_t *)tvp->next;
202f7a4: d2 02 40 00 ld [ %o1 ], %o1
the_thread = _Thread_Get (tid, &location);
switch (location) {
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
202f7a8: 80 a2 60 00 cmp %o1, 0
202f7ac: 32 bf ff fa bne,a 202f794 <rtems_task_variable_delete+0x5c><== ALWAYS TAKEN
202f7b0: c2 02 60 04 ld [ %o1 + 4 ], %g1
return RTEMS_SUCCESSFUL;
}
prev = tvp;
tvp = (rtems_task_variable_t *)tvp->next;
}
_Thread_Enable_dispatch();
202f7b4: 7f ff 81 df call 200ff30 <_Thread_Enable_dispatch>
202f7b8: 01 00 00 00 nop
202f7bc: 82 10 20 09 mov 9, %g1 ! 9 <PROM_START+0x9>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
202f7c0: 81 c7 e0 08 ret
202f7c4: 91 e8 00 01 restore %g0, %g1, %o0
case OBJECTS_LOCAL:
tvp = the_thread->task_variables;
while (tvp) {
if (tvp->ptr == ptr) {
if (prev)
prev->next = tvp->next;
202f7c8: c2 20 80 00 st %g1, [ %g2 ]
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
_RTEMS_Tasks_Invoke_task_variable_dtor( the_thread, tvp );
202f7cc: 40 00 00 2d call 202f880 <_RTEMS_Tasks_Invoke_task_variable_dtor>
202f7d0: 01 00 00 00 nop
_Thread_Enable_dispatch();
202f7d4: 7f ff 81 d7 call 200ff30 <_Thread_Enable_dispatch>
202f7d8: 01 00 00 00 nop
202f7dc: 82 10 20 00 clr %g1 ! 0 <PROM_START>
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
202f7e0: 81 c7 e0 08 ret
202f7e4: 91 e8 00 01 restore %g0, %g1, %o0
while (tvp) {
if (tvp->ptr == ptr) {
if (prev)
prev->next = tvp->next;
else
the_thread->task_variables = (rtems_task_variable_t *)tvp->next;
202f7e8: 10 bf ff f9 b 202f7cc <rtems_task_variable_delete+0x94>
202f7ec: c2 22 21 70 st %g1, [ %o0 + 0x170 ]
0202f7f0 <rtems_task_variable_get>:
rtems_status_code rtems_task_variable_get(
rtems_id tid,
void **ptr,
void **result
)
{
202f7f0: 9d e3 bf 98 save %sp, -104, %sp
Thread_Control *the_thread;
Objects_Locations location;
rtems_task_variable_t *tvp;
if ( !ptr )
202f7f4: 80 a6 60 00 cmp %i1, 0
202f7f8: 02 80 00 1c be 202f868 <rtems_task_variable_get+0x78>
202f7fc: 80 a6 a0 00 cmp %i2, 0
return RTEMS_INVALID_ADDRESS;
if ( !result )
202f800: 02 80 00 1a be 202f868 <rtems_task_variable_get+0x78>
202f804: 90 10 00 18 mov %i0, %o0
return RTEMS_INVALID_ADDRESS;
the_thread = _Thread_Get (tid, &location);
202f808: 7f ff 81 ee call 200ffc0 <_Thread_Get>
202f80c: 92 07 bf fc add %fp, -4, %o1
switch (location) {
202f810: c2 07 bf fc ld [ %fp + -4 ], %g1
202f814: 80 a0 60 00 cmp %g1, 0
202f818: 12 80 00 12 bne 202f860 <rtems_task_variable_get+0x70>
202f81c: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
/*
* Figure out if the variable is in this task's list.
*/
tvp = the_thread->task_variables;
202f820: c2 02 21 70 ld [ %o0 + 0x170 ], %g1
while (tvp) {
202f824: 80 a0 60 00 cmp %g1, 0
202f828: 32 80 00 07 bne,a 202f844 <rtems_task_variable_get+0x54>
202f82c: c4 00 60 04 ld [ %g1 + 4 ], %g2
202f830: 30 80 00 10 b,a 202f870 <rtems_task_variable_get+0x80>
202f834: 80 a0 60 00 cmp %g1, 0
202f838: 02 80 00 0e be 202f870 <rtems_task_variable_get+0x80> <== NEVER TAKEN
202f83c: 01 00 00 00 nop
if (tvp->ptr == ptr) {
202f840: c4 00 60 04 ld [ %g1 + 4 ], %g2
202f844: 80 a0 80 19 cmp %g2, %i1
202f848: 32 bf ff fb bne,a 202f834 <rtems_task_variable_get+0x44>
202f84c: c2 00 40 00 ld [ %g1 ], %g1
/*
* Should this return the current (i.e not the
* saved) value if `tid' is the current task?
*/
*result = tvp->tval;
202f850: c2 00 60 0c ld [ %g1 + 0xc ], %g1
_Thread_Enable_dispatch();
202f854: b0 10 20 00 clr %i0
202f858: 7f ff 81 b6 call 200ff30 <_Thread_Enable_dispatch>
202f85c: c2 26 80 00 st %g1, [ %i2 ]
return RTEMS_SUCCESSFUL;
202f860: 81 c7 e0 08 ret
202f864: 81 e8 00 00 restore
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
202f868: 81 c7 e0 08 ret
202f86c: 91 e8 20 09 restore %g0, 9, %o0
_Thread_Enable_dispatch();
return RTEMS_SUCCESSFUL;
}
tvp = (rtems_task_variable_t *)tvp->next;
}
_Thread_Enable_dispatch();
202f870: 7f ff 81 b0 call 200ff30 <_Thread_Enable_dispatch>
202f874: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
202f878: 81 c7 e0 08 ret
202f87c: 81 e8 00 00 restore
02016778 <rtems_timer_cancel>:
*/
rtems_status_code rtems_timer_cancel(
rtems_id id
)
{
2016778: 9d e3 bf 98 save %sp, -104, %sp
RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get (
Objects_Id id,
Objects_Locations *location
)
{
return (Timer_Control *)
201677c: 11 00 80 fd sethi %hi(0x203f400), %o0
2016780: 92 10 00 18 mov %i0, %o1
2016784: 90 12 22 88 or %o0, 0x288, %o0
2016788: 40 00 0b aa call 2019630 <_Objects_Get>
201678c: 94 07 bf fc add %fp, -4, %o2
Timer_Control *the_timer;
Objects_Locations location;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
2016790: c2 07 bf fc ld [ %fp + -4 ], %g1
2016794: 80 a0 60 00 cmp %g1, 0
2016798: 12 80 00 0a bne 20167c0 <rtems_timer_cancel+0x48>
201679c: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
if ( !_Timer_Is_dormant_class( the_timer->the_class ) )
20167a0: c2 02 20 38 ld [ %o0 + 0x38 ], %g1
20167a4: 80 a0 60 04 cmp %g1, 4
20167a8: 02 80 00 04 be 20167b8 <rtems_timer_cancel+0x40> <== NEVER TAKEN
20167ac: 01 00 00 00 nop
(void) _Watchdog_Remove( &the_timer->Ticker );
20167b0: 40 00 14 d0 call 201baf0 <_Watchdog_Remove>
20167b4: 90 02 20 10 add %o0, 0x10, %o0
_Thread_Enable_dispatch();
20167b8: 40 00 0e 63 call 201a144 <_Thread_Enable_dispatch>
20167bc: b0 10 20 00 clr %i0
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
20167c0: 81 c7 e0 08 ret
20167c4: 81 e8 00 00 restore
02016c84 <rtems_timer_server_fire_when>:
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
2016c84: 9d e3 bf 98 save %sp, -104, %sp
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
2016c88: 03 00 80 fd sethi %hi(0x203f400), %g1
2016c8c: e0 00 62 c8 ld [ %g1 + 0x2c8 ], %l0 ! 203f6c8 <_Timer_server>
rtems_id id,
rtems_time_of_day *wall_time,
rtems_timer_service_routine_entry routine,
void *user_data
)
{
2016c90: a2 10 00 18 mov %i0, %l1
Timer_Control *the_timer;
Objects_Locations location;
rtems_interval seconds;
Timer_server_Control *timer_server = _Timer_server;
if ( !timer_server )
2016c94: 80 a4 20 00 cmp %l0, 0
2016c98: 02 80 00 34 be 2016d68 <rtems_timer_server_fire_when+0xe4>
2016c9c: b0 10 20 0e mov 0xe, %i0
return RTEMS_INCORRECT_STATE;
if ( !_TOD_Is_set )
2016ca0: 03 00 80 fc sethi %hi(0x203f000), %g1
2016ca4: c2 08 63 94 ldub [ %g1 + 0x394 ], %g1 ! 203f394 <_TOD_Is_set>
2016ca8: 80 a0 60 00 cmp %g1, 0
2016cac: 02 80 00 2f be 2016d68 <rtems_timer_server_fire_when+0xe4><== NEVER TAKEN
2016cb0: b0 10 20 0b mov 0xb, %i0
return RTEMS_NOT_DEFINED;
if ( !routine )
2016cb4: 80 a6 a0 00 cmp %i2, 0
2016cb8: 02 80 00 2c be 2016d68 <rtems_timer_server_fire_when+0xe4>
2016cbc: b0 10 20 09 mov 9, %i0
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Validate( wall_time ) )
2016cc0: 7f ff f3 d6 call 2013c18 <_TOD_Validate>
2016cc4: 90 10 00 19 mov %i1, %o0
2016cc8: 80 8a 20 ff btst 0xff, %o0
2016ccc: 12 80 00 04 bne 2016cdc <rtems_timer_server_fire_when+0x58>
2016cd0: 01 00 00 00 nop
case OBJECTS_ERROR:
break;
}
return RTEMS_INVALID_ID;
}
2016cd4: 81 c7 e0 08 ret
2016cd8: 91 e8 20 14 restore %g0, 0x14, %o0
return RTEMS_INVALID_ADDRESS;
if ( !_TOD_Validate( wall_time ) )
return RTEMS_INVALID_CLOCK;
seconds = _TOD_To_seconds( wall_time );
2016cdc: 7f ff f3 99 call 2013b40 <_TOD_To_seconds>
2016ce0: 90 10 00 19 mov %i1, %o0
if ( seconds <= _TOD_Seconds_since_epoch() )
2016ce4: 25 00 80 fd sethi %hi(0x203f400), %l2
2016ce8: c2 04 a0 14 ld [ %l2 + 0x14 ], %g1 ! 203f414 <_TOD_Now>
2016cec: 80 a2 00 01 cmp %o0, %g1
2016cf0: 08 bf ff f9 bleu 2016cd4 <rtems_timer_server_fire_when+0x50>
2016cf4: b2 10 00 08 mov %o0, %i1
2016cf8: 11 00 80 fd sethi %hi(0x203f400), %o0
2016cfc: 92 10 00 11 mov %l1, %o1
2016d00: 90 12 22 88 or %o0, 0x288, %o0
2016d04: 40 00 0a 4b call 2019630 <_Objects_Get>
2016d08: 94 07 bf fc add %fp, -4, %o2
return RTEMS_INVALID_CLOCK;
the_timer = _Timer_Get( id, &location );
switch ( location ) {
2016d0c: c2 07 bf fc ld [ %fp + -4 ], %g1
2016d10: a6 10 00 08 mov %o0, %l3
2016d14: 80 a0 60 00 cmp %g1, 0
2016d18: 12 80 00 14 bne 2016d68 <rtems_timer_server_fire_when+0xe4>
2016d1c: b0 10 20 04 mov 4, %i0
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
2016d20: 40 00 13 74 call 201baf0 <_Watchdog_Remove>
2016d24: 90 02 20 10 add %o0, 0x10, %o0
the_watchdog->routine = routine;
the_watchdog->id = id;
2016d28: e2 24 e0 30 st %l1, [ %l3 + 0x30 ]
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
2016d2c: c4 04 a0 14 ld [ %l2 + 0x14 ], %g2
(*timer_server->schedule_operation)( timer_server, the_timer );
2016d30: c2 04 20 04 ld [ %l0 + 4 ], %g1
2016d34: 90 10 00 10 mov %l0, %o0
2016d38: 92 10 00 13 mov %l3, %o1
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
2016d3c: b2 26 40 02 sub %i1, %g2, %i1
the_timer = _Timer_Get( id, &location );
switch ( location ) {
case OBJECTS_LOCAL:
(void) _Watchdog_Remove( &the_timer->Ticker );
the_timer->the_class = TIMER_TIME_OF_DAY_ON_TASK;
2016d40: 84 10 20 03 mov 3, %g2
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
the_watchdog->routine = routine;
2016d44: f4 24 e0 2c st %i2, [ %l3 + 0x2c ]
2016d48: c4 24 e0 38 st %g2, [ %l3 + 0x38 ]
the_watchdog->id = id;
the_watchdog->user_data = user_data;
2016d4c: f6 24 e0 34 st %i3, [ %l3 + 0x34 ]
_Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data );
the_timer->Ticker.initial = seconds - _TOD_Seconds_since_epoch();
2016d50: f2 24 e0 1c st %i1, [ %l3 + 0x1c ]
Watchdog_Service_routine_entry routine,
Objects_Id id,
void *user_data
)
{
the_watchdog->state = WATCHDOG_INACTIVE;
2016d54: c0 24 e0 18 clr [ %l3 + 0x18 ]
(*timer_server->schedule_operation)( timer_server, the_timer );
2016d58: 9f c0 40 00 call %g1
2016d5c: b0 10 20 00 clr %i0
_Thread_Enable_dispatch();
2016d60: 40 00 0c f9 call 201a144 <_Thread_Enable_dispatch>
2016d64: 01 00 00 00 nop
return RTEMS_SUCCESSFUL;
2016d68: 81 c7 e0 08 ret
2016d6c: 81 e8 00 00 restore