40006674 <_API_extensions_Run_postdriver>: * * _API_extensions_Run_postdriver */ void _API_extensions_Run_postdriver( void ) { 40006674: 9d e3 bf 98 save %sp, -104, %sp Chain_Node *the_node; API_extensions_Control *the_extension; for ( the_node = _API_extensions_List.first ; 40006678: 03 10 00 64 sethi %hi(0x40019000), %g1 4000667c: e0 00 61 80 ld [ %g1 + 0x180 ], %l0 ! 40019180 <_API_extensions_List> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40006680: 03 10 00 64 sethi %hi(0x40019000), %g1 40006684: 10 80 00 08 b 400066a4 <_API_extensions_Run_postdriver+0x30> 40006688: a2 10 61 84 or %g1, 0x184, %l1 ! 40019184 <_API_extensions_List+0x4> !_Chain_Is_tail( &_API_extensions_List, the_node ) ; the_node = the_node->next ) { the_extension = (API_extensions_Control *) the_node; if ( the_extension->postdriver_hook ) 4000668c: 80 a0 60 00 cmp %g1, 0 40006690: 22 80 00 05 be,a 400066a4 <_API_extensions_Run_postdriver+0x30> 40006694: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED (*the_extension->postdriver_hook)(); 40006698: 9f c0 40 00 call %g1 4000669c: 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 ) { 400066a0: e0 04 00 00 ld [ %l0 ], %l0 { Chain_Node *the_node; API_extensions_Control *the_extension; for ( the_node = _API_extensions_List.first ; !_Chain_Is_tail( &_API_extensions_List, the_node ) ; 400066a4: 80 a4 00 11 cmp %l0, %l1 400066a8: 32 bf ff f9 bne,a 4000668c <_API_extensions_Run_postdriver+0x18> 400066ac: c2 04 20 0c ld [ %l0 + 0xc ], %g1 the_extension = (API_extensions_Control *) the_node; if ( the_extension->postdriver_hook ) (*the_extension->postdriver_hook)(); } } 400066b0: 81 c7 e0 08 ret 400066b4: 81 e8 00 00 restore 40006718 <_API_extensions_Run_postswitch>: * * _API_extensions_Run_postswitch */ void _API_extensions_Run_postswitch( void ) { 40006718: 9d e3 bf 98 save %sp, -104, %sp Chain_Node *the_node; API_extensions_Control *the_extension; for ( the_node = _API_extensions_List.first ; 4000671c: 03 10 00 64 sethi %hi(0x40019000), %g1 40006720: e0 00 61 80 ld [ %g1 + 0x180 ], %l0 ! 40019180 <_API_extensions_List> the_node = the_node->next ) { the_extension = (API_extensions_Control *) the_node; if ( the_extension->postswitch_hook ) (*the_extension->postswitch_hook)( _Thread_Executing ); 40006724: 23 10 00 63 sethi %hi(0x40018c00), %l1 40006728: 03 10 00 64 sethi %hi(0x40019000), %g1 4000672c: 10 80 00 08 b 4000674c <_API_extensions_Run_postswitch+0x34> 40006730: a4 10 61 84 or %g1, 0x184, %l2 ! 40019184 <_API_extensions_List+0x4> !_Chain_Is_tail( &_API_extensions_List, the_node ) ; the_node = the_node->next ) { the_extension = (API_extensions_Control *) the_node; if ( the_extension->postswitch_hook ) 40006734: 80 a0 60 00 cmp %g1, 0 40006738: 22 80 00 05 be,a 4000674c <_API_extensions_Run_postswitch+0x34> 4000673c: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED (*the_extension->postswitch_hook)( _Thread_Executing ); 40006740: 9f c0 40 00 call %g1 40006744: d0 04 63 cc ld [ %l1 + 0x3cc ], %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 ) { 40006748: e0 04 00 00 ld [ %l0 ], %l0 { Chain_Node *the_node; API_extensions_Control *the_extension; for ( the_node = _API_extensions_List.first ; !_Chain_Is_tail( &_API_extensions_List, the_node ) ; 4000674c: 80 a4 00 12 cmp %l0, %l2 40006750: 32 bf ff f9 bne,a 40006734 <_API_extensions_Run_postswitch+0x1c> 40006754: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 the_extension = (API_extensions_Control *) the_node; if ( the_extension->postswitch_hook ) (*the_extension->postswitch_hook)( _Thread_Executing ); } } 40006758: 81 c7 e0 08 ret 4000675c: 81 e8 00 00 restore 400066d4 <_API_extensions_Run_predriver>: * * _API_extensions_Run_predriver */ void _API_extensions_Run_predriver( void ) { 400066d4: 9d e3 bf 98 save %sp, -104, %sp Chain_Node *the_node; API_extensions_Control *the_extension; for ( the_node = _API_extensions_List.first ; 400066d8: 03 10 00 64 sethi %hi(0x40019000), %g1 400066dc: e0 00 61 80 ld [ %g1 + 0x180 ], %l0 ! 40019180 <_API_extensions_List> 400066e0: 03 10 00 64 sethi %hi(0x40019000), %g1 400066e4: 10 80 00 08 b 40006704 <_API_extensions_Run_predriver+0x30> 400066e8: a2 10 61 84 or %g1, 0x184, %l1 ! 40019184 <_API_extensions_List+0x4> !_Chain_Is_tail( &_API_extensions_List, the_node ) ; the_node = the_node->next ) { the_extension = (API_extensions_Control *) the_node; if ( the_extension->predriver_hook ) 400066ec: 80 a0 60 00 cmp %g1, 0 400066f0: 22 80 00 05 be,a 40006704 <_API_extensions_Run_predriver+0x30> 400066f4: e0 04 00 00 ld [ %l0 ], %l0 (*the_extension->predriver_hook)(); 400066f8: 9f c0 40 00 call %g1 <== NOT EXECUTED 400066fc: 01 00 00 00 nop <== NOT EXECUTED 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 ) { 40006700: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED { Chain_Node *the_node; API_extensions_Control *the_extension; for ( the_node = _API_extensions_List.first ; !_Chain_Is_tail( &_API_extensions_List, the_node ) ; 40006704: 80 a4 00 11 cmp %l0, %l1 40006708: 32 bf ff f9 bne,a 400066ec <_API_extensions_Run_predriver+0x18> 4000670c: c2 04 20 08 ld [ %l0 + 8 ], %g1 the_extension = (API_extensions_Control *) the_node; if ( the_extension->predriver_hook ) (*the_extension->predriver_hook)(); } } 40006710: 81 c7 e0 08 ret 40006714: 81 e8 00 00 restore 40013420 <_CORE_message_queue_Broadcast>: size_t size, Objects_Id id, CORE_message_queue_API_mp_support_callout api_message_queue_mp_support, uint32_t *count ) { 40013420: 9d e3 bf 98 save %sp, -104, %sp Thread_Control *the_thread; uint32_t number_broadcasted; Thread_Wait_information *waitp; if ( size > the_message_queue->maximum_message_size ) { 40013424: c2 06 20 4c ld [ %i0 + 0x4c ], %g1 size_t size, Objects_Id id, CORE_message_queue_API_mp_support_callout api_message_queue_mp_support, uint32_t *count ) { 40013428: a4 10 00 18 mov %i0, %l2 Thread_Control *the_thread; uint32_t number_broadcasted; Thread_Wait_information *waitp; if ( size > the_message_queue->maximum_message_size ) { 4001342c: 80 a6 80 01 cmp %i2, %g1 40013430: 18 80 00 17 bgu 4001348c <_CORE_message_queue_Broadcast+0x6c> 40013434: 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 ) { 40013438: c2 04 a0 48 ld [ %l2 + 0x48 ], %g1 4001343c: 80 a0 60 00 cmp %g1, 0 40013440: 02 80 00 0a be 40013468 <_CORE_message_queue_Broadcast+0x48> 40013444: a2 10 20 00 clr %l1 *count = 0; 40013448: c0 27 40 00 clr [ %i5 ] <== NOT EXECUTED 4001344c: 81 c7 e0 08 ret <== NOT EXECUTED 40013450: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED const void *source, void *destination, size_t size ) { memcpy(destination, source, size); 40013454: d0 04 20 28 ld [ %l0 + 0x28 ], %o0 40013458: 40 00 20 07 call 4001b474 4001345c: a2 04 60 01 inc %l1 buffer, waitp->return_argument, size ); *(uint32_t *)the_thread->Wait.return_argument_1 = size; 40013460: c2 04 20 2c ld [ %l0 + 0x2c ], %g1 40013464: 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))) { 40013468: 40 00 0b 3f call 40016164 <_Thread_queue_Dequeue> 4001346c: 90 10 00 12 mov %l2, %o0 40013470: 92 10 00 19 mov %i1, %o1 40013474: a0 10 00 08 mov %o0, %l0 40013478: 80 a2 20 00 cmp %o0, 0 4001347c: 12 bf ff f6 bne 40013454 <_CORE_message_queue_Broadcast+0x34> 40013480: 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; 40013484: e2 27 40 00 st %l1, [ %i5 ] 40013488: b0 10 20 00 clr %i0 return CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; } 4001348c: 81 c7 e0 08 ret 40013490: 81 e8 00 00 restore 40013550 <_CORE_message_queue_Initialize>: CORE_message_queue_Control *the_message_queue, CORE_message_queue_Attributes *the_message_queue_attributes, uint32_t maximum_pending_messages, uint32_t maximum_message_size ) { 40013550: 9d e3 bf 98 save %sp, -104, %sp uint32_t message_buffering_required; uint32_t allocated_message_size; the_message_queue->maximum_pending_messages = maximum_pending_messages; the_message_queue->number_of_pending_messages = 0; 40013554: c0 26 20 48 clr [ %i0 + 0x48 ] ) { uint32_t message_buffering_required; uint32_t allocated_message_size; the_message_queue->maximum_pending_messages = maximum_pending_messages; 40013558: 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; 4001355c: f6 26 20 4c st %i3, [ %i0 + 0x4c ] CORE_message_queue_Control *the_message_queue, CORE_message_queue_Notify_Handler the_handler, void *the_argument ) { the_message_queue->notify_handler = the_handler; 40013560: c0 26 20 60 clr [ %i0 + 0x60 ] the_message_queue->notify_argument = the_argument; 40013564: c0 26 20 64 clr [ %i0 + 0x64 ] * 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)) { 40013568: 80 8e e0 03 btst 3, %i3 4001356c: 02 80 00 07 be 40013588 <_CORE_message_queue_Initialize+0x38> 40013570: a0 10 00 1b mov %i3, %l0 allocated_message_size += sizeof(uint32_t); 40013574: 82 06 e0 04 add %i3, 4, %g1 allocated_message_size &= ~(sizeof(uint32_t) - 1); 40013578: a0 08 7f fc and %g1, -4, %l0 } if (allocated_message_size < maximum_message_size) 4001357c: 80 a4 00 1b cmp %l0, %i3 40013580: 0a 80 00 24 bcs 40013610 <_CORE_message_queue_Initialize+0xc0> 40013584: 01 00 00 00 nop /* * Calculate how much total memory is required for message buffering and * check for overflow on the multiplication. */ message_buffering_required = maximum_pending_messages * 40013588: b6 04 20 14 add %l0, 0x14, %i3 4001358c: 92 10 00 1a mov %i2, %o1 40013590: 40 00 40 8e call 400237c8 <.umul> 40013594: 90 10 00 1b mov %i3, %o0 (allocated_message_size + sizeof(CORE_message_queue_Buffer_control)); if (message_buffering_required < allocated_message_size) 40013598: 80 a2 00 10 cmp %o0, %l0 4001359c: 0a 80 00 1d bcs 40013610 <_CORE_message_queue_Initialize+0xc0> 400135a0: 92 10 00 08 mov %o0, %o1 RTEMS_INLINE_ROUTINE void *_Workspace_Allocate( size_t size ) { return _Heap_Allocate( &_Workspace_Area, size ); 400135a4: 11 10 00 c8 sethi %hi(0x40032000), %o0 400135a8: 40 00 02 20 call 40013e28 <_Heap_Allocate> 400135ac: 90 12 23 2c or %o0, 0x32c, %o0 ! 4003232c <_Workspace_Area> * Attempt to allocate the message memory */ the_message_queue->message_buffers = (CORE_message_queue_Buffer *) _Workspace_Allocate( message_buffering_required ); if (the_message_queue->message_buffers == 0) 400135b0: 80 a2 20 00 cmp %o0, 0 400135b4: 02 80 00 17 be 40013610 <_CORE_message_queue_Initialize+0xc0> 400135b8: d0 26 20 5c st %o0, [ %i0 + 0x5c ] /* * Initialize the pool of inactive messages, pending messages, * and set of waiting threads. */ _Chain_Initialize ( 400135bc: 92 10 00 08 mov %o0, %o1 400135c0: 94 10 00 1a mov %i2, %o2 400135c4: 90 06 20 68 add %i0, 0x68, %o0 400135c8: 7f ff ff 88 call 400133e8 <_Chain_Initialize> 400135cc: 96 10 00 1b mov %i3, %o3 allocated_message_size + sizeof( CORE_message_queue_Buffer_control ) ); _Chain_Initialize_empty( &the_message_queue->Pending_messages ); _Thread_queue_Initialize( 400135d0: 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; 400135d4: c0 26 20 54 clr [ %i0 + 0x54 ] 400135d8: 82 18 60 01 xor %g1, 1, %g1 400135dc: 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); 400135e0: 82 06 20 54 add %i0, 0x54, %g1 400135e4: c2 26 20 50 st %g1, [ %i0 + 0x50 ] the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 400135e8: 82 06 20 50 add %i0, 0x50, %g1 400135ec: 90 10 00 18 mov %i0, %o0 400135f0: c2 26 20 58 st %g1, [ %i0 + 0x58 ] 400135f4: 92 60 3f ff subx %g0, -1, %o1 400135f8: 94 10 20 80 mov 0x80, %o2 400135fc: 96 10 20 06 mov 6, %o3 40013600: 40 00 0c 2e call 400166b8 <_Thread_queue_Initialize> 40013604: b0 10 20 01 mov 1, %i0 40013608: 81 c7 e0 08 ret 4001360c: 81 e8 00 00 restore STATES_WAITING_FOR_MESSAGE, CORE_MESSAGE_QUEUE_STATUS_TIMEOUT ); return TRUE; } 40013610: 81 c7 e0 08 ret <== NOT EXECUTED 40013614: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED 40015990 <_CORE_message_queue_Insert_message>: void _CORE_message_queue_Insert_message( CORE_message_queue_Control *the_message_queue, CORE_message_queue_Buffer_control *the_message, CORE_message_queue_Submit_types submit_type ) { 40015990: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; boolean notify = FALSE; the_message->priority = submit_type; switch ( submit_type ) { 40015994: 03 20 00 00 sethi %hi(0x80000000), %g1 40015998: 80 a6 80 01 cmp %i2, %g1 4001599c: 02 80 00 16 be 400159f4 <_CORE_message_queue_Insert_message+0x64> 400159a0: f4 26 60 08 st %i2, [ %i1 + 8 ] 400159a4: 82 00 7c 00 add %g1, -1024, %g1 400159a8: 82 10 63 ff or %g1, 0x3ff, %g1 400159ac: 80 a6 80 01 cmp %i2, %g1 400159b0: 32 80 00 20 bne,a 40015a30 <_CORE_message_queue_Insert_message+0xa0> 400159b4: e0 06 20 50 ld [ %i0 + 0x50 ], %l0 <== NOT EXECUTED case CORE_MESSAGE_QUEUE_SEND_REQUEST: _ISR_Disable( level ); 400159b8: 7f ff b2 cb call 400024e4 400159bc: 01 00 00 00 nop Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); 400159c0: 82 06 20 54 add %i0, 0x54, %g1 if ( the_message_queue->number_of_pending_messages++ == 0 ) 400159c4: c4 06 20 48 ld [ %i0 + 0x48 ], %g2 400159c8: c2 26 40 00 st %g1, [ %i1 ] old_last_node = the_chain->last; 400159cc: c2 06 20 58 ld [ %i0 + 0x58 ], %g1 the_chain->last = the_node; 400159d0: f2 26 20 58 st %i1, [ %i0 + 0x58 ] 400159d4: 84 00 a0 01 inc %g2 old_last_node->next = the_node; the_node->previous = old_last_node; 400159d8: c2 26 60 04 st %g1, [ %i1 + 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; 400159dc: f2 20 40 00 st %i1, [ %g1 ] 400159e0: c4 26 20 48 st %g2, [ %i0 + 0x48 ] 400159e4: 82 18 a0 01 xor %g2, 1, %g1 400159e8: 80 a0 00 01 cmp %g0, %g1 400159ec: a0 60 3f ff subx %g0, -1, %l0 notify = TRUE; _CORE_message_queue_Append_unprotected(the_message_queue, the_message); _ISR_Enable( level ); 400159f0: 30 80 00 27 b,a 40015a8c <_CORE_message_queue_Insert_message+0xfc> break; case CORE_MESSAGE_QUEUE_URGENT_REQUEST: _ISR_Disable( level ); 400159f4: 7f ff b2 bc call 400024e4 400159f8: 01 00 00 00 nop ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; 400159fc: c6 06 20 50 ld [ %i0 + 0x50 ], %g3 if ( the_message_queue->number_of_pending_messages++ == 0 ) 40015a00: c4 06 20 48 ld [ %i0 + 0x48 ], %g2 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head( Chain_Control *the_chain ) { return (Chain_Node *) the_chain; 40015a04: 82 06 20 50 add %i0, 0x50, %g1 { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; after_node->next = the_node; 40015a08: f2 26 20 50 st %i1, [ %i0 + 0x50 ] Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; 40015a0c: c2 26 60 04 st %g1, [ %i1 + 4 ] 40015a10: 84 00 a0 01 inc %g2 before_node = after_node->next; after_node->next = the_node; the_node->next = before_node; before_node->previous = the_node; 40015a14: f2 20 e0 04 st %i1, [ %g3 + 4 ] 40015a18: 82 18 a0 01 xor %g2, 1, %g1 Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; after_node->next = the_node; the_node->next = before_node; 40015a1c: c6 26 40 00 st %g3, [ %i1 ] 40015a20: 80 a0 00 01 cmp %g0, %g1 40015a24: c4 26 20 48 st %g2, [ %i0 + 0x48 ] 40015a28: a0 60 3f ff subx %g0, -1, %l0 notify = TRUE; _CORE_message_queue_Prepend_unprotected(the_message_queue, the_message); _ISR_Enable( level ); 40015a2c: 30 80 00 18 b,a 40015a8c <_CORE_message_queue_Insert_message+0xfc> Chain_Node *the_node; Chain_Control *the_header; the_header = &the_message_queue->Pending_messages; the_node = the_header->first; while ( !_Chain_Is_tail( the_header, the_node ) ) { 40015a30: 10 80 00 06 b 40015a48 <_CORE_message_queue_Insert_message+0xb8> <== NOT EXECUTED 40015a34: 84 06 20 54 add %i0, 0x54, %g2 <== NOT EXECUTED this_message = (CORE_message_queue_Buffer_control *) the_node; if ( this_message->priority <= the_message->priority ) { 40015a38: 80 a0 40 1a cmp %g1, %i2 <== NOT EXECUTED 40015a3c: 14 80 00 06 bg 40015a54 <_CORE_message_queue_Insert_message+0xc4> <== NOT EXECUTED 40015a40: 01 00 00 00 nop <== NOT EXECUTED the_node = the_node->next; 40015a44: e0 04 00 00 ld [ %l0 ], %l0 <== NOT EXECUTED Chain_Node *the_node; Chain_Control *the_header; the_header = &the_message_queue->Pending_messages; the_node = the_header->first; while ( !_Chain_Is_tail( the_header, the_node ) ) { 40015a48: 80 a4 00 02 cmp %l0, %g2 <== NOT EXECUTED 40015a4c: 32 bf ff fb bne,a 40015a38 <_CORE_message_queue_Insert_message+0xa8> <== NOT EXECUTED 40015a50: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED continue; } break; } _ISR_Disable( level ); 40015a54: 7f ff b2 a4 call 400024e4 <== NOT EXECUTED 40015a58: 01 00 00 00 nop <== NOT EXECUTED if ( the_message_queue->number_of_pending_messages++ == 0 ) notify = TRUE; _Chain_Insert_unprotected( the_node->previous, &the_message->Node ); 40015a5c: c2 04 20 04 ld [ %l0 + 4 ], %g1 <== NOT EXECUTED } break; } _ISR_Disable( level ); if ( the_message_queue->number_of_pending_messages++ == 0 ) 40015a60: c4 06 20 48 ld [ %i0 + 0x48 ], %g2 <== NOT EXECUTED ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; 40015a64: c6 00 40 00 ld [ %g1 ], %g3 <== NOT EXECUTED Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; 40015a68: c2 26 60 04 st %g1, [ %i1 + 4 ] <== NOT EXECUTED before_node = after_node->next; after_node->next = the_node; 40015a6c: f2 20 40 00 st %i1, [ %g1 ] <== NOT EXECUTED 40015a70: 84 00 a0 01 inc %g2 <== NOT EXECUTED the_node->next = before_node; before_node->previous = the_node; 40015a74: f2 20 e0 04 st %i1, [ %g3 + 4 ] <== NOT EXECUTED 40015a78: 82 18 a0 01 xor %g2, 1, %g1 <== NOT EXECUTED Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; after_node->next = the_node; the_node->next = before_node; 40015a7c: c6 26 40 00 st %g3, [ %i1 ] <== NOT EXECUTED 40015a80: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED 40015a84: c4 26 20 48 st %g2, [ %i0 + 0x48 ] <== NOT EXECUTED 40015a88: a0 60 3f ff subx %g0, -1, %l0 <== NOT EXECUTED notify = TRUE; _Chain_Insert_unprotected( the_node->previous, &the_message->Node ); _ISR_Enable( level ); 40015a8c: 7f ff b2 9a call 400024f4 40015a90: 01 00 00 00 nop * According to POSIX, does this happen before or after the message * is actually enqueued. It is logical to think afterwards, because * the message is actually in the queue at this point. */ if ( notify && the_message_queue->notify_handler ) 40015a94: 80 a4 20 00 cmp %l0, 0 40015a98: 02 80 00 08 be 40015ab8 <_CORE_message_queue_Insert_message+0x128> 40015a9c: 01 00 00 00 nop 40015aa0: c2 06 20 60 ld [ %i0 + 0x60 ], %g1 40015aa4: 80 a0 60 00 cmp %g1, 0 40015aa8: 02 80 00 04 be 40015ab8 <_CORE_message_queue_Insert_message+0x128> 40015aac: 01 00 00 00 nop (*the_message_queue->notify_handler)( the_message_queue->notify_argument ); 40015ab0: 9f c0 40 00 call %g1 <== NOT EXECUTED 40015ab4: d0 06 20 64 ld [ %i0 + 0x64 ], %o0 <== NOT EXECUTED 40015ab8: 81 c7 e0 08 ret 40015abc: 81 e8 00 00 restore 40012c1c <_CORE_message_queue_Seize>: void *buffer, size_t *size, boolean wait, Watchdog_Interval timeout ) { 40012c1c: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; CORE_message_queue_Buffer_control *the_message; Thread_Control *executing; Thread_Control *the_thread; executing = _Thread_Executing; 40012c20: 03 10 00 9d sethi %hi(0x40027400), %g1 40012c24: e2 00 63 cc ld [ %g1 + 0x3cc ], %l1 ! 400277cc <_Thread_Executing> void *buffer, size_t *size, boolean wait, Watchdog_Interval timeout ) { 40012c28: a0 10 00 18 mov %i0, %l0 Thread_Control *executing; Thread_Control *the_thread; executing = _Thread_Executing; executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_SUCCESSFUL; _ISR_Disable( level ); 40012c2c: 7f ff be 2e call 400024e4 40012c30: c0 24 60 34 clr [ %l1 + 0x34 ] 40012c34: 86 10 00 08 mov %o0, %g3 if ( the_message_queue->number_of_pending_messages != 0 ) { 40012c38: c2 06 20 48 ld [ %i0 + 0x48 ], %g1 40012c3c: 80 a0 60 00 cmp %g1, 0 40012c40: 02 80 00 2a be 40012ce8 <_CORE_message_queue_Seize+0xcc> 40012c44: 80 a7 20 00 cmp %i4, 0 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 40012c48: f2 06 20 50 ld [ %i0 + 0x50 ], %i1 the_message_queue->number_of_pending_messages -= 1; 40012c4c: 82 00 7f ff add %g1, -1, %g1 40012c50: c2 26 20 48 st %g1, [ %i0 + 0x48 ] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain)) 40012c54: 82 06 20 54 add %i0, 0x54, %g1 40012c58: 80 a6 40 01 cmp %i1, %g1 40012c5c: 32 80 00 04 bne,a 40012c6c <_CORE_message_queue_Seize+0x50> 40012c60: c2 06 40 00 ld [ %i1 ], %g1 40012c64: 10 80 00 05 b 40012c78 <_CORE_message_queue_Seize+0x5c> <== NOT EXECUTED 40012c68: b2 10 20 00 clr %i1 <== NOT EXECUTED Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next; the_chain->first = new_first; new_first->previous = _Chain_Head(the_chain); 40012c6c: 84 06 20 50 add %i0, 0x50, %g2 Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next; the_chain->first = new_first; 40012c70: c2 26 20 50 st %g1, [ %i0 + 0x50 ] new_first->previous = _Chain_Head(the_chain); 40012c74: c4 20 60 04 st %g2, [ %g1 + 4 ] the_message = _CORE_message_queue_Get_pending_message( the_message_queue ); _ISR_Enable( level ); 40012c78: 7f ff be 1f call 400024f4 40012c7c: 90 10 00 03 mov %g3, %o0 *size = the_message->Contents.size; 40012c80: d4 06 60 0c ld [ %i1 + 0xc ], %o2 _Thread_Executing->Wait.count = the_message->priority; 40012c84: 03 10 00 9d sethi %hi(0x40027400), %g1 the_message_queue->number_of_pending_messages -= 1; the_message = _CORE_message_queue_Get_pending_message( the_message_queue ); _ISR_Enable( level ); *size = the_message->Contents.size; 40012c88: d4 26 c0 00 st %o2, [ %i3 ] _Thread_Executing->Wait.count = the_message->priority; 40012c8c: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 40012c90: c2 06 60 08 ld [ %i1 + 8 ], %g1 _CORE_message_queue_Copy_buffer(the_message->Contents.buffer,buffer,*size); 40012c94: 92 10 00 1a mov %i2, %o1 the_message = _CORE_message_queue_Get_pending_message( the_message_queue ); _ISR_Enable( level ); *size = the_message->Contents.size; _Thread_Executing->Wait.count = the_message->priority; 40012c98: c2 20 a0 24 st %g1, [ %g2 + 0x24 ] _CORE_message_queue_Copy_buffer(the_message->Contents.buffer,buffer,*size); 40012c9c: a2 06 60 10 add %i1, 0x10, %l1 40012ca0: 7f ff ff d8 call 40012c00 <_CORE_message_queue_Copy_buffer> 40012ca4: 90 10 00 11 mov %l1, %o0 * * NOTE: If we note that the queue was not full before this receive, * then we can avoid this dequeue. */ the_thread = _Thread_queue_Dequeue( &the_message_queue->Wait_queue ); 40012ca8: 7f ff ea a2 call 4000d730 <_Thread_queue_Dequeue> 40012cac: 90 10 00 10 mov %l0, %o0 if ( !the_thread ) { 40012cb0: 82 92 20 00 orcc %o0, 0, %g1 40012cb4: 32 80 00 04 bne,a 40012cc4 <_CORE_message_queue_Seize+0xa8> 40012cb8: d4 00 60 30 ld [ %g1 + 0x30 ], %o2 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _CORE_message_queue_Free_message_buffer ( CORE_message_queue_Control *the_message_queue, CORE_message_queue_Buffer_control *the_message ) { _Chain_Append( &the_message_queue->Inactive_messages, &the_message->Node ); 40012cbc: 7f ff e0 c0 call 4000afbc <_Chain_Append> 40012cc0: 91 ec 20 68 restore %l0, 0x68, %o0 * waiting task. */ the_message->priority = the_thread->Wait.count; the_message->Contents.size = (uint32_t)the_thread->Wait.option; _CORE_message_queue_Copy_buffer( 40012cc4: d0 00 60 28 ld [ %g1 + 0x28 ], %o0 <== NOT EXECUTED * There was a thread waiting to send a message. This code * puts the messages in the message queue on behalf of the * waiting task. */ the_message->priority = the_thread->Wait.count; 40012cc8: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 <== NOT EXECUTED the_message->Contents.size = (uint32_t)the_thread->Wait.option; 40012ccc: d4 26 60 0c st %o2, [ %i1 + 0xc ] <== NOT EXECUTED * There was a thread waiting to send a message. This code * puts the messages in the message queue on behalf of the * waiting task. */ the_message->priority = the_thread->Wait.count; 40012cd0: c2 26 60 08 st %g1, [ %i1 + 8 ] <== NOT EXECUTED the_message->Contents.size = (uint32_t)the_thread->Wait.option; _CORE_message_queue_Copy_buffer( 40012cd4: 7f ff ff cb call 40012c00 <_CORE_message_queue_Copy_buffer> <== NOT EXECUTED 40012cd8: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED the_thread->Wait.return_argument, the_message->Contents.buffer, the_message->Contents.size ); _CORE_message_queue_Insert_message( 40012cdc: f4 06 60 08 ld [ %i1 + 8 ], %i2 <== NOT EXECUTED 40012ce0: 40 00 0b 2c call 40015990 <_CORE_message_queue_Insert_message> <== NOT EXECUTED 40012ce4: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED the_message->priority ); return; } if ( !wait ) { 40012ce8: 12 80 00 08 bne 40012d08 <_CORE_message_queue_Seize+0xec> 40012cec: 82 10 20 01 mov 1, %g1 _ISR_Enable( level ); 40012cf0: 7f ff be 01 call 400024f4 40012cf4: 01 00 00 00 nop executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_NOWAIT; 40012cf8: 82 10 20 04 mov 4, %g1 ! 4 40012cfc: c2 24 60 34 st %g1, [ %l1 + 0x34 ] executing->Wait.return_argument_1 = (void *)size; /* Wait.count will be filled in with the message priority */ _ISR_Enable( level ); _Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout ); } 40012d00: 81 c7 e0 08 ret 40012d04: 81 e8 00 00 restore _Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue ); executing->Wait.queue = &the_message_queue->Wait_queue; executing->Wait.id = id; executing->Wait.return_argument = buffer; executing->Wait.return_argument_1 = (void *)size; 40012d08: f6 24 60 2c st %i3, [ %l1 + 0x2c ] executing->Wait.return_code = CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_NOWAIT; return; } _Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue ); executing->Wait.queue = &the_message_queue->Wait_queue; 40012d0c: f0 24 60 44 st %i0, [ %l1 + 0x44 ] executing->Wait.id = id; 40012d10: f2 24 60 20 st %i1, [ %l1 + 0x20 ] executing->Wait.return_argument = buffer; 40012d14: f4 24 60 28 st %i2, [ %l1 + 0x28 ] RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section ( Thread_queue_Control *the_thread_queue ) { the_thread_queue->sync_state = THREAD_QUEUE_NOTHING_HAPPENED; 40012d18: c2 26 20 30 st %g1, [ %i0 + 0x30 ] executing->Wait.return_argument_1 = (void *)size; /* Wait.count will be filled in with the message priority */ _ISR_Enable( level ); 40012d1c: 7f ff bd f6 call 400024f4 40012d20: 35 10 00 37 sethi %hi(0x4000dc00), %i2 _Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout ); 40012d24: b2 10 00 1d mov %i5, %i1 40012d28: 7f ff ea f0 call 4000d8e8 <_Thread_queue_Enqueue_with_handler> 40012d2c: 95 ee a1 80 restore %i2, 0x180, %o2 40012d30: 01 00 00 00 nop 40012d50 <_CORE_message_queue_Submit>: CORE_message_queue_API_mp_support_callout api_message_queue_mp_support, CORE_message_queue_Submit_types submit_type, boolean wait, Watchdog_Interval timeout ) { 40012d50: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; CORE_message_queue_Buffer_control *the_message; Thread_Control *the_thread; if ( size > the_message_queue->maximum_message_size ) { 40012d54: c2 06 20 4c ld [ %i0 + 0x4c ], %g1 CORE_message_queue_API_mp_support_callout api_message_queue_mp_support, CORE_message_queue_Submit_types submit_type, boolean wait, Watchdog_Interval timeout ) { 40012d58: a2 10 00 18 mov %i0, %l1 ISR_Level level; CORE_message_queue_Buffer_control *the_message; Thread_Control *the_thread; if ( size > the_message_queue->maximum_message_size ) { 40012d5c: 80 a6 80 01 cmp %i2, %g1 40012d60: 18 80 00 3f bgu 40012e5c <_CORE_message_queue_Submit+0x10c> 40012d64: b0 10 20 01 mov 1, %i0 /* * Is there a thread currently waiting on this message queue? */ if ( the_message_queue->number_of_pending_messages == 0 ) { 40012d68: c2 04 60 48 ld [ %l1 + 0x48 ], %g1 40012d6c: 80 a0 60 00 cmp %g1, 0 40012d70: 32 80 00 0f bne,a 40012dac <_CORE_message_queue_Submit+0x5c> 40012d74: c4 04 60 48 ld [ %l1 + 0x48 ], %g2 the_thread = _Thread_queue_Dequeue( &the_message_queue->Wait_queue ); 40012d78: 7f ff ea 6e call 4000d730 <_Thread_queue_Dequeue> 40012d7c: 90 10 00 11 mov %l1, %o0 if ( the_thread ) { 40012d80: a0 92 20 00 orcc %o0, 0, %l0 40012d84: 02 80 00 09 be 40012da8 <_CORE_message_queue_Submit+0x58> 40012d88: 90 10 00 19 mov %i1, %o0 _CORE_message_queue_Copy_buffer( 40012d8c: d2 04 20 28 ld [ %l0 + 0x28 ], %o1 40012d90: 7f ff ff e9 call 40012d34 <_CORE_message_queue_Copy_buffer> 40012d94: 94 10 00 1a mov %i2, %o2 buffer, the_thread->Wait.return_argument, size ); *(size_t *)the_thread->Wait.return_argument_1 = size; 40012d98: c2 04 20 2c ld [ %l0 + 0x2c ], %g1 the_thread->Wait.count = submit_type; 40012d9c: fa 24 20 24 st %i5, [ %l0 + 0x24 ] _CORE_message_queue_Copy_buffer( buffer, the_thread->Wait.return_argument, size ); *(size_t *)the_thread->Wait.return_argument_1 = size; 40012da0: 10 80 00 15 b 40012df4 <_CORE_message_queue_Submit+0xa4> 40012da4: f4 20 40 00 st %i2, [ %g1 ] /* * No one waiting on the message queue at this time, so attempt to * queue the message up for a future receive. */ if ( the_message_queue->number_of_pending_messages < 40012da8: c4 04 60 48 ld [ %l1 + 0x48 ], %g2 40012dac: c2 04 60 44 ld [ %l1 + 0x44 ], %g1 40012db0: 80 a0 80 01 cmp %g2, %g1 40012db4: 1a 80 00 12 bcc 40012dfc <_CORE_message_queue_Submit+0xac> 40012db8: c2 07 a0 5c ld [ %fp + 0x5c ], %g1 RTEMS_INLINE_ROUTINE CORE_message_queue_Buffer_control * _CORE_message_queue_Allocate_message_buffer ( CORE_message_queue_Control *the_message_queue ) { return (CORE_message_queue_Buffer_control *) 40012dbc: 7f ff e0 8c call 4000afec <_Chain_Get> 40012dc0: 90 04 60 68 add %l1, 0x68, %o0 /* * NOTE: If the system is consistent, this error should never occur. */ if ( !the_message ) { 40012dc4: a0 92 20 00 orcc %o0, 0, %l0 40012dc8: 02 80 00 27 be 40012e64 <_CORE_message_queue_Submit+0x114> 40012dcc: 90 10 00 19 mov %i1, %o0 return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED; } _CORE_message_queue_Copy_buffer( 40012dd0: 92 04 20 10 add %l0, 0x10, %o1 40012dd4: 7f ff ff d8 call 40012d34 <_CORE_message_queue_Copy_buffer> 40012dd8: 94 10 00 1a mov %i2, %o2 size ); the_message->Contents.size = size; the_message->priority = submit_type; _CORE_message_queue_Insert_message( 40012ddc: 90 10 00 11 mov %l1, %o0 _CORE_message_queue_Copy_buffer( buffer, the_message->Contents.buffer, size ); the_message->Contents.size = size; 40012de0: f4 24 20 0c st %i2, [ %l0 + 0xc ] the_message->priority = submit_type; 40012de4: fa 24 20 08 st %i5, [ %l0 + 8 ] _CORE_message_queue_Insert_message( 40012de8: 92 10 00 10 mov %l0, %o1 40012dec: 40 00 0a e9 call 40015990 <_CORE_message_queue_Insert_message> 40012df0: 94 10 00 1d mov %i5, %o2 40012df4: 81 c7 e0 08 ret 40012df8: 91 e8 20 00 restore %g0, 0, %o0 * No message buffers were available so we may need to return an * overflow error or block the sender until the message is placed * on the queue. */ if ( !wait ) { 40012dfc: 80 a0 60 00 cmp %g1, 0 40012e00: 02 80 00 17 be 40012e5c <_CORE_message_queue_Submit+0x10c> 40012e04: b0 10 20 02 mov 2, %i0 /* * Do NOT block on a send if the caller is in an ISR. It is * deadly to block in an ISR. */ if ( _ISR_Is_in_progress() ) { 40012e08: 03 10 00 9d sethi %hi(0x40027400), %g1 <== NOT EXECUTED 40012e0c: c2 00 63 b4 ld [ %g1 + 0x3b4 ], %g1 ! 400277b4 <_ISR_Nest_level> <== NOT EXECUTED 40012e10: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40012e14: 12 80 00 14 bne 40012e64 <_CORE_message_queue_Submit+0x114> <== NOT EXECUTED 40012e18: 03 10 00 9d sethi %hi(0x40027400), %g1 <== NOT EXECUTED */ { Thread_Control *executing = _Thread_Executing; _ISR_Disable( level ); 40012e1c: 7f ff bd b2 call 400024e4 <== NOT EXECUTED 40012e20: e0 00 63 cc ld [ %g1 + 0x3cc ], %l0 ! 400277cc <_Thread_Executing> <== NOT EXECUTED 40012e24: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED _Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue ); executing->Wait.queue = &the_message_queue->Wait_queue; executing->Wait.id = id; executing->Wait.return_argument = buffer; executing->Wait.option = size; executing->Wait.count = submit_type; 40012e28: fa 24 20 24 st %i5, [ %l0 + 0x24 ] <== NOT EXECUTED Thread_Control *executing = _Thread_Executing; _ISR_Disable( level ); _Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue ); executing->Wait.queue = &the_message_queue->Wait_queue; executing->Wait.id = id; 40012e2c: f6 24 20 20 st %i3, [ %l0 + 0x20 ] <== NOT EXECUTED executing->Wait.return_argument = buffer; 40012e30: f2 24 20 28 st %i1, [ %l0 + 0x28 ] <== NOT EXECUTED executing->Wait.option = size; 40012e34: f4 24 20 30 st %i2, [ %l0 + 0x30 ] <== NOT EXECUTED { Thread_Control *executing = _Thread_Executing; _ISR_Disable( level ); _Thread_queue_Enter_critical_section( &the_message_queue->Wait_queue ); executing->Wait.queue = &the_message_queue->Wait_queue; 40012e38: e2 24 20 44 st %l1, [ %l0 + 0x44 ] <== NOT EXECUTED 40012e3c: c2 24 60 30 st %g1, [ %l1 + 0x30 ] <== NOT EXECUTED executing->Wait.id = id; executing->Wait.return_argument = buffer; executing->Wait.option = size; executing->Wait.count = submit_type; _ISR_Enable( level ); 40012e40: 7f ff bd ad call 400024f4 <== NOT EXECUTED 40012e44: b0 10 20 07 mov 7, %i0 <== NOT EXECUTED _Thread_queue_Enqueue( &the_message_queue->Wait_queue, timeout ); 40012e48: d2 07 a0 60 ld [ %fp + 0x60 ], %o1 <== NOT EXECUTED 40012e4c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40012e50: 15 10 00 37 sethi %hi(0x4000dc00), %o2 <== NOT EXECUTED 40012e54: 7f ff ea a5 call 4000d8e8 <_Thread_queue_Enqueue_with_handler> <== NOT EXECUTED 40012e58: 94 12 a1 80 or %o2, 0x180, %o2 ! 4000dd80 <_Thread_queue_Timeout> <== NOT EXECUTED 40012e5c: 81 c7 e0 08 ret 40012e60: 81 e8 00 00 restore } return CORE_MESSAGE_QUEUE_STATUS_UNSATISFIED_WAIT; 40012e64: b0 10 20 03 mov 3, %i0 <== NOT EXECUTED } 40012e68: 81 c7 e0 08 ret <== NOT EXECUTED 40012e6c: 81 e8 00 00 restore <== NOT EXECUTED 40006898 <_CORE_mutex_Seize_interrupt_blocking>: void _CORE_mutex_Seize_interrupt_blocking( CORE_mutex_Control *the_mutex, Watchdog_Interval timeout ) { 40006898: 9d e3 bf 98 save %sp, -104, %sp Thread_Control *executing; executing = _Thread_Executing; if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ) { 4000689c: c2 06 20 48 ld [ %i0 + 0x48 ], %g1 400068a0: 80 a0 60 02 cmp %g1, 2 Watchdog_Interval timeout ) { Thread_Control *executing; executing = _Thread_Executing; 400068a4: 03 10 00 63 sethi %hi(0x40018c00), %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) ) { 400068a8: 12 80 00 0a bne 400068d0 <_CORE_mutex_Seize_interrupt_blocking+0x38> 400068ac: d2 00 63 cc ld [ %g1 + 0x3cc ], %o1 ! 40018fcc <_Thread_Executing> if ( the_mutex->holder->current_priority > executing->current_priority ) { 400068b0: d0 06 20 5c ld [ %i0 + 0x5c ], %o0 400068b4: d2 02 60 14 ld [ %o1 + 0x14 ], %o1 400068b8: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 400068bc: 80 a0 40 09 cmp %g1, %o1 400068c0: 28 80 00 05 bleu,a 400068d4 <_CORE_mutex_Seize_interrupt_blocking+0x3c> 400068c4: c2 06 20 58 ld [ %i0 + 0x58 ], %g1 _Thread_Change_priority( 400068c8: 40 00 07 47 call 400085e4 <_Thread_Change_priority> 400068cc: 94 10 20 00 clr %o2 FALSE ); } } the_mutex->blocked_count++; 400068d0: c2 06 20 58 ld [ %i0 + 0x58 ], %g1 _Thread_queue_Enqueue( &the_mutex->Wait_queue, timeout ); 400068d4: 90 10 00 18 mov %i0, %o0 FALSE ); } } the_mutex->blocked_count++; 400068d8: 82 00 60 01 inc %g1 _Thread_queue_Enqueue( &the_mutex->Wait_queue, timeout ); 400068dc: 92 10 00 19 mov %i1, %o1 FALSE ); } } the_mutex->blocked_count++; 400068e0: c2 26 20 58 st %g1, [ %i0 + 0x58 ] _Thread_queue_Enqueue( &the_mutex->Wait_queue, timeout ); 400068e4: 15 10 00 25 sethi %hi(0x40009400), %o2 400068e8: 40 00 09 d3 call 40009034 <_Thread_queue_Enqueue_with_handler> 400068ec: 94 12 a0 cc or %o2, 0xcc, %o2 ! 400094cc <_Thread_queue_Timeout> #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 400068f0: 05 10 00 63 sethi %hi(0x40018c00), %g2 400068f4: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 400068f8: 82 00 7f ff add %g1, -1, %g1 400068fc: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 40006900: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 40006904: 80 a0 60 00 cmp %g1, 0 40006908: 12 80 00 04 bne 40006918 <_CORE_mutex_Seize_interrupt_blocking+0x80> 4000690c: 01 00 00 00 nop _Thread_Dispatch(); 40006910: 40 00 08 61 call 40008a94 <_Thread_Dispatch> 40006914: 81 e8 00 00 restore 40006918: 81 c7 e0 08 ret <== NOT EXECUTED 4000691c: 81 e8 00 00 restore <== NOT EXECUTED 40006920 <_CORE_mutex_Surrender>: CORE_mutex_Status _CORE_mutex_Surrender( CORE_mutex_Control *the_mutex, Objects_Id id, CORE_mutex_API_mp_support_callout api_mutex_mp_support ) { 40006920: 9d e3 bf 98 save %sp, -104, %sp * allowed when the mutex in quetion is FIFO or simple Priority * discipline. But Priority Ceiling or Priority Inheritance mutexes * must be released by the thread which acquired them. */ if ( the_mutex->Attributes.only_owner_release ) { 40006924: c2 06 20 44 ld [ %i0 + 0x44 ], %g1 40006928: 80 a0 60 00 cmp %g1, 0 4000692c: 02 80 00 07 be 40006948 <_CORE_mutex_Surrender+0x28> 40006930: d0 06 20 5c ld [ %i0 + 0x5c ], %o0 if ( !_Thread_Is_executing( holder ) ) 40006934: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006938: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 40018fcc <_Thread_Executing> 4000693c: 80 a2 00 01 cmp %o0, %g1 40006940: 12 80 00 51 bne 40006a84 <_CORE_mutex_Surrender+0x164> 40006944: 84 10 20 03 mov 3, %g2 return CORE_MUTEX_STATUS_NOT_OWNER_OF_RESOURCE; } /* XXX already unlocked -- not right status */ if ( !the_mutex->nest_count ) 40006948: c2 06 20 54 ld [ %i0 + 0x54 ], %g1 4000694c: 80 a0 60 00 cmp %g1, 0 40006950: 02 80 00 4c be 40006a80 <_CORE_mutex_Surrender+0x160> 40006954: 82 00 7f ff add %g1, -1, %g1 return CORE_MUTEX_STATUS_SUCCESSFUL; the_mutex->nest_count--; if ( the_mutex->nest_count != 0 ) { 40006958: 80 a0 60 00 cmp %g1, 0 4000695c: 02 80 00 09 be 40006980 <_CORE_mutex_Surrender+0x60> 40006960: c2 26 20 54 st %g1, [ %i0 + 0x54 ] switch ( the_mutex->Attributes.lock_nesting_behavior ) { 40006964: c2 06 20 40 ld [ %i0 + 0x40 ], %g1 40006968: 80 a0 60 00 cmp %g1, 0 4000696c: 02 80 00 46 be 40006a84 <_CORE_mutex_Surrender+0x164> 40006970: 84 10 20 00 clr %g2 40006974: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40006978: 02 80 00 43 be 40006a84 <_CORE_mutex_Surrender+0x164> <== NOT EXECUTED 4000697c: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED 40006980: c2 06 20 48 ld [ %i0 + 0x48 ], %g1 /* * Formally release the mutex before possibly transferring it to a * blocked thread. */ if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40006984: 80 a0 60 02 cmp %g1, 2 40006988: 22 80 00 06 be,a 400069a0 <_CORE_mutex_Surrender+0x80> 4000698c: c2 02 20 1c ld [ %o0 + 0x1c ], %g1 40006990: 80 a0 60 03 cmp %g1, 3 40006994: 32 80 00 07 bne,a 400069b0 <_CORE_mutex_Surrender+0x90> 40006998: c0 26 20 5c clr [ %i0 + 0x5c ] _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) holder->resource_count--; 4000699c: c2 02 20 1c ld [ %o0 + 0x1c ], %g1 <== NOT EXECUTED 400069a0: 82 00 7f ff add %g1, -1, %g1 400069a4: c2 22 20 1c st %g1, [ %o0 + 0x1c ] 400069a8: c2 06 20 48 ld [ %i0 + 0x48 ], %g1 the_mutex->holder = NULL; 400069ac: c0 26 20 5c clr [ %i0 + 0x5c ] /* * Whether or not someone is waiting for the mutex, an * inherited priority must be lowered if this is the last * mutex (i.e. resource) this task has. */ if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 400069b0: 80 a0 60 02 cmp %g1, 2 400069b4: 02 80 00 05 be 400069c8 <_CORE_mutex_Surrender+0xa8> 400069b8: c0 26 20 60 clr [ %i0 + 0x60 ] 400069bc: 80 a0 60 03 cmp %g1, 3 400069c0: 12 80 00 0d bne 400069f4 <_CORE_mutex_Surrender+0xd4> 400069c4: 01 00 00 00 nop _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { if ( holder->resource_count == 0 && 400069c8: c2 02 20 1c ld [ %o0 + 0x1c ], %g1 400069cc: 80 a0 60 00 cmp %g1, 0 400069d0: 12 80 00 09 bne 400069f4 <_CORE_mutex_Surrender+0xd4> 400069d4: 01 00 00 00 nop 400069d8: d2 02 20 18 ld [ %o0 + 0x18 ], %o1 400069dc: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 400069e0: 80 a2 40 01 cmp %o1, %g1 400069e4: 02 80 00 04 be 400069f4 <_CORE_mutex_Surrender+0xd4> 400069e8: 01 00 00 00 nop holder->real_priority != holder->current_priority ) { _Thread_Change_priority( holder, holder->real_priority, TRUE ); 400069ec: 40 00 06 fe call 400085e4 <_Thread_Change_priority> 400069f0: 94 10 20 01 mov 1, %o2 ! 1 /* * Now we check if another thread was waiting for this mutex. If so, * transfer the mutex to that thread. */ if ( ( the_thread = _Thread_queue_Dequeue( &the_mutex->Wait_queue ) ) ) { 400069f4: 40 00 09 22 call 40008e7c <_Thread_queue_Dequeue> 400069f8: 90 10 00 18 mov %i0, %o0 400069fc: 86 92 20 00 orcc %o0, 0, %g3 40006a00: 02 80 00 1f be 40006a7c <_CORE_mutex_Surrender+0x15c> 40006a04: 82 10 20 01 mov 1, %g1 } else #endif { the_mutex->holder = the_thread; the_mutex->holder_id = the_thread->Object.id; 40006a08: c2 00 e0 08 ld [ %g3 + 8 ], %g1 the_mutex->nest_count = 1; switch ( the_mutex->Attributes.discipline ) { 40006a0c: c4 06 20 48 ld [ %i0 + 0x48 ], %g2 } else #endif { the_mutex->holder = the_thread; the_mutex->holder_id = the_thread->Object.id; 40006a10: c2 26 20 60 st %g1, [ %i0 + 0x60 ] } else #endif { the_mutex->holder = the_thread; 40006a14: c6 26 20 5c st %g3, [ %i0 + 0x5c ] the_mutex->holder_id = the_thread->Object.id; the_mutex->nest_count = 1; 40006a18: 82 10 20 01 mov 1, %g1 switch ( the_mutex->Attributes.discipline ) { 40006a1c: 80 a0 a0 02 cmp %g2, 2 40006a20: 02 80 00 07 be 40006a3c <_CORE_mutex_Surrender+0x11c> 40006a24: c2 26 20 54 st %g1, [ %i0 + 0x54 ] 40006a28: 80 a0 a0 03 cmp %g2, 3 40006a2c: 12 80 00 16 bne 40006a84 <_CORE_mutex_Surrender+0x164> 40006a30: 84 10 20 00 clr %g2 break; case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT: the_thread->resource_count++; break; case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING: the_thread->resource_count++; 40006a34: 10 80 00 07 b 40006a50 <_CORE_mutex_Surrender+0x130> <== NOT EXECUTED 40006a38: c2 00 e0 1c ld [ %g3 + 0x1c ], %g1 <== NOT EXECUTED switch ( the_mutex->Attributes.discipline ) { case CORE_MUTEX_DISCIPLINES_FIFO: case CORE_MUTEX_DISCIPLINES_PRIORITY: break; case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT: the_thread->resource_count++; 40006a3c: c2 00 e0 1c ld [ %g3 + 0x1c ], %g1 40006a40: 84 10 20 00 clr %g2 40006a44: 82 00 60 01 inc %g1 40006a48: 10 80 00 0f b 40006a84 <_CORE_mutex_Surrender+0x164> 40006a4c: c2 20 e0 1c st %g1, [ %g3 + 0x1c ] break; case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING: the_thread->resource_count++; if (the_mutex->Attributes.priority_ceiling < 40006a50: c4 00 e0 14 ld [ %g3 + 0x14 ], %g2 <== NOT EXECUTED break; case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT: the_thread->resource_count++; break; case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING: the_thread->resource_count++; 40006a54: 82 00 60 01 inc %g1 <== NOT EXECUTED 40006a58: c2 20 e0 1c st %g1, [ %g3 + 0x1c ] <== NOT EXECUTED if (the_mutex->Attributes.priority_ceiling < 40006a5c: d2 06 20 4c ld [ %i0 + 0x4c ], %o1 <== NOT EXECUTED 40006a60: 80 a2 40 02 cmp %o1, %g2 <== NOT EXECUTED 40006a64: 3a 80 00 08 bcc,a 40006a84 <_CORE_mutex_Surrender+0x164> <== NOT EXECUTED 40006a68: 84 10 20 00 clr %g2 <== NOT EXECUTED the_thread->current_priority){ _Thread_Change_priority( 40006a6c: 40 00 06 de call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 40006a70: 94 10 20 00 clr %o2 <== NOT EXECUTED } break; } } } else the_mutex->lock = CORE_MUTEX_UNLOCKED; 40006a74: 10 80 00 04 b 40006a84 <_CORE_mutex_Surrender+0x164> <== NOT EXECUTED 40006a78: 84 10 20 00 clr %g2 <== NOT EXECUTED 40006a7c: c2 26 20 50 st %g1, [ %i0 + 0x50 ] 40006a80: 84 10 20 00 clr %g2 return CORE_MUTEX_STATUS_SUCCESSFUL; } 40006a84: 81 c7 e0 08 ret 40006a88: 91 e8 00 02 restore %g0, %g2, %o0 4000c0f8 <_Debug_Is_enabled>: */ boolean _Debug_Is_enabled( rtems_debug_control level ) { 4000c0f8: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 4000c0fc: c2 00 63 d0 ld [ %g1 + 0x3d0 ], %g1 ! 40018fd0 <_Debug_Level> <== NOT EXECUTED 4000c100: 90 0a 00 01 and %o0, %g1, %o0 <== NOT EXECUTED return (_Debug_Level & level) ? TRUE : FALSE; } 4000c104: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED 4000c108: 81 c3 e0 08 retl <== NOT EXECUTED 4000c10c: 90 40 20 00 addx %g0, 0, %o0 <== NOT EXECUTED 40005060 <_Event_Seize>: rtems_event_set event_in, rtems_option option_set, rtems_interval ticks, rtems_event_set *event_out ) { 40005060: 9d e3 bf 98 save %sp, -104, %sp rtems_event_set pending_events; ISR_Level level; RTEMS_API_Control *api; Event_Sync_states sync_state; executing = _Thread_Executing; 40005064: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005068: e0 00 63 cc ld [ %g1 + 0x3cc ], %l0 ! 40018fcc <_Thread_Executing> executing->Wait.return_code = RTEMS_SUCCESSFUL; 4000506c: c0 24 20 34 clr [ %l0 + 0x34 ] api = executing->API_Extensions[ THREAD_API_RTEMS ]; _ISR_Disable( level ); 40005070: 7f ff f3 33 call 40001d3c 40005074: e4 04 21 6c ld [ %l0 + 0x16c ], %l2 40005078: 84 10 00 08 mov %o0, %g2 pending_events = api->pending_events; 4000507c: c2 04 a0 40 ld [ %l2 + 0x40 ], %g1 seized_events = _Event_sets_Get( pending_events, event_in ); if ( !_Event_sets_Is_empty( seized_events ) && 40005080: a2 8e 00 01 andcc %i0, %g1, %l1 40005084: 02 80 00 0e be 400050bc <_Event_Seize+0x5c> 40005088: 80 8e 60 01 btst 1, %i1 4000508c: 80 a4 40 18 cmp %l1, %i0 40005090: 02 80 00 04 be 400050a0 <_Event_Seize+0x40> 40005094: 80 8e 60 02 btst 2, %i1 40005098: 02 80 00 09 be 400050bc <_Event_Seize+0x5c> 4000509c: 80 8e 60 01 btst 1, %i1 (seized_events == event_in || _Options_Is_any( option_set )) ) { api->pending_events = 400050a0: 82 28 40 11 andn %g1, %l1, %g1 400050a4: c2 24 a0 40 st %g1, [ %l2 + 0x40 ] _Event_sets_Clear( pending_events, seized_events ); _ISR_Enable( level ); 400050a8: 7f ff f3 29 call 40001d4c 400050ac: 01 00 00 00 nop 400050b0: e2 26 c0 00 st %l1, [ %i3 ] 400050b4: 81 c7 e0 08 ret 400050b8: 81 e8 00 00 restore *event_out = seized_events; return; } if ( _Options_Is_no_wait( option_set ) ) { 400050bc: 22 80 00 09 be,a 400050e0 <_Event_Seize+0x80> 400050c0: 23 10 00 64 sethi %hi(0x40019000), %l1 _ISR_Enable( level ); 400050c4: 7f ff f3 22 call 40001d4c 400050c8: 90 10 00 02 mov %g2, %o0 executing->Wait.return_code = RTEMS_UNSATISFIED; 400050cc: 82 10 20 0d mov 0xd, %g1 400050d0: c2 24 20 34 st %g1, [ %l0 + 0x34 ] *event_out = seized_events; 400050d4: e2 26 c0 00 st %l1, [ %i3 ] 400050d8: 81 c7 e0 08 ret 400050dc: 81 e8 00 00 restore return; } _Event_Sync_state = EVENT_SYNC_NOTHING_HAPPENED; 400050e0: 82 10 20 01 mov 1, %g1 executing->Wait.option = (uint32_t ) option_set; 400050e4: f2 24 20 30 st %i1, [ %l0 + 0x30 ] executing->Wait.count = (uint32_t ) event_in; 400050e8: f0 24 20 24 st %i0, [ %l0 + 0x24 ] executing->Wait.return_argument = event_out; 400050ec: f6 24 20 28 st %i3, [ %l0 + 0x28 ] executing->Wait.return_code = RTEMS_UNSATISFIED; *event_out = seized_events; return; } _Event_Sync_state = EVENT_SYNC_NOTHING_HAPPENED; 400050f0: c2 24 62 04 st %g1, [ %l1 + 0x204 ] executing->Wait.option = (uint32_t ) option_set; executing->Wait.count = (uint32_t ) event_in; executing->Wait.return_argument = event_out; _ISR_Enable( level ); 400050f4: 7f ff f3 16 call 40001d4c 400050f8: 90 10 00 02 mov %g2, %o0 if ( ticks ) { 400050fc: 80 a6 a0 00 cmp %i2, 0 40005100: 02 80 00 0f be 4000513c <_Event_Seize+0xdc> 40005104: 90 10 00 10 mov %l0, %o0 _Watchdog_Initialize( 40005108: c2 04 20 08 ld [ %l0 + 8 ], %g1 ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 4000510c: 11 10 00 63 sethi %hi(0x40018c00), %o0 void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; the_watchdog->id = id; 40005110: c2 24 20 68 st %g1, [ %l0 + 0x68 ] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; 40005114: 03 10 00 14 sethi %hi(0x40005000), %g1 40005118: 82 10 63 e8 or %g1, 0x3e8, %g1 ! 400053e8 <_Event_Timeout> Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 4000511c: f4 24 20 54 st %i2, [ %l0 + 0x54 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40005120: c0 24 20 50 clr [ %l0 + 0x50 ] the_watchdog->routine = routine; the_watchdog->id = id; the_watchdog->user_data = user_data; 40005124: c0 24 20 6c clr [ %l0 + 0x6c ] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; 40005128: c2 24 20 64 st %g1, [ %l0 + 0x64 ] ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 4000512c: 90 12 23 ec or %o0, 0x3ec, %o0 40005130: 40 00 13 36 call 40009e08 <_Watchdog_Insert> 40005134: 92 04 20 48 add %l0, 0x48, %o1 NULL ); _Watchdog_Insert_ticks( &executing->Timer, ticks ); } _Thread_Set_state( executing, STATES_WAITING_FOR_EVENT ); 40005138: 90 10 00 10 mov %l0, %o0 4000513c: 40 00 11 3c call 4000962c <_Thread_Set_state> 40005140: 92 10 21 00 mov 0x100, %o1 _ISR_Disable( level ); 40005144: 7f ff f2 fe call 40001d3c 40005148: 01 00 00 00 nop 4000514c: b0 10 00 08 mov %o0, %i0 sync_state = _Event_Sync_state; 40005150: c4 04 62 04 ld [ %l1 + 0x204 ], %g2 _Event_Sync_state = EVENT_SYNC_SYNCHRONIZED; 40005154: c0 24 62 04 clr [ %l1 + 0x204 ] switch ( sync_state ) { 40005158: 80 a0 a0 02 cmp %g2, 2 4000515c: 02 80 00 08 be 4000517c <_Event_Seize+0x11c> 40005160: 80 a0 a0 03 cmp %g2, 3 40005164: 02 80 00 09 be 40005188 <_Event_Seize+0x128> 40005168: 80 a0 a0 01 cmp %g2, 1 4000516c: 12 80 00 15 bne 400051c0 <_Event_Seize+0x160> 40005170: 01 00 00 00 nop * enter the synchronization states above. */ return; case EVENT_SYNC_NOTHING_HAPPENED: _ISR_Enable( level ); 40005174: 7f ff f2 f6 call 40001d4c 40005178: 81 e8 00 00 restore return; case EVENT_SYNC_TIMEOUT: executing->Wait.return_code = RTEMS_TIMEOUT; 4000517c: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED 40005180: c2 24 20 34 st %g1, [ %l0 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 40005184: 30 80 00 0b b,a 400051b0 <_Event_Seize+0x150> <== NOT EXECUTED _Thread_Unblock( executing ); return; case EVENT_SYNC_SATISFIED: if ( _Watchdog_Is_active( &executing->Timer ) ) { 40005188: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 <== NOT EXECUTED 4000518c: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 40005190: 12 80 00 08 bne 400051b0 <_Event_Seize+0x150> <== NOT EXECUTED 40005194: 01 00 00 00 nop <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; 40005198: c4 24 20 50 st %g2, [ %l0 + 0x50 ] <== NOT EXECUTED _Watchdog_Deactivate( &executing->Timer ); _ISR_Enable( level ); 4000519c: 7f ff f2 ec call 40001d4c <== NOT EXECUTED 400051a0: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED (void) _Watchdog_Remove( &executing->Timer ); 400051a4: 40 00 13 71 call 40009f68 <_Watchdog_Remove> <== NOT EXECUTED 400051a8: 90 04 20 48 add %l0, 0x48, %o0 <== NOT EXECUTED 400051ac: 30 80 00 03 b,a 400051b8 <_Event_Seize+0x158> <== NOT EXECUTED } else _ISR_Enable( level ); 400051b0: 7f ff f2 e7 call 40001d4c <== NOT EXECUTED 400051b4: b0 10 00 10 mov %l0, %i0 <== NOT EXECUTED _Thread_Unblock( executing ); 400051b8: 7f ff ff a4 call 40005048 <_Thread_Unblock> <== NOT EXECUTED 400051bc: 81 e8 00 00 restore <== NOT EXECUTED 400051c0: 81 c7 e0 08 ret <== NOT EXECUTED 400051c4: 81 e8 00 00 restore <== NOT EXECUTED 400052e0 <_Event_Surrender>: */ void _Event_Surrender( Thread_Control *the_thread ) { 400052e0: 9d e3 bf 98 save %sp, -104, %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 ]; 400052e4: e2 06 21 6c ld [ %i0 + 0x16c ], %l1 option_set = (rtems_option) the_thread->Wait.option; 400052e8: e6 06 20 30 ld [ %i0 + 0x30 ], %l3 _ISR_Disable( level ); 400052ec: 7f ff f2 94 call 40001d3c 400052f0: a0 10 00 18 mov %i0, %l0 400052f4: a4 10 00 08 mov %o0, %l2 pending_events = api->pending_events; 400052f8: c8 04 60 40 ld [ %l1 + 0x40 ], %g4 event_condition = (rtems_event_set) the_thread->Wait.count; 400052fc: c4 06 20 24 ld [ %i0 + 0x24 ], %g2 seized_events = _Event_sets_Get( pending_events, event_condition ); if ( !_Event_sets_Is_empty( seized_events ) ) { 40005300: 86 88 80 04 andcc %g2, %g4, %g3 40005304: 02 80 00 36 be 400053dc <_Event_Surrender+0xfc> 40005308: 01 00 00 00 nop if ( _States_Is_waiting_for_event( the_thread->current_state ) ) { 4000530c: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 40005310: 80 88 61 00 btst 0x100, %g1 40005314: 02 80 00 1e be 4000538c <_Event_Surrender+0xac> 40005318: 1b 10 00 64 sethi %hi(0x40019000), %o5 if ( seized_events == event_condition || _Options_Is_any( option_set ) ) { 4000531c: 80 a0 c0 02 cmp %g3, %g2 40005320: 02 80 00 04 be 40005330 <_Event_Surrender+0x50> 40005324: 80 8c e0 02 btst 2, %l3 40005328: 02 80 00 19 be 4000538c <_Event_Surrender+0xac> 4000532c: 01 00 00 00 nop api->pending_events = 40005330: 82 29 00 03 andn %g4, %g3, %g1 40005334: c2 24 60 40 st %g1, [ %l1 + 0x40 ] _Event_sets_Clear( pending_events, seized_events ); the_thread->Wait.count = 0; *(rtems_event_set *)the_thread->Wait.return_argument = seized_events; 40005338: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 if ( !_Event_sets_Is_empty( seized_events ) ) { 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 ); the_thread->Wait.count = 0; 4000533c: c0 24 20 24 clr [ %l0 + 0x24 ] *(rtems_event_set *)the_thread->Wait.return_argument = seized_events; 40005340: c6 20 40 00 st %g3, [ %g1 ] _ISR_Flash( level ); 40005344: 7f ff f2 82 call 40001d4c 40005348: 01 00 00 00 nop 4000534c: 7f ff f2 7c call 40001d3c 40005350: 01 00 00 00 nop if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { 40005354: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 40005358: 80 a0 60 02 cmp %g1, 2 4000535c: 02 80 00 05 be 40005370 <_Event_Surrender+0x90> 40005360: 82 10 20 03 mov 3, %g1 _ISR_Enable( level ); 40005364: 7f ff f2 7a call 40001d4c 40005368: 90 10 00 12 mov %l2, %o0 4000536c: 30 80 00 06 b,a 40005384 <_Event_Surrender+0xa4> 40005370: c2 24 20 50 st %g1, [ %l0 + 0x50 ] _Thread_Unblock( the_thread ); } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); 40005374: 7f ff f2 76 call 40001d4c 40005378: 90 10 00 12 mov %l2, %o0 (void) _Watchdog_Remove( &the_thread->Timer ); 4000537c: 40 00 12 fb call 40009f68 <_Watchdog_Remove> 40005380: 90 04 20 48 add %l0, 0x48, %o0 _Thread_Unblock( the_thread ); 40005384: 7f ff ff d1 call 400052c8 <_Thread_Unblock> 40005388: 81 e8 00 00 restore } return; } } switch ( _Event_Sync_state ) { 4000538c: c2 03 62 04 ld [ %o5 + 0x204 ], %g1 <== NOT EXECUTED 40005390: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40005394: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40005398: 18 80 00 11 bgu 400053dc <_Event_Surrender+0xfc> <== NOT EXECUTED 4000539c: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED case EVENT_SYNC_SATISFIED: break; case EVENT_SYNC_NOTHING_HAPPENED: case EVENT_SYNC_TIMEOUT: if ( !_Thread_Is_executing( the_thread ) ) 400053a0: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED 400053a4: 80 a4 00 01 cmp %l0, %g1 <== NOT EXECUTED 400053a8: 12 80 00 0d bne 400053dc <_Event_Surrender+0xfc> <== NOT EXECUTED 400053ac: 80 a0 c0 02 cmp %g3, %g2 <== NOT EXECUTED break; if ( seized_events == event_condition || _Options_Is_any(option_set) ) { 400053b0: 02 80 00 04 be 400053c0 <_Event_Surrender+0xe0> <== NOT EXECUTED 400053b4: 80 8c e0 02 btst 2, %l3 <== NOT EXECUTED 400053b8: 02 80 00 09 be 400053dc <_Event_Surrender+0xfc> <== NOT EXECUTED 400053bc: 01 00 00 00 nop <== NOT EXECUTED api->pending_events = 400053c0: 82 29 00 03 andn %g4, %g3, %g1 <== NOT EXECUTED 400053c4: c2 24 60 40 st %g1, [ %l1 + 0x40 ] <== NOT EXECUTED _Event_sets_Clear( pending_events,seized_events ); the_thread->Wait.count = 0; *(rtems_event_set *)the_thread->Wait.return_argument = seized_events; 400053c8: c2 04 20 28 ld [ %l0 + 0x28 ], %g1 <== NOT EXECUTED break; if ( seized_events == event_condition || _Options_Is_any(option_set) ) { api->pending_events = _Event_sets_Clear( pending_events,seized_events ); the_thread->Wait.count = 0; 400053cc: c0 24 20 24 clr [ %l0 + 0x24 ] <== NOT EXECUTED *(rtems_event_set *)the_thread->Wait.return_argument = seized_events; 400053d0: c6 20 40 00 st %g3, [ %g1 ] <== NOT EXECUTED _Event_Sync_state = EVENT_SYNC_SATISFIED; 400053d4: 82 10 20 03 mov 3, %g1 <== NOT EXECUTED 400053d8: c2 23 62 04 st %g1, [ %o5 + 0x204 ] <== NOT EXECUTED } break; } } _ISR_Enable( level ); 400053dc: 7f ff f2 5c call 40001d4c 400053e0: 91 e8 00 12 restore %g0, %l2, %o0 400053e4: 01 00 00 00 nop 400053e8 <_Event_Timeout>: void _Event_Timeout( Objects_Id id, void *ignored ) { 400053e8: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 400053ec: 92 96 20 00 orcc %i0, 0, %o1 400053f0: 12 80 00 0a bne 40005418 <_Event_Timeout+0x30> 400053f4: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400053f8: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400053fc: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40005400: 84 00 a0 01 inc %g2 <== NOT EXECUTED 40005404: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] <== NOT EXECUTED Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40005408: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 4000540c: f0 00 63 cc ld [ %g1 + 0x3cc ], %i0 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40005410: 10 80 00 18 b 40005470 <_Event_Timeout+0x88> <== NOT EXECUTED 40005414: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED 40005418: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 4000541c: 80 a0 a0 04 cmp %g2, 4 40005420: 18 80 00 0e bgu 40005458 <_Event_Timeout+0x70> 40005424: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40005428: 83 32 60 1b srl %o1, 0x1b, %g1 4000542c: 80 a0 60 01 cmp %g1, 1 40005430: 12 80 00 0a bne 40005458 <_Event_Timeout+0x70> 40005434: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40005438: 83 28 a0 02 sll %g2, 2, %g1 4000543c: 05 10 00 63 sethi %hi(0x40018c00), %g2 40005440: 84 10 a2 50 or %g2, 0x250, %g2 ! 40018e50 <_Objects_Information_table> 40005444: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40005448: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 4000544c: 80 a2 20 00 cmp %o0, 0 40005450: 12 80 00 05 bne 40005464 <_Event_Timeout+0x7c> 40005454: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40005458: b0 10 20 00 clr %i0 <== NOT EXECUTED 4000545c: 10 80 00 05 b 40005470 <_Event_Timeout+0x88> <== NOT EXECUTED 40005460: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40005464: 40 00 08 98 call 400076c4 <_Objects_Get> 40005468: 94 07 bf f4 add %fp, -12, %o2 4000546c: b0 10 00 08 mov %o0, %i0 Thread_Control *the_thread; Objects_Locations location; ISR_Level level; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40005470: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005474: 80 a0 60 00 cmp %g1, 0 40005478: 12 80 00 27 bne 40005514 <_Event_Timeout+0x12c> 4000547c: 01 00 00 00 nop * 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 ); 40005480: 7f ff f2 2f call 40001d3c 40005484: 01 00 00 00 nop 40005488: 86 10 00 08 mov %o0, %g3 if ( the_thread->Wait.count ) { /* verify thread is waiting */ 4000548c: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 40005490: 80 a0 60 00 cmp %g1, 0 40005494: 02 80 00 1a be 400054fc <_Event_Timeout+0x114> 40005498: 05 10 00 64 sethi %hi(0x40019000), %g2 the_thread->Wait.count = 0; if ( _Event_Sync_state != EVENT_SYNC_SYNCHRONIZED && 4000549c: c2 00 a2 04 ld [ %g2 + 0x204 ], %g1 ! 40019204 <_Event_Sync_state> 400054a0: 80 a0 60 00 cmp %g1, 0 400054a4: 02 80 00 0d be 400054d8 <_Event_Timeout+0xf0> 400054a8: c0 26 20 24 clr [ %i0 + 0x24 ] 400054ac: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400054b0: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED 400054b4: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED 400054b8: 12 80 00 09 bne 400054dc <_Event_Timeout+0xf4> <== NOT EXECUTED 400054bc: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED _Thread_Is_executing( the_thread ) ) { if ( _Event_Sync_state != EVENT_SYNC_SATISFIED ) { 400054c0: c2 00 a2 04 ld [ %g2 + 0x204 ], %g1 <== NOT EXECUTED 400054c4: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 400054c8: 02 80 00 03 be 400054d4 <_Event_Timeout+0xec> <== NOT EXECUTED 400054cc: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED _Event_Sync_state = EVENT_SYNC_TIMEOUT; 400054d0: c2 20 a2 04 st %g1, [ %g2 + 0x204 ] <== NOT EXECUTED } _ISR_Enable( level ); 400054d4: 30 80 00 0a b,a 400054fc <_Event_Timeout+0x114> <== NOT EXECUTED } else { the_thread->Wait.return_code = RTEMS_TIMEOUT; 400054d8: 82 10 20 06 mov 6, %g1 400054dc: c2 26 20 34 st %g1, [ %i0 + 0x34 ] _ISR_Enable( level ); 400054e0: 7f ff f2 1b call 40001d4c 400054e4: 90 10 00 03 mov %g3, %o0 RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); 400054e8: 90 10 00 18 mov %i0, %o0 400054ec: 13 04 00 ff sethi %hi(0x1003fc00), %o1 400054f0: 40 00 0c af call 400087ac <_Thread_Clear_state> 400054f4: 92 12 63 f8 or %o1, 0x3f8, %o1 ! 1003fff8 400054f8: 30 80 00 03 b,a 40005504 <_Event_Timeout+0x11c> _Thread_Unblock( the_thread ); } } else { _ISR_Enable( level ); 400054fc: 7f ff f2 14 call 40001d4c <== NOT EXECUTED 40005500: 01 00 00 00 nop <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void ) { RTEMS_COMPILER_MEMORY_BARRIER(); _Thread_Dispatch_disable_level -= 1; 40005504: 05 10 00 63 sethi %hi(0x40018c00), %g2 40005508: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 4000550c: 82 00 7f ff add %g1, -1, %g1 40005510: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 40005514: 81 c7 e0 08 ret 40005518: 81 e8 00 00 restore 40006ee8 <_Heap_Calc_block_size>: */ size_t _Heap_Calc_block_size( size_t size, uint32_t page_size, uint32_t min_size) { 40006ee8: 9d e3 bf 90 save %sp, -112, %sp uint32_t block_size = size + HEAP_BLOCK_USED_OVERHEAD; 40006eec: 82 06 20 04 add %i0, 4, %g1 _Heap_Align_up(&block_size, page_size); 40006ef0: 92 10 00 19 mov %i1, %o1 size_t _Heap_Calc_block_size( size_t size, uint32_t page_size, uint32_t min_size) { uint32_t block_size = size + HEAP_BLOCK_USED_OVERHEAD; 40006ef4: c2 27 bf f4 st %g1, [ %fp + -12 ] _Heap_Align_up(&block_size, page_size); 40006ef8: 7f ff ff f0 call 40006eb8 <_Heap_Align_up> 40006efc: 90 07 bf f4 add %fp, -12, %o0 if (block_size < min_size) block_size = min_size; 40006f00: c2 07 bf f4 ld [ %fp + -12 ], %g1 40006f04: 80 a0 40 1a cmp %g1, %i2 40006f08: 1a 80 00 04 bcc 40006f18 <_Heap_Calc_block_size+0x30> 40006f0c: a0 10 00 18 mov %i0, %l0 40006f10: f4 27 bf f4 st %i2, [ %fp + -12 ] <== NOT EXECUTED /* 'block_size' becomes <= 'size' if and only if overflow occured. */ return (block_size > size) ? block_size : 0; 40006f14: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 40006f18: 80 a0 40 10 cmp %g1, %l0 40006f1c: 08 80 00 03 bleu 40006f28 <_Heap_Calc_block_size+0x40> 40006f20: b0 10 20 00 clr %i0 40006f24: b0 10 00 01 mov %g1, %i0 } 40006f28: 81 c7 e0 08 ret 40006f2c: 81 e8 00 00 restore 400187c4 <_Heap_Get_free_information>: */ RTEMS_INLINE_ROUTINE Heap_Block *_Heap_First ( Heap_Control *the_heap ) { return _Heap_Head(the_heap)->next; 400187c4: da 02 20 08 ld [ %o0 + 8 ], %o5 <== NOT EXECUTED ) { Heap_Block *the_block; Heap_Block *const tail = _Heap_Tail(the_heap); info->number = 0; 400187c8: c0 22 40 00 clr [ %o1 ] <== NOT EXECUTED info->largest = 0; 400187cc: c0 22 60 04 clr [ %o1 + 4 ] <== NOT EXECUTED info->total = 0; 400187d0: 10 80 00 0e b 40018808 <_Heap_Get_free_information+0x44> <== NOT EXECUTED 400187d4: c0 22 60 08 clr [ %o1 + 8 ] <== NOT EXECUTED uint32_t const the_size = _Heap_Block_size(the_block); /* As we always coalesce free blocks, prev block must have been used. */ _HAssert(_Heap_Is_prev_used(the_block)); info->number++; 400187d8: c2 02 40 00 ld [ %o1 ], %g1 <== NOT EXECUTED info->total += the_size; 400187dc: c4 02 60 08 ld [ %o1 + 8 ], %g2 <== NOT EXECUTED if ( info->largest < the_size ) 400187e0: c8 02 60 04 ld [ %o1 + 4 ], %g4 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE uint32_t _Heap_Block_size ( Heap_Block *the_block ) { return (the_block->size & ~HEAP_PREV_USED); 400187e4: 86 08 ff fe and %g3, -2, %g3 <== NOT EXECUTED uint32_t const the_size = _Heap_Block_size(the_block); /* As we always coalesce free blocks, prev block must have been used. */ _HAssert(_Heap_Is_prev_used(the_block)); info->number++; 400187e8: 82 00 60 01 inc %g1 <== NOT EXECUTED info->total += the_size; 400187ec: 84 00 80 03 add %g2, %g3, %g2 <== NOT EXECUTED uint32_t const the_size = _Heap_Block_size(the_block); /* As we always coalesce free blocks, prev block must have been used. */ _HAssert(_Heap_Is_prev_used(the_block)); info->number++; 400187f0: c2 22 40 00 st %g1, [ %o1 ] <== NOT EXECUTED info->total += the_size; if ( info->largest < the_size ) 400187f4: 80 a1 00 03 cmp %g4, %g3 <== NOT EXECUTED 400187f8: 1a 80 00 03 bcc 40018804 <_Heap_Get_free_information+0x40> <== NOT EXECUTED 400187fc: c4 22 60 08 st %g2, [ %o1 + 8 ] <== NOT EXECUTED info->largest = the_size; 40018800: c6 22 60 04 st %g3, [ %o1 + 4 ] <== NOT EXECUTED info->largest = 0; info->total = 0; for(the_block = _Heap_First(the_heap); the_block != tail; the_block = the_block->next) 40018804: da 03 60 08 ld [ %o5 + 8 ], %o5 <== NOT EXECUTED info->number = 0; info->largest = 0; info->total = 0; for(the_block = _Heap_First(the_heap); the_block != tail; 40018808: 80 a3 40 08 cmp %o5, %o0 <== NOT EXECUTED 4001880c: 32 bf ff f3 bne,a 400187d8 <_Heap_Get_free_information+0x14> <== NOT EXECUTED 40018810: c6 03 60 04 ld [ %o5 + 4 ], %g3 <== NOT EXECUTED info->number++; info->total += the_size; if ( info->largest < the_size ) info->largest = the_size; } } 40018814: 81 c3 e0 08 retl <== NOT EXECUTED 40018818: 01 00 00 00 nop 40006fd8 <_Heap_Initialize>: Heap_Control *the_heap, void *starting_address, size_t size, uint32_t page_size ) { 40006fd8: 9d e3 bf 98 save %sp, -104, %sp _H_uptr_t start; _H_uptr_t aligned_start; uint32_t overhead; Heap_Statistics *const stats = &the_heap->stats; if (page_size == 0) 40006fdc: 80 a6 e0 00 cmp %i3, 0 40006fe0: 12 80 00 05 bne 40006ff4 <_Heap_Initialize+0x1c> 40006fe4: f6 27 a0 50 st %i3, [ %fp + 0x50 ] page_size = CPU_ALIGNMENT; 40006fe8: 82 10 20 08 mov 8, %g1 <== NOT EXECUTED 40006fec: 10 80 00 05 b 40007000 <_Heap_Initialize+0x28> <== NOT EXECUTED 40006ff0: c2 27 a0 50 st %g1, [ %fp + 0x50 ] <== NOT EXECUTED else _Heap_Align_up( &page_size, CPU_ALIGNMENT ); 40006ff4: 90 07 a0 50 add %fp, 0x50, %o0 40006ff8: 7f ff ff b0 call 40006eb8 <_Heap_Align_up> 40006ffc: 92 10 20 08 mov 8, %o1 /* Calculate aligned_start so that aligned_start + HEAP_BLOCK_USER_OFFSET (value of user pointer) is aligned on 'page_size' boundary. Make sure resulting 'aligned_start' is not below 'starting_address'. */ start = _H_p2u(starting_address); aligned_start = start + HEAP_BLOCK_USER_OFFSET; _Heap_Align_up_uptr ( &aligned_start, page_size ); 40007000: e0 07 a0 50 ld [ %fp + 0x50 ], %l0 /* Calculate aligned_start so that aligned_start + HEAP_BLOCK_USER_OFFSET (value of user pointer) is aligned on 'page_size' boundary. Make sure resulting 'aligned_start' is not below 'starting_address'. */ start = _H_p2u(starting_address); aligned_start = start + HEAP_BLOCK_USER_OFFSET; 40007004: a4 06 60 08 add %i1, 8, %l2 uint32_t alignment ) { _H_uptr_t v = *value; uint32_t a = alignment; _H_uptr_t r = v % a; 40007008: 92 10 00 10 mov %l0, %o1 4000700c: 40 00 36 34 call 400148dc <.urem> 40007010: 90 10 00 12 mov %l2, %o0 *value = r ? v - r + a : v; 40007014: 80 a2 20 00 cmp %o0, 0 40007018: 02 80 00 05 be 4000702c <_Heap_Initialize+0x54> 4000701c: 82 10 20 10 mov 0x10, %g1 40007020: 82 04 80 10 add %l2, %l0, %g1 40007024: a4 20 40 08 sub %g1, %o0, %l2 _Heap_Align_up_uptr ( &aligned_start, page_size ); aligned_start -= HEAP_BLOCK_USER_OFFSET; /* Calculate 'min_block_size'. It's HEAP_MIN_BLOCK_SIZE aligned up to the nearest multiple of 'page_size'. */ the_heap->min_block_size = HEAP_MIN_BLOCK_SIZE; 40007028: 82 10 20 10 mov 0x10, %g1 _Heap_Align_up ( &the_heap->min_block_size, page_size ); 4000702c: 92 10 00 10 mov %l0, %o1 _Heap_Align_up_uptr ( &aligned_start, page_size ); aligned_start -= HEAP_BLOCK_USER_OFFSET; /* Calculate 'min_block_size'. It's HEAP_MIN_BLOCK_SIZE aligned up to the nearest multiple of 'page_size'. */ the_heap->min_block_size = HEAP_MIN_BLOCK_SIZE; 40007030: c2 26 20 14 st %g1, [ %i0 + 0x14 ] _Heap_Align_up ( &the_heap->min_block_size, page_size ); 40007034: 7f ff ff a1 call 40006eb8 <_Heap_Align_up> 40007038: 90 06 20 14 add %i0, 0x14, %o0 (value of user pointer) is aligned on 'page_size' boundary. Make sure resulting 'aligned_start' is not below 'starting_address'. */ start = _H_p2u(starting_address); aligned_start = start + HEAP_BLOCK_USER_OFFSET; _Heap_Align_up_uptr ( &aligned_start, page_size ); aligned_start -= HEAP_BLOCK_USER_OFFSET; 4000703c: b6 04 bf f8 add %l2, -8, %i3 /* Calculate 'the_size' -- size of the first block so that there is enough space at the end for the permanent last block. It is equal to 'size' minus total overhead aligned down to the nearest multiple of 'page_size'. */ overhead = HEAP_OVERHEAD + (aligned_start - start); 40007040: 82 26 c0 19 sub %i3, %i1, %g1 40007044: 82 00 60 08 add %g1, 8, %g1 if ( size < overhead ) 40007048: 80 a6 80 01 cmp %i2, %g1 4000704c: 0a 80 00 2b bcs 400070f8 <_Heap_Initialize+0x120> 40007050: e2 07 a0 50 ld [ %fp + 0x50 ], %l1 return 0; /* Too small area for the heap */ the_size = size - overhead; 40007054: a0 26 80 01 sub %i2, %g1, %l0 uint32_t *value, uint32_t alignment ) { uint32_t v = *value; *value = v - (v % alignment); 40007058: 92 10 00 11 mov %l1, %o1 4000705c: 40 00 36 20 call 400148dc <.urem> 40007060: 90 10 00 10 mov %l0, %o0 _Heap_Align_down ( &the_size, page_size ); if ( the_size == 0 ) 40007064: a0 a4 00 08 subcc %l0, %o0, %l0 40007068: 02 80 00 24 be 400070f8 <_Heap_Initialize+0x120> 4000706c: 07 10 00 63 sethi %hi(0x40018c00), %g3 return 0; /* Too small area for the heap */ the_heap->page_size = page_size; 40007070: e2 26 20 10 st %l1, [ %i0 + 0x10 ] the_heap->begin = starting_address; the_heap->end = starting_address + size; the_block = (Heap_Block *) aligned_start; the_block->prev_size = page_size; 40007074: e2 24 bf f8 st %l1, [ %l2 + -8 ] the_block->size = the_size | HEAP_PREV_USED; 40007078: 82 14 20 01 or %l0, 1, %g1 stats->max_search = 0; stats->allocs = 0; stats->searches = 0; stats->frees = 0; stats->resizes = 0; stats->instance = instance++; 4000707c: c4 00 e0 c8 ld [ %g3 + 0xc8 ], %g2 the_heap->end = starting_address + size; the_block = (Heap_Block *) aligned_start; the_block->prev_size = page_size; the_block->size = the_size | HEAP_PREV_USED; 40007080: c2 26 e0 04 st %g1, [ %i3 + 4 ] _HAssert(_Heap_Is_aligned(the_heap->min_block_size, page_size)); _HAssert(_Heap_Is_aligned_ptr(_Heap_User_area(the_block), page_size)); the_block = _Heap_Block_at( the_block, the_size ); the_heap->final = the_block; /* Permanent final block of the heap */ the_block->prev_size = the_size; /* Previous block is free */ 40007084: e0 26 c0 10 st %l0, [ %i3 + %l0 ] RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( void *base, uint32_t offset ) { return (Heap_Block *) _Addresses_Add_offset( base, offset ); 40007088: 88 06 c0 10 add %i3, %l0, %g4 the_block->size = page_size; 4000708c: e2 21 20 04 st %l1, [ %g4 + 4 ] the_block = (Heap_Block *) aligned_start; the_block->prev_size = page_size; the_block->size = the_size | HEAP_PREV_USED; the_block->next = _Heap_Tail( the_heap ); 40007090: f0 26 e0 08 st %i0, [ %i3 + 8 ] the_block->prev = _Heap_Head( the_heap ); 40007094: f0 26 e0 0c st %i0, [ %i3 + 0xc ] stats->max_search = 0; stats->allocs = 0; stats->searches = 0; stats->frees = 0; stats->resizes = 0; stats->instance = instance++; 40007098: c4 26 20 28 st %g2, [ %i0 + 0x28 ] the_block->size = page_size; stats->size = size; stats->free_size = the_size; stats->min_free_size = the_size; stats->free_blocks = 1; 4000709c: 82 10 20 01 mov 1, %g1 the_block = _Heap_Block_at( the_block, the_size ); the_heap->final = the_block; /* Permanent final block of the heap */ the_block->prev_size = the_size; /* Previous block is free */ the_block->size = page_size; stats->size = size; 400070a0: f4 26 20 2c st %i2, [ %i0 + 0x2c ] stats->free_size = the_size; stats->min_free_size = the_size; stats->free_blocks = 1; stats->max_free_blocks = 1; 400070a4: c2 26 20 3c st %g1, [ %i0 + 0x3c ] the_block->size = page_size; stats->size = size; stats->free_size = the_size; stats->min_free_size = the_size; stats->free_blocks = 1; 400070a8: c2 26 20 38 st %g1, [ %i0 + 0x38 ] the_heap->final = the_block; /* Permanent final block of the heap */ the_block->prev_size = the_size; /* Previous block is free */ the_block->size = page_size; stats->size = size; stats->free_size = the_size; 400070ac: e0 26 20 30 st %l0, [ %i0 + 0x30 ] stats->min_free_size = the_size; 400070b0: e0 26 20 34 st %l0, [ %i0 + 0x34 ] stats->free_blocks = 1; stats->max_free_blocks = 1; stats->used_blocks = 0; 400070b4: c0 26 20 40 clr [ %i0 + 0x40 ] stats->max_search = 0; 400070b8: c0 26 20 44 clr [ %i0 + 0x44 ] stats->allocs = 0; 400070bc: c0 26 20 48 clr [ %i0 + 0x48 ] stats->searches = 0; 400070c0: c0 26 20 4c clr [ %i0 + 0x4c ] stats->frees = 0; 400070c4: c0 26 20 50 clr [ %i0 + 0x50 ] stats->resizes = 0; 400070c8: c0 26 20 54 clr [ %i0 + 0x54 ] if ( the_size == 0 ) return 0; /* Too small area for the heap */ the_heap->page_size = page_size; the_heap->begin = starting_address; the_heap->end = starting_address + size; 400070cc: 82 06 40 1a add %i1, %i2, %g1 stats->max_search = 0; stats->allocs = 0; stats->searches = 0; stats->frees = 0; stats->resizes = 0; stats->instance = instance++; 400070d0: 84 00 a0 01 inc %g2 if ( the_size == 0 ) return 0; /* Too small area for the heap */ the_heap->page_size = page_size; the_heap->begin = starting_address; the_heap->end = starting_address + size; 400070d4: c2 26 20 1c st %g1, [ %i0 + 0x1c ] _Heap_Align_down ( &the_size, page_size ); if ( the_size == 0 ) return 0; /* Too small area for the heap */ the_heap->page_size = page_size; the_heap->begin = starting_address; 400070d8: f2 26 20 18 st %i1, [ %i0 + 0x18 ] the_block->prev_size = page_size; the_block->size = the_size | HEAP_PREV_USED; the_block->next = _Heap_Tail( the_heap ); the_block->prev = _Heap_Head( the_heap ); _Heap_Head(the_heap)->next = the_block; 400070dc: f6 26 20 08 st %i3, [ %i0 + 8 ] _Heap_Tail(the_heap)->prev = the_block; 400070e0: f6 26 20 0c st %i3, [ %i0 + 0xc ] the_heap->start = the_block; 400070e4: f6 26 20 20 st %i3, [ %i0 + 0x20 ] _HAssert(_Heap_Is_aligned(the_heap->page_size, CPU_ALIGNMENT)); _HAssert(_Heap_Is_aligned(the_heap->min_block_size, page_size)); _HAssert(_Heap_Is_aligned_ptr(_Heap_User_area(the_block), page_size)); the_block = _Heap_Block_at( the_block, the_size ); the_heap->final = the_block; /* Permanent final block of the heap */ 400070e8: c8 26 20 24 st %g4, [ %i0 + 0x24 ] stats->max_search = 0; stats->allocs = 0; stats->searches = 0; stats->frees = 0; stats->resizes = 0; stats->instance = instance++; 400070ec: c4 20 e0 c8 st %g2, [ %g3 + 0xc8 ] return ( the_size - HEAP_BLOCK_USED_OVERHEAD ); 400070f0: 81 c7 e0 08 ret 400070f4: 91 ec 3f fc restore %l0, -4, %o0 } 400070f8: 81 c7 e0 08 ret 400070fc: 91 e8 20 00 restore %g0, 0, %o0 4000c2f8 <_Heap_Resize_block>: void *starting_address, size_t size, uint32_t *old_mem_size, uint32_t *avail_mem_size ) { 4000c2f8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED uint32_t old_block_size; uint32_t old_user_size; uint32_t prev_used_flag; Heap_Statistics *const stats = &the_heap->stats; uint32_t const min_block_size = the_heap->min_block_size; uint32_t const page_size = the_heap->page_size; 4000c2fc: e6 06 20 10 ld [ %i0 + 0x10 ], %l3 <== NOT EXECUTED Heap_Block *next_next_block; uint32_t old_block_size; uint32_t old_user_size; uint32_t prev_used_flag; Heap_Statistics *const stats = &the_heap->stats; uint32_t const min_block_size = the_heap->min_block_size; 4000c300: ea 06 20 14 ld [ %i0 + 0x14 ], %l5 <== NOT EXECUTED uint32_t const page_size = the_heap->page_size; *old_mem_size = 0; 4000c304: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED *avail_mem_size = 0; 4000c308: c0 27 00 00 clr [ %i4 ] <== NOT EXECUTED /* The address passed could be greater than the block address plus * HEAP_BLOCK_USER_OFFSET as _Heap_Allocate_aligned() may produce such user * pointers. To get rid of this offset we need to align the address down * to the nearest 'page_size' boundary. */ _Heap_Align_down_uptr ( &addr, the_heap->page_size ); *the_block = (Heap_Block *)(addr - HEAP_BLOCK_USER_OFFSET); 4000c30c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 4000c310: 40 00 21 73 call 400148dc <.urem> <== NOT EXECUTED 4000c314: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED RTEMS_INLINE_ROUTINE boolean _Heap_Is_block_in ( Heap_Control *the_heap, Heap_Block *the_block ) { return _Addresses_Is_in_range( the_block, the_heap->start, the_heap->final ); 4000c318: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 <== NOT EXECUTED /* The address passed could be greater than the block address plus * HEAP_BLOCK_USER_OFFSET as _Heap_Allocate_aligned() may produce such user * pointers. To get rid of this offset we need to align the address down * to the nearest 'page_size' boundary. */ _Heap_Align_down_uptr ( &addr, the_heap->page_size ); *the_block = (Heap_Block *)(addr - HEAP_BLOCK_USER_OFFSET); 4000c31c: 90 26 40 08 sub %i1, %o0, %o0 <== NOT EXECUTED 4000c320: a4 02 3f f8 add %o0, -8, %l2 <== NOT EXECUTED _Heap_Start_of_block(the_heap, starting_address, &the_block); _HAssert(_Heap_Is_block_in(the_heap, the_block)); if (!_Heap_Is_block_in(the_heap, the_block)) 4000c324: 80 a4 80 01 cmp %l2, %g1 <== NOT EXECUTED 4000c328: 0a 80 00 78 bcs 4000c508 <_Heap_Resize_block+0x210> <== NOT EXECUTED 4000c32c: c4 06 20 24 ld [ %i0 + 0x24 ], %g2 <== NOT EXECUTED 4000c330: 80 a4 80 02 cmp %l2, %g2 <== NOT EXECUTED 4000c334: 38 80 00 78 bgu,a 4000c514 <_Heap_Resize_block+0x21c> <== NOT EXECUTED 4000c338: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED return HEAP_RESIZE_FATAL_ERROR; prev_used_flag = the_block->size & HEAP_PREV_USED; 4000c33c: c6 04 a0 04 ld [ %l2 + 4 ], %g3 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE uint32_t _Heap_Block_size ( Heap_Block *the_block ) { return (the_block->size & ~HEAP_PREV_USED); 4000c340: ae 08 ff fe and %g3, -2, %l7 <== NOT EXECUTED RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( void *base, uint32_t offset ) { return (Heap_Block *) _Addresses_Add_offset( base, offset ); 4000c344: a2 04 80 17 add %l2, %l7, %l1 <== NOT EXECUTED old_block_size = _Heap_Block_size(the_block); next_block = _Heap_Block_at(the_block, old_block_size); _HAssert(_Heap_Is_block_in(the_heap, next_block)); _HAssert(_Heap_Is_prev_used(next_block)); if ( !_Heap_Is_block_in(the_heap, next_block) || 4000c348: 80 a4 40 01 cmp %l1, %g1 <== NOT EXECUTED 4000c34c: 2a 80 00 72 bcs,a 4000c514 <_Heap_Resize_block+0x21c> <== NOT EXECUTED 4000c350: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED 4000c354: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED 4000c358: 38 80 00 6f bgu,a 4000c514 <_Heap_Resize_block+0x21c> <== NOT EXECUTED 4000c35c: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE boolean _Heap_Is_prev_used ( Heap_Block *the_block ) { return (the_block->size & HEAP_PREV_USED); 4000c360: c2 04 60 04 ld [ %l1 + 4 ], %g1 <== NOT EXECUTED 4000c364: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 4000c368: 02 80 00 68 be 4000c508 <_Heap_Resize_block+0x210> <== NOT EXECUTED 4000c36c: a8 08 7f fe and %g1, -2, %l4 <== NOT EXECUTED !_Heap_Is_prev_used(next_block)) return HEAP_RESIZE_FATAL_ERROR; next_block_size = _Heap_Block_size(next_block); next_next_block = _Heap_Block_at(next_block, next_block_size); next_is_used = (next_block == the_heap->final) || 4000c370: 80 a4 40 02 cmp %l1, %g2 <== NOT EXECUTED 4000c374: ac 10 20 01 mov 1, %l6 <== NOT EXECUTED 4000c378: 02 80 00 04 be 4000c388 <_Heap_Resize_block+0x90> <== NOT EXECUTED 4000c37c: ba 04 40 14 add %l1, %l4, %i5 <== NOT EXECUTED 4000c380: c2 07 60 04 ld [ %i5 + 4 ], %g1 <== NOT EXECUTED 4000c384: ac 08 60 01 and %g1, 1, %l6 <== NOT EXECUTED _Heap_Is_prev_used(next_next_block); /* See _Heap_Size_of_user_area() source for explanations */ old_user_size = _Addresses_Subtract(next_block, starting_address) 4000c388: 82 24 40 19 sub %l1, %i1, %g1 <== NOT EXECUTED 4000c38c: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED + HEAP_BLOCK_HEADER_OFFSET; *old_mem_size = old_user_size; 4000c390: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED if (size > old_user_size) { 4000c394: 80 a6 80 01 cmp %i2, %g1 <== NOT EXECUTED 4000c398: 08 80 00 1f bleu 4000c414 <_Heap_Resize_block+0x11c> <== NOT EXECUTED 4000c39c: b6 08 e0 01 and %g3, 1, %i3 <== NOT EXECUTED /* Need to extend the block: allocate part of the next block and then merge 'the_block' and allocated block together. */ if (next_is_used) /* Next block is in use, -- no way to extend */ 4000c3a0: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED 4000c3a4: 12 80 00 5b bne 4000c510 <_Heap_Resize_block+0x218> <== NOT EXECUTED 4000c3a8: a0 26 80 01 sub %i2, %g1, %l0 <== NOT EXECUTED uint32_t alignment ) { uint32_t v = *value; uint32_t a = alignment; uint32_t r = v % a; 4000c3ac: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED 4000c3b0: 40 00 21 4b call 400148dc <.urem> <== NOT EXECUTED 4000c3b4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED *value = r ? v - r + a : v; 4000c3b8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 4000c3bc: 02 80 00 05 be 4000c3d0 <_Heap_Resize_block+0xd8> <== NOT EXECUTED 4000c3c0: 80 a4 00 15 cmp %l0, %l5 <== NOT EXECUTED 4000c3c4: 82 04 00 13 add %l0, %l3, %g1 <== NOT EXECUTED 4000c3c8: a0 20 40 08 sub %g1, %o0, %l0 <== NOT EXECUTED 4000c3cc: 80 a4 00 15 cmp %l0, %l5 <== NOT EXECUTED 4000c3d0: 1a 80 00 03 bcc 4000c3dc <_Heap_Resize_block+0xe4> <== NOT EXECUTED 4000c3d4: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 4000c3d8: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED else { uint32_t add_block_size = size - old_user_size; _Heap_Align_up(&add_block_size, page_size); if (add_block_size < min_block_size) add_block_size = min_block_size; if (add_block_size > next_block_size) 4000c3dc: 80 a2 00 14 cmp %o0, %l4 <== NOT EXECUTED 4000c3e0: 38 80 00 4d bgu,a 4000c514 <_Heap_Resize_block+0x21c> <== NOT EXECUTED 4000c3e4: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED return HEAP_RESIZE_UNSATISFIED; /* Next block is too small or none. */ add_block_size = 4000c3e8: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED 4000c3ec: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED 4000c3f0: 7f ff ea d0 call 40006f30 <_Heap_Block_allocate> <== NOT EXECUTED 4000c3f4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED _Heap_Block_allocate(the_heap, next_block, add_block_size); /* Merge two subsequent blocks */ the_block->size = (old_block_size + add_block_size) | prev_used_flag; 4000c3f8: 90 02 00 17 add %o0, %l7, %o0 <== NOT EXECUTED 4000c3fc: 90 12 00 1b or %o0, %i3, %o0 <== NOT EXECUTED 4000c400: d0 24 a0 04 st %o0, [ %l2 + 4 ] <== NOT EXECUTED --stats->used_blocks; 4000c404: c2 06 20 40 ld [ %i0 + 0x40 ], %g1 <== NOT EXECUTED 4000c408: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 4000c40c: 10 80 00 3a b 4000c4f4 <_Heap_Resize_block+0x1fc> <== NOT EXECUTED 4000c410: c2 26 20 40 st %g1, [ %i0 + 0x40 ] <== NOT EXECUTED } } else { /* Calculate how much memory we could free */ uint32_t free_block_size = old_user_size - size; 4000c414: a0 20 40 1a sub %g1, %i2, %l0 <== NOT EXECUTED uint32_t *value, uint32_t alignment ) { uint32_t v = *value; *value = v - (v % alignment); 4000c418: 92 10 00 13 mov %l3, %o1 <== NOT EXECUTED 4000c41c: 40 00 21 30 call 400148dc <.urem> <== NOT EXECUTED 4000c420: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED _Heap_Align_down(&free_block_size, page_size); if (free_block_size > 0) { 4000c424: a0 a4 00 08 subcc %l0, %o0, %l0 <== NOT EXECUTED 4000c428: 22 80 00 34 be,a 4000c4f8 <_Heap_Resize_block+0x200> <== NOT EXECUTED 4000c42c: c2 06 20 54 ld [ %i0 + 0x54 ], %g1 <== NOT EXECUTED /* To free some memory the block should be shortened so that it can can hold 'size' user bytes and still remain not shorter than 'min_block_size'. */ uint32_t new_block_size = old_block_size - free_block_size; 4000c430: 84 25 c0 10 sub %l7, %l0, %g2 <== NOT EXECUTED if (new_block_size < min_block_size) { 4000c434: 80 a0 80 15 cmp %g2, %l5 <== NOT EXECUTED 4000c438: 1a 80 00 08 bcc 4000c458 <_Heap_Resize_block+0x160> <== NOT EXECUTED 4000c43c: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED uint32_t delta = min_block_size - new_block_size; 4000c440: 82 25 40 02 sub %l5, %g2, %g1 <== NOT EXECUTED _HAssert(free_block_size >= delta); free_block_size -= delta; if (free_block_size == 0) { 4000c444: a0 a4 00 01 subcc %l0, %g1, %l0 <== NOT EXECUTED 4000c448: 22 80 00 2c be,a 4000c4f8 <_Heap_Resize_block+0x200> <== NOT EXECUTED 4000c44c: c2 06 20 54 ld [ %i0 + 0x54 ], %g1 <== NOT EXECUTED ++stats->resizes; return HEAP_RESIZE_SUCCESSFUL; } new_block_size += delta; 4000c450: 84 00 80 01 add %g2, %g1, %g2 <== NOT EXECUTED _HAssert(new_block_size >= min_block_size); _HAssert(new_block_size + free_block_size == old_block_size); _HAssert(_Heap_Is_aligned(new_block_size, page_size)); _HAssert(_Heap_Is_aligned(free_block_size, page_size)); if (!next_is_used) { 4000c454: 80 a5 a0 00 cmp %l6, 0 <== NOT EXECUTED 4000c458: 12 80 00 15 bne 4000c4ac <_Heap_Resize_block+0x1b4> <== NOT EXECUTED 4000c45c: 80 a4 00 15 cmp %l0, %l5 <== NOT EXECUTED Heap_Block *const new_next_block = _Heap_Block_at(the_block, new_block_size); uint32_t const new_next_block_size = next_block_size + free_block_size; _HAssert(_Heap_Is_block_in(the_heap, next_next_block)); the_block->size = new_block_size | prev_used_flag; 4000c460: 82 10 80 1b or %g2, %i3, %g1 <== NOT EXECUTED if (!next_is_used) { /* Extend the next block to the low addresses by 'free_block_size' */ Heap_Block *const new_next_block = _Heap_Block_at(the_block, new_block_size); uint32_t const new_next_block_size = next_block_size + free_block_size; 4000c464: 86 04 00 14 add %l0, %l4, %g3 <== NOT EXECUTED _HAssert(_Heap_Is_block_in(the_heap, next_next_block)); the_block->size = new_block_size | prev_used_flag; 4000c468: c2 24 a0 04 st %g1, [ %l2 + 4 ] <== NOT EXECUTED new_next_block->size = new_next_block_size | HEAP_PREV_USED; 4000c46c: 82 10 e0 01 or %g3, 1, %g1 <== NOT EXECUTED RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( void *base, uint32_t offset ) { return (Heap_Block *) _Addresses_Add_offset( base, offset ); 4000c470: 84 04 80 02 add %l2, %g2, %g2 <== NOT EXECUTED next_next_block->prev_size = new_next_block_size; 4000c474: c6 27 40 00 st %g3, [ %i5 ] <== NOT EXECUTED Heap_Block *new_block ) { Heap_Block *block = old_block; Heap_Block *next = block->next; Heap_Block *prev = block->prev; 4000c478: da 04 60 0c ld [ %l1 + 0xc ], %o5 <== NOT EXECUTED Heap_Block *old_block, Heap_Block *new_block ) { Heap_Block *block = old_block; Heap_Block *next = block->next; 4000c47c: c8 04 60 08 ld [ %l1 + 8 ], %g4 <== NOT EXECUTED _Heap_Block_at(the_block, new_block_size); uint32_t const new_next_block_size = next_block_size + free_block_size; _HAssert(_Heap_Is_block_in(the_heap, next_next_block)); the_block->size = new_block_size | prev_used_flag; new_next_block->size = new_next_block_size | HEAP_PREV_USED; 4000c480: c2 20 a0 04 st %g1, [ %g2 + 4 ] <== NOT EXECUTED next_next_block->prev_size = new_next_block_size; _Heap_Block_replace(next_block, new_next_block); the_heap->stats.free_size += free_block_size; 4000c484: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 <== NOT EXECUTED Heap_Block *prev = block->prev; block = new_block; block->next = next; 4000c488: c8 20 a0 08 st %g4, [ %g2 + 8 ] <== NOT EXECUTED 4000c48c: 82 00 40 10 add %g1, %l0, %g1 <== NOT EXECUTED block->prev = prev; 4000c490: da 20 a0 0c st %o5, [ %g2 + 0xc ] <== NOT EXECUTED 4000c494: c2 26 20 30 st %g1, [ %i0 + 0x30 ] <== NOT EXECUTED *avail_mem_size = new_next_block_size - HEAP_BLOCK_USED_OVERHEAD; 4000c498: 86 00 ff fc add %g3, -4, %g3 <== NOT EXECUTED next->prev = prev->next = block; 4000c49c: c4 21 20 0c st %g2, [ %g4 + 0xc ] <== NOT EXECUTED 4000c4a0: c4 23 60 08 st %g2, [ %o5 + 8 ] <== NOT EXECUTED 4000c4a4: 10 80 00 14 b 4000c4f4 <_Heap_Resize_block+0x1fc> <== NOT EXECUTED 4000c4a8: c6 27 00 00 st %g3, [ %i4 ] <== NOT EXECUTED } else if (free_block_size >= min_block_size) { 4000c4ac: 2a 80 00 13 bcs,a 4000c4f8 <_Heap_Resize_block+0x200> <== NOT EXECUTED 4000c4b0: c2 06 20 54 ld [ %i0 + 0x54 ], %g1 <== NOT EXECUTED /* Split the block into 2 used parts, then free the second one. */ the_block->size = new_block_size | prev_used_flag; 4000c4b4: 82 10 80 1b or %g2, %i3, %g1 <== NOT EXECUTED 4000c4b8: c2 24 a0 04 st %g1, [ %l2 + 4 ] <== NOT EXECUTED next_block = _Heap_Block_at(the_block, new_block_size); next_block->size = free_block_size | HEAP_PREV_USED; 4000c4bc: 82 14 20 01 or %l0, 1, %g1 <== NOT EXECUTED RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( void *base, uint32_t offset ) { return (Heap_Block *) _Addresses_Add_offset( base, offset ); 4000c4c0: 92 04 80 02 add %l2, %g2, %o1 <== NOT EXECUTED 4000c4c4: c2 22 60 04 st %g1, [ %o1 + 4 ] <== NOT EXECUTED ++stats->used_blocks; /* We have created used block */ 4000c4c8: c2 06 20 40 ld [ %i0 + 0x40 ], %g1 <== NOT EXECUTED --stats->frees; /* Don't count next call in stats */ 4000c4cc: c4 06 20 50 ld [ %i0 + 0x50 ], %g2 <== NOT EXECUTED } else if (free_block_size >= min_block_size) { /* Split the block into 2 used parts, then free the second one. */ the_block->size = new_block_size | prev_used_flag; next_block = _Heap_Block_at(the_block, new_block_size); next_block->size = free_block_size | HEAP_PREV_USED; ++stats->used_blocks; /* We have created used block */ 4000c4d0: 82 00 60 01 inc %g1 <== NOT EXECUTED --stats->frees; /* Don't count next call in stats */ 4000c4d4: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED } else if (free_block_size >= min_block_size) { /* Split the block into 2 used parts, then free the second one. */ the_block->size = new_block_size | prev_used_flag; next_block = _Heap_Block_at(the_block, new_block_size); next_block->size = free_block_size | HEAP_PREV_USED; ++stats->used_blocks; /* We have created used block */ 4000c4d8: c2 26 20 40 st %g1, [ %i0 + 0x40 ] <== NOT EXECUTED --stats->frees; /* Don't count next call in stats */ 4000c4dc: c4 26 20 50 st %g2, [ %i0 + 0x50 ] <== NOT EXECUTED _Heap_Free(the_heap, _Heap_User_area(next_block)); 4000c4e0: 92 02 60 08 add %o1, 8, %o1 <== NOT EXECUTED 4000c4e4: 7f ff ea 03 call 40006cf0 <_Heap_Free> <== NOT EXECUTED 4000c4e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED *avail_mem_size = free_block_size - HEAP_BLOCK_USED_OVERHEAD; 4000c4ec: 82 04 3f fc add %l0, -4, %g1 <== NOT EXECUTED 4000c4f0: c2 27 00 00 st %g1, [ %i4 ] <== NOT EXECUTED } } } ++stats->resizes; 4000c4f4: c2 06 20 54 ld [ %i0 + 0x54 ], %g1 <== NOT EXECUTED 4000c4f8: 84 10 20 00 clr %g2 <== NOT EXECUTED 4000c4fc: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000c500: 10 80 00 05 b 4000c514 <_Heap_Resize_block+0x21c> <== NOT EXECUTED 4000c504: c2 26 20 54 st %g1, [ %i0 + 0x54 ] <== NOT EXECUTED return HEAP_RESIZE_SUCCESSFUL; 4000c508: 10 80 00 03 b 4000c514 <_Heap_Resize_block+0x21c> <== NOT EXECUTED 4000c50c: 84 10 20 02 mov 2, %g2 <== NOT EXECUTED 4000c510: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED } 4000c514: 81 c7 e0 08 ret <== NOT EXECUTED 4000c518: 91 e8 00 02 restore %g0, %g2, %o0 <== NOT EXECUTED 4000c51c <_Heap_Size_of_user_area>: boolean _Heap_Size_of_user_area( Heap_Control *the_heap, void *starting_address, size_t *size ) { 4000c51c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED Heap_Block *the_block; Heap_Block *next_block; uint32_t the_size; if ( !_Addresses_Is_in_range( 4000c520: e2 06 20 20 ld [ %i0 + 0x20 ], %l1 <== NOT EXECUTED 4000c524: 80 a6 40 11 cmp %i1, %l1 <== NOT EXECUTED 4000c528: 0a 80 00 1f bcs 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c52c: e0 06 20 24 ld [ %i0 + 0x24 ], %l0 <== NOT EXECUTED 4000c530: 80 a6 40 10 cmp %i1, %l0 <== NOT EXECUTED 4000c534: 18 80 00 1c bgu 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c538: 01 00 00 00 nop <== NOT EXECUTED /* The address passed could be greater than the block address plus * HEAP_BLOCK_USER_OFFSET as _Heap_Allocate_aligned() may produce such user * pointers. To get rid of this offset we need to align the address down * to the nearest 'page_size' boundary. */ _Heap_Align_down_uptr ( &addr, the_heap->page_size ); *the_block = (Heap_Block *)(addr - HEAP_BLOCK_USER_OFFSET); 4000c53c: d2 06 20 10 ld [ %i0 + 0x10 ], %o1 <== NOT EXECUTED 4000c540: 40 00 20 e7 call 400148dc <.urem> <== NOT EXECUTED 4000c544: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 4000c548: 90 26 40 08 sub %i1, %o0, %o0 <== NOT EXECUTED 4000c54c: 90 02 3f f8 add %o0, -8, %o0 <== NOT EXECUTED return( FALSE ); _Heap_Start_of_block( the_heap, starting_address, &the_block ); _HAssert(_Heap_Is_block_in( the_heap, the_block )); if ( !_Heap_Is_block_in( the_heap, the_block ) ) 4000c550: 80 a2 00 11 cmp %o0, %l1 <== NOT EXECUTED 4000c554: 0a 80 00 14 bcs 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c558: 80 a2 00 10 cmp %o0, %l0 <== NOT EXECUTED 4000c55c: 18 80 00 12 bgu 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c560: 01 00 00 00 nop <== NOT EXECUTED RTEMS_INLINE_ROUTINE Heap_Block *_Heap_Block_at( void *base, uint32_t offset ) { return (Heap_Block *) _Addresses_Add_offset( base, offset ); 4000c564: c2 02 20 04 ld [ %o0 + 4 ], %g1 <== NOT EXECUTED 4000c568: 82 08 7f fe and %g1, -2, %g1 <== NOT EXECUTED 4000c56c: 90 02 00 01 add %o0, %g1, %o0 <== NOT EXECUTED the_size = _Heap_Block_size( the_block ); next_block = _Heap_Block_at( the_block, the_size ); _HAssert(_Heap_Is_block_in( the_heap, next_block )); _HAssert(_Heap_Is_prev_used( next_block )); if ( 4000c570: 80 a2 00 11 cmp %o0, %l1 <== NOT EXECUTED 4000c574: 0a 80 00 0c bcs 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c578: 80 a2 00 10 cmp %o0, %l0 <== NOT EXECUTED 4000c57c: 18 80 00 0a bgu 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c580: 01 00 00 00 nop <== NOT EXECUTED 4000c584: c2 02 20 04 ld [ %o0 + 4 ], %g1 <== NOT EXECUTED 4000c588: 80 88 60 01 btst 1, %g1 <== NOT EXECUTED 4000c58c: 02 80 00 06 be 4000c5a4 <_Heap_Size_of_user_area+0x88> <== NOT EXECUTED 4000c590: 82 22 00 19 sub %o0, %i1, %g1 <== NOT EXECUTED and then add correction equal to the offset of the 'size' field of the 'Heap_Block' structure. The correction is due to the fact that 'prev_size' field of the next block is actually used as user accessible area of 'the_block'. */ *size = _Addresses_Subtract ( next_block, starting_address ) 4000c594: 82 00 60 04 add %g1, 4, %g1 <== NOT EXECUTED 4000c598: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED 4000c59c: 81 c7 e0 08 ret <== NOT EXECUTED 4000c5a0: 91 e8 20 01 restore %g0, 1, %o0 <== NOT EXECUTED + HEAP_BLOCK_HEADER_OFFSET; return( TRUE ); } 4000c5a4: 81 c7 e0 08 ret <== NOT EXECUTED 4000c5a8: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED 40006558 <_IO_Manager_initialization>: void _IO_Manager_initialization( rtems_driver_address_table *driver_table, uint32_t drivers_in_table, uint32_t number_of_drivers ) { 40006558: 9d e3 bf 98 save %sp, -104, %sp 4000655c: 23 10 00 64 sethi %hi(0x40019000), %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 ) 40006560: 80 a6 80 19 cmp %i2, %i1 40006564: 18 80 00 06 bgu 4000657c <_IO_Manager_initialization+0x24> 40006568: 25 10 00 64 sethi %hi(0x40019000), %l2 * 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; 4000656c: f0 24 62 58 st %i0, [ %l1 + 0x258 ] _IO_Number_of_drivers = number_of_drivers; 40006570: f2 24 a2 54 st %i1, [ %l2 + 0x254 ] 40006574: 81 c7 e0 08 ret 40006578: 81 e8 00 00 restore /* * 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 *) 4000657c: 83 2e a0 03 sll %i2, 3, %g1 <== NOT EXECUTED 40006580: a1 2e a0 05 sll %i2, 5, %l0 <== NOT EXECUTED 40006584: a0 24 00 01 sub %l0, %g1, %l0 <== NOT EXECUTED 40006588: 40 00 0e cb call 4000a0b4 <_Workspace_Allocate_or_fatal_error> <== NOT EXECUTED 4000658c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED _Workspace_Allocate_or_fatal_error( sizeof( rtems_driver_address_table ) * ( number_of_drivers ) ); _IO_Number_of_drivers = number_of_drivers; memset( 40006590: 94 10 00 10 mov %l0, %o2 <== NOT EXECUTED _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; 40006594: f4 24 a2 54 st %i2, [ %l2 + 0x254 ] <== NOT EXECUTED /* * 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 *) 40006598: d0 24 62 58 st %o0, [ %l1 + 0x258 ] <== NOT EXECUTED _Workspace_Allocate_or_fatal_error( sizeof( rtems_driver_address_table ) * ( number_of_drivers ) ); _IO_Number_of_drivers = number_of_drivers; memset( 4000659c: 40 00 1d fd call 4000dd90 <== NOT EXECUTED 400065a0: 92 10 20 00 clr %o1 <== NOT EXECUTED _IO_Driver_address_table, 0, sizeof( rtems_driver_address_table ) * ( number_of_drivers ) ); for ( index = 0 ; index < drivers_in_table ; index++ ) _IO_Driver_address_table[index] = driver_table[index]; 400065a4: e2 04 62 58 ld [ %l1 + 0x258 ], %l1 <== NOT EXECUTED 400065a8: b4 10 20 00 clr %i2 <== NOT EXECUTED 400065ac: 10 80 00 07 b 400065c8 <_IO_Manager_initialization+0x70> <== NOT EXECUTED 400065b0: a0 10 20 00 clr %l0 <== NOT EXECUTED 400065b4: 92 04 00 18 add %l0, %i0, %o1 <== NOT EXECUTED memset( _IO_Driver_address_table, 0, sizeof( rtems_driver_address_table ) * ( number_of_drivers ) ); for ( index = 0 ; index < drivers_in_table ; index++ ) 400065b8: b4 06 a0 01 inc %i2 <== NOT EXECUTED 400065bc: a0 04 20 18 add %l0, 0x18, %l0 <== NOT EXECUTED _IO_Driver_address_table[index] = driver_table[index]; 400065c0: 40 00 1d c7 call 4000dcdc <== NOT EXECUTED 400065c4: 94 10 20 18 mov 0x18, %o2 <== NOT EXECUTED memset( _IO_Driver_address_table, 0, sizeof( rtems_driver_address_table ) * ( number_of_drivers ) ); for ( index = 0 ; index < drivers_in_table ; index++ ) 400065c8: 80 a6 80 19 cmp %i2, %i1 <== NOT EXECUTED 400065cc: 12 bf ff fa bne 400065b4 <_IO_Manager_initialization+0x5c> <== NOT EXECUTED 400065d0: 90 04 00 11 add %l0, %l1, %o0 <== NOT EXECUTED 400065d4: 81 c7 e0 08 ret <== NOT EXECUTED 400065d8: 81 e8 00 00 restore <== NOT EXECUTED 40007140 <_ISR_Handler_initialization>: * * Output parameters: NONE */ void _ISR_Handler_initialization( void ) { 40007140: 9d e3 bf 98 save %sp, -104, %sp _ISR_Signals_to_thread_executing = FALSE; 40007144: 03 10 00 64 sethi %hi(0x40019000), %g1 40007148: c0 20 60 78 clr [ %g1 + 0x78 ] ! 40019078 <_ISR_Signals_to_thread_executing> _ISR_Nest_level = 0; 4000714c: 03 10 00 63 sethi %hi(0x40018c00), %g1 _ISR_Vector_table = _Workspace_Allocate_or_fatal_error( 40007150: 90 10 24 00 mov 0x400, %o0 void _ISR_Handler_initialization( void ) { _ISR_Signals_to_thread_executing = FALSE; _ISR_Nest_level = 0; 40007154: c0 20 63 b4 clr [ %g1 + 0x3b4 ] _ISR_Vector_table = _Workspace_Allocate_or_fatal_error( 40007158: 40 00 0b d7 call 4000a0b4 <_Workspace_Allocate_or_fatal_error> 4000715c: 01 00 00 00 nop _CPU_Initialize_vectors(); #if ( CPU_ALLOCATE_INTERRUPT_STACK == TRUE ) if ( _CPU_Table.interrupt_stack_size < STACK_MINIMUM_SIZE ) 40007160: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007164: a0 10 63 04 or %g1, 0x304, %l0 ! 40018f04 <_CPU_Table> 40007168: c4 04 20 18 ld [ %l0 + 0x18 ], %g2 { _ISR_Signals_to_thread_executing = FALSE; _ISR_Nest_level = 0; _ISR_Vector_table = _Workspace_Allocate_or_fatal_error( 4000716c: 03 10 00 63 sethi %hi(0x40018c00), %g1 _CPU_Initialize_vectors(); #if ( CPU_ALLOCATE_INTERRUPT_STACK == TRUE ) if ( _CPU_Table.interrupt_stack_size < STACK_MINIMUM_SIZE ) 40007170: 80 a0 af ff cmp %g2, 0xfff 40007174: 18 80 00 06 bgu 4000718c <_ISR_Handler_initialization+0x4c> 40007178: d0 20 63 94 st %o0, [ %g1 + 0x394 ] _Internal_error_Occurred( 4000717c: 90 10 20 00 clr %o0 <== NOT EXECUTED 40007180: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 40007184: 7f ff ff df call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40007188: 94 10 20 05 mov 5, %o2 <== NOT EXECUTED INTERNAL_ERROR_CORE, TRUE, INTERNAL_ERROR_INTERRUPT_STACK_TOO_SMALL ); _CPU_Interrupt_stack_low = 4000718c: 40 00 0b ca call 4000a0b4 <_Workspace_Allocate_or_fatal_error> 40007190: d0 04 20 18 ld [ %l0 + 0x18 ], %o0 _Workspace_Allocate_or_fatal_error( _CPU_Table.interrupt_stack_size ); _CPU_Interrupt_stack_high = _Addresses_Add_offset( 40007194: c4 04 20 18 ld [ %l0 + 0x18 ], %g2 INTERNAL_ERROR_CORE, TRUE, INTERNAL_ERROR_INTERRUPT_STACK_TOO_SMALL ); _CPU_Interrupt_stack_low = 40007198: 03 10 00 63 sethi %hi(0x40018c00), %g1 _Workspace_Allocate_or_fatal_error( _CPU_Table.interrupt_stack_size ); _CPU_Interrupt_stack_high = _Addresses_Add_offset( 4000719c: 84 02 00 02 add %o0, %g2, %g2 INTERNAL_ERROR_CORE, TRUE, INTERNAL_ERROR_INTERRUPT_STACK_TOO_SMALL ); _CPU_Interrupt_stack_low = 400071a0: d0 20 63 00 st %o0, [ %g1 + 0x300 ] _Workspace_Allocate_or_fatal_error( _CPU_Table.interrupt_stack_size ); _CPU_Interrupt_stack_high = _Addresses_Add_offset( 400071a4: 03 10 00 63 sethi %hi(0x40018c00), %g1 400071a8: c4 20 62 4c st %g2, [ %g1 + 0x24c ] ! 40018e4c <_CPU_Interrupt_stack_high> #if ( CPU_HAS_HARDWARE_INTERRUPT_STACK == TRUE ) _CPU_Install_interrupt_stack(); #endif } 400071ac: 81 c7 e0 08 ret 400071b0: 81 e8 00 00 restore 4000c5bc <_Objects_Compare_name_string>: boolean _Objects_Compare_name_string( void *name_1, void *name_2, uint16_t length ) { 4000c5bc: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED if ( !strncmp( name_1, name_2, length ) ) 4000c5c0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 4000c5c4: 95 2e a0 10 sll %i2, 0x10, %o2 <== NOT EXECUTED 4000c5c8: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 4000c5cc: 40 00 08 ed call 4000e980 <== NOT EXECUTED 4000c5d0: 95 32 a0 10 srl %o2, 0x10, %o2 <== NOT EXECUTED return TRUE; return FALSE; } 4000c5d4: 80 a0 00 08 cmp %g0, %o0 <== NOT EXECUTED 4000c5d8: b0 60 3f ff subx %g0, -1, %i0 <== NOT EXECUTED 4000c5dc: 81 c7 e0 08 ret <== NOT EXECUTED 4000c5e0: 81 e8 00 00 restore <== NOT EXECUTED 40015ac0 <_Objects_Copy_name_raw>: const size_t length ) { uint32_t *source_p = (uint32_t *) source; uint32_t *destination_p = (uint32_t *) destination; size_t tmp_length = length / OBJECTS_NAME_ALIGNMENT; 40015ac0: 10 80 00 05 b 40015ad4 <_Objects_Copy_name_raw+0x14> <== NOT EXECUTED 40015ac4: 95 32 a0 02 srl %o2, 2, %o2 <== NOT EXECUTED while ( tmp_length-- ) *destination_p++ = *source_p++; 40015ac8: 90 02 20 04 add %o0, 4, %o0 <== NOT EXECUTED 40015acc: c2 22 40 00 st %g1, [ %o1 ] <== NOT EXECUTED 40015ad0: 92 02 60 04 add %o1, 4, %o1 <== NOT EXECUTED { uint32_t *source_p = (uint32_t *) source; uint32_t *destination_p = (uint32_t *) destination; size_t tmp_length = length / OBJECTS_NAME_ALIGNMENT; while ( tmp_length-- ) 40015ad4: 94 02 bf ff add %o2, -1, %o2 <== NOT EXECUTED 40015ad8: 80 a2 bf ff cmp %o2, -1 <== NOT EXECUTED 40015adc: 32 bf ff fb bne,a 40015ac8 <_Objects_Copy_name_raw+0x8> <== NOT EXECUTED 40015ae0: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED *destination_p++ = *source_p++; } 40015ae4: 81 c3 e0 08 retl <== NOT EXECUTED 40015ae8: 01 00 00 00 nop 40007290 <_Objects_Extend_information>: */ void _Objects_Extend_information( Objects_Information *information ) { 40007290: 9d e3 bf 88 save %sp, -120, %sp */ RTEMS_INLINE_ROUTINE uint32_t _Objects_Get_index( Objects_Id id ) { return (id >> OBJECTS_INDEX_START_BIT) & OBJECTS_INDEX_VALID_BITS; 40007294: c4 06 20 08 ld [ %i0 + 8 ], %g2 minimum_index = _Objects_Get_index( information->minimum_id ); index_base = minimum_index; block = 0; if ( information->maximum < minimum_index ) 40007298: e0 16 20 10 lduh [ %i0 + 0x10 ], %l0 4000729c: 03 00 00 3f sethi %hi(0xfc00), %g1 400072a0: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 400072a4: a2 08 80 01 and %g2, %g1, %l1 400072a8: 80 a4 00 11 cmp %l0, %l1 400072ac: 3a 80 00 06 bcc,a 400072c4 <_Objects_Extend_information+0x34> 400072b0: e4 06 20 18 ld [ %i0 + 0x18 ], %l2 400072b4: ac 10 00 11 mov %l1, %l6 400072b8: 90 10 20 00 clr %o0 400072bc: 10 80 00 12 b 40007304 <_Objects_Extend_information+0x74> 400072c0: b8 10 20 00 clr %i4 block_count = 0; else { block_count = information->maximum / information->allocation_size; 400072c4: 90 10 00 10 mov %l0, %o0 400072c8: 92 10 00 12 mov %l2, %o1 400072cc: 40 00 34 d8 call 4001462c <.udiv> 400072d0: ac 10 00 11 mov %l1, %l6 400072d4: 10 80 00 09 b 400072f8 <_Objects_Extend_information+0x68> 400072d8: b8 10 20 00 clr %i4 for ( ; block < block_count; block++ ) { if ( information->object_blocks[ block ] == NULL ) 400072dc: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 400072e0: c2 00 40 02 ld [ %g1 + %g2 ], %g1 400072e4: 80 a0 60 00 cmp %g1, 0 400072e8: 02 80 00 08 be 40007308 <_Objects_Extend_information+0x78> 400072ec: 80 a5 80 10 cmp %l6, %l0 break; else index_base += information->allocation_size; 400072f0: ac 05 80 12 add %l6, %l2, %l6 if ( information->maximum < minimum_index ) block_count = 0; else { block_count = information->maximum / information->allocation_size; for ( ; block < block_count; block++ ) { 400072f4: b8 07 20 01 inc %i4 400072f8: 80 a7 00 08 cmp %i4, %o0 400072fc: 12 bf ff f8 bne 400072dc <_Objects_Extend_information+0x4c> 40007300: 85 2f 20 02 sll %i4, 2, %g2 /* * If the index_base is the maximum we need to grow the tables. */ if (index_base >= information->maximum ) { 40007304: 80 a5 80 10 cmp %l6, %l0 40007308: 2a 80 00 63 bcs,a 40007494 <_Objects_Extend_information+0x204> 4000730c: c2 06 20 14 ld [ %i0 + 0x14 ], %g1 * Up the block count and maximum */ block_count++; maximum = information->maximum + information->allocation_size; 40007310: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 /* * Allocate the tables and break it up. */ if ( information->auto_extend ) { 40007314: c4 06 20 14 ld [ %i0 + 0x14 ], %g2 * Up the block count and maximum */ block_count++; maximum = information->maximum + information->allocation_size; 40007318: ae 04 00 01 add %l0, %g1, %l7 /* * Allocate the tables and break it up. */ if ( information->auto_extend ) { 4000731c: 80 a0 a0 00 cmp %g2, 0 /* * Up the block count and maximum */ block_count++; 40007320: a0 02 20 01 add %o0, 1, %l0 40007324: 82 05 c0 11 add %l7, %l1, %g1 /* * Allocate the tables and break it up. */ if ( information->auto_extend ) { 40007328: 02 80 00 0b be 40007354 <_Objects_Extend_information+0xc4> 4000732c: 91 2c 20 01 sll %l0, 1, %o0 object_blocks = (void**) 40007330: 90 02 00 10 add %o0, %l0, %o0 40007334: 90 00 40 08 add %g1, %o0, %o0 40007338: 7f ff ff cf call 40007274 <_Workspace_Allocate> 4000733c: 91 2a 20 02 sll %o0, 2, %o0 block_count * (sizeof(void *) + sizeof(uint32_t ) + sizeof(Objects_Name *)) + ((maximum + minimum_index) * sizeof(Objects_Control *)) ); if ( !object_blocks ) 40007340: a4 92 20 00 orcc %o0, 0, %l2 40007344: 32 80 00 0a bne,a 4000736c <_Objects_Extend_information+0xdc> 40007348: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1 4000734c: 81 c7 e0 08 ret <== NOT EXECUTED 40007350: 81 e8 00 00 restore <== NOT EXECUTED return; } else { object_blocks = (void**) 40007354: 90 02 00 10 add %o0, %l0, %o0 40007358: 90 00 40 08 add %g1, %o0, %o0 4000735c: 40 00 0b 56 call 4000a0b4 <_Workspace_Allocate_or_fatal_error> 40007360: 91 2a 20 02 sll %o0, 2, %o0 40007364: a4 10 00 08 mov %o0, %l2 * in the copies. */ block_count--; if ( information->maximum > minimum_index ) { 40007368: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1 /* * Take the block count down. Saves all the (block_count - 1) * in the copies. */ block_count--; 4000736c: ba 04 3f ff add %l0, -1, %i5 if ( information->maximum > minimum_index ) { 40007370: 80 a0 40 11 cmp %g1, %l1 40007374: 84 10 20 00 clr %g2 40007378: 83 2c 20 02 sll %l0, 2, %g1 /* * Break the block into the various sections. * */ inactive_per_block = (uint32_t *) _Addresses_Add_offset( 4000737c: a8 04 80 01 add %l2, %g1, %l4 object_blocks, block_count * sizeof(void*) ); name_table = (Objects_Name *) _Addresses_Add_offset( 40007380: aa 05 00 01 add %l4, %g1, %l5 * in the copies. */ block_count--; if ( information->maximum > minimum_index ) { 40007384: 08 80 00 19 bleu 400073e8 <_Objects_Extend_information+0x158> 40007388: a6 05 40 01 add %l5, %g1, %l3 /* * 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, 4000738c: d2 06 20 3c ld [ %i0 + 0x3c ], %o1 40007390: a1 2f 60 02 sll %i5, 2, %l0 40007394: 90 10 00 12 mov %l2, %o0 40007398: 40 00 1a 51 call 4000dcdc 4000739c: 94 10 00 10 mov %l0, %o2 information->object_blocks, block_count * sizeof(void*) ); memcpy( inactive_per_block, 400073a0: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 400073a4: 94 10 00 10 mov %l0, %o2 400073a8: 40 00 1a 4d call 4000dcdc 400073ac: 90 10 00 14 mov %l4, %o0 information->inactive_per_block, block_count * sizeof(uint32_t ) ); memcpy( name_table, 400073b0: d2 06 20 24 ld [ %i0 + 0x24 ], %o1 400073b4: 94 10 00 10 mov %l0, %o2 400073b8: 40 00 1a 49 call 4000dcdc 400073bc: 90 10 00 15 mov %l5, %o0 information->name_table, block_count * sizeof(Objects_Name *) ); memcpy( local_table, 400073c0: d4 16 20 10 lduh [ %i0 + 0x10 ], %o2 400073c4: d2 06 20 20 ld [ %i0 + 0x20 ], %o1 400073c8: 94 02 80 11 add %o2, %l1, %o2 400073cc: 90 10 00 13 mov %l3, %o0 400073d0: 40 00 1a 43 call 4000dcdc 400073d4: 95 2a a0 02 sll %o2, 2, %o2 /* * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; 400073d8: 10 80 00 08 b 400073f8 <_Objects_Extend_information+0x168> 400073dc: 83 2f 60 02 sll %i5, 2, %g1 else { /* * Deal with the special case of the 0 to minimum_index */ for ( index = 0; index < minimum_index; index++ ) { 400073e0: 84 00 a0 01 inc %g2 local_table[ index ] = NULL; 400073e4: c0 20 40 13 clr [ %g1 + %l3 ] else { /* * Deal with the special case of the 0 to minimum_index */ for ( index = 0; index < minimum_index; index++ ) { 400073e8: 80 a0 80 11 cmp %g2, %l1 400073ec: 32 bf ff fd bne,a 400073e0 <_Objects_Extend_information+0x150> 400073f0: 83 28 a0 02 sll %g2, 2, %g1 /* * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; 400073f4: 83 2f 60 02 sll %i5, 2, %g1 inactive_per_block[block_count] = 0; 400073f8: c0 25 00 01 clr [ %l4 + %g1 ] /* * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; 400073fc: c0 24 80 01 clr [ %l2 + %g1 ] inactive_per_block[block_count] = 0; name_table[block_count] = NULL; for ( index=index_base ; index < ( information->allocation_size + index_base ); 40007400: c4 06 20 18 ld [ %i0 + 0x18 ], %g2 * Initialise the new entries in the table. */ object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; name_table[block_count] = NULL; 40007404: c0 25 40 01 clr [ %l5 + %g1 ] for ( index=index_base ; index < ( information->allocation_size + index_base ); 40007408: 83 2d a0 02 sll %l6, 2, %g1 4000740c: 86 05 80 02 add %l6, %g2, %g3 40007410: 84 04 c0 01 add %l3, %g1, %g2 40007414: 10 80 00 04 b 40007424 <_Objects_Extend_information+0x194> 40007418: 82 10 00 16 mov %l6, %g1 index++ ) { local_table[ index ] = NULL; 4000741c: c0 20 bf fc clr [ %g2 + -4 ] inactive_per_block[block_count] = 0; name_table[block_count] = NULL; for ( index=index_base ; index < ( information->allocation_size + index_base ); index++ ) { 40007420: 82 00 60 01 inc %g1 object_blocks[block_count] = NULL; inactive_per_block[block_count] = 0; name_table[block_count] = NULL; for ( index=index_base ; index < ( information->allocation_size + index_base ); 40007424: 80 a0 40 03 cmp %g1, %g3 40007428: 0a bf ff fd bcs 4000741c <_Objects_Extend_information+0x18c> 4000742c: 84 00 a0 04 add %g2, 4, %g2 index++ ) { local_table[ index ] = NULL; } _ISR_Disable( level ); 40007430: 7f ff ea 43 call 40001d3c 40007434: 01 00 00 00 nop 40007438: a0 10 00 08 mov %o0, %l0 information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->name_table = name_table; information->local_table = local_table; information->maximum = maximum; information->maximum_id = _Objects_Build_id( 4000743c: d0 06 00 00 ld [ %i0 ], %o0 40007440: d2 16 20 04 lduh [ %i0 + 4 ], %o1 _ISR_Disable( level ); old_tables = information->object_blocks; information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; 40007444: e8 26 20 38 st %l4, [ %i0 + 0x38 ] information->name_table = name_table; 40007448: ea 26 20 24 st %l5, [ %i0 + 0x24 ] information->local_table = local_table; 4000744c: e6 26 20 20 st %l3, [ %i0 + 0x20 ] information->maximum = maximum; 40007450: ee 36 20 10 sth %l7, [ %i0 + 0x10 ] information->maximum_id = _Objects_Build_id( 40007454: 97 2d e0 10 sll %l7, 0x10, %o3 local_table[ index ] = NULL; } _ISR_Disable( level ); old_tables = information->object_blocks; 40007458: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 information->object_blocks = object_blocks; information->inactive_per_block = inactive_per_block; information->name_table = name_table; information->local_table = local_table; information->maximum = maximum; information->maximum_id = _Objects_Build_id( 4000745c: 97 32 e0 10 srl %o3, 0x10, %o3 _ISR_Disable( level ); old_tables = information->object_blocks; information->object_blocks = object_blocks; 40007460: e4 26 20 3c st %l2, [ %i0 + 0x3c ] information->inactive_per_block = inactive_per_block; information->name_table = name_table; information->local_table = local_table; information->maximum = maximum; information->maximum_id = _Objects_Build_id( 40007464: 7f ff ff 7d call 40007258 <_Objects_Build_id> 40007468: 94 10 20 01 mov 1, %o2 4000746c: d0 26 20 0c st %o0, [ %i0 + 0xc ] information->the_class, _Objects_Local_node, information->maximum ); _ISR_Enable( level ); 40007470: 7f ff ea 37 call 40001d4c 40007474: 90 10 00 10 mov %l0, %o0 if ( old_tables ) 40007478: 80 a4 60 00 cmp %l1, 0 4000747c: 02 80 00 05 be 40007490 <_Objects_Extend_information+0x200> 40007480: 11 10 00 63 sethi %hi(0x40018c00), %o0 RTEMS_INLINE_ROUTINE boolean _Workspace_Free( void *block ) { return _Heap_Free( &_Workspace_Area, block ); 40007484: 92 10 00 11 mov %l1, %o1 40007488: 7f ff fe 1a call 40006cf0 <_Heap_Free> 4000748c: 90 12 23 3c or %o0, 0x33c, %o0 /* * Allocate the name table, and the objects */ if ( information->auto_extend ) { 40007490: c2 06 20 14 ld [ %i0 + 0x14 ], %g1 40007494: e2 06 20 3c ld [ %i0 + 0x3c ], %l1 40007498: 80 a0 60 00 cmp %g1, 0 4000749c: a1 2f 20 02 sll %i4, 2, %l0 400074a0: d0 16 20 44 lduh [ %i0 + 0x44 ], %o0 400074a4: 02 80 00 11 be 400074e8 <_Objects_Extend_information+0x258> 400074a8: c2 06 20 1c ld [ %i0 + 0x1c ], %g1 information->object_blocks[ block ] = 400074ac: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 400074b0: 91 2a 20 10 sll %o0, 0x10, %o0 400074b4: 91 32 20 10 srl %o0, 0x10, %o0 400074b8: 40 00 34 23 call 40014544 <.umul> 400074bc: 90 02 00 01 add %o0, %g1, %o0 400074c0: 7f ff ff 6d call 40007274 <_Workspace_Allocate> 400074c4: 01 00 00 00 nop _Workspace_Allocate( (information->allocation_size * information->name_length) + (information->allocation_size * information->size) ); if ( !information->object_blocks[ block ] ) 400074c8: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 /* * Allocate the name table, and the objects */ if ( information->auto_extend ) { information->object_blocks[ block ] = 400074cc: d0 24 00 11 st %o0, [ %l0 + %l1 ] _Workspace_Allocate( (information->allocation_size * information->name_length) + (information->allocation_size * information->size) ); if ( !information->object_blocks[ block ] ) 400074d0: c2 00 40 10 ld [ %g1 + %l0 ], %g1 400074d4: 80 a0 60 00 cmp %g1, 0 400074d8: 32 80 00 0d bne,a 4000750c <_Objects_Extend_information+0x27c> 400074dc: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 400074e0: 81 c7 e0 08 ret <== NOT EXECUTED 400074e4: 81 e8 00 00 restore <== NOT EXECUTED return; } else { information->object_blocks[ block ] = 400074e8: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 400074ec: 91 2a 20 10 sll %o0, 0x10, %o0 400074f0: 91 32 20 10 srl %o0, 0x10, %o0 400074f4: 40 00 34 14 call 40014544 <.umul> 400074f8: 90 02 00 01 add %o0, %g1, %o0 400074fc: 40 00 0a ee call 4000a0b4 <_Workspace_Allocate_or_fatal_error> 40007500: 01 00 00 00 nop 40007504: d0 24 00 11 st %o0, [ %l0 + %l1 ] 40007508: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 4000750c: d0 06 20 1c ld [ %i0 + 0x1c ], %o0 40007510: 40 00 34 0d call 40014544 <.umul> 40007514: e0 06 20 3c ld [ %i0 + 0x3c ], %l0 (information->allocation_size * information->name_length) + (information->allocation_size * information->size) ); } name_area = (Objects_Name *) _Addresses_Add_offset( 40007518: a7 2f 20 02 sll %i4, 2, %l3 information->object_blocks[ block ], (information->allocation_size * information->size) ); information->name_table[ block ] = name_area; 4000751c: c4 06 20 24 ld [ %i0 + 0x24 ], %g2 40007520: c2 04 00 13 ld [ %l0 + %l3 ], %g1 /* * Initialize objects .. add to a local chain first. */ _Chain_Initialize( 40007524: d4 06 20 18 ld [ %i0 + 0x18 ], %o2 40007528: a2 02 00 01 add %o0, %g1, %l1 4000752c: d6 06 20 1c ld [ %i0 + 0x1c ], %o3 name_area = (Objects_Name *) _Addresses_Add_offset( information->object_blocks[ block ], (information->allocation_size * information->size) ); information->name_table[ block ] = name_area; 40007530: e2 20 80 13 st %l1, [ %g2 + %l3 ] /* * Initialize objects .. add to a local chain first. */ _Chain_Initialize( 40007534: d2 04 00 13 ld [ %l0 + %l3 ], %o1 40007538: 90 07 bf ec add %fp, -20, %o0 4000753c: a4 10 00 16 mov %l6, %l2 * Move from the local chain, initialise, then append to the inactive chain */ index = index_base; while ( (the_object = (Objects_Control *) _Chain_Get( &Inactive ) ) != NULL ) { 40007540: aa 10 00 08 mov %o0, %l5 /* * Initialize objects .. add to a local chain first. */ _Chain_Initialize( 40007544: 40 00 13 15 call 4000c198 <_Chain_Initialize> 40007548: a8 06 20 28 add %i0, 0x28, %l4 4000754c: 30 80 00 0c b,a 4000757c <_Objects_Extend_information+0x2ec> index = index_base; while ( (the_object = (Objects_Control *) _Chain_Get( &Inactive ) ) != NULL ) { the_object->id = _Objects_Build_id( 40007550: d2 16 20 04 lduh [ %i0 + 4 ], %o1 40007554: d0 06 00 00 ld [ %i0 ], %o0 40007558: 7f ff ff 40 call 40007258 <_Objects_Build_id> 4000755c: a4 04 a0 01 inc %l2 40007560: c2 16 20 44 lduh [ %i0 + 0x44 ], %g1 40007564: d0 24 20 08 st %o0, [ %l0 + 8 ] information->the_class, _Objects_Local_node, index ); the_object->name = (void *) name_area; 40007568: e2 24 20 0c st %l1, [ %l0 + 0xc ] name_area = _Addresses_Add_offset( name_area, information->name_length ); _Chain_Append( &information->Inactive, &the_object->Node ); 4000756c: 92 10 00 10 mov %l0, %o1 40007570: a2 04 40 01 add %l1, %g1, %l1 40007574: 7f ff fc 7b call 40006760 <_Chain_Append> 40007578: 90 10 00 14 mov %l4, %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 ) { 4000757c: 7f ff fc 85 call 40006790 <_Chain_Get> 40007580: 90 10 00 15 mov %l5, %o0 the_object->id = _Objects_Build_id( 40007584: 96 10 00 12 mov %l2, %o3 * Move from the local chain, initialise, then append to the inactive chain */ index = index_base; while ( (the_object = (Objects_Control *) _Chain_Get( &Inactive ) ) != NULL ) { 40007588: a0 10 00 08 mov %o0, %l0 4000758c: 80 a2 20 00 cmp %o0, 0 40007590: 12 bf ff f0 bne 40007550 <_Objects_Extend_information+0x2c0> 40007594: 94 10 20 01 mov 1, %o2 _Chain_Append( &information->Inactive, &the_object->Node ); index++; } information->inactive_per_block[ block ] = information->allocation_size; 40007598: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 4000759c: c4 06 20 38 ld [ %i0 + 0x38 ], %g2 information->inactive += information->allocation_size; 400075a0: c6 16 20 34 lduh [ %i0 + 0x34 ], %g3 _Chain_Append( &information->Inactive, &the_object->Node ); index++; } information->inactive_per_block[ block ] = information->allocation_size; 400075a4: c2 20 80 13 st %g1, [ %g2 + %l3 ] information->inactive += information->allocation_size; 400075a8: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 400075ac: 82 00 40 03 add %g1, %g3, %g1 400075b0: c2 36 20 34 sth %g1, [ %i0 + 0x34 ] 400075b4: 81 c7 e0 08 ret 400075b8: 81 e8 00 00 restore 4000764c <_Objects_Get_isr_disable>: Objects_Information *information, Objects_Id id, Objects_Locations *location, ISR_Level *level_p ) { 4000764c: 9d e3 bf 98 save %sp, -104, %sp Objects_Control *the_object; uint32_t index; ISR_Level level; index = id - information->minimum_id + 1; 40007650: c2 06 20 08 ld [ %i0 + 8 ], %g1 _ISR_Disable( level ); 40007654: 7f ff e9 ba call 40001d3c 40007658: b2 26 40 01 sub %i1, %g1, %i1 { Objects_Control *the_object; uint32_t index; ISR_Level level; index = id - information->minimum_id + 1; 4000765c: b2 06 60 01 inc %i1 _ISR_Disable( level ); if ( information->maximum >= index ) { 40007660: c2 16 20 10 lduh [ %i0 + 0x10 ], %g1 40007664: 80 a0 40 19 cmp %g1, %i1 40007668: 0a 80 00 11 bcs 400076ac <_Objects_Get_isr_disable+0x60> 4000766c: 83 2e 60 02 sll %i1, 2, %g1 if ( (the_object = information->local_table[ index ]) != NULL ) { 40007670: c4 06 20 20 ld [ %i0 + 0x20 ], %g2 40007674: f0 00 80 01 ld [ %g2 + %g1 ], %i0 40007678: 80 a6 20 00 cmp %i0, 0 4000767c: 02 80 00 06 be 40007694 <_Objects_Get_isr_disable+0x48> 40007680: 01 00 00 00 nop *location = OBJECTS_LOCAL; *level_p = level; 40007684: d0 26 c0 00 st %o0, [ %i3 ] index = id - information->minimum_id + 1; _ISR_Disable( level ); if ( information->maximum >= index ) { if ( (the_object = information->local_table[ index ]) != NULL ) { *location = OBJECTS_LOCAL; 40007688: c0 26 80 00 clr [ %i2 ] 4000768c: 81 c7 e0 08 ret 40007690: 81 e8 00 00 restore *level_p = level; return the_object; } _ISR_Enable( level ); 40007694: 7f ff e9 ae call 40001d4c <== NOT EXECUTED 40007698: 01 00 00 00 nop <== NOT EXECUTED *location = OBJECTS_ERROR; 4000769c: 82 10 20 02 mov 2, %g1 ! 2 <== NOT EXECUTED 400076a0: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED 400076a4: 81 c7 e0 08 ret <== NOT EXECUTED 400076a8: 81 e8 00 00 restore <== NOT EXECUTED return NULL; } _ISR_Enable( level ); 400076ac: 7f ff e9 a8 call 40001d4c 400076b0: b0 10 20 00 clr %i0 *location = OBJECTS_ERROR; 400076b4: 82 10 20 02 mov 2, %g1 400076b8: c2 26 80 00 st %g1, [ %i2 ] _Objects_MP_Is_remote( information, id, location, &the_object ); return the_object; #else return NULL; #endif } 400076bc: 81 c7 e0 08 ret 400076c0: 81 e8 00 00 restore 40009118 <_Objects_Get_name_as_string>: char *_Objects_Get_name_as_string( Objects_Id id, size_t length, char *name ) { 40009118: 9d e3 bf 88 save %sp, -120, %sp 4000911c: 92 10 00 18 mov %i0, %o1 uint32_t i; char lname[5]; Objects_Control *the_object; Objects_Locations location; if ( length == 0 ) 40009120: 80 a6 60 00 cmp %i1, 0 40009124: 02 80 00 43 be 40009230 <_Objects_Get_name_as_string+0x118> 40009128: b0 10 00 1a mov %i2, %i0 return NULL; if ( name == NULL ) 4000912c: 80 a6 a0 00 cmp %i2, 0 40009130: 02 80 00 3e be 40009228 <_Objects_Get_name_as_string+0x110> 40009134: 85 32 60 16 srl %o1, 0x16, %g2 if ( !_Objects_Is_class_valid( the_class ) ) return NULL; the_api = _Objects_Get_API( id ); return _Objects_Information_table[ the_api ][ the_class ]; 40009138: 03 10 00 94 sethi %hi(0x40025000), %g1 4000913c: 84 08 a0 1c and %g2, 0x1c, %g2 40009140: 82 10 63 60 or %g1, 0x360, %g1 40009144: c4 00 40 02 ld [ %g1 + %g2 ], %g2 40009148: 83 32 60 1b srl %o1, 0x1b, %g1 4000914c: 83 28 60 02 sll %g1, 2, %g1 40009150: e0 00 80 01 ld [ %g2 + %g1 ], %l0 return NULL; information = _Objects_Get_information( id ); if ( !information ) 40009154: 80 a4 20 00 cmp %l0, 0 40009158: 22 80 00 34 be,a 40009228 <_Objects_Get_name_as_string+0x110> 4000915c: b0 10 20 00 clr %i0 <== NOT EXECUTED return NULL; the_object = _Objects_Get( information, id, &location ); 40009160: 90 10 00 10 mov %l0, %o0 40009164: 40 00 00 36 call 4000923c <_Objects_Get> 40009168: 94 07 bf f4 add %fp, -12, %o2 switch ( location ) { 4000916c: c2 07 bf f4 ld [ %fp + -12 ], %g1 40009170: 80 a0 60 00 cmp %g1, 0 40009174: 32 80 00 2d bne,a 40009228 <_Objects_Get_name_as_string+0x110> 40009178: b0 10 20 00 clr %i0 <== NOT EXECUTED case OBJECTS_ERROR: return NULL; case OBJECTS_LOCAL: if ( information->is_string ) { 4000917c: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 40009180: 80 a0 60 00 cmp %g1, 0 40009184: 12 80 00 0b bne 400091b0 <_Objects_Get_name_as_string+0x98> 40009188: d0 02 20 0c ld [ %o0 + 0xc ], %o0 s = the_object->name; } else { uint32_t u32_name = (uint32_t) the_object->name; lname[ 0 ] = (u32_name >> 24) & 0xff; 4000918c: 83 32 20 18 srl %o0, 0x18, %g1 40009190: c2 2f bf ef stb %g1, [ %fp + -17 ] lname[ 1 ] = (u32_name >> 16) & 0xff; 40009194: 83 32 20 10 srl %o0, 0x10, %g1 lname[ 2 ] = (u32_name >> 8) & 0xff; lname[ 3 ] = (u32_name >> 0) & 0xff; 40009198: d0 2f bf f2 stb %o0, [ %fp + -14 ] s = the_object->name; } else { uint32_t u32_name = (uint32_t) the_object->name; lname[ 0 ] = (u32_name >> 24) & 0xff; lname[ 1 ] = (u32_name >> 16) & 0xff; 4000919c: c2 2f bf f0 stb %g1, [ %fp + -16 ] lname[ 2 ] = (u32_name >> 8) & 0xff; lname[ 3 ] = (u32_name >> 0) & 0xff; lname[ 4 ] = '\0'; 400091a0: c0 2f bf f3 clrb [ %fp + -13 ] } else { uint32_t u32_name = (uint32_t) the_object->name; lname[ 0 ] = (u32_name >> 24) & 0xff; lname[ 1 ] = (u32_name >> 16) & 0xff; lname[ 2 ] = (u32_name >> 8) & 0xff; 400091a4: 83 32 20 08 srl %o0, 8, %g1 lname[ 3 ] = (u32_name >> 0) & 0xff; lname[ 4 ] = '\0'; 400091a8: 90 07 bf ef add %fp, -17, %o0 } else { uint32_t u32_name = (uint32_t) the_object->name; lname[ 0 ] = (u32_name >> 24) & 0xff; lname[ 1 ] = (u32_name >> 16) & 0xff; lname[ 2 ] = (u32_name >> 8) & 0xff; 400091ac: c2 2f bf f1 stb %g1, [ %fp + -15 ] lname[ 3 ] = (u32_name >> 0) & 0xff; lname[ 4 ] = '\0'; 400091b0: 84 10 00 18 mov %i0, %g2 400091b4: 88 10 20 01 mov 1, %g4 s = lname; } for ( i=0, d=name ; i<(length-1) && *s ; i++, s++, d++ ) { *d = (!isprint(*s)) ? '*' : *s; 400091b8: 10 80 00 09 b 400091dc <_Objects_Get_name_as_string+0xc4> 400091bc: 19 10 00 73 sethi %hi(0x4001cc00), %o4 400091c0: c2 03 22 28 ld [ %o4 + 0x228 ], %g1 ! 4001ce28 <__ctype_ptr> 400091c4: c2 48 40 03 ldsb [ %g1 + %g3 ], %g1 400091c8: 80 88 60 97 btst 0x97, %g1 400091cc: 22 80 00 02 be,a 400091d4 <_Objects_Get_name_as_string+0xbc> 400091d0: 9a 10 20 2a mov 0x2a, %o5 <== NOT EXECUTED 400091d4: da 28 80 00 stb %o5, [ %g2 ] lname[ 3 ] = (u32_name >> 0) & 0xff; lname[ 4 ] = '\0'; s = lname; } for ( i=0, d=name ; i<(length-1) && *s ; i++, s++, d++ ) { 400091d8: 84 00 a0 01 inc %g2 400091dc: 80 a1 00 19 cmp %g4, %i1 400091e0: 02 80 00 07 be 400091fc <_Objects_Get_name_as_string+0xe4> 400091e4: 82 02 00 04 add %o0, %g4, %g1 400091e8: c6 48 7f ff ldsb [ %g1 + -1 ], %g3 400091ec: 88 01 20 01 inc %g4 400091f0: 80 a0 e0 00 cmp %g3, 0 400091f4: 12 bf ff f3 bne 400091c0 <_Objects_Get_name_as_string+0xa8> 400091f8: da 08 7f ff ldub [ %g1 + -1 ], %o5 *d = (!isprint(*s)) ? '*' : *s; } *d = '\0'; 400091fc: c0 28 80 00 clrb [ %g2 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40009200: 03 10 00 95 sethi %hi(0x40025400), %g1 40009204: c4 00 60 00 ld [ %g1 ], %g2 40009208: 84 00 bf ff add %g2, -1, %g2 4000920c: c4 20 60 00 st %g2, [ %g1 ] 40009210: c2 00 60 00 ld [ %g1 ], %g1 40009214: 80 a0 60 00 cmp %g1, 0 40009218: 12 80 00 07 bne 40009234 <_Objects_Get_name_as_string+0x11c> 4000921c: 01 00 00 00 nop _Thread_Dispatch(); 40009220: 40 00 04 bc call 4000a510 <_Thread_Dispatch> 40009224: 01 00 00 00 nop 40009228: 81 c7 e0 08 ret 4000922c: 81 e8 00 00 restore 40009230: b0 10 20 00 clr %i0 <== NOT EXECUTED _Thread_Enable_dispatch(); return name; } return NULL; /* unreachable path */ } 40009234: 81 c7 e0 08 ret <== NOT EXECUTED 40009238: 81 e8 00 00 restore <== NOT EXECUTED 40015aec <_Objects_Get_next>: Objects_Information *information, Objects_Id id, Objects_Locations *location_p, Objects_Id *next_id_p ) { 40015aec: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED Objects_Control *object; Objects_Id next_id; if (_Objects_Get_index(id) == OBJECTS_ID_INITIAL_INDEX) 40015af0: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED 40015af4: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff <== NOT EXECUTED 40015af8: 80 8e 40 01 btst %i1, %g1 <== NOT EXECUTED 40015afc: 22 80 00 02 be,a 40015b04 <_Objects_Get_next+0x18> <== NOT EXECUTED 40015b00: f2 06 20 08 ld [ %i0 + 8 ], %i1 <== NOT EXECUTED else next_id = id; do { /* walked off end of list? */ if (_Objects_Get_index(next_id) > information->maximum) 40015b04: 03 00 00 3f sethi %hi(0xfc00), %g1 <== NOT EXECUTED 40015b08: a0 10 63 ff or %g1, 0x3ff, %l0 ! ffff <== NOT EXECUTED 40015b0c: c4 16 20 10 lduh [ %i0 + 0x10 ], %g2 <== NOT EXECUTED 40015b10: 82 0e 40 10 and %i1, %l0, %g1 <== NOT EXECUTED *location_p = OBJECTS_ERROR; goto final; } /* try to grab one */ object = _Objects_Get(information, next_id, location_p); 40015b14: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 40015b18: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED else next_id = id; do { /* walked off end of list? */ if (_Objects_Get_index(next_id) > information->maximum) 40015b1c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 40015b20: 18 80 00 0a bgu 40015b48 <_Objects_Get_next+0x5c> <== NOT EXECUTED 40015b24: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED *location_p = OBJECTS_ERROR; goto final; } /* try to grab one */ object = _Objects_Get(information, next_id, location_p); 40015b28: 7f ff d8 fe call 4000bf20 <_Objects_Get> <== NOT EXECUTED 40015b2c: b2 06 60 01 inc %i1 <== NOT EXECUTED next_id++; } while (*location_p != OBJECTS_LOCAL); 40015b30: c2 06 80 00 ld [ %i2 ], %g1 <== NOT EXECUTED 40015b34: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40015b38: 32 bf ff f6 bne,a 40015b10 <_Objects_Get_next+0x24> <== NOT EXECUTED 40015b3c: c4 16 20 10 lduh [ %i0 + 0x10 ], %g2 <== NOT EXECUTED *next_id_p = next_id; 40015b40: 10 80 00 07 b 40015b5c <_Objects_Get_next+0x70> <== NOT EXECUTED 40015b44: f2 26 c0 00 st %i1, [ %i3 ] <== NOT EXECUTED do { /* walked off end of list? */ if (_Objects_Get_index(next_id) > information->maximum) { *location_p = OBJECTS_ERROR; 40015b48: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *next_id_p = next_id; return object; final: *next_id_p = OBJECTS_ID_FINAL; 40015b4c: 90 10 20 00 clr %o0 <== NOT EXECUTED do { /* walked off end of list? */ if (_Objects_Get_index(next_id) > information->maximum) { *location_p = OBJECTS_ERROR; 40015b50: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED *next_id_p = next_id; return object; final: *next_id_p = OBJECTS_ID_FINAL; 40015b54: 82 10 3f ff mov -1, %g1 <== NOT EXECUTED 40015b58: c2 26 c0 00 st %g1, [ %i3 ] <== NOT EXECUTED return 0; } 40015b5c: 81 c7 e0 08 ret <== NOT EXECUTED 40015b60: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED 4001495c <_Objects_Get_no_protection>: ) { Objects_Control *the_object; uint32_t index; index = id - information->minimum_id + 1; 4001495c: c2 02 20 08 ld [ %o0 + 8 ], %g1 if ( information->maximum >= index ) { 40014960: c4 12 20 10 lduh [ %o0 + 0x10 ], %g2 ) { Objects_Control *the_object; uint32_t index; index = id - information->minimum_id + 1; 40014964: 92 22 40 01 sub %o1, %g1, %o1 40014968: 82 02 60 01 add %o1, 1, %g1 if ( information->maximum >= index ) { 4001496c: 80 a0 80 01 cmp %g2, %g1 40014970: 0a 80 00 0b bcs 4001499c <_Objects_Get_no_protection+0x40> 40014974: 83 28 60 02 sll %g1, 2, %g1 if ( (the_object = information->local_table[ index ]) != NULL ) { 40014978: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4001497c: d0 00 80 01 ld [ %g2 + %g1 ], %o0 40014980: 80 a2 20 00 cmp %o0, 0 40014984: 02 80 00 04 be 40014994 <_Objects_Get_no_protection+0x38> 40014988: 82 10 20 02 mov 2, %g1 *location = OBJECTS_LOCAL; 4001498c: 81 c3 e0 08 retl 40014990: c0 22 80 00 clr [ %o2 ] return the_object; } *location = OBJECTS_ERROR; 40014994: 81 c3 e0 08 retl <== NOT EXECUTED 40014998: c2 22 80 00 st %g1, [ %o2 ] <== NOT EXECUTED return NULL; } *location = OBJECTS_ERROR; 4001499c: 82 10 20 02 mov 2, %g1 400149a0: 90 10 20 00 clr %o0 /* * Not supported for multiprocessing */ return NULL; } 400149a4: 81 c3 e0 08 retl 400149a8: c2 22 80 00 st %g1, [ %o2 ] 40007928 <_Objects_Handler_initialization>: uint32_t node, uint32_t maximum_nodes, uint32_t maximum_global_objects ) { if ( node < 1 || node > maximum_nodes ) 40007928: 80 a2 20 00 cmp %o0, 0 4000792c: 22 80 00 05 be,a 40007940 <_Objects_Handler_initialization+0x18> 40007930: 90 10 20 00 clr %o0 <== NOT EXECUTED 40007934: 80 a2 00 09 cmp %o0, %o1 40007938: 08 80 00 07 bleu 40007954 <_Objects_Handler_initialization+0x2c> 4000793c: 90 10 20 00 clr %o0 _Internal_error_Occurred( 40007940: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 40007944: 94 10 20 08 mov 8, %o2 <== NOT EXECUTED 40007948: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 4000794c: 7f ff fd ed call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40007950: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED 40007954: 81 c3 e0 08 retl 40007958: 01 00 00 00 nop 40008d6c <_Objects_Id_to_name>: Objects_Name_or_id_lookup_errors _Objects_Id_to_name ( Objects_Id id, Objects_Name *name ) { 40008d6c: 9d e3 bf 90 save %sp, -112, %sp 40008d70: 92 10 00 18 mov %i0, %o1 uint32_t the_class; Objects_Information *information; Objects_Control *the_object = (Objects_Control *) 0; Objects_Locations ignored_location; if ( !name ) 40008d74: 80 a6 60 00 cmp %i1, 0 40008d78: 02 80 00 26 be 40008e10 <_Objects_Id_to_name+0xa4> 40008d7c: b0 10 20 01 mov 1, %i0 */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); 40008d80: 83 32 60 18 srl %o1, 0x18, %g1 40008d84: 82 08 60 07 and %g1, 7, %g1 return OBJECTS_INVALID_NAME; the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) 40008d88: 80 a0 60 04 cmp %g1, 4 40008d8c: 18 80 00 23 bgu 40008e18 <_Objects_Id_to_name+0xac> 40008d90: 85 28 60 02 sll %g1, 2, %g2 return OBJECTS_INVALID_ID; the_class = _Objects_Get_class( id ); information = _Objects_Information_table[ the_api ][ the_class ]; 40008d94: 03 10 00 74 sethi %hi(0x4001d000), %g1 40008d98: 82 10 62 70 or %g1, 0x270, %g1 ! 4001d270 <_Objects_Information_table> 40008d9c: c4 00 40 02 ld [ %g1 + %g2 ], %g2 40008da0: 83 32 60 1b srl %o1, 0x1b, %g1 40008da4: 83 28 60 02 sll %g1, 2, %g1 40008da8: d0 00 80 01 ld [ %g2 + %g1 ], %o0 if ( !information ) 40008dac: 80 a2 20 00 cmp %o0, 0 40008db0: 02 80 00 18 be 40008e10 <_Objects_Id_to_name+0xa4> 40008db4: b0 10 20 03 mov 3, %i0 return OBJECTS_INVALID_ID; if ( information->is_string ) 40008db8: c2 02 20 40 ld [ %o0 + 0x40 ], %g1 40008dbc: 80 a0 60 00 cmp %g1, 0 40008dc0: 12 80 00 17 bne 40008e1c <_Objects_Id_to_name+0xb0> 40008dc4: 01 00 00 00 nop return OBJECTS_INVALID_ID; the_object = _Objects_Get( information, id, &ignored_location ); 40008dc8: 7f ff ff c4 call 40008cd8 <_Objects_Get> 40008dcc: 94 07 bf f4 add %fp, -12, %o2 if ( !the_object ) 40008dd0: 80 a2 20 00 cmp %o0, 0 40008dd4: 02 80 00 0f be 40008e10 <_Objects_Id_to_name+0xa4> 40008dd8: b0 10 20 03 mov 3, %i0 return OBJECTS_INVALID_ID; *name = the_object->name; 40008ddc: c2 02 20 0c ld [ %o0 + 0xc ], %g1 40008de0: c2 26 40 00 st %g1, [ %i1 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40008de4: 05 10 00 74 sethi %hi(0x4001d000), %g2 40008de8: c2 00 a3 10 ld [ %g2 + 0x310 ], %g1 ! 4001d310 <_Thread_Dispatch_disable_level> 40008dec: b0 10 20 00 clr %i0 40008df0: 82 00 7f ff add %g1, -1, %g1 40008df4: c2 20 a3 10 st %g1, [ %g2 + 0x310 ] 40008df8: c2 00 a3 10 ld [ %g2 + 0x310 ], %g1 40008dfc: 80 a0 60 00 cmp %g1, 0 40008e00: 12 80 00 07 bne 40008e1c <_Objects_Id_to_name+0xb0> 40008e04: 01 00 00 00 nop _Thread_Dispatch(); 40008e08: 40 00 04 d6 call 4000a160 <_Thread_Dispatch> 40008e0c: 01 00 00 00 nop 40008e10: 81 c7 e0 08 ret 40008e14: 81 e8 00 00 restore 40008e18: b0 10 20 03 mov 3, %i0 <== NOT EXECUTED _Thread_Enable_dispatch(); return OBJECTS_NAME_OR_ID_LOOKUP_SUCCESSFUL; } 40008e1c: 81 c7 e0 08 ret <== NOT EXECUTED 40008e20: 81 e8 00 00 restore <== NOT EXECUTED 40007758 <_Objects_Initialize_information>: , boolean supports_global, Objects_Thread_queue_Extract_callout extract #endif ) { 40007758: 9d e3 bf 98 save %sp, -104, %sp /* * Set the entry in the object information table. */ _Objects_Information_table[ the_api ][ the_class ] = information; 4000775c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007760: 85 2e 60 02 sll %i1, 2, %g2 40007764: 82 10 62 50 or %g1, 0x250, %g1 40007768: c2 00 40 02 ld [ %g1 + %g2 ], %g1 */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 4000776c: 89 2e a0 1b sll %i2, 0x1b, %g4 #if defined(RTEMS_MULTIPROCESSING) uint32_t index; #endif information->the_api = the_api; information->the_class = the_class; 40007770: f4 36 20 04 sth %i2, [ %i0 + 4 ] /* * Set the entry in the object information table. */ _Objects_Information_table[ the_api ][ the_class ] = information; 40007774: b5 2e a0 02 sll %i2, 2, %i2 40007778: f0 20 40 1a st %i0, [ %g1 + %i2 ] /* * Are we operating in unlimited, or auto-extend mode */ information->auto_extend = (maximum & OBJECTS_UNLIMITED_OBJECTS) ? TRUE : FALSE; 4000777c: 83 36 e0 1f srl %i3, 0x1f, %g1 40007780: c2 26 20 14 st %g1, [ %i0 + 0x14 ] maximum &= ~OBJECTS_UNLIMITED_OBJECTS; 40007784: 03 20 00 00 sethi %hi(0x80000000), %g1 , boolean supports_global, Objects_Thread_queue_Extract_callout extract #endif ) { 40007788: de 07 a0 5c ld [ %fp + 0x5c ], %o7 uint32_t index; #endif information->the_api = the_api; information->the_class = the_class; information->is_string = is_string; 4000778c: fa 26 20 40 st %i5, [ %i0 + 0x40 ] /* * Are we operating in unlimited, or auto-extend mode */ information->auto_extend = (maximum & OBJECTS_UNLIMITED_OBJECTS) ? TRUE : FALSE; maximum &= ~OBJECTS_UNLIMITED_OBJECTS; 40007790: ba 2e c0 01 andn %i3, %g1, %i5 /* * Provide a null local table entry for the case of any empty table. */ information->local_table = &null_local_table; 40007794: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007798: 82 10 60 cc or %g1, 0xcc, %g1 ! 40018ccc */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 4000779c: 80 a0 00 1d cmp %g0, %i5 /* * Set the size of the object */ information->size = size; 400077a0: b9 2f 20 10 sll %i4, 0x10, %i4 */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 400077a4: 86 40 20 00 addx %g0, 0, %g3 400077a8: 85 2e 60 18 sll %i1, 0x18, %g2 /* * Set the size of the object */ information->size = size; 400077ac: b9 37 20 10 srl %i4, 0x10, %i4 /* * Provide a null local table entry for the case of any empty table. */ information->local_table = &null_local_table; 400077b0: c2 26 20 20 st %g1, [ %i0 + 0x20 ] /* * Set the size of the object */ information->size = size; 400077b4: f8 26 20 1c st %i4, [ %i0 + 0x1c ] */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 400077b8: 03 00 00 40 sethi %hi(0x10000), %g1 uint32_t name_length; #if defined(RTEMS_MULTIPROCESSING) uint32_t index; #endif information->the_api = the_api; 400077bc: f2 26 00 00 st %i1, [ %i0 ] */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 400077c0: 84 10 80 01 or %g2, %g1, %g2 information->the_api = the_api; information->the_class = the_class; information->is_string = is_string; information->local_table = 0; information->name_table = 0; 400077c4: c0 26 20 24 clr [ %i0 + 0x24 ] */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 400077c8: 84 10 80 04 or %g2, %g4, %g2 information->the_class = the_class; information->is_string = is_string; information->local_table = 0; information->name_table = 0; information->inactive_per_block = 0; 400077cc: c0 26 20 38 clr [ %i0 + 0x38 ] */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 400077d0: 84 10 80 03 or %g2, %g3, %g2 information->is_string = is_string; information->local_table = 0; information->name_table = 0; information->inactive_per_block = 0; information->object_blocks = 0; 400077d4: c0 26 20 3c clr [ %i0 + 0x3c ] information->inactive = 0; 400077d8: c0 36 20 34 clrh [ %i0 + 0x34 ] /* * The allocation unit is the maximum value */ information->allocation_size = maximum; 400077dc: fa 26 20 18 st %i5, [ %i0 + 0x18 ] */ if ( maximum == 0 ) minimum_index = 0; else minimum_index = 1; information->minimum_id = 400077e0: c4 26 20 08 st %g2, [ %i0 + 8 ] * Calculate the maximum name length */ name_length = maximum_name_length; if ( name_length & (OBJECTS_NAME_ALIGNMENT-1) ) 400077e4: 80 8b e0 03 btst 3, %o7 400077e8: 02 80 00 04 be 400077f8 <_Objects_Initialize_information+0xa0> 400077ec: 82 10 00 0f mov %o7, %g1 name_length = (name_length + OBJECTS_NAME_ALIGNMENT) & 400077f0: 82 03 e0 04 add %o7, 4, %g1 <== NOT EXECUTED 400077f4: 82 08 7f fc and %g1, -4, %g1 <== NOT EXECUTED ~(OBJECTS_NAME_ALIGNMENT-1); information->name_length = name_length; 400077f8: c2 36 20 44 sth %g1, [ %i0 + 0x44 ] */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 400077fc: 82 06 20 2c add %i0, 0x2c, %g1 the_chain->permanent_null = NULL; 40007800: c0 26 20 2c clr [ %i0 + 0x2c ] */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 40007804: c2 26 20 28 st %g1, [ %i0 + 0x28 ] the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 40007808: 82 06 20 28 add %i0, 0x28, %g1 /* * Initialize objects .. if there are any */ if ( maximum ) { 4000780c: 80 a7 60 00 cmp %i5, 0 40007810: 02 80 00 05 be 40007824 <_Objects_Initialize_information+0xcc> 40007814: c2 26 20 30 st %g1, [ %i0 + 0x30 ] /* * Reset the maximum value. It will be updated when the information is * extended. */ information->maximum = 0; 40007818: c0 36 20 10 clrh [ %i0 + 0x10 ] * 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 ); 4000781c: 7f ff fe 9d call 40007290 <_Objects_Extend_information> 40007820: 81 e8 00 00 restore 40007824: 81 c7 e0 08 ret 40007828: 81 e8 00 00 restore 4000782c <_Objects_Name_to_id>: Objects_Information *information, Objects_Name name, uint32_t node, Objects_Id *id ) { 4000782c: 9d e3 bf 98 save %sp, -104, %sp 40007830: a2 10 00 18 mov %i0, %l1 Objects_Control *the_object; uint32_t index; uint32_t name_length; Objects_Name_comparators compare_them; if ( !id ) 40007834: 80 a6 e0 00 cmp %i3, 0 40007838: 02 80 00 3a be 40007920 <_Objects_Name_to_id+0xf4> 4000783c: b0 10 20 02 mov 2, %i0 return OBJECTS_INVALID_ADDRESS; if ( name == 0 ) 40007840: 80 a6 60 00 cmp %i1, 0 40007844: 02 80 00 2d be 400078f8 <_Objects_Name_to_id+0xcc> 40007848: 01 00 00 00 nop return OBJECTS_INVALID_NAME; search_local_node = FALSE; if ( information->maximum != 0 && 4000784c: c2 14 60 10 lduh [ %l1 + 0x10 ], %g1 40007850: 80 a0 60 00 cmp %g1, 0 40007854: 02 80 00 29 be 400078f8 <_Objects_Name_to_id+0xcc> 40007858: 80 a6 a0 00 cmp %i2, 0 4000785c: 22 80 00 2a be,a 40007904 <_Objects_Name_to_id+0xd8> 40007860: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 40007864: 03 1f ff ff sethi %hi(0x7ffffc00), %g1 40007868: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff 4000786c: 80 a6 80 01 cmp %i2, %g1 40007870: 02 80 00 24 be 40007900 <_Objects_Name_to_id+0xd4> 40007874: 80 a6 a0 01 cmp %i2, 1 40007878: 22 80 00 23 be,a 40007904 <_Objects_Name_to_id+0xd8> 4000787c: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 name_length = information->name_length; if ( information->is_string ) compare_them = _Objects_Compare_name_string; else compare_them = _Objects_Compare_name_raw; for ( index = 1; index <= information->maximum; index++ ) { 40007880: 81 c7 e0 08 ret 40007884: 91 e8 20 01 restore %g0, 1, %o0 if ( name == 0 ) return OBJECTS_INVALID_NAME; search_local_node = FALSE; if ( information->maximum != 0 && 40007888: a4 10 61 bc or %g1, 0x1bc, %l2 <== NOT EXECUTED for ( index = 1; index <= information->maximum; index++ ) { the_object = information->local_table[ index ]; if ( !the_object || !the_object->name ) continue; if ( (*compare_them)( name, the_object->name, name_length ) ) { 4000788c: 83 28 a0 10 sll %g2, 0x10, %g1 if ( name == 0 ) return OBJECTS_INVALID_NAME; search_local_node = FALSE; if ( information->maximum != 0 && 40007890: a0 10 20 01 mov 1, %l0 for ( index = 1; index <= information->maximum; index++ ) { the_object = information->local_table[ index ]; if ( !the_object || !the_object->name ) continue; if ( (*compare_them)( name, the_object->name, name_length ) ) { 40007894: 10 80 00 15 b 400078e8 <_Objects_Name_to_id+0xbc> 40007898: b1 30 60 10 srl %g1, 0x10, %i0 if ( information->is_string ) compare_them = _Objects_Compare_name_string; else compare_them = _Objects_Compare_name_raw; for ( index = 1; index <= information->maximum; index++ ) { the_object = information->local_table[ index ]; 4000789c: c2 04 60 20 ld [ %l1 + 0x20 ], %g1 name_length = information->name_length; if ( information->is_string ) compare_them = _Objects_Compare_name_string; else compare_them = _Objects_Compare_name_raw; for ( index = 1; index <= information->maximum; index++ ) { 400078a0: a0 04 20 01 inc %l0 the_object = information->local_table[ index ]; 400078a4: f4 00 40 02 ld [ %g1 + %g2 ], %i2 if ( !the_object || !the_object->name ) 400078a8: 80 a6 a0 00 cmp %i2, 0 400078ac: 02 80 00 0f be 400078e8 <_Objects_Name_to_id+0xbc> 400078b0: 90 10 00 19 mov %i1, %o0 400078b4: d2 06 a0 0c ld [ %i2 + 0xc ], %o1 400078b8: 80 a2 60 00 cmp %o1, 0 400078bc: 02 80 00 0b be 400078e8 <_Objects_Name_to_id+0xbc> 400078c0: 94 10 00 18 mov %i0, %o2 continue; if ( (*compare_them)( name, the_object->name, name_length ) ) { 400078c4: 9f c4 80 00 call %l2 400078c8: 01 00 00 00 nop 400078cc: 80 a2 20 00 cmp %o0, 0 400078d0: 22 80 00 07 be,a 400078ec <_Objects_Name_to_id+0xc0> 400078d4: c2 14 60 10 lduh [ %l1 + 0x10 ], %g1 *id = the_object->id; 400078d8: c2 06 a0 08 ld [ %i2 + 8 ], %g1 400078dc: c2 26 c0 00 st %g1, [ %i3 ] 400078e0: 81 c7 e0 08 ret 400078e4: 91 e8 20 00 restore %g0, 0, %o0 name_length = information->name_length; if ( information->is_string ) compare_them = _Objects_Compare_name_string; else compare_them = _Objects_Compare_name_raw; for ( index = 1; index <= information->maximum; index++ ) { 400078e8: c2 14 60 10 lduh [ %l1 + 0x10 ], %g1 400078ec: 80 a4 00 01 cmp %l0, %g1 400078f0: 08 bf ff eb bleu 4000789c <_Objects_Name_to_id+0x70> 400078f4: 85 2c 20 02 sll %l0, 2, %g2 400078f8: 81 c7 e0 08 ret 400078fc: 91 e8 20 01 restore %g0, 1, %o0 search_local_node = TRUE; if ( search_local_node ) { name_length = information->name_length; if ( information->is_string ) compare_them = _Objects_Compare_name_string; 40007900: c2 04 60 40 ld [ %l1 + 0x40 ], %g1 _Objects_Is_local_node( node ) )) search_local_node = TRUE; if ( search_local_node ) { name_length = information->name_length; 40007904: c4 14 60 44 lduh [ %l1 + 0x44 ], %g2 if ( information->is_string ) compare_them = _Objects_Compare_name_string; 40007908: 80 a0 60 00 cmp %g1, 0 4000790c: 03 10 00 31 sethi %hi(0x4000c400), %g1 40007910: 02 bf ff df be 4000788c <_Objects_Name_to_id+0x60> 40007914: a4 10 61 ac or %g1, 0x1ac, %l2 ! 4000c5ac <_Objects_Compare_name_raw> if ( name == 0 ) return OBJECTS_INVALID_NAME; search_local_node = FALSE; if ( information->maximum != 0 && 40007918: 10 bf ff dc b 40007888 <_Objects_Name_to_id+0x5c> <== NOT EXECUTED 4000791c: 03 10 00 31 sethi %hi(0x4000c400), %g1 <== NOT EXECUTED return ( _Objects_MP_Global_name_search( information, name, node, id ) ); #else return OBJECTS_INVALID_NAME; #endif } 40007920: 81 c7 e0 08 ret <== NOT EXECUTED 40007924: 81 e8 00 00 restore <== NOT EXECUTED 4000795c <_Objects_Shrink_information>: */ void _Objects_Shrink_information( Objects_Information *information ) { 4000795c: 9d e3 bf 98 save %sp, -104, %sp 40007960: c4 06 20 08 ld [ %i0 + 8 ], %g2 /* * Search the list to find block or chunnk with all objects inactive. */ index_base = _Objects_Get_index( information->minimum_id ); block_count = ( information->maximum - index_base ) / information->allocation_size; 40007964: e0 06 20 18 ld [ %i0 + 0x18 ], %l0 40007968: d0 16 20 10 lduh [ %i0 + 0x10 ], %o0 4000796c: 03 00 00 3f sethi %hi(0xfc00), %g1 40007970: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40007974: 92 10 00 10 mov %l0, %o1 40007978: a2 08 80 01 and %g2, %g1, %l1 4000797c: 40 00 33 2c call 4001462c <.udiv> 40007980: 90 22 00 11 sub %o0, %l1, %o0 40007984: 86 10 20 00 clr %g3 40007988: 10 80 00 33 b 40007a54 <_Objects_Shrink_information+0xf8> 4000798c: a4 10 20 00 clr %l2 for ( block = 0; block < block_count; block++ ) { 40007990: 86 00 e0 01 inc %g3 if ( information->inactive_per_block[ block ] == information->allocation_size ) { 40007994: c2 00 40 12 ld [ %g1 + %l2 ], %g1 40007998: 80 a0 40 10 cmp %g1, %l0 4000799c: 12 80 00 2c bne 40007a4c <_Objects_Shrink_information+0xf0> 400079a0: 84 04 a0 04 add %l2, 4, %g2 /* * XXX - Not to sure how to use a chain where you need to iterate and * and remove elements. */ the_object = (Objects_Control *) information->Inactive.first; 400079a4: e0 06 20 28 ld [ %i0 + 0x28 ], %l0 400079a8: 03 00 00 3f sethi %hi(0xfc00), %g1 400079ac: a6 10 63 ff or %g1, 0x3ff, %l3 ! ffff 400079b0: c2 04 20 08 ld [ %l0 + 8 ], %g1 400079b4: 84 08 40 13 and %g1, %l3, %g2 */ do { index = _Objects_Get_index( the_object->id ); if ((index >= index_base) && 400079b8: 80 a0 80 11 cmp %g2, %l1 400079bc: 2a 80 00 0c bcs,a 400079ec <_Objects_Shrink_information+0x90> 400079c0: e0 04 00 00 ld [ %l0 ], %l0 400079c4: c2 06 20 18 ld [ %i0 + 0x18 ], %g1 400079c8: 82 04 40 01 add %l1, %g1, %g1 400079cc: 80 a0 80 01 cmp %g2, %g1 400079d0: 1a 80 00 06 bcc 400079e8 <_Objects_Shrink_information+0x8c> 400079d4: 90 10 00 10 mov %l0, %o0 if ( !_Chain_Is_last( &the_object->Node ) ) the_object = (Objects_Control *) the_object->Node.next; else the_object = NULL; _Chain_Extract( &extract_me->Node ); 400079d8: 40 00 11 e6 call 4000c170 <_Chain_Extract> 400079dc: e0 04 00 00 ld [ %l0 ], %l0 } else { the_object = (Objects_Control *) the_object->Node.next; } } while ( the_object && !_Chain_Is_last( &the_object->Node ) ); 400079e0: 10 80 00 04 b 400079f0 <_Objects_Shrink_information+0x94> 400079e4: 80 a4 20 00 cmp %l0, 0 the_object = NULL; _Chain_Extract( &extract_me->Node ); } else { the_object = (Objects_Control *) the_object->Node.next; 400079e8: e0 04 00 00 ld [ %l0 ], %l0 } } while ( the_object && !_Chain_Is_last( &the_object->Node ) ); 400079ec: 80 a4 20 00 cmp %l0, 0 400079f0: 22 80 00 07 be,a 40007a0c <_Objects_Shrink_information+0xb0> 400079f4: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 <== NOT EXECUTED 400079f8: c2 04 00 00 ld [ %l0 ], %g1 400079fc: 80 a0 60 00 cmp %g1, 0 40007a00: 32 bf ff ed bne,a 400079b4 <_Objects_Shrink_information+0x58> 40007a04: c2 04 20 08 ld [ %l0 + 8 ], %g1 40007a08: c2 06 20 3c ld [ %i0 + 0x3c ], %g1 40007a0c: 11 10 00 63 sethi %hi(0x40018c00), %o0 40007a10: d2 00 40 12 ld [ %g1 + %l2 ], %o1 40007a14: 7f ff fc b7 call 40006cf0 <_Heap_Free> 40007a18: 90 12 23 3c or %o0, 0x33c, %o0 */ _Workspace_Free( information->object_blocks[ block ] ); information->name_table[ block ] = NULL; information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; 40007a1c: c2 06 20 38 ld [ %i0 + 0x38 ], %g1 /* * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->name_table[ block ] = NULL; 40007a20: c6 06 20 24 ld [ %i0 + 0x24 ], %g3 information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; 40007a24: c0 20 40 12 clr [ %g1 + %l2 ] * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->name_table[ block ] = NULL; information->object_blocks[ block ] = NULL; 40007a28: c8 06 20 3c ld [ %i0 + 0x3c ], %g4 information->inactive_per_block[ block ] = 0; information->inactive -= information->allocation_size; 40007a2c: c2 16 20 34 lduh [ %i0 + 0x34 ], %g1 40007a30: c4 06 20 18 ld [ %i0 + 0x18 ], %g2 /* * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->name_table[ block ] = NULL; 40007a34: c0 20 c0 12 clr [ %g3 + %l2 ] information->object_blocks[ block ] = NULL; information->inactive_per_block[ block ] = 0; information->inactive -= information->allocation_size; 40007a38: 82 20 40 02 sub %g1, %g2, %g1 * Free the memory and reset the structures in the object' information */ _Workspace_Free( information->object_blocks[ block ] ); information->name_table[ block ] = NULL; information->object_blocks[ block ] = NULL; 40007a3c: c0 21 00 12 clr [ %g4 + %l2 ] information->inactive_per_block[ block ] = 0; information->inactive -= information->allocation_size; 40007a40: c2 36 20 34 sth %g1, [ %i0 + 0x34 ] 40007a44: 81 c7 e0 08 ret 40007a48: 81 e8 00 00 restore return; } index_base += information->allocation_size; 40007a4c: a2 04 40 10 add %l1, %l0, %l1 */ index_base = _Objects_Get_index( information->minimum_id ); block_count = ( information->maximum - index_base ) / information->allocation_size; for ( block = 0; block < block_count; block++ ) { 40007a50: a4 10 00 02 mov %g2, %l2 40007a54: 80 a0 c0 08 cmp %g3, %o0 40007a58: 32 bf ff ce bne,a 40007990 <_Objects_Shrink_information+0x34> 40007a5c: c2 06 20 38 ld [ %i0 + 0x38 ], %g1 40007a60: 81 c7 e0 08 ret 40007a64: 81 e8 00 00 restore 40007a9c <_Protected_heap_Allocate>: void *_Protected_heap_Allocate( Heap_Control *the_heap, size_t size ) { 40007a9c: 9d e3 bf 98 save %sp, -104, %sp void *p; _RTEMS_Lock_allocator(); 40007aa0: 7f ff e8 a7 call 40001d3c 40007aa4: 01 00 00 00 nop 40007aa8: a2 10 00 08 mov %o0, %l1 40007aac: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007ab0: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 40007ab4: 80 a0 60 00 cmp %g1, 0 40007ab8: 02 80 00 0b be 40007ae4 <_Protected_heap_Allocate+0x48> 40007abc: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007ac0: 03 10 00 64 sethi %hi(0x40019000), %g1 40007ac4: c2 00 60 d0 ld [ %g1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> 40007ac8: 80 a0 60 01 cmp %g1, 1 40007acc: 08 80 00 05 bleu 40007ae0 <_Protected_heap_Allocate+0x44> 40007ad0: 90 10 20 00 clr %o0 40007ad4: 92 10 20 00 clr %o1 <== NOT EXECUTED 40007ad8: 7f ff fd 8a call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40007adc: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 40007ae0: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007ae4: e0 00 63 c4 ld [ %g1 + 0x3c4 ], %l0 ! 40018fc4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40007ae8: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007aec: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 40007af0: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 40007af4: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 40007af8: 80 a0 60 00 cmp %g1, 0 40007afc: 22 80 00 33 be,a 40007bc8 <_Protected_heap_Allocate+0x12c> 40007b00: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 40007b04: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 40007b08: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 40007b0c: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; 40007b10: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 40007b14: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 40007b18: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40007b1c: 80 a0 e0 02 cmp %g3, 2 40007b20: 02 80 00 05 be 40007b34 <_Protected_heap_Allocate+0x98> 40007b24: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 40007b28: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40007b2c: 32 80 00 06 bne,a 40007b44 <_Protected_heap_Allocate+0xa8> <== NOT EXECUTED 40007b30: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 40007b34: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 40007b38: 82 00 60 01 inc %g1 40007b3c: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 40007b40: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 40007b44: 80 a0 60 03 cmp %g1, 3 40007b48: 22 80 00 03 be,a 40007b54 <_Protected_heap_Allocate+0xb8> 40007b4c: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40007b50: 30 80 00 2c b,a 40007c00 <_Protected_heap_Allocate+0x164> { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 40007b54: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40007b58: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40007b5c: 12 80 00 03 bne 40007b68 <_Protected_heap_Allocate+0xcc> <== NOT EXECUTED 40007b60: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 40007b64: 30 80 00 27 b,a 40007c00 <_Protected_heap_Allocate+0x164> <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40007b68: 08 80 00 10 bleu 40007ba8 <_Protected_heap_Allocate+0x10c> <== NOT EXECUTED 40007b6c: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40007b70: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40007b74: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40007b78: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007b7c: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 40007b80: 7f ff e8 73 call 40001d4c <== NOT EXECUTED 40007b84: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 40007b88: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 40007b8c: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 40007b90: 40 00 02 95 call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 40007b94: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 40007b98: 7f ff ff b4 call 40007a68 <_Thread_Enable_dispatch> <== NOT EXECUTED 40007b9c: 01 00 00 00 nop <== NOT EXECUTED p = _Heap_Allocate( the_heap, size ); 40007ba0: 10 80 00 32 b 40007c68 <_Protected_heap_Allocate+0x1cc> <== NOT EXECUTED 40007ba4: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40007ba8: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40007bac: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 40007bb0: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 40007bb4: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40007bb8: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40007bbc: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40007bc0: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 40007bc4: 30 80 00 0f b,a 40007c00 <_Protected_heap_Allocate+0x164> <== NOT EXECUTED /* * 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 ) ) { 40007bc8: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 40007bcc: 32 80 00 13 bne,a 40007c18 <_Protected_heap_Allocate+0x17c> <== NOT EXECUTED 40007bd0: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 40007bd4: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40018c50 <== NOT EXECUTED 40007bd8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40007bdc: 22 80 00 07 be,a 40007bf8 <_Protected_heap_Allocate+0x15c> <== NOT EXECUTED 40007be0: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 40007be4: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40007be8: 32 80 00 0c bne,a 40007c18 <_Protected_heap_Allocate+0x17c> <== NOT EXECUTED 40007bec: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40007bf0: 10 80 00 08 b 40007c10 <_Protected_heap_Allocate+0x174> <== NOT EXECUTED 40007bf4: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 40007bf8: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007bfc: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 40007c00: 7f ff e8 53 call 40001d4c 40007c04: 90 10 00 11 mov %l1, %o0 40007c08: 10 80 00 18 b 40007c68 <_Protected_heap_Allocate+0x1cc> 40007c0c: 90 10 00 18 mov %i0, %o0 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40007c10: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 40007c14: 30 bf ff fb b,a 40007c00 <_Protected_heap_Allocate+0x164> <== NOT EXECUTED size_t size ) { void *p; _RTEMS_Lock_allocator(); 40007c18: c6 04 23 c4 ld [ %l0 + 0x3c4 ], %g3 <== NOT EXECUTED 40007c1c: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007c20: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 40007c24: c8 00 63 cc ld [ %g1 + 0x3cc ], %g4 <== NOT EXECUTED 40007c28: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40007c2c: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40007c30: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 40007c34: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007c38: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED 40007c3c: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 40007c40: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section ( Thread_queue_Control *the_thread_queue ) { the_thread_queue->sync_state = THREAD_QUEUE_NOTHING_HAPPENED; 40007c44: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 40007c48: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 40007c4c: 7f ff e8 40 call 40001d4c <== NOT EXECUTED 40007c50: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40007c54: d0 04 23 c4 ld [ %l0 + 0x3c4 ], %o0 <== NOT EXECUTED 40007c58: 92 10 20 00 clr %o1 <== NOT EXECUTED 40007c5c: 7f ff fb 0f call 40006898 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 40007c60: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED p = _Heap_Allocate( the_heap, size ); 40007c64: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 40007c68: 7f ff fb fb call 40006c54 <_Heap_Allocate> 40007c6c: 92 10 00 19 mov %i1, %o1 40007c70: 05 10 00 63 sethi %hi(0x40018c00), %g2 40007c74: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 40007c78: b0 10 00 08 mov %o0, %i0 40007c7c: 82 00 60 01 inc %g1 40007c80: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] _RTEMS_Unlock_allocator(); 40007c84: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007c88: d0 00 63 c4 ld [ %g1 + 0x3c4 ], %o0 ! 40018fc4 <_RTEMS_Allocator_Mutex> 40007c8c: 94 10 20 00 clr %o2 40007c90: d2 02 20 08 ld [ %o0 + 8 ], %o1 40007c94: 7f ff fb 23 call 40006920 <_CORE_mutex_Surrender> 40007c98: 90 02 20 10 add %o0, 0x10, %o0 40007c9c: 7f ff ff 73 call 40007a68 <_Thread_Enable_dispatch> 40007ca0: 01 00 00 00 nop return p; } 40007ca4: 81 c7 e0 08 ret 40007ca8: 81 e8 00 00 restore 40007ce0 <_Protected_heap_Extend>: boolean _Protected_heap_Extend( Heap_Control *the_heap, void *starting_address, size_t size ) { 40007ce0: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED Heap_Extend_status status; uint32_t amount_extended; _RTEMS_Lock_allocator(); 40007ce4: 7f ff e8 16 call 40001d3c <== NOT EXECUTED 40007ce8: 01 00 00 00 nop <== NOT EXECUTED 40007cec: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED 40007cf0: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007cf4: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40007cf8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40007cfc: 02 80 00 0b be 40007d28 <_Protected_heap_Extend+0x48> <== NOT EXECUTED 40007d00: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007d04: 03 10 00 64 sethi %hi(0x40019000), %g1 <== NOT EXECUTED 40007d08: c2 00 60 d0 ld [ %g1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> <== NOT EXECUTED 40007d0c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40007d10: 08 80 00 05 bleu 40007d24 <_Protected_heap_Extend+0x44> <== NOT EXECUTED 40007d14: 90 10 20 00 clr %o0 <== NOT EXECUTED 40007d18: 92 10 20 00 clr %o1 <== NOT EXECUTED 40007d1c: 7f ff fc f9 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40007d20: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 40007d24: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007d28: e0 00 63 c4 ld [ %g1 + 0x3c4 ], %l0 ! 40018fc4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40007d2c: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007d30: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 40007d34: c0 20 a0 34 clr [ %g2 + 0x34 ] <== NOT EXECUTED if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 40007d38: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED 40007d3c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40007d40: 22 80 00 33 be,a 40007e0c <_Protected_heap_Extend+0x12c> <== NOT EXECUTED 40007d44: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 40007d48: c0 24 20 60 clr [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 40007d4c: c2 00 a0 08 ld [ %g2 + 8 ], %g1 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 40007d50: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 <== NOT EXECUTED 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; 40007d54: c2 24 20 70 st %g1, [ %l0 + 0x70 ] <== NOT EXECUTED 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; 40007d58: c4 24 20 6c st %g2, [ %l0 + 0x6c ] <== NOT EXECUTED the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 40007d5c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40007d60: 80 a0 e0 02 cmp %g3, 2 <== NOT EXECUTED 40007d64: 02 80 00 05 be 40007d78 <_Protected_heap_Extend+0x98> <== NOT EXECUTED 40007d68: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED 40007d6c: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40007d70: 32 80 00 06 bne,a 40007d88 <_Protected_heap_Extend+0xa8> <== NOT EXECUTED 40007d74: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 40007d78: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40007d7c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007d80: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 40007d84: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED 40007d88: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 40007d8c: 22 80 00 03 be,a 40007d98 <_Protected_heap_Extend+0xb8> <== NOT EXECUTED 40007d90: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40007d94: 30 80 00 2c b,a 40007e44 <_Protected_heap_Extend+0x164> <== NOT EXECUTED { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 40007d98: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40007d9c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40007da0: 12 80 00 03 bne 40007dac <_Protected_heap_Extend+0xcc> <== NOT EXECUTED 40007da4: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 40007da8: 30 80 00 27 b,a 40007e44 <_Protected_heap_Extend+0x164> <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40007dac: 08 80 00 10 bleu 40007dec <_Protected_heap_Extend+0x10c> <== NOT EXECUTED 40007db0: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40007db4: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40007db8: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40007dbc: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007dc0: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 40007dc4: 7f ff e7 e2 call 40001d4c <== NOT EXECUTED 40007dc8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 40007dcc: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 40007dd0: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 40007dd4: 40 00 02 04 call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 40007dd8: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 40007ddc: 7f ff ff b4 call 40007cac <_Thread_Enable_dispatch> <== NOT EXECUTED 40007de0: 01 00 00 00 nop <== NOT EXECUTED status = _Heap_Extend(the_heap, starting_address, size, &amount_extended); 40007de4: 10 80 00 32 b 40007eac <_Protected_heap_Extend+0x1cc> <== NOT EXECUTED 40007de8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40007dec: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40007df0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 40007df4: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 40007df8: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40007dfc: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40007e00: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40007e04: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 40007e08: 30 80 00 0f b,a 40007e44 <_Protected_heap_Extend+0x164> <== NOT EXECUTED /* * 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 ) ) { 40007e0c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 40007e10: 32 80 00 13 bne,a 40007e5c <_Protected_heap_Extend+0x17c> <== NOT EXECUTED 40007e14: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 40007e18: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40018c50 <== NOT EXECUTED 40007e1c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40007e20: 22 80 00 07 be,a 40007e3c <_Protected_heap_Extend+0x15c> <== NOT EXECUTED 40007e24: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 40007e28: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40007e2c: 12 80 00 0c bne 40007e5c <_Protected_heap_Extend+0x17c> <== NOT EXECUTED 40007e30: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40007e34: 10 80 00 08 b 40007e54 <_Protected_heap_Extend+0x174> <== NOT EXECUTED 40007e38: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 40007e3c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007e40: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 40007e44: 7f ff e7 c2 call 40001d4c <== NOT EXECUTED 40007e48: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40007e4c: 10 80 00 18 b 40007eac <_Protected_heap_Extend+0x1cc> <== NOT EXECUTED 40007e50: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40007e54: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 40007e58: 30 bf ff fb b,a 40007e44 <_Protected_heap_Extend+0x164> <== NOT EXECUTED ) { Heap_Extend_status status; uint32_t amount_extended; _RTEMS_Lock_allocator(); 40007e5c: c6 04 23 c4 ld [ %l0 + 0x3c4 ], %g3 <== NOT EXECUTED 40007e60: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007e64: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 40007e68: c8 00 63 cc ld [ %g1 + 0x3cc ], %g4 <== NOT EXECUTED 40007e6c: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40007e70: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40007e74: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 40007e78: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007e7c: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED 40007e80: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 40007e84: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 40007e88: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 40007e8c: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 40007e90: 7f ff e7 af call 40001d4c <== NOT EXECUTED 40007e94: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40007e98: d0 04 23 c4 ld [ %l0 + 0x3c4 ], %o0 <== NOT EXECUTED 40007e9c: 92 10 20 00 clr %o1 <== NOT EXECUTED 40007ea0: 7f ff fa 7e call 40006898 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 40007ea4: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED status = _Heap_Extend(the_heap, starting_address, size, &amount_extended); 40007ea8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 40007eac: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 40007eb0: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED 40007eb4: 40 00 10 e0 call 4000c234 <_Heap_Extend> <== NOT EXECUTED 40007eb8: 96 07 bf f4 add %fp, -12, %o3 <== NOT EXECUTED 40007ebc: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40007ec0: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40007ec4: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED 40007ec8: 82 00 60 01 inc %g1 <== NOT EXECUTED 40007ecc: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _RTEMS_Unlock_allocator(); 40007ed0: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007ed4: d0 00 63 c4 ld [ %g1 + 0x3c4 ], %o0 ! 40018fc4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 40007ed8: 94 10 20 00 clr %o2 <== NOT EXECUTED 40007edc: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 40007ee0: 7f ff fa 90 call 40006920 <_CORE_mutex_Surrender> <== NOT EXECUTED 40007ee4: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 40007ee8: 7f ff ff 71 call 40007cac <_Thread_Enable_dispatch> <== NOT EXECUTED 40007eec: 01 00 00 00 nop <== NOT EXECUTED return (status == HEAP_EXTEND_SUCCESSFUL); } 40007ef0: 80 a0 00 10 cmp %g0, %l0 <== NOT EXECUTED 40007ef4: b0 60 3f ff subx %g0, -1, %i0 <== NOT EXECUTED 40007ef8: 81 c7 e0 08 ret <== NOT EXECUTED 40007efc: 81 e8 00 00 restore <== NOT EXECUTED 40007f34 <_Protected_heap_Free>: boolean _Protected_heap_Free( Heap_Control *the_heap, void *start_address ) { 40007f34: 9d e3 bf 98 save %sp, -104, %sp boolean status; _RTEMS_Lock_allocator(); 40007f38: 7f ff e7 81 call 40001d3c 40007f3c: 01 00 00 00 nop 40007f40: a2 10 00 08 mov %o0, %l1 40007f44: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007f48: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 40007f4c: 80 a0 60 00 cmp %g1, 0 40007f50: 02 80 00 0b be 40007f7c <_Protected_heap_Free+0x48> 40007f54: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007f58: 03 10 00 64 sethi %hi(0x40019000), %g1 <== NOT EXECUTED 40007f5c: c2 00 60 d0 ld [ %g1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> <== NOT EXECUTED 40007f60: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40007f64: 08 80 00 05 bleu 40007f78 <_Protected_heap_Free+0x44> <== NOT EXECUTED 40007f68: 90 10 20 00 clr %o0 <== NOT EXECUTED 40007f6c: 92 10 20 00 clr %o1 <== NOT EXECUTED 40007f70: 7f ff fc 64 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40007f74: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 40007f78: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40007f7c: e0 00 63 c4 ld [ %g1 + 0x3c4 ], %l0 ! 40018fc4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40007f80: 03 10 00 63 sethi %hi(0x40018c00), %g1 40007f84: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 40007f88: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 40007f8c: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 40007f90: 80 a0 60 00 cmp %g1, 0 40007f94: 22 80 00 33 be,a 40008060 <_Protected_heap_Free+0x12c> 40007f98: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 40007f9c: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 40007fa0: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 40007fa4: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; 40007fa8: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 40007fac: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 40007fb0: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40007fb4: 80 a0 e0 02 cmp %g3, 2 40007fb8: 02 80 00 05 be 40007fcc <_Protected_heap_Free+0x98> 40007fbc: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 40007fc0: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40007fc4: 32 80 00 06 bne,a 40007fdc <_Protected_heap_Free+0xa8> <== NOT EXECUTED 40007fc8: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 40007fcc: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 40007fd0: 82 00 60 01 inc %g1 40007fd4: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 40007fd8: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 40007fdc: 80 a0 60 03 cmp %g1, 3 40007fe0: 22 80 00 03 be,a 40007fec <_Protected_heap_Free+0xb8> 40007fe4: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40007fe8: 30 80 00 2c b,a 40008098 <_Protected_heap_Free+0x164> { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 40007fec: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40007ff0: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40007ff4: 12 80 00 03 bne 40008000 <_Protected_heap_Free+0xcc> <== NOT EXECUTED 40007ff8: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 40007ffc: 30 80 00 27 b,a 40008098 <_Protected_heap_Free+0x164> <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40008000: 08 80 00 10 bleu 40008040 <_Protected_heap_Free+0x10c> <== NOT EXECUTED 40008004: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40008008: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 4000800c: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40008010: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008014: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 40008018: 7f ff e7 4d call 40001d4c <== NOT EXECUTED 4000801c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 40008020: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 40008024: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 40008028: 40 00 01 6f call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 4000802c: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 40008030: 7f ff ff b4 call 40007f00 <_Thread_Enable_dispatch> <== NOT EXECUTED 40008034: 01 00 00 00 nop <== NOT EXECUTED status = _Heap_Free( the_heap, start_address ); 40008038: 10 80 00 32 b 40008100 <_Protected_heap_Free+0x1cc> <== NOT EXECUTED 4000803c: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40008040: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40008044: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 40008048: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 4000804c: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40008050: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40008054: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40008058: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 4000805c: 30 80 00 0f b,a 40008098 <_Protected_heap_Free+0x164> <== NOT EXECUTED /* * 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 ) ) { 40008060: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 40008064: 32 80 00 13 bne,a 400080b0 <_Protected_heap_Free+0x17c> <== NOT EXECUTED 40008068: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 4000806c: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40018c50 <== NOT EXECUTED 40008070: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40008074: 22 80 00 07 be,a 40008090 <_Protected_heap_Free+0x15c> <== NOT EXECUTED 40008078: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 4000807c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40008080: 32 80 00 0c bne,a 400080b0 <_Protected_heap_Free+0x17c> <== NOT EXECUTED 40008084: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40008088: 10 80 00 08 b 400080a8 <_Protected_heap_Free+0x174> <== NOT EXECUTED 4000808c: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 40008090: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008094: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 40008098: 7f ff e7 2d call 40001d4c 4000809c: 90 10 00 11 mov %l1, %o0 400080a0: 10 80 00 18 b 40008100 <_Protected_heap_Free+0x1cc> 400080a4: 90 10 00 18 mov %i0, %o0 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 400080a8: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 400080ac: 30 bf ff fb b,a 40008098 <_Protected_heap_Free+0x164> <== NOT EXECUTED void *start_address ) { boolean status; _RTEMS_Lock_allocator(); 400080b0: c6 04 23 c4 ld [ %l0 + 0x3c4 ], %g3 <== NOT EXECUTED 400080b4: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400080b8: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 400080bc: c8 00 63 cc ld [ %g1 + 0x3cc ], %g4 <== NOT EXECUTED 400080c0: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 400080c4: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400080c8: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 400080cc: 82 00 60 01 inc %g1 <== NOT EXECUTED 400080d0: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED 400080d4: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 400080d8: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 400080dc: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 400080e0: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 400080e4: 7f ff e7 1a call 40001d4c <== NOT EXECUTED 400080e8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 400080ec: d0 04 23 c4 ld [ %l0 + 0x3c4 ], %o0 <== NOT EXECUTED 400080f0: 92 10 20 00 clr %o1 <== NOT EXECUTED 400080f4: 7f ff f9 e9 call 40006898 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 400080f8: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED status = _Heap_Free( the_heap, start_address ); 400080fc: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 40008100: 7f ff fa fc call 40006cf0 <_Heap_Free> 40008104: 92 10 00 19 mov %i1, %o1 40008108: 05 10 00 63 sethi %hi(0x40018c00), %g2 4000810c: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 40008110: b0 10 00 08 mov %o0, %i0 40008114: 82 00 60 01 inc %g1 40008118: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] _RTEMS_Unlock_allocator(); 4000811c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008120: d0 00 63 c4 ld [ %g1 + 0x3c4 ], %o0 ! 40018fc4 <_RTEMS_Allocator_Mutex> 40008124: 94 10 20 00 clr %o2 40008128: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000812c: 7f ff f9 fd call 40006920 <_CORE_mutex_Surrender> 40008130: 90 02 20 10 add %o0, 0x10, %o0 40008134: 7f ff ff 73 call 40007f00 <_Thread_Enable_dispatch> 40008138: 01 00 00 00 nop return status; } 4000813c: 81 c7 e0 08 ret 40008140: 81 e8 00 00 restore 40008178 <_Protected_heap_Get_block_size>: boolean _Protected_heap_Get_block_size( Heap_Control *the_heap, void *starting_address, size_t *size ) { 40008178: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED boolean status; _RTEMS_Lock_allocator(); 4000817c: 7f ff e6 f0 call 40001d3c <== NOT EXECUTED 40008180: 01 00 00 00 nop <== NOT EXECUTED 40008184: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED 40008188: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 4000818c: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40008190: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40008194: 02 80 00 0b be 400081c0 <_Protected_heap_Get_block_size+0x48> <== NOT EXECUTED 40008198: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 4000819c: 03 10 00 64 sethi %hi(0x40019000), %g1 <== NOT EXECUTED 400081a0: c2 00 60 d0 ld [ %g1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> <== NOT EXECUTED 400081a4: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400081a8: 08 80 00 05 bleu 400081bc <_Protected_heap_Get_block_size+0x44> <== NOT EXECUTED 400081ac: 90 10 20 00 clr %o0 <== NOT EXECUTED 400081b0: 92 10 20 00 clr %o1 <== NOT EXECUTED 400081b4: 7f ff fb d3 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 400081b8: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 400081bc: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400081c0: e0 00 63 c4 ld [ %g1 + 0x3c4 ], %l0 ! 40018fc4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 400081c4: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400081c8: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 400081cc: c0 20 a0 34 clr [ %g2 + 0x34 ] <== NOT EXECUTED if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 400081d0: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED 400081d4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 400081d8: 22 80 00 33 be,a 400082a4 <_Protected_heap_Get_block_size+0x12c> <== NOT EXECUTED 400081dc: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 400081e0: c0 24 20 60 clr [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 400081e4: c2 00 a0 08 ld [ %g2 + 8 ], %g1 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 400081e8: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 <== NOT EXECUTED 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; 400081ec: c2 24 20 70 st %g1, [ %l0 + 0x70 ] <== NOT EXECUTED 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; 400081f0: c4 24 20 6c st %g2, [ %l0 + 0x6c ] <== NOT EXECUTED the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 400081f4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 400081f8: 80 a0 e0 02 cmp %g3, 2 <== NOT EXECUTED 400081fc: 02 80 00 05 be 40008210 <_Protected_heap_Get_block_size+0x98> <== NOT EXECUTED 40008200: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED 40008204: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40008208: 32 80 00 06 bne,a 40008220 <_Protected_heap_Get_block_size+0xa8> <== NOT EXECUTED 4000820c: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 40008210: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40008214: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008218: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 4000821c: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED 40008220: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 40008224: 22 80 00 03 be,a 40008230 <_Protected_heap_Get_block_size+0xb8> <== NOT EXECUTED 40008228: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 4000822c: 30 80 00 2c b,a 400082dc <_Protected_heap_Get_block_size+0x164> <== NOT EXECUTED { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 40008230: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40008234: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40008238: 12 80 00 03 bne 40008244 <_Protected_heap_Get_block_size+0xcc> <== NOT EXECUTED 4000823c: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 40008240: 30 80 00 27 b,a 400082dc <_Protected_heap_Get_block_size+0x164> <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40008244: 08 80 00 10 bleu 40008284 <_Protected_heap_Get_block_size+0x10c> <== NOT EXECUTED 40008248: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000824c: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40008250: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40008254: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008258: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 4000825c: 7f ff e6 bc call 40001d4c <== NOT EXECUTED 40008260: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 40008264: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 40008268: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 4000826c: 40 00 00 de call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 40008270: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 40008274: 7f ff ff b4 call 40008144 <_Thread_Enable_dispatch> <== NOT EXECUTED 40008278: 01 00 00 00 nop <== NOT EXECUTED status = _Heap_Size_of_user_area( the_heap, starting_address, size ); 4000827c: 10 80 00 32 b 40008344 <_Protected_heap_Get_block_size+0x1cc> <== NOT EXECUTED 40008280: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40008284: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40008288: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 4000828c: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 40008290: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40008294: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40008298: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 4000829c: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 400082a0: 30 80 00 0f b,a 400082dc <_Protected_heap_Get_block_size+0x164> <== NOT EXECUTED /* * 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 ) ) { 400082a4: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 400082a8: 32 80 00 13 bne,a 400082f4 <_Protected_heap_Get_block_size+0x17c> <== NOT EXECUTED 400082ac: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 400082b0: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40018c50 <== NOT EXECUTED 400082b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 400082b8: 22 80 00 07 be,a 400082d4 <_Protected_heap_Get_block_size+0x15c> <== NOT EXECUTED 400082bc: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 400082c0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400082c4: 32 80 00 0c bne,a 400082f4 <_Protected_heap_Get_block_size+0x17c> <== NOT EXECUTED 400082c8: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 400082cc: 10 80 00 08 b 400082ec <_Protected_heap_Get_block_size+0x174> <== NOT EXECUTED 400082d0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 400082d4: 82 00 60 01 inc %g1 <== NOT EXECUTED 400082d8: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 400082dc: 7f ff e6 9c call 40001d4c <== NOT EXECUTED 400082e0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 400082e4: 10 80 00 18 b 40008344 <_Protected_heap_Get_block_size+0x1cc> <== NOT EXECUTED 400082e8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 400082ec: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 400082f0: 30 bf ff fb b,a 400082dc <_Protected_heap_Get_block_size+0x164> <== NOT EXECUTED size_t *size ) { boolean status; _RTEMS_Lock_allocator(); 400082f4: c6 04 23 c4 ld [ %l0 + 0x3c4 ], %g3 <== NOT EXECUTED 400082f8: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400082fc: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 40008300: c8 00 63 cc ld [ %g1 + 0x3cc ], %g4 <== NOT EXECUTED 40008304: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40008308: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000830c: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 40008310: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008314: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED 40008318: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 4000831c: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 40008320: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 40008324: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 40008328: 7f ff e6 89 call 40001d4c <== NOT EXECUTED 4000832c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40008330: d0 04 23 c4 ld [ %l0 + 0x3c4 ], %o0 <== NOT EXECUTED 40008334: 92 10 20 00 clr %o1 <== NOT EXECUTED 40008338: 7f ff f9 58 call 40006898 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 4000833c: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED status = _Heap_Size_of_user_area( the_heap, starting_address, size ); 40008340: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 40008344: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 40008348: 40 00 10 75 call 4000c51c <_Heap_Size_of_user_area> <== NOT EXECUTED 4000834c: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED 40008350: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40008354: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40008358: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 4000835c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008360: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _RTEMS_Unlock_allocator(); 40008364: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008368: d0 00 63 c4 ld [ %g1 + 0x3c4 ], %o0 ! 40018fc4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 4000836c: 94 10 20 00 clr %o2 <== NOT EXECUTED 40008370: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 40008374: 7f ff f9 6b call 40006920 <_CORE_mutex_Surrender> <== NOT EXECUTED 40008378: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 4000837c: 7f ff ff 72 call 40008144 <_Thread_Enable_dispatch> <== NOT EXECUTED 40008380: 01 00 00 00 nop <== NOT EXECUTED return status; } 40008384: 81 c7 e0 08 ret <== NOT EXECUTED 40008388: 81 e8 00 00 restore <== NOT EXECUTED 4000b940 <_Protected_heap_Get_free_information>: void _Protected_heap_Get_free_information( Heap_Control *the_heap, Heap_Information *info ) { 4000b940: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED _RTEMS_Lock_allocator(); 4000b944: 7f ff e0 96 call 40003b9c <== NOT EXECUTED 4000b948: 01 00 00 00 nop <== NOT EXECUTED 4000b94c: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED 4000b950: 03 10 00 e5 sethi %hi(0x40039400), %g1 <== NOT EXECUTED 4000b954: c2 00 63 b0 ld [ %g1 + 0x3b0 ], %g1 ! 400397b0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000b958: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000b95c: 02 80 00 0b be 4000b988 <_Protected_heap_Get_free_information+0x48> <== NOT EXECUTED 4000b960: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4000b964: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4000b968: c2 00 61 90 ld [ %g1 + 0x190 ], %g1 ! 40039990 <_System_state_Current> <== NOT EXECUTED 4000b96c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000b970: 08 80 00 05 bleu 4000b984 <_Protected_heap_Get_free_information+0x44> <== NOT EXECUTED 4000b974: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000b978: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000b97c: 7f ff fb 80 call 4000a77c <_Internal_error_Occurred> <== NOT EXECUTED 4000b980: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 4000b984: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4000b988: e0 00 60 84 ld [ %g1 + 0x84 ], %l0 ! 40039884 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 4000b98c: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4000b990: c4 00 60 8c ld [ %g1 + 0x8c ], %g2 ! 4003988c <_Thread_Executing> <== NOT EXECUTED executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 4000b994: c0 20 a0 34 clr [ %g2 + 0x34 ] <== NOT EXECUTED if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 4000b998: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED 4000b99c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000b9a0: 22 80 00 33 be,a 4000ba6c <_Protected_heap_Get_free_information+0x12c> <== NOT EXECUTED 4000b9a4: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 4000b9a8: c0 24 20 60 clr [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 4000b9ac: c2 00 a0 08 ld [ %g2 + 8 ], %g1 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 4000b9b0: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 <== NOT EXECUTED 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; 4000b9b4: c2 24 20 70 st %g1, [ %l0 + 0x70 ] <== NOT EXECUTED 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; 4000b9b8: c4 24 20 6c st %g2, [ %l0 + 0x6c ] <== NOT EXECUTED the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 4000b9bc: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 4000b9c0: 80 a0 e0 02 cmp %g3, 2 <== NOT EXECUTED 4000b9c4: 02 80 00 05 be 4000b9d8 <_Protected_heap_Get_free_information+0x98> <== NOT EXECUTED 4000b9c8: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED 4000b9cc: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 4000b9d0: 32 80 00 06 bne,a 4000b9e8 <_Protected_heap_Get_free_information+0xa8> <== NOT EXECUTED 4000b9d4: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4000b9d8: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 4000b9dc: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000b9e0: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 4000b9e4: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED 4000b9e8: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 4000b9ec: 22 80 00 03 be,a 4000b9f8 <_Protected_heap_Get_free_information+0xb8> <== NOT EXECUTED 4000b9f0: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 4000b9f4: 30 80 00 2c b,a 4000baa4 <_Protected_heap_Get_free_information+0x164> <== NOT EXECUTED { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 4000b9f8: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 4000b9fc: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 4000ba00: 12 80 00 03 bne 4000ba0c <_Protected_heap_Get_free_information+0xcc> <== NOT EXECUTED 4000ba04: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 4000ba08: 30 80 00 27 b,a 4000baa4 <_Protected_heap_Get_free_information+0x164> <== NOT EXECUTED return 0; } if ( current > ceiling ) { 4000ba0c: 08 80 00 10 bleu 4000ba4c <_Protected_heap_Get_free_information+0x10c> <== NOT EXECUTED 4000ba10: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000ba14: 05 10 00 e5 sethi %hi(0x40039400), %g2 <== NOT EXECUTED 4000ba18: c2 00 a3 b0 ld [ %g2 + 0x3b0 ], %g1 ! 400397b0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000ba1c: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000ba20: c2 20 a3 b0 st %g1, [ %g2 + 0x3b0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 4000ba24: 7f ff e0 62 call 40003bac <== NOT EXECUTED 4000ba28: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 4000ba2c: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 4000ba30: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 4000ba34: 40 00 00 db call 4000bda0 <_Thread_Change_priority> <== NOT EXECUTED 4000ba38: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 4000ba3c: 7f ff ff b4 call 4000b90c <_Thread_Enable_dispatch> <== NOT EXECUTED 4000ba40: 01 00 00 00 nop <== NOT EXECUTED _Heap_Get_free_information( the_heap, info ); 4000ba44: 10 80 00 32 b 4000bb0c <_Protected_heap_Get_free_information+0x1cc> <== NOT EXECUTED 4000ba48: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 4000ba4c: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 4000ba50: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 4000ba54: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 4000ba58: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 4000ba5c: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 4000ba60: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 4000ba64: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 4000ba68: 30 80 00 0f b,a 4000baa4 <_Protected_heap_Get_free_information+0x164> <== NOT EXECUTED /* * 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 ) ) { 4000ba6c: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 4000ba70: 32 80 00 13 bne,a 4000babc <_Protected_heap_Get_free_information+0x17c> <== NOT EXECUTED 4000ba74: 21 10 00 e6 sethi %hi(0x40039800), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 4000ba78: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40039850 <_Workspace_Area+0x54> <== NOT EXECUTED 4000ba7c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000ba80: 22 80 00 07 be,a 4000ba9c <_Protected_heap_Get_free_information+0x15c> <== NOT EXECUTED 4000ba84: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 4000ba88: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000ba8c: 32 80 00 0c bne,a 4000babc <_Protected_heap_Get_free_information+0x17c> <== NOT EXECUTED 4000ba90: 21 10 00 e6 sethi %hi(0x40039800), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 4000ba94: 10 80 00 08 b 4000bab4 <_Protected_heap_Get_free_information+0x174> <== NOT EXECUTED 4000ba98: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 4000ba9c: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000baa0: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 4000baa4: 7f ff e0 42 call 40003bac <== NOT EXECUTED 4000baa8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4000baac: 10 80 00 18 b 4000bb0c <_Protected_heap_Get_free_information+0x1cc> <== NOT EXECUTED 4000bab0: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 4000bab4: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 4000bab8: 30 bf ff fb b,a 4000baa4 <_Protected_heap_Get_free_information+0x164> <== NOT EXECUTED void _Protected_heap_Get_free_information( Heap_Control *the_heap, Heap_Information *info ) { _RTEMS_Lock_allocator(); 4000babc: c6 04 20 84 ld [ %l0 + 0x84 ], %g3 <== NOT EXECUTED 4000bac0: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4000bac4: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 4000bac8: c8 00 60 8c ld [ %g1 + 0x8c ], %g4 <== NOT EXECUTED 4000bacc: 05 10 00 e5 sethi %hi(0x40039400), %g2 <== NOT EXECUTED 4000bad0: c2 00 a3 b0 ld [ %g2 + 0x3b0 ], %g1 ! 400397b0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000bad4: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 4000bad8: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000badc: c2 20 a3 b0 st %g1, [ %g2 + 0x3b0 ] <== NOT EXECUTED 4000bae0: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 4000bae4: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 4000bae8: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 4000baec: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 4000baf0: 7f ff e0 2f call 40003bac <== NOT EXECUTED 4000baf4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4000baf8: d0 04 20 84 ld [ %l0 + 0x84 ], %o0 <== NOT EXECUTED 4000bafc: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000bb00: 7f ff f9 05 call 40009f14 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 4000bb04: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED _Heap_Get_free_information( the_heap, info ); 4000bb08: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 4000bb0c: 40 00 33 2e call 400187c4 <_Heap_Get_free_information> <== NOT EXECUTED 4000bb10: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 4000bb14: 05 10 00 e5 sethi %hi(0x40039400), %g2 <== NOT EXECUTED 4000bb18: c2 00 a3 b0 ld [ %g2 + 0x3b0 ], %g1 ! 400397b0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000bb1c: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000bb20: c2 20 a3 b0 st %g1, [ %g2 + 0x3b0 ] <== NOT EXECUTED _RTEMS_Unlock_allocator(); 4000bb24: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4000bb28: d0 00 60 84 ld [ %g1 + 0x84 ], %o0 ! 40039884 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 4000bb2c: 94 10 20 00 clr %o2 <== NOT EXECUTED 4000bb30: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 4000bb34: 7f ff f9 1a call 40009f9c <_CORE_mutex_Surrender> <== NOT EXECUTED 4000bb38: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 4000bb3c: 7f ff ff 74 call 4000b90c <_Thread_Enable_dispatch> <== NOT EXECUTED 4000bb40: 81 e8 00 00 restore <== NOT EXECUTED 4000bb44: 01 00 00 00 nop 400083c0 <_Protected_heap_Resize_block>: boolean _Protected_heap_Resize_block( Heap_Control *the_heap, void *starting_address, size_t size ) { 400083c0: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED Heap_Resize_status status; uint32_t old_mem_size; uint32_t avail_mem_size; _RTEMS_Lock_allocator(); 400083c4: 7f ff e6 5e call 40001d3c <== NOT EXECUTED 400083c8: 01 00 00 00 nop <== NOT EXECUTED 400083cc: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED 400083d0: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400083d4: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400083d8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 400083dc: 02 80 00 0b be 40008408 <_Protected_heap_Resize_block+0x48> <== NOT EXECUTED 400083e0: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400083e4: 03 10 00 64 sethi %hi(0x40019000), %g1 <== NOT EXECUTED 400083e8: c2 00 60 d0 ld [ %g1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> <== NOT EXECUTED 400083ec: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400083f0: 08 80 00 05 bleu 40008404 <_Protected_heap_Resize_block+0x44> <== NOT EXECUTED 400083f4: 90 10 20 00 clr %o0 <== NOT EXECUTED 400083f8: 92 10 20 00 clr %o1 <== NOT EXECUTED 400083fc: 7f ff fb 41 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40008400: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 40008404: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008408: e0 00 63 c4 ld [ %g1 + 0x3c4 ], %l0 ! 40018fc4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 4000840c: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008410: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 40008414: c0 20 a0 34 clr [ %g2 + 0x34 ] <== NOT EXECUTED if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 40008418: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 <== NOT EXECUTED 4000841c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40008420: 22 80 00 33 be,a 400084ec <_Protected_heap_Resize_block+0x12c> <== NOT EXECUTED 40008424: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 40008428: c0 24 20 60 clr [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 4000842c: c2 00 a0 08 ld [ %g2 + 8 ], %g1 <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 40008430: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 <== NOT EXECUTED 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; 40008434: c2 24 20 70 st %g1, [ %l0 + 0x70 ] <== NOT EXECUTED 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; 40008438: c4 24 20 6c st %g2, [ %l0 + 0x6c ] <== NOT EXECUTED the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 4000843c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40008440: 80 a0 e0 02 cmp %g3, 2 <== NOT EXECUTED 40008444: 02 80 00 05 be 40008458 <_Protected_heap_Resize_block+0x98> <== NOT EXECUTED 40008448: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED 4000844c: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40008450: 32 80 00 06 bne,a 40008468 <_Protected_heap_Resize_block+0xa8> <== NOT EXECUTED 40008454: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 40008458: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 4000845c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008460: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 40008464: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED 40008468: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 4000846c: 22 80 00 03 be,a 40008478 <_Protected_heap_Resize_block+0xb8> <== NOT EXECUTED 40008470: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40008474: 30 80 00 2c b,a 40008524 <_Protected_heap_Resize_block+0x164> <== NOT EXECUTED { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 40008478: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 4000847c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40008480: 12 80 00 03 bne 4000848c <_Protected_heap_Resize_block+0xcc> <== NOT EXECUTED 40008484: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 40008488: 30 80 00 27 b,a 40008524 <_Protected_heap_Resize_block+0x164> <== NOT EXECUTED return 0; } if ( current > ceiling ) { 4000848c: 08 80 00 10 bleu 400084cc <_Protected_heap_Resize_block+0x10c> <== NOT EXECUTED 40008490: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40008494: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40008498: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000849c: 82 00 60 01 inc %g1 <== NOT EXECUTED 400084a0: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 400084a4: 7f ff e6 2a call 40001d4c <== NOT EXECUTED 400084a8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 400084ac: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 400084b0: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 400084b4: 40 00 00 4c call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 400084b8: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 400084bc: 7f ff ff b4 call 4000838c <_Thread_Enable_dispatch> <== NOT EXECUTED 400084c0: 01 00 00 00 nop <== NOT EXECUTED status = _Heap_Resize_block( 400084c4: 10 80 00 32 b 4000858c <_Protected_heap_Resize_block+0x1cc> <== NOT EXECUTED 400084c8: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 400084cc: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 400084d0: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 400084d4: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 400084d8: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 400084dc: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 400084e0: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 400084e4: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 400084e8: 30 80 00 0f b,a 40008524 <_Protected_heap_Resize_block+0x164> <== NOT EXECUTED /* * 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 ) ) { 400084ec: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 400084f0: 32 80 00 13 bne,a 4000853c <_Protected_heap_Resize_block+0x17c> <== NOT EXECUTED 400084f4: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 400084f8: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40018c50 <== NOT EXECUTED 400084fc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40008500: 22 80 00 07 be,a 4000851c <_Protected_heap_Resize_block+0x15c> <== NOT EXECUTED 40008504: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 40008508: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000850c: 12 80 00 0c bne 4000853c <_Protected_heap_Resize_block+0x17c> <== NOT EXECUTED 40008510: 21 10 00 63 sethi %hi(0x40018c00), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40008514: 10 80 00 08 b 40008534 <_Protected_heap_Resize_block+0x174> <== NOT EXECUTED 40008518: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 4000851c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40008520: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 40008524: 7f ff e6 0a call 40001d4c <== NOT EXECUTED 40008528: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4000852c: 10 80 00 18 b 4000858c <_Protected_heap_Resize_block+0x1cc> <== NOT EXECUTED 40008530: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40008534: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 40008538: 30 bf ff fb b,a 40008524 <_Protected_heap_Resize_block+0x164> <== NOT EXECUTED { Heap_Resize_status status; uint32_t old_mem_size; uint32_t avail_mem_size; _RTEMS_Lock_allocator(); 4000853c: c6 04 23 c4 ld [ %l0 + 0x3c4 ], %g3 <== NOT EXECUTED 40008540: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008544: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 40008548: c8 00 63 cc ld [ %g1 + 0x3cc ], %g4 <== NOT EXECUTED 4000854c: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40008550: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40008554: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 40008558: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000855c: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED 40008560: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 40008564: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 40008568: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 4000856c: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 40008570: 7f ff e5 f7 call 40001d4c <== NOT EXECUTED 40008574: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40008578: d0 04 23 c4 ld [ %l0 + 0x3c4 ], %o0 <== NOT EXECUTED 4000857c: 92 10 20 00 clr %o1 <== NOT EXECUTED 40008580: 7f ff f8 c6 call 40006898 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 40008584: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED status = _Heap_Resize_block( 40008588: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED 4000858c: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 40008590: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED 40008594: 96 07 bf f4 add %fp, -12, %o3 <== NOT EXECUTED 40008598: 40 00 0f 58 call 4000c2f8 <_Heap_Resize_block> <== NOT EXECUTED 4000859c: 98 07 bf f0 add %fp, -16, %o4 <== NOT EXECUTED 400085a0: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 400085a4: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400085a8: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED 400085ac: 82 00 60 01 inc %g1 <== NOT EXECUTED 400085b0: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED the_heap, starting_address, size, &old_mem_size, &avail_mem_size ); _RTEMS_Unlock_allocator(); 400085b4: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400085b8: d0 00 63 c4 ld [ %g1 + 0x3c4 ], %o0 ! 40018fc4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 400085bc: 94 10 20 00 clr %o2 <== NOT EXECUTED 400085c0: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 400085c4: 7f ff f8 d7 call 40006920 <_CORE_mutex_Surrender> <== NOT EXECUTED 400085c8: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 400085cc: 7f ff ff 70 call 4000838c <_Thread_Enable_dispatch> <== NOT EXECUTED 400085d0: 01 00 00 00 nop <== NOT EXECUTED return (status == HEAP_RESIZE_SUCCESSFUL); } 400085d4: 80 a0 00 10 cmp %g0, %l0 <== NOT EXECUTED 400085d8: b0 60 3f ff subx %g0, -1, %i0 <== NOT EXECUTED 400085dc: 81 c7 e0 08 ret <== NOT EXECUTED 400085e0: 81 e8 00 00 restore <== NOT EXECUTED 4000bfd8 <_RTEMS_tasks_Delete_extension>: User_extensions_routine _RTEMS_tasks_Delete_extension( Thread_Control *executing, Thread_Control *deleted ) { 4000bfd8: 9d e3 bf 98 save %sp, -104, %sp /* * Free per task variable memory */ tvp = deleted->task_variables; 4000bfdc: e0 06 61 7c ld [ %i1 + 0x17c ], %l0 deleted->task_variables = NULL; while (tvp) { next = (rtems_task_variable_t *)tvp->next; if (_Thread_Is_executing(deleted)) { 4000bfe0: 25 10 00 63 sethi %hi(0x40018c00), %l2 /* * Free per task variable memory */ tvp = deleted->task_variables; deleted->task_variables = NULL; 4000bfe4: 10 80 00 18 b 4000c044 <_RTEMS_tasks_Delete_extension+0x6c> 4000bfe8: c0 26 61 7c clr [ %i1 + 0x17c ] 4000bfec: c4 04 20 10 ld [ %l0 + 0x10 ], %g2 <== NOT EXECUTED while (tvp) { next = (rtems_task_variable_t *)tvp->next; if (_Thread_Is_executing(deleted)) { 4000bff0: 80 a6 40 01 cmp %i1, %g1 <== NOT EXECUTED 4000bff4: 12 80 00 0c bne 4000c024 <_RTEMS_tasks_Delete_extension+0x4c> <== NOT EXECUTED 4000bff8: e2 04 00 00 ld [ %l0 ], %l1 <== NOT EXECUTED if (tvp->dtor) 4000bffc: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 4000c000: 22 80 00 06 be,a 4000c018 <_RTEMS_tasks_Delete_extension+0x40> <== NOT EXECUTED 4000c004: c4 04 20 04 ld [ %l0 + 4 ], %g2 <== NOT EXECUTED (*tvp->dtor)(*tvp->ptr); 4000c008: c2 04 20 04 ld [ %l0 + 4 ], %g1 <== NOT EXECUTED 4000c00c: 9f c0 80 00 call %g2 <== NOT EXECUTED 4000c010: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED *tvp->ptr = tvp->gval; 4000c014: c4 04 20 04 ld [ %l0 + 4 ], %g2 <== NOT EXECUTED 4000c018: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED 4000c01c: 10 80 00 07 b 4000c038 <_RTEMS_tasks_Delete_extension+0x60> <== NOT EXECUTED 4000c020: c2 20 80 00 st %g1, [ %g2 ] <== NOT EXECUTED } else { if (tvp->dtor) 4000c024: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 4000c028: 02 80 00 05 be 4000c03c <_RTEMS_tasks_Delete_extension+0x64> <== NOT EXECUTED 4000c02c: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED (*tvp->dtor)(tvp->tval); 4000c030: 9f c0 80 00 call %g2 <== NOT EXECUTED 4000c034: d0 04 20 0c ld [ %l0 + 0xc ], %o0 <== NOT EXECUTED } _Workspace_Free( tvp ); 4000c038: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 4000c03c: 7f ff ff e0 call 4000bfbc <_Workspace_Free> <== NOT EXECUTED 4000c040: a0 10 00 11 mov %l1, %l0 <== NOT EXECUTED * Free per task variable memory */ tvp = deleted->task_variables; deleted->task_variables = NULL; while (tvp) { 4000c044: 80 a4 20 00 cmp %l0, 0 4000c048: 12 bf ff e9 bne 4000bfec <_RTEMS_tasks_Delete_extension+0x14> 4000c04c: c2 04 a3 cc ld [ %l2 + 0x3cc ], %g1 /* * Free API specific memory */ (void) _Workspace_Free( deleted->API_Extensions[ THREAD_API_RTEMS ] ); 4000c050: 7f ff ff db call 4000bfbc <_Workspace_Free> 4000c054: d0 06 61 6c ld [ %i1 + 0x16c ], %o0 deleted->API_Extensions[ THREAD_API_RTEMS ] = NULL; 4000c058: c0 26 61 6c clr [ %i1 + 0x16c ] } 4000c05c: 81 c7 e0 08 ret 4000c060: 81 e8 00 00 restore 4000601c <_RTEMS_tasks_Initialize_user_tasks_body>: * * Output parameters: NONE */ void _RTEMS_tasks_Initialize_user_tasks_body( void ) { 4000601c: 9d e3 bf 90 save %sp, -112, %sp rtems_status_code return_value; rtems_initialization_tasks_table *user_tasks; rtems_api_configuration_table *api_configuration; api_configuration = _Configuration_Table->RTEMS_api_configuration; 40006020: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006024: c2 00 63 b0 ld [ %g1 + 0x3b0 ], %g1 ! 40018fb0 <_Configuration_Table> 40006028: c2 00 60 2c ld [ %g1 + 0x2c ], %g1 /* * NOTE: This is slightly different from the Ada implementation. */ user_tasks = api_configuration->User_initialization_tasks_table; 4000602c: d0 00 60 28 ld [ %g1 + 0x28 ], %o0 maximum = api_configuration->number_of_initialization_tasks; if ( !user_tasks || maximum == 0 ) 40006030: 80 a2 20 00 cmp %o0, 0 40006034: 02 80 00 25 be 400060c8 <_RTEMS_tasks_Initialize_user_tasks_body+0xac> 40006038: e4 00 60 24 ld [ %g1 + 0x24 ], %l2 4000603c: 80 a4 a0 00 cmp %l2, 0 40006040: 02 80 00 22 be 400060c8 <_RTEMS_tasks_Initialize_user_tasks_body+0xac> 40006044: a0 10 00 08 mov %o0, %l0 return; 40006048: a2 10 20 00 clr %l1 for ( index=0 ; index < maximum ; index++ ) { return_value = rtems_task_create( 4000604c: 10 80 00 1c b 400060bc <_RTEMS_tasks_Initialize_user_tasks_body+0xa0> 40006050: a6 07 bf f4 add %fp, -12, %l3 40006054: d6 04 20 14 ld [ %l0 + 0x14 ], %o3 40006058: d8 04 20 0c ld [ %l0 + 0xc ], %o4 4000605c: d2 04 20 08 ld [ %l0 + 8 ], %o1 40006060: d4 04 20 04 ld [ %l0 + 4 ], %o2 40006064: d0 04 00 00 ld [ %l0 ], %o0 40006068: 7f ff ff 34 call 40005d38 4000606c: a2 04 60 01 inc %l1 user_tasks[ index ].mode_set, user_tasks[ index ].attribute_set, &id ); if ( !rtems_is_status_successful( return_value ) ) 40006070: 80 a2 20 00 cmp %o0, 0 40006074: 22 80 00 07 be,a 40006090 <_RTEMS_tasks_Initialize_user_tasks_body+0x74> 40006078: d2 04 20 10 ld [ %l0 + 0x10 ], %o1 _Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, TRUE, return_value ); 4000607c: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED 40006080: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 40006084: 40 00 04 1f call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40006088: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED return_value = rtems_task_start( 4000608c: d2 04 20 10 ld [ %l0 + 0x10 ], %o1 <== NOT EXECUTED 40006090: d4 04 20 18 ld [ %l0 + 0x18 ], %o2 40006094: d0 07 bf f4 ld [ %fp + -12 ], %o0 40006098: 40 00 00 1b call 40006104 4000609c: a0 04 20 1c add %l0, 0x1c, %l0 id, user_tasks[ index ].entry_point, user_tasks[ index ].argument ); if ( !rtems_is_status_successful( return_value ) ) 400060a0: 80 a2 20 00 cmp %o0, 0 400060a4: 02 80 00 07 be 400060c0 <_RTEMS_tasks_Initialize_user_tasks_body+0xa4> 400060a8: 80 a4 40 12 cmp %l1, %l2 _Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, TRUE, return_value ); 400060ac: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED 400060b0: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 400060b4: 40 00 04 13 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 400060b8: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED maximum = api_configuration->number_of_initialization_tasks; if ( !user_tasks || maximum == 0 ) return; for ( index=0 ; index < maximum ; index++ ) { 400060bc: 80 a4 40 12 cmp %l1, %l2 400060c0: 12 bf ff e5 bne 40006054 <_RTEMS_tasks_Initialize_user_tasks_body+0x38> 400060c4: 9a 10 00 13 mov %l3, %o5 400060c8: 81 c7 e0 08 ret 400060cc: 81 e8 00 00 restore 40006c2c <_Rate_monotonic_Timeout>: void _Rate_monotonic_Timeout( Objects_Id id, void *ignored ) { 40006c2c: 9d e3 bf 90 save %sp, -112, %sp 40006c30: 11 10 00 75 sethi %hi(0x4001d400), %o0 40006c34: 92 10 00 18 mov %i0, %o1 40006c38: 90 12 20 48 or %o0, 0x48, %o0 40006c3c: 40 00 09 38 call 4000911c <_Objects_Get> 40006c40: 94 07 bf f4 add %fp, -12, %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 ) { 40006c44: c2 07 bf f4 ld [ %fp + -12 ], %g1 40006c48: 80 a0 60 00 cmp %g1, 0 40006c4c: 12 80 00 20 bne 40006ccc <_Rate_monotonic_Timeout+0xa0> 40006c50: b0 10 00 08 mov %o0, %i0 case OBJECTS_REMOTE: /* impossible */ case OBJECTS_ERROR: break; case OBJECTS_LOCAL: the_thread = the_period->owner; 40006c54: d0 02 20 50 ld [ %o0 + 0x50 ], %o0 if ( _States_Is_waiting_for_period( the_thread->current_state ) && 40006c58: 03 00 00 10 sethi %hi(0x4000), %g1 40006c5c: c4 02 20 10 ld [ %o0 + 0x10 ], %g2 40006c60: 80 88 80 01 btst %g2, %g1 40006c64: 22 80 00 0c be,a 40006c94 <_Rate_monotonic_Timeout+0x68> 40006c68: c2 06 20 38 ld [ %i0 + 0x38 ], %g1 40006c6c: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 40006c70: c2 06 20 08 ld [ %i0 + 8 ], %g1 40006c74: 80 a0 80 01 cmp %g2, %g1 40006c78: 32 80 00 07 bne,a 40006c94 <_Rate_monotonic_Timeout+0x68> 40006c7c: c2 06 20 38 ld [ %i0 + 0x38 ], %g1 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); 40006c80: 13 04 00 ff sethi %hi(0x1003fc00), %o1 40006c84: 40 00 0d 60 call 4000a204 <_Thread_Clear_state> 40006c88: 92 12 63 f8 or %o1, 0x3f8, %o1 ! 1003fff8 the_thread->Wait.id == the_period->Object.id ) { _Thread_Unblock( the_thread ); _Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length ); 40006c8c: 10 80 00 08 b 40006cac <_Rate_monotonic_Timeout+0x80> 40006c90: d2 06 20 4c ld [ %i0 + 0x4c ], %o1 } else if ( the_period->state == RATE_MONOTONIC_OWNER_IS_BLOCKING ) { 40006c94: 80 a0 60 01 cmp %g1, 1 40006c98: 12 80 00 08 bne 40006cb8 <_Rate_monotonic_Timeout+0x8c> 40006c9c: 82 10 20 04 mov 4, %g1 the_period->state = RATE_MONOTONIC_EXPIRED_WHILE_BLOCKING; _Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length ); 40006ca0: d2 06 20 4c ld [ %i0 + 0x4c ], %o1 <== NOT EXECUTED the_thread->Wait.id == the_period->Object.id ) { _Thread_Unblock( the_thread ); _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; 40006ca4: 82 10 20 03 mov 3, %g1 <== NOT EXECUTED 40006ca8: c2 26 20 38 st %g1, [ %i0 + 0x38 ] <== NOT EXECUTED _Watchdog_Insert_ticks( &the_period->Timer, the_period->next_length ); 40006cac: 7f ff ff d8 call 40006c0c <_Watchdog_Insert_ticks> 40006cb0: 90 06 20 10 add %i0, 0x10, %o0 40006cb4: 30 80 00 02 b,a 40006cbc <_Rate_monotonic_Timeout+0x90> } else the_period->state = RATE_MONOTONIC_EXPIRED; 40006cb8: c2 26 20 38 st %g1, [ %i0 + 0x38 ] */ RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void ) { RTEMS_COMPILER_MEMORY_BARRIER(); _Thread_Dispatch_disable_level -= 1; 40006cbc: 05 10 00 75 sethi %hi(0x4001d400), %g2 40006cc0: c2 00 a1 e0 ld [ %g2 + 0x1e0 ], %g1 ! 4001d5e0 <_Thread_Dispatch_disable_level> 40006cc4: 82 00 7f ff add %g1, -1, %g1 40006cc8: c2 20 a1 e0 st %g1, [ %g2 + 0x1e0 ] 40006ccc: 81 c7 e0 08 ret 40006cd0: 81 e8 00 00 restore 40008504 <_TOD_Set>: */ void _TOD_Set( const struct timespec *time ) { 40008504: 9d e3 bf 98 save %sp, -104, %sp rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40008508: 03 10 00 95 sethi %hi(0x40025400), %g1 4000850c: c4 00 60 00 ld [ %g1 ], %g2 40008510: 84 00 a0 01 inc %g2 40008514: c4 20 60 00 st %g2, [ %g1 ] _Thread_Disable_dispatch(); _TOD_Deactivate(); if ( time->tv_sec < _TOD_Seconds_since_epoch ) 40008518: 03 10 00 95 sethi %hi(0x40025400), %g1 4000851c: d2 06 00 00 ld [ %i0 ], %o1 40008520: c2 00 60 b8 ld [ %g1 + 0xb8 ], %g1 40008524: 80 a2 40 01 cmp %o1, %g1 40008528: 36 80 00 05 bge,a 4000853c <_TOD_Set+0x38> 4000852c: 92 22 40 01 sub %o1, %g1, %o1 _Watchdog_Adjust_seconds( WATCHDOG_BACKWARD, 40008530: 92 20 40 09 sub %g1, %o1, %o1 40008534: 10 80 00 03 b 40008540 <_TOD_Set+0x3c> 40008538: 90 10 20 01 mov 1, %o0 _TOD_Seconds_since_epoch - time->tv_sec ); else _Watchdog_Adjust_seconds( WATCHDOG_FORWARD, 4000853c: 90 10 20 00 clr %o0 40008540: 7f ff ff e9 call 400084e4 <_Watchdog_Adjust_seconds> 40008544: 01 00 00 00 nop time->tv_sec - _TOD_Seconds_since_epoch ); /* POSIX format TOD (timespec) */ _TOD_Now = *time; 40008548: c4 06 00 00 ld [ %i0 ], %g2 4000854c: 03 10 00 95 sethi %hi(0x40025400), %g1 40008550: c4 20 60 b8 st %g2, [ %g1 + 0xb8 ] ! 400254b8 <_TOD_Now> 40008554: c4 06 20 04 ld [ %i0 + 4 ], %g2 40008558: 82 10 60 b8 or %g1, 0xb8, %g1 4000855c: c4 20 60 04 st %g2, [ %g1 + 4 ] _TOD_Is_set = TRUE; 40008560: 84 10 20 01 mov 1, %g2 40008564: 03 10 00 95 sethi %hi(0x40025400), %g1 40008568: c4 20 60 3c st %g2, [ %g1 + 0x3c ] ! 4002543c <_TOD_Is_set> #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000856c: 05 10 00 95 sethi %hi(0x40025400), %g2 40008570: c2 00 a0 00 ld [ %g2 ], %g1 40008574: 82 00 7f ff add %g1, -1, %g1 40008578: c2 20 a0 00 st %g1, [ %g2 ] 4000857c: c2 00 a0 00 ld [ %g2 ], %g1 40008580: 80 a0 60 00 cmp %g1, 0 40008584: 12 80 00 04 bne 40008594 <_TOD_Set+0x90> 40008588: 01 00 00 00 nop _Thread_Dispatch(); 4000858c: 40 00 07 e1 call 4000a510 <_Thread_Dispatch> <== NOT EXECUTED 40008590: 81 e8 00 00 restore <== NOT EXECUTED 40008594: 81 c7 e0 08 ret 40008598: 81 e8 00 00 restore 40008924 <_Thread_Create_idle>: */ const char *_Thread_Idle_name = "IDLE"; void _Thread_Create_idle( void ) { 40008924: 9d e3 bf 80 save %sp, -128, %sp * This routine allocates an internal thread. */ RTEMS_INLINE_ROUTINE Thread_Control *_Thread_Internal_allocate( void ) { return (Thread_Control *) _Objects_Allocate( &_Thread_Internal_information ); 40008928: 11 10 00 64 sethi %hi(0x40019000), %o0 4000892c: 7f ff fa 22 call 400071b4 <_Objects_Allocate> 40008930: 90 12 20 80 or %o0, 0x80, %o0 ! 40019080 <_Thread_Internal_information> idle = (void *) _CPU_Thread_Idle_body; #else idle = (void *) _Thread_Idle_body; #endif if ( _CPU_Table.idle_task ) 40008934: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008938: c4 00 63 10 ld [ %g1 + 0x310 ], %g2 ! 40018f10 <_CPU_Table+0xc> * The entire workspace is zeroed during its initialization. Thus, all * fields not explicitly assigned were explicitly zeroed by * _Workspace_Initialization. */ _Thread_Idle = _Thread_Internal_allocate(); 4000893c: 03 10 00 64 sethi %hi(0x40019000), %g1 40008940: d0 20 60 d8 st %o0, [ %g1 + 0xd8 ] ! 400190d8 <_Thread_Idle> idle = (void *) _CPU_Thread_Idle_body; #else idle = (void *) _Thread_Idle_body; #endif if ( _CPU_Table.idle_task ) 40008944: 80 a0 a0 00 cmp %g2, 0 40008948: 03 10 00 22 sethi %hi(0x40008800), %g1 4000894c: 02 80 00 03 be 40008958 <_Thread_Create_idle+0x34> 40008950: b4 10 63 d4 or %g1, 0x3d4, %i2 ! 40008bd4 <_Thread_Idle_body> idle = _CPU_Table.idle_task; 40008954: b4 10 00 02 mov %g2, %i2 <== NOT EXECUTED idle_task_stack_size = _CPU_Table.idle_task_stack_size; 40008958: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000895c: d6 00 63 18 ld [ %g1 + 0x318 ], %o3 ! 40018f18 <_CPU_Table+0x14> if ( idle_task_stack_size < STACK_MINIMUM_SIZE ) 40008960: 80 a2 ef ff cmp %o3, 0xfff 40008964: 28 80 00 02 bleu,a 4000896c <_Thread_Create_idle+0x48> 40008968: 17 00 00 04 sethi %hi(0x1000), %o3 idle_task_stack_size = STACK_MINIMUM_SIZE; _Thread_Initialize( 4000896c: 03 10 00 61 sethi %hi(0x40018400), %g1 40008970: c2 00 60 48 ld [ %g1 + 0x48 ], %g1 ! 40018448 <_Thread_Idle_name> 40008974: 92 10 00 08 mov %o0, %o1 40008978: c2 23 a0 6c st %g1, [ %sp + 0x6c ] 4000897c: 82 10 20 01 mov 1, %g1 40008980: c0 23 a0 60 clr [ %sp + 0x60 ] 40008984: c2 23 a0 5c st %g1, [ %sp + 0x5c ] 40008988: c0 23 a0 64 clr [ %sp + 0x64 ] 4000898c: c0 23 a0 68 clr [ %sp + 0x68 ] 40008990: 11 10 00 64 sethi %hi(0x40019000), %o0 40008994: 94 10 20 00 clr %o2 40008998: 90 12 20 80 or %o0, 0x80, %o0 4000899c: 98 10 20 00 clr %o4 400089a0: 40 00 00 8e call 40008bd8 <_Thread_Initialize> 400089a4: 9a 10 20 ff mov 0xff, %o5 /* * WARNING!!! This is necessary to "kick" start the system and * MUST be done before _Thread_Start is invoked. */ _Thread_Heir = 400089a8: 03 10 00 64 sethi %hi(0x40019000), %g1 400089ac: c4 00 60 d8 ld [ %g1 + 0xd8 ], %g2 ! 400190d8 <_Thread_Idle> 400089b0: 03 10 00 63 sethi %hi(0x40018c00), %g1 400089b4: c4 20 63 cc st %g2, [ %g1 + 0x3cc ] ! 40018fcc <_Thread_Executing> 400089b8: 03 10 00 63 sethi %hi(0x40018c00), %g1 _Thread_Executing = _Thread_Idle; _Thread_Start( 400089bc: b0 10 00 02 mov %g2, %i0 /* * WARNING!!! This is necessary to "kick" start the system and * MUST be done before _Thread_Start is invoked. */ _Thread_Heir = 400089c0: c4 20 63 a4 st %g2, [ %g1 + 0x3a4 ] _Thread_Executing = _Thread_Idle; _Thread_Start( 400089c4: b2 10 20 00 clr %i1 400089c8: b6 10 20 00 clr %i3 400089cc: 40 00 03 d8 call 4000992c <_Thread_Start> 400089d0: 99 e8 20 00 restore %g0, 0, %o4 400089d4: 01 00 00 00 nop 400089d8 <_Thread_Delay_ended>: void _Thread_Delay_ended( Objects_Id id, void *ignored ) { 400089d8: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 400089dc: 92 96 20 00 orcc %i0, 0, %o1 400089e0: 12 80 00 0a bne 40008a08 <_Thread_Delay_ended+0x30> 400089e4: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400089e8: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400089ec: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400089f0: 84 00 a0 01 inc %g2 <== NOT EXECUTED 400089f4: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] <== NOT EXECUTED Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 400089f8: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400089fc: d0 00 63 cc ld [ %g1 + 0x3cc ], %o0 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40008a00: 10 80 00 19 b 40008a64 <_Thread_Delay_ended+0x8c> <== NOT EXECUTED 40008a04: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); 40008a08: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40008a0c: 80 a0 a0 04 cmp %g2, 4 40008a10: 18 80 00 06 bgu 40008a28 <_Thread_Delay_ended+0x50> 40008a14: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40008a18: 83 32 60 1b srl %o1, 0x1b, %g1 40008a1c: 80 a0 60 01 cmp %g1, 1 40008a20: 02 80 00 05 be 40008a34 <_Thread_Delay_ended+0x5c> 40008a24: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40008a28: 90 10 20 00 clr %o0 <== NOT EXECUTED 40008a2c: 10 80 00 0e b 40008a64 <_Thread_Delay_ended+0x8c> <== NOT EXECUTED 40008a30: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40008a34: 83 28 a0 02 sll %g2, 2, %g1 40008a38: 05 10 00 63 sethi %hi(0x40018c00), %g2 40008a3c: 84 10 a2 50 or %g2, 0x250, %g2 ! 40018e50 <_Objects_Information_table> 40008a40: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40008a44: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40008a48: 80 a2 20 00 cmp %o0, 0 40008a4c: 12 80 00 04 bne 40008a5c <_Thread_Delay_ended+0x84> 40008a50: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40008a54: 10 80 00 04 b 40008a64 <_Thread_Delay_ended+0x8c> <== NOT EXECUTED 40008a58: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40008a5c: 7f ff fb 1a call 400076c4 <_Objects_Get> 40008a60: 94 07 bf f4 add %fp, -12, %o2 Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40008a64: c2 07 bf f4 ld [ %fp + -12 ], %g1 40008a68: 80 a0 60 00 cmp %g1, 0 40008a6c: 12 80 00 08 bne 40008a8c <_Thread_Delay_ended+0xb4> 40008a70: 13 04 00 ff sethi %hi(0x1003fc00), %o1 RTEMS_INLINE_ROUTINE void _Thread_Unblock ( Thread_Control *the_thread ) { _Thread_Clear_state( the_thread, STATES_BLOCKED ); 40008a74: 7f ff ff 4e call 400087ac <_Thread_Clear_state> 40008a78: 92 12 63 f8 or %o1, 0x3f8, %o1 ! 1003fff8 */ RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void ) { RTEMS_COMPILER_MEMORY_BARRIER(); _Thread_Dispatch_disable_level -= 1; 40008a7c: 05 10 00 63 sethi %hi(0x40018c00), %g2 40008a80: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 40008a84: 82 00 7f ff add %g1, -1, %g1 40008a88: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 40008a8c: 81 c7 e0 08 ret 40008a90: 81 e8 00 00 restore 4000d328 <_Thread_Evaluate_mode>: boolean _Thread_Evaluate_mode( void ) { Thread_Control *executing; executing = _Thread_Executing; 4000d328: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000d32c: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> if ( !_States_Is_ready( executing->current_state ) || 4000d330: c2 00 a0 10 ld [ %g2 + 0x10 ], %g1 4000d334: 80 a0 60 00 cmp %g1, 0 4000d338: 32 80 00 0b bne,a 4000d364 <_Thread_Evaluate_mode+0x3c> 4000d33c: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED 4000d340: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000d344: c2 00 63 a4 ld [ %g1 + 0x3a4 ], %g1 ! 40018fa4 <_Thread_Heir> 4000d348: 80 a0 80 01 cmp %g2, %g1 4000d34c: 02 80 00 0b be 4000d378 <_Thread_Evaluate_mode+0x50> 4000d350: 01 00 00 00 nop 4000d354: c2 00 a0 7c ld [ %g2 + 0x7c ], %g1 4000d358: 80 a0 60 00 cmp %g1, 0 4000d35c: 02 80 00 07 be 4000d378 <_Thread_Evaluate_mode+0x50> 4000d360: 84 10 20 01 mov 1, %g2 ( !_Thread_Is_heir( executing ) && executing->is_preemptible ) ) { _Context_Switch_necessary = TRUE; 4000d364: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000d368: 90 10 20 01 mov 1, %o0 4000d36c: c4 20 63 dc st %g2, [ %g1 + 0x3dc ] 4000d370: 81 c3 e0 08 retl 4000d374: 01 00 00 00 nop return TRUE; } return FALSE; } 4000d378: 81 c3 e0 08 retl 4000d37c: 90 10 20 00 clr %o0 ! 0 4000d380 <_Thread_Handler>: * * Output parameters: NONE */ void _Thread_Handler( void ) { 4000d380: 9d e3 bf 98 save %sp, -104, %sp #endif #if defined(__USE__MAIN__) extern void _main(void); #endif executing = _Thread_Executing; 4000d384: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000d388: f4 00 63 cc ld [ %g1 + 0x3cc ], %i2 ! 40018fcc <_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(); 4000d38c: 3f 10 00 34 sethi %hi(0x4000d000), %i7 4000d390: be 17 e3 80 or %i7, 0x380, %i7 ! 4000d380 <_Thread_Handler> * have to put level into a register for those cpu's that use * inline asm here */ level = executing->Start.isr_level; _ISR_Set_level(level); 4000d394: d0 06 a0 c4 ld [ %i2 + 0xc4 ], %o0 4000d398: 7f ff d2 6d call 40001d4c 4000d39c: 91 2a 20 08 sll %o0, 8, %o0 #if defined(__USE_INIT_FINI__) || defined(__USE__MAIN__) doneCons = doneConstructors; 4000d3a0: 05 10 00 63 sethi %hi(0x40018c00), %g2 doneConstructors = 1; 4000d3a4: 82 10 20 01 mov 1, %g1 level = executing->Start.isr_level; _ISR_Set_level(level); #if defined(__USE_INIT_FINI__) || defined(__USE__MAIN__) doneCons = doneConstructors; 4000d3a8: f2 08 a1 0c ldub [ %g2 + 0x10c ], %i1 * 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 ); 4000d3ac: 90 10 00 1a mov %i2, %o0 4000d3b0: 7f ff f2 17 call 40009c0c <_User_extensions_Thread_begin> 4000d3b4: c2 28 a1 0c stb %g1, [ %g2 + 0x10c ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000d3b8: 05 10 00 63 sethi %hi(0x40018c00), %g2 4000d3bc: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 4000d3c0: 82 00 7f ff add %g1, -1, %g1 4000d3c4: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 4000d3c8: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 4000d3cc: 80 a0 60 00 cmp %g1, 0 4000d3d0: 12 80 00 05 bne 4000d3e4 <_Thread_Handler+0x64> 4000d3d4: 83 2e 60 18 sll %i1, 0x18, %g1 _Thread_Dispatch(); 4000d3d8: 7f ff ed af call 40008a94 <_Thread_Dispatch> 4000d3dc: 01 00 00 00 nop /* * _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) */ 4000d3e0: 83 2e 60 18 sll %i1, 0x18, %g1 4000d3e4: 80 a0 60 00 cmp %g1, 0 4000d3e8: 32 80 00 05 bne,a 4000d3fc <_Thread_Handler+0x7c> 4000d3ec: c2 06 a0 ac ld [ %i2 + 0xac ], %g1 _init (); 4000d3f0: 40 00 2a b0 call 40017eb0 <_init> 4000d3f4: 01 00 00 00 nop #if defined(__USE__MAIN__) if (!doneCons && _main) __main (); #endif switch ( executing->Start.prototype ) { 4000d3f8: c2 06 a0 ac ld [ %i2 + 0xac ], %g1 4000d3fc: 80 a0 60 01 cmp %g1, 1 4000d400: 22 80 00 0d be,a 4000d434 <_Thread_Handler+0xb4> 4000d404: c2 06 a0 a8 ld [ %i2 + 0xa8 ], %g1 <== NOT EXECUTED 4000d408: 2a 80 00 09 bcs,a 4000d42c <_Thread_Handler+0xac> 4000d40c: c2 06 a0 a8 ld [ %i2 + 0xa8 ], %g1 4000d410: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 4000d414: 02 80 00 0d be 4000d448 <_Thread_Handler+0xc8> <== NOT EXECUTED 4000d418: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 4000d41c: 12 80 00 14 bne 4000d46c <_Thread_Handler+0xec> <== NOT EXECUTED 4000d420: 90 10 00 1a mov %i2, %o0 <== NOT EXECUTED executing->Start.pointer_argument, executing->Start.numeric_argument ); break; case THREAD_START_BOTH_NUMERIC_FIRST: executing->Wait.return_argument = 4000d424: 10 80 00 0c b 4000d454 <_Thread_Handler+0xd4> <== NOT EXECUTED 4000d428: c2 06 a0 a8 ld [ %i2 + 0xa8 ], %g1 <== NOT EXECUTED __main (); #endif switch ( executing->Start.prototype ) { case THREAD_START_NUMERIC: executing->Wait.return_argument = 4000d42c: 10 80 00 03 b 4000d438 <_Thread_Handler+0xb8> 4000d430: d0 06 a0 b4 ld [ %i2 + 0xb4 ], %o0 (*(Thread_Entry_numeric) executing->Start.entry_point)( executing->Start.numeric_argument ); break; case THREAD_START_POINTER: executing->Wait.return_argument = 4000d434: d0 06 a0 b0 ld [ %i2 + 0xb0 ], %o0 <== NOT EXECUTED 4000d438: 9f c0 40 00 call %g1 4000d43c: 01 00 00 00 nop executing->Start.pointer_argument, executing->Start.numeric_argument ); break; case THREAD_START_BOTH_NUMERIC_FIRST: executing->Wait.return_argument = 4000d440: 10 80 00 0a b 4000d468 <_Thread_Handler+0xe8> 4000d444: d0 26 a0 28 st %o0, [ %i2 + 0x28 ] (*(Thread_Entry_pointer) executing->Start.entry_point)( executing->Start.pointer_argument ); break; case THREAD_START_BOTH_POINTER_FIRST: executing->Wait.return_argument = 4000d448: c2 06 a0 a8 ld [ %i2 + 0xa8 ], %g1 <== NOT EXECUTED 4000d44c: 10 80 00 04 b 4000d45c <_Thread_Handler+0xdc> <== NOT EXECUTED 4000d450: d0 1e a0 b0 ldd [ %i2 + 0xb0 ], %o0 <== NOT EXECUTED executing->Start.pointer_argument, executing->Start.numeric_argument ); break; case THREAD_START_BOTH_NUMERIC_FIRST: executing->Wait.return_argument = 4000d454: d0 06 a0 b4 ld [ %i2 + 0xb4 ], %o0 <== NOT EXECUTED 4000d458: d2 06 a0 b0 ld [ %i2 + 0xb0 ], %o1 <== NOT EXECUTED 4000d45c: 9f c0 40 00 call %g1 <== NOT EXECUTED 4000d460: 01 00 00 00 nop <== NOT EXECUTED 4000d464: d0 26 a0 28 st %o0, [ %i2 + 0x28 ] <== NOT EXECUTED * 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 ); 4000d468: 90 10 00 1a mov %i2, %o0 4000d46c: 7f ff f2 0b call 40009c98 <_User_extensions_Thread_exitted> 4000d470: b0 10 20 00 clr %i0 _Internal_error_Occurred( 4000d474: b2 10 20 01 mov 1, %i1 4000d478: 7f ff e7 22 call 40007100 <_Internal_error_Occurred> 4000d47c: 95 e8 20 06 restore %g0, 6, %o2 4000d480: 01 00 00 00 nop 40008d94 <_Thread_Handler_initialization>: void _Thread_Handler_initialization( uint32_t ticks_per_timeslice, uint32_t maximum_extensions, uint32_t maximum_proxies ) { 40008d94: 9d e3 bf 90 save %sp, -112, %sp /* * BOTH stacks hooks must be set or both must be NULL. * Do not allow mixture. */ if ( !( ( _CPU_Table.stack_allocate_hook == 0 ) 40008d98: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008d9c: 82 10 63 04 or %g1, 0x304, %g1 ! 40018f04 <_CPU_Table> 40008da0: c4 00 60 20 ld [ %g1 + 0x20 ], %g2 40008da4: c2 00 60 24 ld [ %g1 + 0x24 ], %g1 40008da8: 80 a0 00 02 cmp %g0, %g2 40008dac: 84 60 3f ff subx %g0, -1, %g2 40008db0: 80 a0 00 01 cmp %g0, %g1 40008db4: 82 60 3f ff subx %g0, -1, %g1 40008db8: 80 a0 80 01 cmp %g2, %g1 40008dbc: 02 80 00 07 be 40008dd8 <_Thread_Handler_initialization+0x44> 40008dc0: 03 10 00 63 sethi %hi(0x40018c00), %g1 == ( _CPU_Table.stack_free_hook == 0 ) ) ) _Internal_error_Occurred( 40008dc4: 90 10 20 00 clr %o0 <== NOT EXECUTED 40008dc8: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 40008dcc: 7f ff f8 cd call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40008dd0: 94 10 20 0f mov 0xf, %o2 <== NOT EXECUTED INTERNAL_ERROR_CORE, TRUE, INTERNAL_ERROR_BAD_STACK_HOOK ); _Context_Switch_necessary = FALSE; 40008dd4: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008dd8: c0 20 63 dc clr [ %g1 + 0x3dc ] ! 40018fdc <_Context_Switch_necessary> _Thread_Executing = NULL; 40008ddc: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008de0: c0 20 63 cc clr [ %g1 + 0x3cc ] ! 40018fcc <_Thread_Executing> _Thread_Heir = NULL; 40008de4: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008de8: c0 20 63 a4 clr [ %g1 + 0x3a4 ] ! 40018fa4 <_Thread_Heir> #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) _Thread_Allocated_fp = NULL; #endif _Thread_Do_post_task_switch_extension = 0; 40008dec: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008df0: c0 20 63 bc clr [ %g1 + 0x3bc ] ! 40018fbc <_Thread_Do_post_task_switch_extension> _Thread_Maximum_extensions = maximum_extensions; 40008df4: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008df8: f2 20 63 b8 st %i1, [ %g1 + 0x3b8 ] ! 40018fb8 <_Thread_Maximum_extensions> _Thread_Ticks_per_timeslice = ticks_per_timeslice; 40008dfc: 03 10 00 63 sethi %hi(0x40018c00), %g1 _Thread_Ready_chain = (Chain_Control *) _Workspace_Allocate_or_fatal_error( 40008e00: 90 10 2c 00 mov 0xc00, %o0 40008e04: 40 00 04 ac call 4000a0b4 <_Workspace_Allocate_or_fatal_error> 40008e08: f0 20 62 48 st %i0, [ %g1 + 0x248 ] 40008e0c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008e10: 84 10 00 08 mov %o0, %g2 40008e14: d0 20 62 44 st %o0, [ %g1 + 0x244 ] (PRIORITY_MAXIMUM + 1) * sizeof(Chain_Control) ); for ( index=0; index <= PRIORITY_MAXIMUM ; index++ ) 40008e18: 86 02 2c 00 add %o0, 0xc00, %g3 */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 40008e1c: 82 00 a0 04 add %g2, 4, %g1 the_chain->permanent_null = NULL; 40008e20: c0 20 a0 04 clr [ %g2 + 4 ] the_chain->last = _Chain_Head(the_chain); 40008e24: 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); 40008e28: c2 20 80 00 st %g1, [ %g2 ] the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 40008e2c: 84 00 a0 0c add %g2, 0xc, %g2 40008e30: 80 a0 80 03 cmp %g2, %g3 40008e34: 12 bf ff fb bne 40008e20 <_Thread_Handler_initialization+0x8c> 40008e38: 82 00 a0 04 add %g2, 4, %g1 /* * Initialize this class of objects. */ _Objects_Initialize_information( 40008e3c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008e40: c2 00 63 f8 ld [ %g1 + 0x3f8 ], %g1 ! 40018ff8 <_System_state_Is_multiprocessing> 40008e44: 96 10 20 02 mov 2, %o3 40008e48: 80 a0 00 01 cmp %g0, %g1 40008e4c: 82 10 20 08 mov 8, %g1 40008e50: 96 42 ff ff addx %o3, -1, %o3 40008e54: c2 23 a0 5c st %g1, [ %sp + 0x5c ] 40008e58: 11 10 00 64 sethi %hi(0x40019000), %o0 40008e5c: 92 10 20 01 mov 1, %o1 40008e60: 90 12 20 80 or %o0, 0x80, %o0 40008e64: 94 10 20 01 mov 1, %o2 40008e68: 98 10 21 80 mov 0x180, %o4 40008e6c: 7f ff fa 3b call 40007758 <_Objects_Initialize_information> 40008e70: 9a 10 20 01 mov 1, %o5 FALSE, /* TRUE if this is a global object class */ NULL /* Proxy extraction support callout */ #endif ); } 40008e74: 81 c7 e0 08 ret 40008e78: 81 e8 00 00 restore 40008bd8 <_Thread_Initialize>: Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) { 40008bd8: 9d e3 bf 98 save %sp, -104, %sp /* * Initialize the Ada self pointer */ the_thread->rtems_ada_self = NULL; 40008bdc: c0 26 60 80 clr [ %i1 + 0x80 ] /* * Allocate and Initialize the stack for this thread. */ if ( !stack_area ) { 40008be0: 80 a6 a0 00 cmp %i2, 0 40008be4: 12 80 00 10 bne 40008c24 <_Thread_Initialize+0x4c> 40008be8: e0 07 a0 60 ld [ %fp + 0x60 ], %l0 if ( !_Stack_Is_enough( stack_size ) ) 40008bec: 80 a6 ef ff cmp %i3, 0xfff 40008bf0: 08 80 00 03 bleu 40008bfc <_Thread_Initialize+0x24> 40008bf4: 13 00 00 04 sethi %hi(0x1000), %o1 40008bf8: 92 10 00 1b mov %i3, %o1 actual_stack_size = STACK_MINIMUM_SIZE; else actual_stack_size = stack_size; actual_stack_size = _Thread_Stack_Allocate( the_thread, actual_stack_size ); 40008bfc: 40 00 03 13 call 40009848 <_Thread_Stack_Allocate> 40008c00: 90 10 00 19 mov %i1, %o0 if ( !actual_stack_size || actual_stack_size < stack_size ) 40008c04: 80 a2 20 00 cmp %o0, 0 40008c08: 02 80 00 1f be 40008c84 <_Thread_Initialize+0xac> 40008c0c: 80 a2 00 1b cmp %o0, %i3 40008c10: 0a 80 00 1d bcs 40008c84 <_Thread_Initialize+0xac> 40008c14: 82 10 20 01 mov 1, %g1 return FALSE; /* stack allocation failed */ stack = the_thread->Start.stack; 40008c18: f4 06 60 d8 ld [ %i1 + 0xd8 ], %i2 the_thread->Start.core_allocated_stack = TRUE; 40008c1c: 10 80 00 04 b 40008c2c <_Thread_Initialize+0x54> 40008c20: c2 26 60 cc st %g1, [ %i1 + 0xcc ] } else { stack = stack_area; actual_stack_size = stack_size; the_thread->Start.core_allocated_stack = FALSE; 40008c24: c0 26 60 cc clr [ %i1 + 0xcc ] <== NOT EXECUTED 40008c28: 90 10 00 1b mov %i3, %o0 <== NOT EXECUTED /* * Allocate the extensions area for this thread */ if ( _Thread_Maximum_extensions ) { 40008c2c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008c30: d2 00 63 b8 ld [ %g1 + 0x3b8 ], %o1 ! 40018fb8 <_Thread_Maximum_extensions> Stack_Control *the_stack, void *starting_address, size_t size ) { the_stack->area = starting_address; 40008c34: f4 26 60 d4 st %i2, [ %i1 + 0xd4 ] the_stack->size = size; 40008c38: d0 26 60 d0 st %o0, [ %i1 + 0xd0 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40008c3c: c0 26 60 50 clr [ %i1 + 0x50 ] the_watchdog->routine = routine; 40008c40: c0 26 60 64 clr [ %i1 + 0x64 ] the_watchdog->id = id; 40008c44: c0 26 60 68 clr [ %i1 + 0x68 ] the_watchdog->user_data = user_data; 40008c48: c0 26 60 6c clr [ %i1 + 0x6c ] /* * Clear the libc reent hook. */ the_thread->libc_reent = NULL; 40008c4c: c0 26 61 68 clr [ %i1 + 0x168 ] /* * Allocate the extensions area for this thread */ if ( _Thread_Maximum_extensions ) { 40008c50: 80 a2 60 00 cmp %o1, 0 40008c54: 02 80 00 0e be 40008c8c <_Thread_Initialize+0xb4> 40008c58: b6 10 20 00 clr %i3 RTEMS_INLINE_ROUTINE void *_Workspace_Allocate( size_t size ) { return _Heap_Allocate( &_Workspace_Area, size ); 40008c5c: 92 02 60 01 inc %o1 40008c60: 11 10 00 63 sethi %hi(0x40018c00), %o0 40008c64: 93 2a 60 02 sll %o1, 2, %o1 40008c68: 7f ff f7 fb call 40006c54 <_Heap_Allocate> 40008c6c: 90 12 23 3c or %o0, 0x33c, %o0 extensions_area = _Workspace_Allocate( (_Thread_Maximum_extensions + 1) * sizeof( void * ) ); if ( !extensions_area ) { 40008c70: b6 92 20 00 orcc %o0, 0, %i3 40008c74: 12 80 00 07 bne 40008c90 <_Thread_Initialize+0xb8> 40008c78: 80 a6 e0 00 cmp %i3, 0 #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( fp_area ) (void) _Workspace_Free( fp_area ); #endif _Thread_Stack_Free( the_thread ); 40008c7c: 40 00 03 0a call 400098a4 <_Thread_Stack_Free> <== NOT EXECUTED 40008c80: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 40008c84: 81 c7 e0 08 ret 40008c88: 91 e8 20 00 restore %g0, 0, %o0 * create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) { 40008c8c: 80 a6 e0 00 cmp %i3, 0 40008c90: 02 80 00 0d be 40008cc4 <_Thread_Initialize+0xec> 40008c94: f6 26 61 78 st %i3, [ %i1 + 0x178 ] int i; for ( i = 0; i < (_Thread_Maximum_extensions + 1); i++ ) 40008c98: 03 10 00 63 sethi %hi(0x40018c00), %g1 40008c9c: c2 00 63 b8 ld [ %g1 + 0x3b8 ], %g1 ! 40018fb8 <_Thread_Maximum_extensions> 40008ca0: 86 10 20 00 clr %g3 40008ca4: 10 80 00 05 b 40008cb8 <_Thread_Initialize+0xe0> 40008ca8: 88 00 60 01 add %g1, 1, %g4 the_thread->extensions[i] = NULL; 40008cac: 83 28 e0 02 sll %g3, 2, %g1 * call. */ if ( the_thread->extensions ) { int i; for ( i = 0; i < (_Thread_Maximum_extensions + 1); i++ ) 40008cb0: 86 00 e0 01 inc %g3 the_thread->extensions[i] = NULL; 40008cb4: c0 20 80 01 clr [ %g2 + %g1 ] * call. */ if ( the_thread->extensions ) { int i; for ( i = 0; i < (_Thread_Maximum_extensions + 1); i++ ) 40008cb8: 80 a0 c0 04 cmp %g3, %g4 40008cbc: 32 bf ff fc bne,a 40008cac <_Thread_Initialize+0xd4> 40008cc0: c4 06 61 78 ld [ %i1 + 0x178 ], %g2 /* * General initialization */ the_thread->Start.is_preemptible = is_preemptible; 40008cc4: c2 07 a0 5c ld [ %fp + 0x5c ], %g1 the_thread->Start.budget_algorithm = budget_algorithm; 40008cc8: e0 26 60 bc st %l0, [ %i1 + 0xbc ] /* * General initialization */ the_thread->Start.is_preemptible = is_preemptible; 40008ccc: c2 26 60 b8 st %g1, [ %i1 + 0xb8 ] the_thread->Start.budget_algorithm = budget_algorithm; the_thread->Start.budget_callout = budget_callout; 40008cd0: c2 07 a0 64 ld [ %fp + 0x64 ], %g1 switch ( budget_algorithm ) { 40008cd4: 80 a4 20 02 cmp %l0, 2 40008cd8: 12 80 00 05 bne 40008cec <_Thread_Initialize+0x114> 40008cdc: c2 26 60 c0 st %g1, [ %i1 + 0xc0 ] case THREAD_CPU_BUDGET_ALGORITHM_NONE: case THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE: break; case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE: the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice; 40008ce0: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008ce4: c2 00 62 48 ld [ %g1 + 0x248 ], %g1 ! 40018e48 <_Thread_Ticks_per_timeslice> <== NOT EXECUTED 40008ce8: c2 26 60 84 st %g1, [ %i1 + 0x84 ] <== NOT EXECUTED break; case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: break; } the_thread->Start.isr_level = isr_level; 40008cec: c2 07 a0 68 ld [ %fp + 0x68 ], %g1 the_thread->current_state = STATES_DORMANT; the_thread->Wait.queue = NULL; 40008cf0: c0 26 60 44 clr [ %i1 + 0x44 ] break; case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: break; } the_thread->Start.isr_level = isr_level; 40008cf4: c2 26 60 c4 st %g1, [ %i1 + 0xc4 ] the_thread->current_state = STATES_DORMANT; 40008cf8: 82 10 20 01 mov 1, %g1 the_thread->Wait.queue = NULL; the_thread->resource_count = 0; 40008cfc: c0 26 60 1c clr [ %i1 + 0x1c ] break; } the_thread->Start.isr_level = isr_level; the_thread->current_state = STATES_DORMANT; 40008d00: c2 26 60 10 st %g1, [ %i1 + 0x10 ] the_thread->Wait.queue = NULL; the_thread->resource_count = 0; the_thread->suspend_count = 0; 40008d04: c0 26 60 70 clr [ %i1 + 0x70 ] the_thread->real_priority = priority; 40008d08: fa 26 60 18 st %i5, [ %i1 + 0x18 ] the_thread->Start.initial_priority = priority; 40008d0c: fa 26 60 c8 st %i5, [ %i1 + 0xc8 ] _Thread_Set_priority( the_thread, priority ); 40008d10: 92 10 00 1d mov %i5, %o1 40008d14: 40 00 02 2c call 400095c4 <_Thread_Set_priority> 40008d18: 90 10 00 19 mov %i1, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 40008d1c: c4 06 60 08 ld [ %i1 + 8 ], %g2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40008d20: c6 16 20 10 lduh [ %i0 + 0x10 ], %g3 /* * Initialize the CPU usage statistics */ #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS the_thread->cpu_time_used.tv_sec = 0; 40008d24: c0 26 60 90 clr [ %i1 + 0x90 ] 40008d28: 03 00 00 3f sethi %hi(0xfc00), %g1 40008d2c: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40008d30: 82 08 80 01 and %g2, %g1, %g1 40008d34: 80 a0 40 03 cmp %g1, %g3 40008d38: 18 80 00 05 bgu 40008d4c <_Thread_Initialize+0x174> 40008d3c: c0 26 60 94 clr [ %i1 + 0x94 ] information->local_table[ index ] = the_object; 40008d40: c4 06 20 20 ld [ %i0 + 0x20 ], %g2 40008d44: 83 28 60 02 sll %g1, 2, %g1 40008d48: f2 20 80 01 st %i1, [ %g2 + %g1 ] if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 40008d4c: c2 07 a0 6c ld [ %fp + 0x6c ], %g1 /* * Invoke create extensions */ if ( !_User_extensions_Thread_create( the_thread ) ) { 40008d50: 90 10 00 19 mov %i1, %o0 40008d54: c2 26 60 0c st %g1, [ %i1 + 0xc ] 40008d58: 40 00 03 e1 call 40009cdc <_User_extensions_Thread_create> 40008d5c: b0 10 20 01 mov 1, %i0 40008d60: 80 a2 20 00 cmp %o0, 0 40008d64: 12 80 00 0a bne 40008d8c <_Thread_Initialize+0x1b4> 40008d68: 80 a6 e0 00 cmp %i3, 0 if ( extensions_area ) 40008d6c: 02 80 00 05 be 40008d80 <_Thread_Initialize+0x1a8> 40008d70: 11 10 00 63 sethi %hi(0x40018c00), %o0 RTEMS_INLINE_ROUTINE boolean _Workspace_Free( void *block ) { return _Heap_Free( &_Workspace_Area, block ); 40008d74: 92 10 00 1b mov %i3, %o1 <== NOT EXECUTED 40008d78: 7f ff f7 de call 40006cf0 <_Heap_Free> <== NOT EXECUTED 40008d7c: 90 12 23 3c or %o0, 0x33c, %o0 <== NOT EXECUTED #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( fp_area ) (void) _Workspace_Free( fp_area ); #endif _Thread_Stack_Free( the_thread ); 40008d80: 90 10 00 19 mov %i1, %o0 40008d84: 40 00 02 c8 call 400098a4 <_Thread_Stack_Free> 40008d88: b0 10 20 00 clr %i0 return FALSE; } return TRUE; } 40008d8c: 81 c7 e0 08 ret 40008d90: 81 e8 00 00 restore 4000d868 <_Thread_Reset>: void _Thread_Reset( Thread_Control *the_thread, void *pointer_argument, uint32_t numeric_argument ) { 4000d868: 9d e3 bf 98 save %sp, -104, %sp the_thread->resource_count = 0; the_thread->suspend_count = 0; the_thread->is_preemptible = the_thread->Start.is_preemptible; 4000d86c: c2 06 20 b8 ld [ %i0 + 0xb8 ], %g1 the_thread->budget_algorithm = the_thread->Start.budget_algorithm; 4000d870: c4 06 20 bc ld [ %i0 + 0xbc ], %g2 the_thread->budget_callout = the_thread->Start.budget_callout; 4000d874: c6 06 20 c0 ld [ %i0 + 0xc0 ], %g3 uint32_t numeric_argument ) { the_thread->resource_count = 0; the_thread->suspend_count = 0; the_thread->is_preemptible = the_thread->Start.is_preemptible; 4000d878: c2 26 20 7c st %g1, [ %i0 + 0x7c ] the_thread->budget_algorithm = the_thread->Start.budget_algorithm; the_thread->budget_callout = the_thread->Start.budget_callout; 4000d87c: c4 3e 20 88 std %g2, [ %i0 + 0x88 ] the_thread->Start.pointer_argument = pointer_argument; 4000d880: f2 26 20 b0 st %i1, [ %i0 + 0xb0 ] the_thread->Start.numeric_argument = numeric_argument; 4000d884: f4 26 20 b4 st %i2, [ %i0 + 0xb4 ] Thread_Control *the_thread, void *pointer_argument, uint32_t numeric_argument ) { the_thread->resource_count = 0; 4000d888: c0 26 20 1c clr [ %i0 + 0x1c ] the_thread->suspend_count = 0; 4000d88c: c0 26 20 70 clr [ %i0 + 0x70 ] the_thread->budget_callout = the_thread->Start.budget_callout; the_thread->Start.pointer_argument = pointer_argument; the_thread->Start.numeric_argument = numeric_argument; if ( !_Thread_queue_Extract_with_proxy( the_thread ) ) { 4000d890: 7f ff f1 f4 call 4000a060 <_Thread_queue_Extract_with_proxy> 4000d894: 90 10 00 18 mov %i0, %o0 4000d898: 80 a2 20 00 cmp %o0, 0 4000d89c: 32 80 00 09 bne,a 4000d8c0 <_Thread_Reset+0x58> 4000d8a0: f2 06 20 c8 ld [ %i0 + 0xc8 ], %i1 if ( _Watchdog_Is_active( &the_thread->Timer ) ) 4000d8a4: c2 06 20 50 ld [ %i0 + 0x50 ], %g1 4000d8a8: 80 a0 60 02 cmp %g1, 2 4000d8ac: 32 80 00 05 bne,a 4000d8c0 <_Thread_Reset+0x58> 4000d8b0: f2 06 20 c8 ld [ %i0 + 0xc8 ], %i1 (void) _Watchdog_Remove( &the_thread->Timer ); 4000d8b4: 7f ff f5 2c call 4000ad64 <_Watchdog_Remove> <== NOT EXECUTED 4000d8b8: 90 06 20 48 add %i0, 0x48, %o0 <== NOT EXECUTED } if ( the_thread->current_priority != the_thread->Start.initial_priority ) { 4000d8bc: f2 06 20 c8 ld [ %i0 + 0xc8 ], %i1 <== NOT EXECUTED 4000d8c0: c2 06 20 14 ld [ %i0 + 0x14 ], %g1 4000d8c4: 80 a0 40 19 cmp %g1, %i1 4000d8c8: 02 80 00 05 be 4000d8dc <_Thread_Reset+0x74> 4000d8cc: 01 00 00 00 nop the_thread->real_priority = the_thread->Start.initial_priority; 4000d8d0: f2 26 20 18 st %i1, [ %i0 + 0x18 ] _Thread_Set_priority( the_thread, the_thread->Start.initial_priority ); 4000d8d4: 7f ff f2 a9 call 4000a378 <_Thread_Set_priority> 4000d8d8: 81 e8 00 00 restore 4000d8dc: 81 c7 e0 08 ret 4000d8e0: 81 e8 00 00 restore 4000ca18 <_Thread_Reset_timeslice>: * ready chain * select heir */ void _Thread_Reset_timeslice( void ) { 4000ca18: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; Thread_Control *executing; Chain_Control *ready; executing = _Thread_Executing; 4000ca1c: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000ca20: e0 00 63 cc ld [ %g1 + 0x3cc ], %l0 ! 40018fcc <_Thread_Executing> ready = executing->ready; _ISR_Disable( level ); 4000ca24: 7f ff d4 c6 call 40001d3c 4000ca28: e2 04 20 98 ld [ %l0 + 0x98 ], %l1 4000ca2c: b0 10 00 08 mov %o0, %i0 if ( _Chain_Has_only_one_node( ready ) ) { 4000ca30: c4 04 40 00 ld [ %l1 ], %g2 4000ca34: c2 04 60 08 ld [ %l1 + 8 ], %g1 4000ca38: 80 a0 80 01 cmp %g2, %g1 4000ca3c: 32 80 00 03 bne,a 4000ca48 <_Thread_Reset_timeslice+0x30> 4000ca40: c6 04 00 00 ld [ %l0 ], %g3 _ISR_Enable( level ); 4000ca44: 30 80 00 18 b,a 4000caa4 <_Thread_Reset_timeslice+0x8c> { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; 4000ca48: c4 04 20 04 ld [ %l0 + 4 ], %g2 Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); 4000ca4c: 82 04 60 04 add %l1, 4, %g1 Chain_Node *previous; next = the_node->next; previous = the_node->previous; next->previous = previous; previous->next = next; 4000ca50: c6 20 80 00 st %g3, [ %g2 ] Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); 4000ca54: c2 24 00 00 st %g1, [ %l0 ] Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; next->previous = previous; 4000ca58: c4 20 e0 04 st %g2, [ %g3 + 4 ] ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); old_last_node = the_chain->last; 4000ca5c: c2 04 60 08 ld [ %l1 + 8 ], %g1 the_chain->last = the_node; 4000ca60: e0 24 60 08 st %l0, [ %l1 + 8 ] old_last_node->next = the_node; the_node->previous = old_last_node; 4000ca64: 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; 4000ca68: e0 20 40 00 st %l0, [ %g1 ] return; } _Chain_Extract_unprotected( &executing->Object.Node ); _Chain_Append_unprotected( ready, &executing->Object.Node ); _ISR_Flash( level ); 4000ca6c: 7f ff d4 b8 call 40001d4c 4000ca70: 01 00 00 00 nop 4000ca74: 7f ff d4 b2 call 40001d3c 4000ca78: 01 00 00 00 nop if ( _Thread_Is_heir( executing ) ) 4000ca7c: 05 10 00 63 sethi %hi(0x40018c00), %g2 4000ca80: c2 00 a3 a4 ld [ %g2 + 0x3a4 ], %g1 ! 40018fa4 <_Thread_Heir> 4000ca84: 80 a4 00 01 cmp %l0, %g1 4000ca88: 32 80 00 05 bne,a 4000ca9c <_Thread_Reset_timeslice+0x84> 4000ca8c: 84 10 20 01 mov 1, %g2 <== NOT EXECUTED _Thread_Heir = (Thread_Control *) ready->first; 4000ca90: c2 04 40 00 ld [ %l1 ], %g1 4000ca94: c2 20 a3 a4 st %g1, [ %g2 + 0x3a4 ] _Context_Switch_necessary = TRUE; 4000ca98: 84 10 20 01 mov 1, %g2 4000ca9c: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000caa0: c4 20 63 dc st %g2, [ %g1 + 0x3dc ] ! 40018fdc <_Context_Switch_necessary> _ISR_Enable( level ); 4000caa4: 7f ff d4 aa call 40001d4c 4000caa8: 81 e8 00 00 restore 4000caac: 01 00 00 00 nop 4000b098 <_Thread_Resume>: void _Thread_Resume( Thread_Control *the_thread, boolean force ) { 4000b098: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; States_Control current_state; _ISR_Disable( level ); 4000b09c: 7f ff de 71 call 40002a60 4000b0a0: 01 00 00 00 nop 4000b0a4: a0 10 00 08 mov %o0, %l0 if ( force == TRUE ) 4000b0a8: 80 a6 60 01 cmp %i1, 1 4000b0ac: 32 80 00 04 bne,a 4000b0bc <_Thread_Resume+0x24> 4000b0b0: c2 06 20 70 ld [ %i0 + 0x70 ], %g1 <== NOT EXECUTED the_thread->suspend_count = 0; 4000b0b4: 10 80 00 04 b 4000b0c4 <_Thread_Resume+0x2c> 4000b0b8: c0 26 20 70 clr [ %i0 + 0x70 ] else the_thread->suspend_count--; 4000b0bc: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 4000b0c0: c2 26 20 70 st %g1, [ %i0 + 0x70 ] <== NOT EXECUTED if ( the_thread->suspend_count > 0 ) { 4000b0c4: c2 06 20 70 ld [ %i0 + 0x70 ], %g1 4000b0c8: 80 a0 60 00 cmp %g1, 0 4000b0cc: 22 80 00 03 be,a 4000b0d8 <_Thread_Resume+0x40> 4000b0d0: c2 06 20 10 ld [ %i0 + 0x10 ], %g1 _ISR_Enable( level ); 4000b0d4: 30 80 00 2e b,a 4000b18c <_Thread_Resume+0xf4> <== NOT EXECUTED return; } current_state = the_thread->current_state; if ( current_state & STATES_SUSPENDED ) { 4000b0d8: 80 88 60 02 btst 2, %g1 4000b0dc: 02 80 00 2c be 4000b18c <_Thread_Resume+0xf4> 4000b0e0: 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 ) ) { 4000b0e4: 80 a0 60 00 cmp %g1, 0 4000b0e8: 12 80 00 29 bne 4000b18c <_Thread_Resume+0xf4> 4000b0ec: c2 26 20 10 st %g1, [ %i0 + 0x10 ] RTEMS_INLINE_ROUTINE void _Priority_Add_to_bit_map ( Priority_Information *the_priority_map ) { *the_priority_map->minor |= the_priority_map->ready_minor; 4000b0f0: c8 06 20 9c ld [ %i0 + 0x9c ], %g4 4000b0f4: c4 16 20 a2 lduh [ %i0 + 0xa2 ], %g2 4000b0f8: c2 11 00 00 lduh [ %g4 ], %g1 _Priority_Add_to_bit_map( &the_thread->Priority_map ); _Chain_Append_unprotected(the_thread->ready, &the_thread->Object.Node); 4000b0fc: c6 06 20 98 ld [ %i0 + 0x98 ], %g3 4000b100: 82 10 40 02 or %g1, %g2, %g1 4000b104: c2 31 00 00 sth %g1, [ %g4 ] Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); 4000b108: 82 00 e0 04 add %g3, 4, %g1 _Priority_Major_bit_map |= the_priority_map->ready_major; 4000b10c: 09 10 00 95 sethi %hi(0x40025400), %g4 4000b110: c2 26 00 00 st %g1, [ %i0 ] 4000b114: da 16 20 a0 lduh [ %i0 + 0xa0 ], %o5 old_last_node = the_chain->last; 4000b118: c2 00 e0 08 ld [ %g3 + 8 ], %g1 4000b11c: c4 11 20 d0 lduh [ %g4 + 0xd0 ], %g2 the_chain->last = the_node; 4000b120: f0 20 e0 08 st %i0, [ %g3 + 8 ] 4000b124: 84 10 80 0d or %g2, %o5, %g2 old_last_node->next = the_node; the_node->previous = old_last_node; 4000b128: c2 26 20 04 st %g1, [ %i0 + 4 ] 4000b12c: c4 31 20 d0 sth %g2, [ %g4 + 0xd0 ] 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; 4000b130: f0 20 40 00 st %i0, [ %g1 ] _ISR_Flash( level ); 4000b134: 7f ff de 4f call 40002a70 4000b138: 90 10 00 10 mov %l0, %o0 4000b13c: 7f ff de 49 call 40002a60 4000b140: 01 00 00 00 nop if ( the_thread->current_priority < _Thread_Heir->current_priority ) { 4000b144: 07 10 00 95 sethi %hi(0x40025400), %g3 4000b148: c2 00 e0 b4 ld [ %g3 + 0xb4 ], %g1 ! 400254b4 <_Thread_Heir> 4000b14c: c4 06 20 14 ld [ %i0 + 0x14 ], %g2 4000b150: c2 00 60 14 ld [ %g1 + 0x14 ], %g1 4000b154: 80 a0 80 01 cmp %g2, %g1 4000b158: 1a 80 00 0d bcc 4000b18c <_Thread_Resume+0xf4> 4000b15c: 03 10 00 95 sethi %hi(0x40025400), %g1 _Thread_Heir = the_thread; if ( _Thread_Executing->is_preemptible || 4000b160: c2 00 60 dc ld [ %g1 + 0xdc ], %g1 ! 400254dc <_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; 4000b164: f0 20 e0 b4 st %i0, [ %g3 + 0xb4 ] if ( _Thread_Executing->is_preemptible || 4000b168: c2 00 60 7c ld [ %g1 + 0x7c ], %g1 4000b16c: 80 a0 60 00 cmp %g1, 0 4000b170: 32 80 00 05 bne,a 4000b184 <_Thread_Resume+0xec> 4000b174: 84 10 20 01 mov 1, %g2 4000b178: 80 a0 a0 00 cmp %g2, 0 4000b17c: 12 80 00 04 bne 4000b18c <_Thread_Resume+0xf4> 4000b180: 84 10 20 01 mov 1, %g2 the_thread->current_priority == 0 ) _Context_Switch_necessary = TRUE; 4000b184: 03 10 00 95 sethi %hi(0x40025400), %g1 4000b188: c4 20 60 ec st %g2, [ %g1 + 0xec ] ! 400254ec <_Context_Switch_necessary> } } } _ISR_Enable( level ); 4000b18c: 7f ff de 39 call 40002a70 4000b190: 91 e8 00 10 restore %g0, %l0, %o0 4000b194: 01 00 00 00 nop 40009848 <_Thread_Stack_Allocate>: size_t _Thread_Stack_Allocate( Thread_Control *the_thread, size_t stack_size ) { 40009848: 9d e3 bf 98 save %sp, -104, %sp void *stack_addr = 0; size_t the_stack_size = stack_size; if ( !_Stack_Is_enough( the_stack_size ) ) 4000984c: 80 a6 6f ff cmp %i1, 0xfff 40009850: 28 80 00 02 bleu,a 40009858 <_Thread_Stack_Allocate+0x10> 40009854: 33 00 00 04 sethi %hi(0x1000), %i1 <== NOT EXECUTED * Call ONLY the CPU table stack allocate hook, _or_ the * the RTEMS workspace allocate. This is so the stack free * routine can call the correct deallocation routine. */ if ( _CPU_Table.stack_allocate_hook ) { 40009858: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000985c: c2 00 63 24 ld [ %g1 + 0x324 ], %g1 ! 40018f24 <_CPU_Table+0x20> 40009860: 80 a0 60 00 cmp %g1, 0 40009864: 02 80 00 06 be 4000987c <_Thread_Stack_Allocate+0x34> 40009868: 92 06 60 10 add %i1, 0x10, %o1 stack_addr = (*_CPU_Table.stack_allocate_hook)( the_stack_size ); 4000986c: 9f c0 40 00 call %g1 <== NOT EXECUTED 40009870: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED } if ( !stack_addr ) the_stack_size = 0; the_thread->Start.stack = stack_addr; 40009874: 10 80 00 07 b 40009890 <_Thread_Stack_Allocate+0x48> <== NOT EXECUTED 40009878: d0 26 20 d8 st %o0, [ %i0 + 0xd8 ] <== NOT EXECUTED RTEMS_INLINE_ROUTINE void *_Workspace_Allocate( size_t size ) { return _Heap_Allocate( &_Workspace_Area, size ); 4000987c: 11 10 00 63 sethi %hi(0x40018c00), %o0 40009880: b2 10 00 09 mov %o1, %i1 40009884: 7f ff f4 f4 call 40006c54 <_Heap_Allocate> 40009888: 90 12 23 3c or %o0, 0x33c, %o0 4000988c: d0 26 20 d8 st %o0, [ %i0 + 0xd8 ] the_stack_size = _Stack_Adjust_size( the_stack_size ); stack_addr = _Workspace_Allocate( the_stack_size ); } if ( !stack_addr ) 40009890: 80 a0 00 08 cmp %g0, %o0 40009894: b0 60 20 00 subx %g0, 0, %i0 the_stack_size = 0; the_thread->Start.stack = stack_addr; return the_stack_size; } 40009898: b0 0e 40 18 and %i1, %i0, %i0 4000989c: 81 c7 e0 08 ret 400098a0: 81 e8 00 00 restore 400098a4 <_Thread_Stack_Free>: */ void _Thread_Stack_Free( Thread_Control *the_thread ) { 400098a4: 9d e3 bf 98 save %sp, -104, %sp /* * If the API provided the stack space, then don't free it. */ if ( !the_thread->Start.core_allocated_stack ) 400098a8: c2 06 20 cc ld [ %i0 + 0xcc ], %g1 400098ac: 80 a0 60 00 cmp %g1, 0 400098b0: 02 80 00 08 be 400098d0 <_Thread_Stack_Free+0x2c> 400098b4: 03 10 00 63 sethi %hi(0x40018c00), %g1 * Call ONLY the CPU table stack free hook, or the * the RTEMS workspace free. This is so the free * routine properly matches the allocation of the stack. */ if ( _CPU_Table.stack_free_hook ) 400098b8: c2 00 63 28 ld [ %g1 + 0x328 ], %g1 ! 40018f28 <_CPU_Table+0x24> 400098bc: 80 a0 60 00 cmp %g1, 0 400098c0: 02 80 00 06 be 400098d8 <_Thread_Stack_Free+0x34> 400098c4: d0 06 20 d4 ld [ %i0 + 0xd4 ], %o0 (*_CPU_Table.stack_free_hook)( the_thread->Start.Initial_stack.area ); 400098c8: 9f c0 40 00 call %g1 <== NOT EXECUTED 400098cc: 01 00 00 00 nop <== NOT EXECUTED 400098d0: 81 c7 e0 08 ret <== NOT EXECUTED 400098d4: 81 e8 00 00 restore <== NOT EXECUTED RTEMS_INLINE_ROUTINE boolean _Workspace_Free( void *block ) { return _Heap_Free( &_Workspace_Area, block ); 400098d8: 31 10 00 63 sethi %hi(0x40018c00), %i0 400098dc: b2 10 00 08 mov %o0, %i1 400098e0: 7f ff f5 04 call 40006cf0 <_Heap_Free> 400098e4: 91 ee 23 3c restore %i0, 0x33c, %o0 400098e8: 01 00 00 00 nop 40009974 <_Thread_Tickle_timeslice>: * * Output parameters: NONE */ void _Thread_Tickle_timeslice( void ) { 40009974: 9d e3 bf 98 save %sp, -104, %sp Thread_Control *executing; executing = _Thread_Executing; 40009978: 03 10 00 63 sethi %hi(0x40018c00), %g1 4000997c: e0 00 63 cc ld [ %g1 + 0x3cc ], %l0 ! 40018fcc <_Thread_Executing> /* * If the thread is not preemptible or is not ready, then * just return. */ if ( !executing->is_preemptible ) 40009980: c2 04 20 7c ld [ %l0 + 0x7c ], %g1 40009984: 80 a0 60 00 cmp %g1, 0 40009988: 02 80 00 23 be 40009a14 <_Thread_Tickle_timeslice+0xa0> 4000998c: 01 00 00 00 nop return; if ( !_States_Is_ready( executing->current_state ) ) 40009990: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 40009994: 80 a0 60 00 cmp %g1, 0 40009998: 12 80 00 1f bne 40009a14 <_Thread_Tickle_timeslice+0xa0> 4000999c: 01 00 00 00 nop /* * The cpu budget algorithm determines what happens next. */ switch ( executing->budget_algorithm ) { 400099a0: c2 04 20 88 ld [ %l0 + 0x88 ], %g1 400099a4: 80 a0 60 01 cmp %g1, 1 400099a8: 0a 80 00 12 bcs 400099f0 <_Thread_Tickle_timeslice+0x7c> 400099ac: 80 a0 60 02 cmp %g1, 2 400099b0: 28 80 00 07 bleu,a 400099cc <_Thread_Tickle_timeslice+0x58> 400099b4: c2 04 20 84 ld [ %l0 + 0x84 ], %g1 400099b8: 80 a0 60 03 cmp %g1, 3 <== NOT EXECUTED 400099bc: 12 80 00 16 bne 40009a14 <_Thread_Tickle_timeslice+0xa0> <== NOT EXECUTED 400099c0: 01 00 00 00 nop <== NOT EXECUTED executing->cpu_time_budget = _Thread_Ticks_per_timeslice; } break; case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: if ( --executing->cpu_time_budget == 0 ) 400099c4: 10 80 00 0d b 400099f8 <_Thread_Tickle_timeslice+0x84> <== NOT EXECUTED 400099c8: c2 04 20 84 ld [ %l0 + 0x84 ], %g1 <== NOT EXECUTED case THREAD_CPU_BUDGET_ALGORITHM_NONE: break; case THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE: case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE: if ( (int)(--executing->cpu_time_budget) <= 0 ) { 400099cc: 82 00 7f ff add %g1, -1, %g1 400099d0: 80 a0 60 00 cmp %g1, 0 400099d4: 14 80 00 07 bg 400099f0 <_Thread_Tickle_timeslice+0x7c> 400099d8: c2 24 20 84 st %g1, [ %l0 + 0x84 ] _Thread_Reset_timeslice(); 400099dc: 40 00 0c 0f call 4000ca18 <_Thread_Reset_timeslice> 400099e0: 01 00 00 00 nop executing->cpu_time_budget = _Thread_Ticks_per_timeslice; 400099e4: 03 10 00 63 sethi %hi(0x40018c00), %g1 400099e8: c2 00 62 48 ld [ %g1 + 0x248 ], %g1 ! 40018e48 <_Thread_Ticks_per_timeslice> 400099ec: c2 24 20 84 st %g1, [ %l0 + 0x84 ] 400099f0: 81 c7 e0 08 ret 400099f4: 81 e8 00 00 restore } break; case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: if ( --executing->cpu_time_budget == 0 ) 400099f8: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 400099fc: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40009a00: 12 bf ff fc bne 400099f0 <_Thread_Tickle_timeslice+0x7c> <== NOT EXECUTED 40009a04: c2 24 20 84 st %g1, [ %l0 + 0x84 ] <== NOT EXECUTED (*executing->budget_callout)( executing ); 40009a08: c2 04 20 8c ld [ %l0 + 0x8c ], %g1 <== NOT EXECUTED 40009a0c: 9f c0 40 00 call %g1 <== NOT EXECUTED 40009a10: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED 40009a14: 81 c7 e0 08 ret 40009a18: 81 e8 00 00 restore 40008e7c <_Thread_queue_Dequeue>: Thread_queue_Control *the_thread_queue ) { Thread_Control *the_thread; switch ( the_thread_queue->discipline ) { 40008e7c: c2 02 20 34 ld [ %o0 + 0x34 ], %g1 40008e80: 80 a0 60 00 cmp %g1, 0 40008e84: 02 80 00 05 be 40008e98 <_Thread_queue_Dequeue+0x1c> 40008e88: 80 a0 60 01 cmp %g1, 1 40008e8c: 12 80 00 09 bne 40008eb0 <_Thread_queue_Dequeue+0x34> 40008e90: 01 00 00 00 nop 40008e94: 30 80 00 04 b,a 40008ea4 <_Thread_queue_Dequeue+0x28> case THREAD_QUEUE_DISCIPLINE_FIFO: the_thread = _Thread_queue_Dequeue_fifo( the_thread_queue ); 40008e98: 82 13 c0 00 mov %o7, %g1 40008e9c: 40 00 0d e9 call 4000c640 <_Thread_queue_Dequeue_fifo> 40008ea0: 9e 10 40 00 mov %g1, %o7 break; case THREAD_QUEUE_DISCIPLINE_PRIORITY: the_thread = _Thread_queue_Dequeue_priority( the_thread_queue ); 40008ea4: 82 13 c0 00 mov %o7, %g1 40008ea8: 40 00 00 0a call 40008ed0 <_Thread_queue_Dequeue_priority> 40008eac: 9e 10 40 00 mov %g1, %o7 the_thread = NULL; break; } return( the_thread ); } 40008eb0: 81 c3 e0 08 retl <== NOT EXECUTED 40008eb4: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000c640 <_Thread_queue_Dequeue_fifo>: */ Thread_Control *_Thread_queue_Dequeue_fifo( Thread_queue_Control *the_thread_queue ) { 4000c640: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; Thread_Control *the_thread; _ISR_Disable( level ); 4000c644: 7f ff d5 be call 40001d3c 4000c648: a0 10 00 18 mov %i0, %l0 4000c64c: 84 10 00 08 mov %o0, %g2 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 4000c650: f0 06 00 00 ld [ %i0 ], %i0 if ( !_Chain_Is_empty( &the_thread_queue->Queues.Fifo ) ) { 4000c654: 82 04 20 04 add %l0, 4, %g1 4000c658: 80 a6 00 01 cmp %i0, %g1 4000c65c: 22 80 00 16 be,a 4000c6b4 <_Thread_queue_Dequeue_fifo+0x74> 4000c660: c2 04 20 30 ld [ %l0 + 0x30 ], %g1 { Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next; 4000c664: c2 06 00 00 ld [ %i0 ], %g1 the_chain->first = new_first; 4000c668: c2 24 00 00 st %g1, [ %l0 ] the_thread = (Thread_Control *) _Chain_Get_first_unprotected( &the_thread_queue->Queues.Fifo ); the_thread->Wait.queue = NULL; if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { 4000c66c: c4 06 20 50 ld [ %i0 + 0x50 ], %g2 new_first->previous = _Chain_Head(the_chain); 4000c670: e0 20 60 04 st %l0, [ %g1 + 4 ] 4000c674: 80 a0 a0 02 cmp %g2, 2 4000c678: 02 80 00 05 be 4000c68c <_Thread_queue_Dequeue_fifo+0x4c> 4000c67c: c0 26 20 44 clr [ %i0 + 0x44 ] _ISR_Enable( level ); 4000c680: 7f ff d5 b3 call 40001d4c 4000c684: 01 00 00 00 nop 4000c688: 30 80 00 07 b,a 4000c6a4 <_Thread_queue_Dequeue_fifo+0x64> RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; 4000c68c: 82 10 20 03 mov 3, %g1 ! 3 4000c690: c2 26 20 50 st %g1, [ %i0 + 0x50 ] _Thread_Unblock( the_thread ); } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); 4000c694: 7f ff d5 ae call 40001d4c 4000c698: 01 00 00 00 nop (void) _Watchdog_Remove( &the_thread->Timer ); 4000c69c: 7f ff f6 33 call 40009f68 <_Watchdog_Remove> 4000c6a0: 90 06 20 48 add %i0, 0x48, %o0 _Thread_Unblock( the_thread ); 4000c6a4: 7f ff ff e1 call 4000c628 <_Thread_Unblock> 4000c6a8: 90 10 00 18 mov %i0, %o0 4000c6ac: 81 c7 e0 08 ret 4000c6b0: 81 e8 00 00 restore #endif return the_thread; } switch ( the_thread_queue->sync_state ) { 4000c6b4: 80 a0 60 02 cmp %g1, 2 4000c6b8: 18 80 00 06 bgu 4000c6d0 <_Thread_queue_Dequeue_fifo+0x90> 4000c6bc: 80 a0 60 03 cmp %g1, 3 4000c6c0: 80 a0 60 01 cmp %g1, 1 4000c6c4: 1a 80 00 0a bcc 4000c6ec <_Thread_queue_Dequeue_fifo+0xac> 4000c6c8: 82 10 20 03 mov 3, %g1 4000c6cc: 30 80 00 03 b,a 4000c6d8 <_Thread_queue_Dequeue_fifo+0x98> 4000c6d0: 12 bf ff f7 bne 4000c6ac <_Thread_queue_Dequeue_fifo+0x6c> <== NOT EXECUTED 4000c6d4: b0 10 20 00 clr %i0 <== NOT EXECUTED case THREAD_QUEUE_SYNCHRONIZED: case THREAD_QUEUE_SATISFIED: _ISR_Enable( level ); 4000c6d8: b0 10 20 00 clr %i0 4000c6dc: 7f ff d5 9c call 40001d4c 4000c6e0: 90 10 00 02 mov %g2, %o0 4000c6e4: 81 c7 e0 08 ret 4000c6e8: 81 e8 00 00 restore return NULL; case THREAD_QUEUE_NOTHING_HAPPENED: case THREAD_QUEUE_TIMEOUT: the_thread_queue->sync_state = THREAD_QUEUE_SATISFIED; 4000c6ec: c2 24 20 30 st %g1, [ %l0 + 0x30 ] <== NOT EXECUTED _ISR_Enable( level ); 4000c6f0: 7f ff d5 97 call 40001d4c <== NOT EXECUTED 4000c6f4: 01 00 00 00 nop <== NOT EXECUTED return _Thread_Executing; 4000c6f8: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 4000c6fc: f0 00 63 cc ld [ %g1 + 0x3cc ], %i0 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED } return NULL; /* this is only to prevent warnings */ } 4000c700: 81 c7 e0 08 ret <== NOT EXECUTED 4000c704: 81 e8 00 00 restore <== NOT EXECUTED 40008ed0 <_Thread_queue_Dequeue_priority>: */ Thread_Control *_Thread_queue_Dequeue_priority( Thread_queue_Control *the_thread_queue ) { 40008ed0: 9d e3 bf 98 save %sp, -104, %sp Chain_Node *new_second_node; Chain_Node *last_node; Chain_Node *next_node; Chain_Node *previous_node; _ISR_Disable( level ); 40008ed4: 7f ff e3 9a call 40001d3c 40008ed8: 01 00 00 00 nop 40008edc: 98 10 00 08 mov %o0, %o4 40008ee0: 86 10 20 00 clr %g3 40008ee4: 88 10 20 00 clr %g4 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 40008ee8: d0 01 00 18 ld [ %g4 + %i0 ], %o0 for( index=0 ; index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; index++ ) { if ( !_Chain_Is_empty( &the_thread_queue->Queues.Priority[ index ] ) ) { 40008eec: 85 28 e0 02 sll %g3, 2, %g2 40008ef0: 83 28 e0 04 sll %g3, 4, %g1 40008ef4: 82 20 40 02 sub %g1, %g2, %g1 40008ef8: 82 06 00 01 add %i0, %g1, %g1 40008efc: 82 00 60 04 add %g1, 4, %g1 40008f00: 80 a2 00 01 cmp %o0, %g1 40008f04: 02 80 00 04 be 40008f14 <_Thread_queue_Dequeue_priority+0x44> 40008f08: 88 01 20 0c add %g4, 0xc, %g4 the_thread = (Thread_Control *) 40008f0c: 10 80 00 1c b 40008f7c <_Thread_queue_Dequeue_priority+0xac> 40008f10: b0 10 00 08 mov %o0, %i0 Chain_Node *previous_node; _ISR_Disable( level ); for( index=0 ; index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; index++ ) { 40008f14: 86 00 e0 01 inc %g3 Chain_Node *next_node; Chain_Node *previous_node; _ISR_Disable( level ); for( index=0 ; index < TASK_QUEUE_DATA_NUMBER_OF_PRIORITY_HEADERS ; 40008f18: 80 a0 e0 04 cmp %g3, 4 40008f1c: 32 bf ff f4 bne,a 40008eec <_Thread_queue_Dequeue_priority+0x1c> 40008f20: d0 01 00 18 ld [ %g4 + %i0 ], %o0 the_thread_queue->Queues.Priority[ index ].first; goto dequeue; } } switch ( the_thread_queue->sync_state ) { 40008f24: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 40008f28: 80 a0 60 02 cmp %g1, 2 40008f2c: 18 80 00 06 bgu 40008f44 <_Thread_queue_Dequeue_priority+0x74> 40008f30: 80 a0 60 03 cmp %g1, 3 40008f34: 80 a0 60 01 cmp %g1, 1 40008f38: 1a 80 00 0a bcc 40008f60 <_Thread_queue_Dequeue_priority+0x90> 40008f3c: 82 10 20 03 mov 3, %g1 40008f40: 30 80 00 03 b,a 40008f4c <_Thread_queue_Dequeue_priority+0x7c> 40008f44: 12 80 00 0e bne 40008f7c <_Thread_queue_Dequeue_priority+0xac> <== NOT EXECUTED 40008f48: b0 10 20 00 clr %i0 <== NOT EXECUTED case THREAD_QUEUE_SYNCHRONIZED: case THREAD_QUEUE_SATISFIED: _ISR_Enable( level ); 40008f4c: b0 10 20 00 clr %i0 40008f50: 7f ff e3 7f call 40001d4c 40008f54: 90 10 00 0c mov %o4, %o0 40008f58: 81 c7 e0 08 ret 40008f5c: 81 e8 00 00 restore return NULL; case THREAD_QUEUE_NOTHING_HAPPENED: case THREAD_QUEUE_TIMEOUT: the_thread_queue->sync_state = THREAD_QUEUE_SATISFIED; 40008f60: c2 26 20 30 st %g1, [ %i0 + 0x30 ] <== NOT EXECUTED _ISR_Enable( level ); 40008f64: 7f ff e3 7a call 40001d4c <== NOT EXECUTED 40008f68: 90 10 00 0c mov %o4, %o0 <== NOT EXECUTED return _Thread_Executing; 40008f6c: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40008f70: f0 00 63 cc ld [ %g1 + 0x3cc ], %i0 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED 40008f74: 81 c7 e0 08 ret <== NOT EXECUTED 40008f78: 81 e8 00 00 restore <== NOT EXECUTED } dequeue: the_thread->Wait.queue = NULL; new_first_node = the_thread->Wait.Block2n.first; 40008f7c: c6 06 20 38 ld [ %i0 + 0x38 ], %g3 new_first_thread = (Thread_Control *) new_first_node; next_node = the_thread->Object.Node.next; previous_node = the_thread->Object.Node.previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { 40008f80: 82 06 20 3c add %i0, 0x3c, %g1 _ISR_Enable( level ); return _Thread_Executing; } dequeue: the_thread->Wait.queue = NULL; 40008f84: c0 26 20 44 clr [ %i0 + 0x44 ] new_first_node = the_thread->Wait.Block2n.first; new_first_thread = (Thread_Control *) new_first_node; next_node = the_thread->Object.Node.next; previous_node = the_thread->Object.Node.previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { 40008f88: 80 a0 c0 01 cmp %g3, %g1 dequeue: the_thread->Wait.queue = NULL; new_first_node = the_thread->Wait.Block2n.first; new_first_thread = (Thread_Control *) new_first_node; next_node = the_thread->Object.Node.next; 40008f8c: c4 06 00 00 ld [ %i0 ], %g2 previous_node = the_thread->Object.Node.previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { 40008f90: 02 80 00 14 be 40008fe0 <_Thread_queue_Dequeue_priority+0x110> 40008f94: c2 06 20 04 ld [ %i0 + 4 ], %g1 last_node = the_thread->Wait.Block2n.last; 40008f98: da 06 20 40 ld [ %i0 + 0x40 ], %o5 new_second_node = new_first_node->next; 40008f9c: c8 00 c0 00 ld [ %g3 ], %g4 previous_node->next = new_first_node; next_node->previous = new_first_node; 40008fa0: c6 20 a0 04 st %g3, [ %g2 + 4 ] if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { last_node = the_thread->Wait.Block2n.last; new_second_node = new_first_node->next; previous_node->next = new_first_node; 40008fa4: c6 20 40 00 st %g3, [ %g1 ] next_node->previous = new_first_node; new_first_node->next = next_node; 40008fa8: c4 20 c0 00 st %g2, [ %g3 ] new_first_node->previous = previous_node; 40008fac: c2 20 e0 04 st %g1, [ %g3 + 4 ] if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) { 40008fb0: c4 06 20 38 ld [ %i0 + 0x38 ], %g2 40008fb4: c2 06 20 40 ld [ %i0 + 0x40 ], %g1 40008fb8: 80 a0 80 01 cmp %g2, %g1 40008fbc: 22 80 00 0c be,a 40008fec <_Thread_queue_Dequeue_priority+0x11c> 40008fc0: c2 06 20 50 ld [ %i0 + 0x50 ], %g1 /* > two threads on 2-n */ new_second_node->previous = 40008fc4: 82 00 e0 38 add %g3, 0x38, %g1 40008fc8: c2 21 20 04 st %g1, [ %g4 + 4 ] _Chain_Head( &new_first_thread->Wait.Block2n ); new_first_thread->Wait.Block2n.first = new_second_node; 40008fcc: c8 20 e0 38 st %g4, [ %g3 + 0x38 ] new_first_thread->Wait.Block2n.last = last_node; 40008fd0: da 20 e0 40 st %o5, [ %g3 + 0x40 ] last_node->next = _Chain_Tail( &new_first_thread->Wait.Block2n ); 40008fd4: 82 00 e0 3c add %g3, 0x3c, %g1 40008fd8: 10 80 00 04 b 40008fe8 <_Thread_queue_Dequeue_priority+0x118> 40008fdc: c2 23 40 00 st %g1, [ %o5 ] } } else { previous_node->next = next_node; next_node->previous = previous_node; 40008fe0: c2 20 a0 04 st %g1, [ %g2 + 4 ] new_first_thread->Wait.Block2n.last = last_node; last_node->next = _Chain_Tail( &new_first_thread->Wait.Block2n ); } } else { previous_node->next = next_node; 40008fe4: c4 20 40 00 st %g2, [ %g1 ] next_node->previous = previous_node; } if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { 40008fe8: c2 06 20 50 ld [ %i0 + 0x50 ], %g1 40008fec: 80 a0 60 02 cmp %g1, 2 40008ff0: 02 80 00 08 be 40009010 <_Thread_queue_Dequeue_priority+0x140> 40008ff4: 82 10 20 03 mov 3, %g1 _ISR_Enable( level ); 40008ff8: 7f ff e3 55 call 40001d4c 40008ffc: 90 10 00 0c mov %o4, %o0 _Thread_Unblock( the_thread ); 40009000: 7f ff ff ae call 40008eb8 <_Thread_Unblock> 40009004: 90 10 00 18 mov %i0, %o0 40009008: 81 c7 e0 08 ret 4000900c: 81 e8 00 00 restore RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; 40009010: c2 26 20 50 st %g1, [ %i0 + 0x50 ] } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); 40009014: 7f ff e3 4e call 40001d4c 40009018: 90 10 00 0c mov %o4, %o0 (void) _Watchdog_Remove( &the_thread->Timer ); 4000901c: 40 00 03 d3 call 40009f68 <_Watchdog_Remove> 40009020: 90 06 20 48 add %i0, 0x48, %o0 _Thread_Unblock( the_thread ); 40009024: 7f ff ff a5 call 40008eb8 <_Thread_Unblock> 40009028: 90 10 00 18 mov %i0, %o0 #if defined(RTEMS_MULTIPROCESSING) if ( !_Objects_Is_local_id( the_thread->Object.id ) ) _Thread_MP_Free_proxy( the_thread ); #endif return( the_thread ); } 4000902c: 81 c7 e0 08 ret 40009030: 81 e8 00 00 restore 4000c708 <_Thread_queue_Enqueue_fifo>: void _Thread_queue_Enqueue_fifo ( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { 4000c708: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; Thread_queue_States sync_state; _ISR_Disable( level ); 4000c70c: 7f ff d5 8c call 40001d3c 4000c710: a0 10 00 18 mov %i0, %l0 void _Thread_queue_Enqueue_fifo ( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { 4000c714: b0 10 00 19 mov %i1, %i0 ISR_Level level; Thread_queue_States sync_state; _ISR_Disable( level ); sync_state = the_thread_queue->sync_state; 4000c718: c4 04 20 30 ld [ %l0 + 0x30 ], %g2 the_thread_queue->sync_state = THREAD_QUEUE_SYNCHRONIZED; switch ( sync_state ) { 4000c71c: 80 a0 a0 02 cmp %g2, 2 4000c720: 02 80 00 10 be 4000c760 <_Thread_queue_Enqueue_fifo+0x58> 4000c724: c0 24 20 30 clr [ %l0 + 0x30 ] 4000c728: 80 a0 a0 03 cmp %g2, 3 4000c72c: 02 80 00 12 be 4000c774 <_Thread_queue_Enqueue_fifo+0x6c> 4000c730: 80 a0 a0 01 cmp %g2, 1 4000c734: 32 80 00 1e bne,a 4000c7ac <_Thread_queue_Enqueue_fifo+0xa4> 4000c738: 33 04 00 ff sethi %hi(0x1003fc00), %i1 <== NOT EXECUTED Chain_Node *the_node ) { Chain_Node *old_last_node; the_node->next = _Chain_Tail(the_chain); 4000c73c: 82 04 20 04 add %l0, 4, %g1 4000c740: c2 26 40 00 st %g1, [ %i1 ] old_last_node = the_chain->last; 4000c744: c2 04 20 08 ld [ %l0 + 8 ], %g1 the_chain->last = the_node; 4000c748: f2 24 20 08 st %i1, [ %l0 + 8 ] case THREAD_QUEUE_NOTHING_HAPPENED: _Chain_Append_unprotected( &the_thread_queue->Queues.Fifo, &the_thread->Object.Node ); the_thread->Wait.queue = the_thread_queue; 4000c74c: e0 26 60 44 st %l0, [ %i1 + 0x44 ] old_last_node->next = the_node; the_node->previous = old_last_node; 4000c750: c2 26 60 04 st %g1, [ %i1 + 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; 4000c754: f2 20 40 00 st %i1, [ %g1 ] _ISR_Enable( level ); 4000c758: 7f ff d5 7d call 40001d4c 4000c75c: 91 e8 00 08 restore %g0, %o0, %o0 return; case THREAD_QUEUE_TIMEOUT: the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; 4000c760: c2 06 60 44 ld [ %i1 + 0x44 ], %g1 <== NOT EXECUTED the_thread->Wait.queue = NULL; 4000c764: c0 26 60 44 clr [ %i1 + 0x44 ] <== NOT EXECUTED the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return; case THREAD_QUEUE_TIMEOUT: the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; 4000c768: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 <== NOT EXECUTED 4000c76c: c2 26 60 34 st %g1, [ %i1 + 0x34 ] <== NOT EXECUTED the_thread->Wait.queue = NULL; _ISR_Enable( level ); 4000c770: 30 80 00 0d b,a 4000c7a4 <_Thread_queue_Enqueue_fifo+0x9c> <== NOT EXECUTED break; case THREAD_QUEUE_SATISFIED: if ( _Watchdog_Is_active( &the_thread->Timer ) ) { 4000c774: c2 06 60 50 ld [ %i1 + 0x50 ], %g1 <== NOT EXECUTED 4000c778: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 4000c77c: 12 80 00 0a bne 4000c7a4 <_Thread_queue_Enqueue_fifo+0x9c> <== NOT EXECUTED 4000c780: 01 00 00 00 nop <== NOT EXECUTED 4000c784: c4 26 60 50 st %g2, [ %i1 + 0x50 ] <== NOT EXECUTED _Watchdog_Deactivate( &the_thread->Timer ); the_thread->Wait.queue = NULL; 4000c788: c0 26 60 44 clr [ %i1 + 0x44 ] <== NOT EXECUTED _ISR_Enable( level ); 4000c78c: 7f ff d5 70 call 40001d4c <== NOT EXECUTED 4000c790: 01 00 00 00 nop <== NOT EXECUTED (void) _Watchdog_Remove( &the_thread->Timer ); 4000c794: 7f ff f5 f5 call 40009f68 <_Watchdog_Remove> <== NOT EXECUTED 4000c798: 90 06 60 48 add %i1, 0x48, %o0 <== NOT EXECUTED 4000c79c: 10 80 00 04 b 4000c7ac <_Thread_queue_Enqueue_fifo+0xa4> <== NOT EXECUTED 4000c7a0: 33 04 00 ff sethi %hi(0x1003fc00), %i1 <== NOT EXECUTED } else _ISR_Enable( level ); 4000c7a4: 7f ff d5 6a call 40001d4c <== NOT EXECUTED 4000c7a8: 33 04 00 ff sethi %hi(0x1003fc00), %i1 <== NOT EXECUTED 4000c7ac: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 <== NOT EXECUTED 4000c7b0: 7f ff ef ff call 400087ac <_Thread_Clear_state> <== NOT EXECUTED 4000c7b4: 81 e8 00 00 restore <== NOT EXECUTED 4000c7b8: 01 00 00 00 nop 400090b8 <_Thread_queue_Enqueue_priority>: void _Thread_queue_Enqueue_priority( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { 400090b8: 9d e3 bf 98 save %sp, -104, %sp States_Control block_state; Thread_queue_States sync_state; _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; 400090bc: e4 06 60 14 ld [ %i1 + 0x14 ], %l2 */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 400090c0: 82 06 60 3c add %i1, 0x3c, %g1 the_chain->permanent_null = NULL; 400090c4: 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); 400090c8: c2 26 60 38 st %g1, [ %i1 + 0x38 ] the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 400090cc: 82 06 60 38 add %i1, 0x38, %g1 400090d0: c2 26 60 40 st %g1, [ %i1 + 0x40 ] header_index = _Thread_queue_Header_number( priority ); header = &the_thread_queue->Queues.Priority[ header_index ]; block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) ) 400090d4: 80 8c a0 20 btst 0x20, %l2 RTEMS_INLINE_ROUTINE uint32_t _Thread_queue_Header_number ( Priority_Control the_priority ) { return (the_priority / TASK_QUEUE_DATA_PRIORITIES_PER_HEADER); 400090d8: 85 34 a0 06 srl %l2, 6, %g2 400090dc: 12 80 00 34 bne 400091ac <_Thread_queue_Enqueue_priority+0xf4> 400090e0: ec 06 20 38 ld [ %i0 + 0x38 ], %l6 goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->first; 400090e4: 83 28 a0 04 sll %g2, 4, %g1 400090e8: 85 28 a0 02 sll %g2, 2, %g2 400090ec: aa 20 40 02 sub %g1, %g2, %l5 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 400090f0: 82 06 00 15 add %i0, %l5, %g1 400090f4: a8 00 60 04 add %g1, 4, %l4 if ( _Thread_queue_Is_reverse_search( priority ) ) goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level ); 400090f8: 7f ff e3 11 call 40001d3c 400090fc: 01 00 00 00 nop 40009100: a2 10 00 08 mov %o0, %l1 search_thread = (Thread_Control *) header->first; 40009104: e0 06 00 15 ld [ %i0 + %l5 ], %l0 40009108: 10 80 00 18 b 40009168 <_Thread_queue_Enqueue_priority+0xb0> 4000910c: a6 10 3f ff mov -1, %l3 while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) { search_priority = search_thread->current_priority; if ( priority <= search_priority ) 40009110: 80 a4 80 13 cmp %l2, %l3 40009114: 28 80 00 19 bleu,a 40009178 <_Thread_queue_Enqueue_priority+0xc0> 40009118: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 break; #if ( CPU_UNROLL_ENQUEUE_PRIORITY == TRUE ) search_thread = (Thread_Control *) search_thread->Object.Node.next; 4000911c: e0 04 00 00 ld [ %l0 ], %l0 if ( _Chain_Is_tail( header, (Chain_Node *)search_thread ) ) 40009120: 80 a4 00 14 cmp %l0, %l4 40009124: 22 80 00 15 be,a 40009178 <_Thread_queue_Enqueue_priority+0xc0> 40009128: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 break; search_priority = search_thread->current_priority; 4000912c: e6 04 20 14 ld [ %l0 + 0x14 ], %l3 if ( priority <= search_priority ) 40009130: 80 a4 80 13 cmp %l2, %l3 40009134: 28 80 00 11 bleu,a 40009178 <_Thread_queue_Enqueue_priority+0xc0> 40009138: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 break; #endif _ISR_Flash( level ); 4000913c: 7f ff e3 04 call 40001d4c 40009140: 90 10 00 11 mov %l1, %o0 40009144: 7f ff e2 fe call 40001d3c 40009148: 01 00 00 00 nop if ( !_States_Are_set( search_thread->current_state, block_state) ) { 4000914c: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 40009150: 80 8d 80 01 btst %l6, %g1 40009154: 32 80 00 05 bne,a 40009168 <_Thread_queue_Enqueue_priority+0xb0> 40009158: e0 04 00 00 ld [ %l0 ], %l0 _ISR_Enable( level ); 4000915c: 7f ff e2 fc call 40001d4c <== NOT EXECUTED 40009160: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40009164: 30 bf ff e5 b,a 400090f8 <_Thread_queue_Enqueue_priority+0x40> <== NOT EXECUTED 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 ) ) { 40009168: 80 a4 00 14 cmp %l0, %l4 4000916c: 32 bf ff e9 bne,a 40009110 <_Thread_queue_Enqueue_priority+0x58> 40009170: e6 04 20 14 ld [ %l0 + 0x14 ], %l3 } search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state != THREAD_QUEUE_NOTHING_HAPPENED ) 40009174: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 40009178: 80 a0 60 01 cmp %g1, 1 4000917c: 32 80 00 47 bne,a 40009298 <_Thread_queue_Enqueue_priority+0x1e0> 40009180: c4 06 20 30 ld [ %i0 + 0x30 ], %g2 <== NOT EXECUTED goto synchronize; the_thread_queue->sync_state = THREAD_QUEUE_SYNCHRONIZED; if ( priority == search_priority ) 40009184: 80 a4 80 13 cmp %l2, %l3 40009188: 02 80 00 3c be 40009278 <_Thread_queue_Enqueue_priority+0x1c0> 4000918c: c0 26 20 30 clr [ %i0 + 0x30 ] goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous; 40009190: c2 04 20 04 ld [ %l0 + 4 ], %g1 the_node = (Chain_Node *) the_thread; the_node->next = search_node; 40009194: e0 26 40 00 st %l0, [ %i1 ] the_node->previous = previous_node; 40009198: 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; 4000919c: 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; 400091a0: f2 20 40 00 st %i1, [ %g1 ] search_node->previous = the_node; 400091a4: f2 24 20 04 st %i1, [ %l0 + 4 ] the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); 400091a8: 30 80 00 32 b,a 40009270 <_Thread_queue_Enqueue_priority+0x1b8> restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; _ISR_Disable( level ); search_thread = (Thread_Control *) header->last; 400091ac: 83 28 a0 04 sll %g2, 4, %g1 400091b0: 85 28 a0 02 sll %g2, 2, %g2 400091b4: 82 20 40 02 sub %g1, %g2, %g1 400091b8: a6 00 40 18 add %g1, %i0, %l3 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head( Chain_Control *the_chain ) { return (Chain_Node *) the_chain; 400091bc: aa 10 00 13 mov %l3, %l5 return; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; _ISR_Disable( level ); 400091c0: 7f ff e2 df call 40001d3c 400091c4: 01 00 00 00 nop 400091c8: a2 10 00 08 mov %o0, %l1 search_thread = (Thread_Control *) header->last; 400091cc: e0 05 60 08 ld [ %l5 + 8 ], %l0 400091d0: 10 80 00 18 b 40009230 <_Thread_queue_Enqueue_priority+0x178> 400091d4: a8 10 21 00 mov 0x100, %l4 while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) { search_priority = search_thread->current_priority; if ( priority >= search_priority ) 400091d8: 80 a4 80 14 cmp %l2, %l4 400091dc: 3a 80 00 19 bcc,a 40009240 <_Thread_queue_Enqueue_priority+0x188> 400091e0: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 break; #if ( CPU_UNROLL_ENQUEUE_PRIORITY == TRUE ) search_thread = (Thread_Control *) search_thread->Object.Node.previous; 400091e4: e0 04 20 04 ld [ %l0 + 4 ], %l0 if ( _Chain_Is_head( header, (Chain_Node *)search_thread ) ) 400091e8: 80 a4 00 13 cmp %l0, %l3 400091ec: 22 80 00 15 be,a 40009240 <_Thread_queue_Enqueue_priority+0x188> 400091f0: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 break; search_priority = search_thread->current_priority; 400091f4: e8 04 20 14 ld [ %l0 + 0x14 ], %l4 if ( priority >= search_priority ) 400091f8: 80 a4 80 14 cmp %l2, %l4 400091fc: 3a 80 00 11 bcc,a 40009240 <_Thread_queue_Enqueue_priority+0x188> 40009200: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 <== NOT EXECUTED break; #endif _ISR_Flash( level ); 40009204: 7f ff e2 d2 call 40001d4c 40009208: 90 10 00 11 mov %l1, %o0 4000920c: 7f ff e2 cc call 40001d3c 40009210: 01 00 00 00 nop if ( !_States_Are_set( search_thread->current_state, block_state) ) { 40009214: c2 04 20 10 ld [ %l0 + 0x10 ], %g1 40009218: 80 8d 80 01 btst %l6, %g1 4000921c: 32 80 00 05 bne,a 40009230 <_Thread_queue_Enqueue_priority+0x178> 40009220: e0 04 20 04 ld [ %l0 + 4 ], %l0 _ISR_Enable( level ); 40009224: 7f ff e2 ca call 40001d4c <== NOT EXECUTED 40009228: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4000922c: 30 bf ff e5 b,a 400091c0 <_Thread_queue_Enqueue_priority+0x108> <== NOT EXECUTED 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 ) ) { 40009230: 80 a4 00 13 cmp %l0, %l3 40009234: 32 bf ff e9 bne,a 400091d8 <_Thread_queue_Enqueue_priority+0x120> 40009238: e8 04 20 14 ld [ %l0 + 0x14 ], %l4 } search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state != THREAD_QUEUE_NOTHING_HAPPENED ) 4000923c: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 40009240: 80 a0 60 01 cmp %g1, 1 40009244: 32 80 00 15 bne,a 40009298 <_Thread_queue_Enqueue_priority+0x1e0> 40009248: c4 06 20 30 ld [ %i0 + 0x30 ], %g2 <== NOT EXECUTED goto synchronize; the_thread_queue->sync_state = THREAD_QUEUE_SYNCHRONIZED; if ( priority == search_priority ) 4000924c: 80 a4 80 14 cmp %l2, %l4 40009250: 02 80 00 0a be 40009278 <_Thread_queue_Enqueue_priority+0x1c0> 40009254: c0 26 20 30 clr [ %i0 + 0x30 ] goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next; 40009258: c2 04 00 00 ld [ %l0 ], %g1 the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node; 4000925c: e0 26 60 04 st %l0, [ %i1 + 4 ] search_node = (Chain_Node *) search_thread; next_node = search_node->next; the_node = (Chain_Node *) the_thread; the_node->next = next_node; 40009260: c2 26 40 00 st %g1, [ %i1 ] the_node->previous = search_node; search_node->next = the_node; next_node->previous = the_node; the_thread->Wait.queue = the_thread_queue; 40009264: 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; 40009268: f2 24 00 00 st %i1, [ %l0 ] next_node->previous = the_node; 4000926c: f2 20 60 04 st %i1, [ %g1 + 4 ] the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); 40009270: 7f ff e2 b7 call 40001d4c 40009274: 91 e8 00 11 restore %g0, %l1, %o0 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40009278: 82 04 20 3c add %l0, 0x3c, %g1 return; equal_priority: /* add at end of priority group */ search_node = _Chain_Tail( &search_thread->Wait.Block2n ); previous_node = search_node->previous; 4000927c: c4 00 60 04 ld [ %g1 + 4 ], %g2 the_node = (Chain_Node *) the_thread; the_node->next = search_node; 40009280: c2 26 40 00 st %g1, [ %i1 ] the_node->previous = previous_node; 40009284: 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; 40009288: 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; 4000928c: f2 20 80 00 st %i1, [ %g2 ] search_node->previous = the_node; 40009290: f2 20 60 04 st %i1, [ %g1 + 4 ] the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); 40009294: 30 bf ff f7 b,a 40009270 <_Thread_queue_Enqueue_priority+0x1b8> synchronize: sync_state = the_thread_queue->sync_state; the_thread_queue->sync_state = THREAD_QUEUE_SYNCHRONIZED; switch ( sync_state ) { 40009298: 80 a0 a0 02 cmp %g2, 2 <== NOT EXECUTED 4000929c: 02 80 00 07 be 400092b8 <_Thread_queue_Enqueue_priority+0x200> <== NOT EXECUTED 400092a0: c0 26 20 30 clr [ %i0 + 0x30 ] <== NOT EXECUTED 400092a4: 80 a0 a0 03 cmp %g2, 3 <== NOT EXECUTED 400092a8: 12 80 00 17 bne 40009304 <_Thread_queue_Enqueue_priority+0x24c> <== NOT EXECUTED 400092ac: b0 10 00 19 mov %i1, %i0 <== NOT EXECUTED the_thread->Wait.queue = NULL; _ISR_Enable( level ); break; case THREAD_QUEUE_SATISFIED: if ( _Watchdog_Is_active( &the_thread->Timer ) ) { 400092b0: 10 80 00 07 b 400092cc <_Thread_queue_Enqueue_priority+0x214> <== NOT EXECUTED 400092b4: c2 06 60 50 ld [ %i1 + 0x50 ], %g1 <== NOT EXECUTED * This should never happen. All of this was dealt with above. */ break; case THREAD_QUEUE_TIMEOUT: the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; 400092b8: c2 06 60 44 ld [ %i1 + 0x44 ], %g1 <== NOT EXECUTED the_thread->Wait.queue = NULL; 400092bc: c0 26 60 44 clr [ %i1 + 0x44 ] <== NOT EXECUTED * This should never happen. All of this was dealt with above. */ break; case THREAD_QUEUE_TIMEOUT: the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; 400092c0: c2 00 60 3c ld [ %g1 + 0x3c ], %g1 <== NOT EXECUTED 400092c4: c2 26 60 34 st %g1, [ %i1 + 0x34 ] <== NOT EXECUTED the_thread->Wait.queue = NULL; _ISR_Enable( level ); 400092c8: 30 80 00 0c b,a 400092f8 <_Thread_queue_Enqueue_priority+0x240> <== NOT EXECUTED break; case THREAD_QUEUE_SATISFIED: if ( _Watchdog_Is_active( &the_thread->Timer ) ) { 400092cc: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 400092d0: 12 80 00 0a bne 400092f8 <_Thread_queue_Enqueue_priority+0x240> <== NOT EXECUTED 400092d4: 01 00 00 00 nop <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Watchdog_Deactivate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_REMOVE_IT; 400092d8: c4 26 60 50 st %g2, [ %i1 + 0x50 ] <== NOT EXECUTED _Watchdog_Deactivate( &the_thread->Timer ); the_thread->Wait.queue = NULL; 400092dc: c0 26 60 44 clr [ %i1 + 0x44 ] <== NOT EXECUTED _ISR_Enable( level ); 400092e0: 7f ff e2 9b call 40001d4c <== NOT EXECUTED 400092e4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED (void) _Watchdog_Remove( &the_thread->Timer ); 400092e8: 40 00 03 20 call 40009f68 <_Watchdog_Remove> <== NOT EXECUTED 400092ec: 90 06 60 48 add %i1, 0x48, %o0 <== NOT EXECUTED 400092f0: 10 80 00 05 b 40009304 <_Thread_queue_Enqueue_priority+0x24c> <== NOT EXECUTED 400092f4: b0 10 00 19 mov %i1, %i0 <== NOT EXECUTED } else _ISR_Enable( level ); 400092f8: 7f ff e2 95 call 40001d4c <== NOT EXECUTED 400092fc: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40009300: b0 10 00 19 mov %i1, %i0 <== NOT EXECUTED 40009304: 33 04 00 ff sethi %hi(0x1003fc00), %i1 <== NOT EXECUTED 40009308: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 <== NOT EXECUTED 4000930c: 7f ff fd 28 call 400087ac <_Thread_Clear_state> <== NOT EXECUTED 40009310: 81 e8 00 00 restore <== NOT EXECUTED 40009314: 01 00 00 00 nop 40009034 <_Thread_queue_Enqueue_with_handler>: void _Thread_queue_Enqueue_with_handler( Thread_queue_Control *the_thread_queue, Watchdog_Interval timeout, Thread_queue_Timeout_callout handler ) { 40009034: 9d e3 bf 98 save %sp, -104, %sp Thread_Control *the_thread; the_thread = _Thread_Executing; 40009038: 03 10 00 63 sethi %hi(0x40018c00), %g1 else #endif /* * Set the blocking state for this thread queue in the thread. */ _Thread_Set_state( the_thread, the_thread_queue->state ); 4000903c: d2 06 20 38 ld [ %i0 + 0x38 ], %o1 Thread_queue_Timeout_callout handler ) { Thread_Control *the_thread; the_thread = _Thread_Executing; 40009040: e0 00 63 cc ld [ %g1 + 0x3cc ], %l0 void _Thread_queue_Enqueue_with_handler( Thread_queue_Control *the_thread_queue, Watchdog_Interval timeout, Thread_queue_Timeout_callout handler ) { 40009044: a2 10 00 18 mov %i0, %l1 else #endif /* * Set the blocking state for this thread queue in the thread. */ _Thread_Set_state( the_thread, the_thread_queue->state ); 40009048: 40 00 01 79 call 4000962c <_Thread_Set_state> 4000904c: 90 10 00 10 mov %l0, %o0 /* * If the thread wants to timeout, then schedule its timer. */ if ( timeout ) { 40009050: 80 a6 60 00 cmp %i1, 0 40009054: 22 80 00 0d be,a 40009088 <_Thread_queue_Enqueue_with_handler+0x54> 40009058: c2 04 60 34 ld [ %l1 + 0x34 ], %g1 _Watchdog_Initialize( 4000905c: c2 04 20 08 ld [ %l0 + 8 ], %g1 ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40009060: 11 10 00 63 sethi %hi(0x40018c00), %o0 Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; 40009064: f4 24 20 64 st %i2, [ %l0 + 0x64 ] the_watchdog->id = id; 40009068: c2 24 20 68 st %g1, [ %l0 + 0x68 ] Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 4000906c: f2 24 20 54 st %i1, [ %l0 + 0x54 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40009070: c0 24 20 50 clr [ %l0 + 0x50 ] the_watchdog->routine = routine; the_watchdog->id = id; the_watchdog->user_data = user_data; 40009074: c0 24 20 6c clr [ %l0 + 0x6c ] ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40009078: 90 12 23 ec or %o0, 0x3ec, %o0 4000907c: 40 00 03 63 call 40009e08 <_Watchdog_Insert> 40009080: 92 04 20 48 add %l0, 0x48, %o1 } /* * Now enqueue the thread per the discipline for this thread queue. */ switch( the_thread_queue->discipline ) { 40009084: c2 04 60 34 ld [ %l1 + 0x34 ], %g1 40009088: 80 a0 60 00 cmp %g1, 0 4000908c: 02 80 00 05 be 400090a0 <_Thread_queue_Enqueue_with_handler+0x6c> 40009090: 80 a0 60 01 cmp %g1, 1 40009094: 12 80 00 07 bne 400090b0 <_Thread_queue_Enqueue_with_handler+0x7c> 40009098: 01 00 00 00 nop 4000909c: 30 80 00 03 b,a 400090a8 <_Thread_queue_Enqueue_with_handler+0x74> case THREAD_QUEUE_DISCIPLINE_FIFO: _Thread_queue_Enqueue_fifo( the_thread_queue, the_thread ); 400090a0: 40 00 0d 9a call 4000c708 <_Thread_queue_Enqueue_fifo> 400090a4: 93 e8 00 10 restore %g0, %l0, %o1 break; case THREAD_QUEUE_DISCIPLINE_PRIORITY: _Thread_queue_Enqueue_priority( the_thread_queue, the_thread ); 400090a8: 40 00 00 04 call 400090b8 <_Thread_queue_Enqueue_priority> 400090ac: 93 e8 00 10 restore %g0, %l0, %o1 400090b0: 81 c7 e0 08 ret <== NOT EXECUTED 400090b4: 81 e8 00 00 restore <== NOT EXECUTED 4000c7bc <_Thread_queue_Extract>: void _Thread_queue_Extract( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { switch ( the_thread_queue->discipline ) { 4000c7bc: c2 02 20 34 ld [ %o0 + 0x34 ], %g1 4000c7c0: 80 a0 60 00 cmp %g1, 0 4000c7c4: 02 80 00 05 be 4000c7d8 <_Thread_queue_Extract+0x1c> 4000c7c8: 80 a0 60 01 cmp %g1, 1 4000c7cc: 12 80 00 09 bne 4000c7f0 <_Thread_queue_Extract+0x34> 4000c7d0: 94 10 20 00 clr %o2 4000c7d4: 30 80 00 04 b,a 4000c7e4 <_Thread_queue_Extract+0x28> case THREAD_QUEUE_DISCIPLINE_FIFO: _Thread_queue_Extract_fifo( the_thread_queue, the_thread ); 4000c7d8: 82 13 c0 00 mov %o7, %g1 4000c7dc: 40 00 03 2a call 4000d484 <_Thread_queue_Extract_fifo> 4000c7e0: 9e 10 40 00 mov %g1, %o7 break; case THREAD_QUEUE_DISCIPLINE_PRIORITY: _Thread_queue_Extract_priority( the_thread_queue, the_thread ); 4000c7e4: 82 13 c0 00 mov %o7, %g1 4000c7e8: 40 00 00 04 call 4000c7f8 <_Thread_queue_Extract_priority_helper> 4000c7ec: 9e 10 40 00 mov %g1, %o7 4000c7f0: 81 c3 e0 08 retl <== NOT EXECUTED 4000c7f4: 01 00 00 00 nop 4000d484 <_Thread_queue_Extract_fifo>: void _Thread_queue_Extract_fifo( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { 4000d484: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; _ISR_Disable( level ); 4000d488: 7f ff d2 2d call 40001d3c 4000d48c: b0 10 00 19 mov %i1, %i0 if ( !_States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { 4000d490: c4 06 60 10 ld [ %i1 + 0x10 ], %g2 4000d494: 03 00 00 ef sethi %hi(0x3bc00), %g1 4000d498: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 4000d49c: 80 88 80 01 btst %g2, %g1 4000d4a0: 32 80 00 04 bne,a 4000d4b0 <_Thread_queue_Extract_fifo+0x2c> 4000d4a4: c2 06 40 00 ld [ %i1 ], %g1 _ISR_Enable( level ); 4000d4a8: 7f ff d2 29 call 40001d4c <== NOT EXECUTED 4000d4ac: 91 e8 00 08 restore %g0, %o0, %o0 <== NOT EXECUTED { Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; 4000d4b0: c4 06 60 04 ld [ %i1 + 4 ], %g2 _Chain_Extract_unprotected( &the_thread->Object.Node ); the_thread->Wait.queue = NULL; if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { 4000d4b4: c6 06 60 50 ld [ %i1 + 0x50 ], %g3 next->previous = previous; previous->next = next; 4000d4b8: c2 20 80 00 st %g1, [ %g2 ] Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; next->previous = previous; 4000d4bc: c4 20 60 04 st %g2, [ %g1 + 4 ] 4000d4c0: 80 a0 e0 02 cmp %g3, 2 4000d4c4: 02 80 00 06 be 4000d4dc <_Thread_queue_Extract_fifo+0x58> 4000d4c8: c0 26 60 44 clr [ %i1 + 0x44 ] _ISR_Enable( level ); 4000d4cc: 7f ff d2 20 call 40001d4c 4000d4d0: 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 ); 4000d4d4: 10 80 00 0a b 4000d4fc <_Thread_queue_Extract_fifo+0x78> 4000d4d8: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 4000d4dc: 82 10 20 03 mov 3, %g1 4000d4e0: c2 26 60 50 st %g1, [ %i1 + 0x50 ] } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); 4000d4e4: 7f ff d2 1a call 40001d4c 4000d4e8: 01 00 00 00 nop (void) _Watchdog_Remove( &the_thread->Timer ); 4000d4ec: 7f ff f2 9f call 40009f68 <_Watchdog_Remove> 4000d4f0: 90 06 60 48 add %i1, 0x48, %o0 4000d4f4: 33 04 00 ff sethi %hi(0x1003fc00), %i1 4000d4f8: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 4000d4fc: 7f ff ec ac call 400087ac <_Thread_Clear_state> 4000d500: 81 e8 00 00 restore 4000d504: 01 00 00 00 nop 4000c7f8 <_Thread_queue_Extract_priority_helper>: void _Thread_queue_Extract_priority_helper( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread, boolean requeuing ) { 4000c7f8: 9d e3 bf 98 save %sp, -104, %sp Chain_Node *new_first_node; Chain_Node *new_second_node; Chain_Node *last_node; the_node = (Chain_Node *) the_thread; _ISR_Disable( level ); 4000c7fc: 7f ff d5 50 call 40001d3c 4000c800: b0 10 00 19 mov %i1, %i0 if ( !_States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { 4000c804: c4 06 60 10 ld [ %i1 + 0x10 ], %g2 4000c808: 03 00 00 ef sethi %hi(0x3bc00), %g1 4000c80c: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 4000c810: 80 88 80 01 btst %g2, %g1 4000c814: 32 80 00 03 bne,a 4000c820 <_Thread_queue_Extract_priority_helper+0x28> 4000c818: c6 06 60 38 ld [ %i1 + 0x38 ], %g3 _ISR_Enable( level ); 4000c81c: 30 80 00 1d b,a 4000c890 <_Thread_queue_Extract_priority_helper+0x98> <== NOT EXECUTED */ next_node = the_node->next; previous_node = the_node->previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { 4000c820: 82 06 60 3c add %i1, 0x3c, %g1 /* * The thread was actually waiting on a thread queue so let's remove it. */ next_node = the_node->next; 4000c824: c4 06 40 00 ld [ %i1 ], %g2 previous_node = the_node->previous; if ( !_Chain_Is_empty( &the_thread->Wait.Block2n ) ) { 4000c828: 80 a0 c0 01 cmp %g3, %g1 4000c82c: 02 80 00 14 be 4000c87c <_Thread_queue_Extract_priority_helper+0x84> 4000c830: c2 06 60 04 ld [ %i1 + 4 ], %g1 new_first_node = the_thread->Wait.Block2n.first; new_first_thread = (Thread_Control *) new_first_node; last_node = the_thread->Wait.Block2n.last; 4000c834: da 06 60 40 ld [ %i1 + 0x40 ], %o5 new_second_node = new_first_node->next; 4000c838: c8 00 c0 00 ld [ %g3 ], %g4 previous_node->next = new_first_node; next_node->previous = new_first_node; 4000c83c: c6 20 a0 04 st %g3, [ %g2 + 4 ] new_first_node = the_thread->Wait.Block2n.first; new_first_thread = (Thread_Control *) new_first_node; last_node = the_thread->Wait.Block2n.last; new_second_node = new_first_node->next; previous_node->next = new_first_node; 4000c840: c6 20 40 00 st %g3, [ %g1 ] next_node->previous = new_first_node; new_first_node->next = next_node; 4000c844: c4 20 c0 00 st %g2, [ %g3 ] new_first_node->previous = previous_node; 4000c848: c2 20 e0 04 st %g1, [ %g3 + 4 ] if ( !_Chain_Has_only_one_node( &the_thread->Wait.Block2n ) ) { 4000c84c: c4 06 60 38 ld [ %i1 + 0x38 ], %g2 4000c850: c2 06 60 40 ld [ %i1 + 0x40 ], %g1 4000c854: 80 a0 80 01 cmp %g2, %g1 4000c858: 02 80 00 0c be 4000c888 <_Thread_queue_Extract_priority_helper+0x90> 4000c85c: 80 a6 a0 00 cmp %i2, 0 /* > two threads on 2-n */ new_second_node->previous = 4000c860: 82 00 e0 38 add %g3, 0x38, %g1 <== NOT EXECUTED 4000c864: c2 21 20 04 st %g1, [ %g4 + 4 ] <== NOT EXECUTED _Chain_Head( &new_first_thread->Wait.Block2n ); new_first_thread->Wait.Block2n.first = new_second_node; 4000c868: c8 20 e0 38 st %g4, [ %g3 + 0x38 ] <== NOT EXECUTED new_first_thread->Wait.Block2n.last = last_node; 4000c86c: da 20 e0 40 st %o5, [ %g3 + 0x40 ] <== NOT EXECUTED last_node->next = _Chain_Tail( &new_first_thread->Wait.Block2n ); 4000c870: 82 00 e0 3c add %g3, 0x3c, %g1 <== NOT EXECUTED 4000c874: 10 80 00 05 b 4000c888 <_Thread_queue_Extract_priority_helper+0x90> <== NOT EXECUTED 4000c878: c2 23 40 00 st %g1, [ %o5 ] <== NOT EXECUTED } } else { previous_node->next = next_node; next_node->previous = previous_node; 4000c87c: c2 20 a0 04 st %g1, [ %g2 + 4 ] new_first_thread->Wait.Block2n.last = last_node; last_node->next = _Chain_Tail( &new_first_thread->Wait.Block2n ); } } else { previous_node->next = next_node; 4000c880: c4 20 40 00 st %g2, [ %g1 ] /* * If we are not supposed to touch timers or the thread's state, return. */ if ( requeuing ) { 4000c884: 80 a6 a0 00 cmp %i2, 0 4000c888: 22 80 00 04 be,a 4000c898 <_Thread_queue_Extract_priority_helper+0xa0> 4000c88c: c2 06 20 50 ld [ %i0 + 0x50 ], %g1 _ISR_Enable( level ); 4000c890: 7f ff d5 2f call 40001d4c 4000c894: 91 e8 00 08 restore %g0, %o0, %o0 return; } if ( !_Watchdog_Is_active( &the_thread->Timer ) ) { 4000c898: 80 a0 60 02 cmp %g1, 2 4000c89c: 02 80 00 06 be 4000c8b4 <_Thread_queue_Extract_priority_helper+0xbc> 4000c8a0: 82 10 20 03 mov 3, %g1 _ISR_Enable( level ); 4000c8a4: 7f ff d5 2a call 40001d4c 4000c8a8: 33 04 00 ff sethi %hi(0x1003fc00), %i1 4000c8ac: 10 80 00 08 b 4000c8cc <_Thread_queue_Extract_priority_helper+0xd4> 4000c8b0: b2 16 63 f8 or %i1, 0x3f8, %i1 ! 1003fff8 4000c8b4: c2 26 20 50 st %g1, [ %i0 + 0x50 ] <== NOT EXECUTED } else { _Watchdog_Deactivate( &the_thread->Timer ); _ISR_Enable( level ); 4000c8b8: 7f ff d5 25 call 40001d4c <== NOT EXECUTED 4000c8bc: 33 04 00 ff sethi %hi(0x1003fc00), %i1 <== NOT EXECUTED (void) _Watchdog_Remove( &the_thread->Timer ); 4000c8c0: 7f ff f5 aa call 40009f68 <_Watchdog_Remove> <== NOT EXECUTED 4000c8c4: 90 06 20 48 add %i0, 0x48, %o0 <== NOT EXECUTED 4000c8c8: b2 16 63 f8 or %i1, 0x3f8, %i1 <== NOT EXECUTED 4000c8cc: 7f ff ef b8 call 400087ac <_Thread_Clear_state> 4000c8d0: 81 e8 00 00 restore 4000c8d4: 01 00 00 00 nop 40009318 <_Thread_queue_Extract_with_proxy>: */ boolean _Thread_queue_Extract_with_proxy( Thread_Control *the_thread ) { 40009318: 9d e3 bf 98 save %sp, -104, %sp States_Control state; Objects_Information *the_information; Objects_Thread_queue_Extract_callout proxy_extract_callout; state = the_thread->current_state; 4000931c: c4 06 20 10 ld [ %i0 + 0x10 ], %g2 */ boolean _Thread_queue_Extract_with_proxy( Thread_Control *the_thread ) { 40009320: a0 10 00 18 mov %i0, %l0 Objects_Information *the_information; Objects_Thread_queue_Extract_callout proxy_extract_callout; state = the_thread->current_state; if ( _States_Is_waiting_on_thread_queue( state ) ) { 40009324: 03 00 00 ef sethi %hi(0x3bc00), %g1 40009328: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 4000932c: 80 88 80 01 btst %g2, %g1 40009330: 02 80 00 1e be 400093a8 <_Thread_queue_Extract_with_proxy+0x90> 40009334: b0 10 20 00 clr %i0 if ( _States_Is_waiting_for_rpc_reply( state ) && 40009338: 03 00 00 08 sethi %hi(0x2000), %g1 4000933c: 80 88 80 01 btst %g2, %g1 40009340: 22 80 00 17 be,a 4000939c <_Thread_queue_Extract_with_proxy+0x84> 40009344: d0 04 20 44 ld [ %l0 + 0x44 ], %o0 40009348: 03 00 00 e7 sethi %hi(0x39c00), %g1 <== NOT EXECUTED 4000934c: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 39ee0 <== NOT EXECUTED 40009350: 80 88 80 01 btst %g2, %g1 <== NOT EXECUTED 40009354: 22 80 00 12 be,a 4000939c <_Thread_queue_Extract_with_proxy+0x84> <== NOT EXECUTED 40009358: d0 04 20 44 ld [ %l0 + 0x44 ], %o0 <== NOT EXECUTED _States_Is_locally_blocked( state ) ) { the_information = _Objects_Get_information( the_thread->Wait.id ); 4000935c: c6 04 20 20 ld [ %l0 + 0x20 ], %g3 <== NOT EXECUTED proxy_extract_callout = 40009360: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40009364: 85 30 e0 16 srl %g3, 0x16, %g2 <== NOT EXECUTED 40009368: 82 10 62 50 or %g1, 0x250, %g1 <== NOT EXECUTED 4000936c: 84 08 a0 1c and %g2, 0x1c, %g2 <== NOT EXECUTED 40009370: c2 00 40 02 ld [ %g1 + %g2 ], %g1 <== NOT EXECUTED 40009374: 87 30 e0 1b srl %g3, 0x1b, %g3 <== NOT EXECUTED 40009378: 87 28 e0 02 sll %g3, 2, %g3 <== NOT EXECUTED 4000937c: c2 00 40 03 ld [ %g1 + %g3 ], %g1 <== NOT EXECUTED 40009380: c2 00 60 48 ld [ %g1 + 0x48 ], %g1 <== NOT EXECUTED (Objects_Thread_queue_Extract_callout) the_information->extract; if ( proxy_extract_callout ) 40009384: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40009388: 22 80 00 05 be,a 4000939c <_Thread_queue_Extract_with_proxy+0x84> <== NOT EXECUTED 4000938c: d0 04 20 44 ld [ %l0 + 0x44 ], %o0 <== NOT EXECUTED (*proxy_extract_callout)( the_thread ); 40009390: 9f c0 40 00 call %g1 <== NOT EXECUTED 40009394: 90 10 00 10 mov %l0, %o0 <== NOT EXECUTED } _Thread_queue_Extract( the_thread->Wait.queue, the_thread ); 40009398: d0 04 20 44 ld [ %l0 + 0x44 ], %o0 <== NOT EXECUTED 4000939c: 92 10 00 10 mov %l0, %o1 400093a0: 40 00 0d 07 call 4000c7bc <_Thread_queue_Extract> 400093a4: b0 10 20 01 mov 1, %i0 return TRUE; } return FALSE; } 400093a8: 81 c7 e0 08 ret 400093ac: 81 e8 00 00 restore 4001a0e0 <_Thread_queue_First>: Thread_queue_Control *the_thread_queue ) { Thread_Control *the_thread; switch ( the_thread_queue->discipline ) { 4001a0e0: c2 02 20 34 ld [ %o0 + 0x34 ], %g1 4001a0e4: 80 a0 60 00 cmp %g1, 0 4001a0e8: 02 80 00 05 be 4001a0fc <_Thread_queue_First+0x1c> 4001a0ec: 80 a0 60 01 cmp %g1, 1 4001a0f0: 12 80 00 09 bne 4001a114 <_Thread_queue_First+0x34> 4001a0f4: 01 00 00 00 nop 4001a0f8: 30 80 00 04 b,a 4001a108 <_Thread_queue_First+0x28> case THREAD_QUEUE_DISCIPLINE_FIFO: the_thread = _Thread_queue_First_fifo( the_thread_queue ); 4001a0fc: 82 13 c0 00 mov %o7, %g1 4001a100: 40 00 02 da call 4001ac68 <_Thread_queue_First_fifo> 4001a104: 9e 10 40 00 mov %g1, %o7 break; case THREAD_QUEUE_DISCIPLINE_PRIORITY: the_thread = _Thread_queue_First_priority( the_thread_queue ); 4001a108: 82 13 c0 00 mov %o7, %g1 4001a10c: 40 00 00 04 call 4001a11c <_Thread_queue_First_priority> 4001a110: 9e 10 40 00 mov %g1, %o7 the_thread = NULL; break; } return the_thread; } 4001a114: 81 c3 e0 08 retl <== NOT EXECUTED 4001a118: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000945c <_Thread_queue_Requeue>: void _Thread_queue_Requeue( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread ) { 4000945c: 9d e3 bf 98 save %sp, -104, %sp /* just in case the thread really wasn't blocked here */ if ( !the_thread_queue ) { 40009460: 80 a6 20 00 cmp %i0, 0 40009464: 02 80 00 18 be 400094c4 <_Thread_queue_Requeue+0x68> 40009468: 01 00 00 00 nop return; } switch ( the_thread_queue->discipline ) { 4000946c: e0 06 20 34 ld [ %i0 + 0x34 ], %l0 40009470: 80 a4 20 01 cmp %l0, 1 40009474: 12 80 00 14 bne 400094c4 <_Thread_queue_Requeue+0x68> 40009478: 01 00 00 00 nop break; case THREAD_QUEUE_DISCIPLINE_PRIORITY: { Thread_queue_Control *tq = the_thread_queue; ISR_Level level; _ISR_Disable( level ); 4000947c: 7f ff e2 30 call 40001d3c 40009480: 01 00 00 00 nop 40009484: a2 10 00 08 mov %o0, %l1 if ( _States_Is_waiting_on_thread_queue( the_thread->current_state ) ) { 40009488: c4 06 60 10 ld [ %i1 + 0x10 ], %g2 4000948c: 03 00 00 ef sethi %hi(0x3bc00), %g1 40009490: 82 10 62 e0 or %g1, 0x2e0, %g1 ! 3bee0 40009494: 80 88 80 01 btst %g2, %g1 40009498: 02 80 00 09 be 400094bc <_Thread_queue_Requeue+0x60> 4000949c: 90 10 00 18 mov %i0, %o0 _Thread_queue_Enter_critical_section( tq ); _Thread_queue_Extract_priority_helper( tq, the_thread, TRUE ); 400094a0: 92 10 00 19 mov %i1, %o1 400094a4: 94 10 20 01 mov 1, %o2 400094a8: 40 00 0c d4 call 4000c7f8 <_Thread_queue_Extract_priority_helper> 400094ac: e0 26 20 30 st %l0, [ %i0 + 0x30 ] _Thread_queue_Enqueue_priority( tq, the_thread ); 400094b0: 90 10 00 18 mov %i0, %o0 400094b4: 7f ff ff 01 call 400090b8 <_Thread_queue_Enqueue_priority> 400094b8: 92 10 00 19 mov %i1, %o1 } _ISR_Enable( level ); 400094bc: 7f ff e2 24 call 40001d4c 400094c0: 91 e8 00 11 restore %g0, %l1, %o0 400094c4: 81 c7 e0 08 ret <== NOT EXECUTED 400094c8: 81 e8 00 00 restore <== NOT EXECUTED 400094cc <_Thread_queue_Timeout>: void _Thread_queue_Timeout( Objects_Id id, void *ignored ) { 400094cc: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 400094d0: 92 96 20 00 orcc %i0, 0, %o1 400094d4: 12 80 00 0a bne 400094fc <_Thread_queue_Timeout+0x30> 400094d8: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400094dc: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400094e0: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400094e4: 84 00 a0 01 inc %g2 <== NOT EXECUTED 400094e8: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] <== NOT EXECUTED Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 400094ec: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 400094f0: d2 00 63 cc ld [ %g1 + 0x3cc ], %o1 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 400094f4: 10 80 00 18 b 40009554 <_Thread_queue_Timeout+0x88> <== NOT EXECUTED 400094f8: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); 400094fc: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40009500: 80 a0 a0 04 cmp %g2, 4 40009504: 18 80 00 0e bgu 4000953c <_Thread_queue_Timeout+0x70> 40009508: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 4000950c: 83 32 60 1b srl %o1, 0x1b, %g1 40009510: 80 a0 60 01 cmp %g1, 1 40009514: 12 80 00 0a bne 4000953c <_Thread_queue_Timeout+0x70> 40009518: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 4000951c: 83 28 a0 02 sll %g2, 2, %g1 40009520: 05 10 00 63 sethi %hi(0x40018c00), %g2 40009524: 84 10 a2 50 or %g2, 0x250, %g2 ! 40018e50 <_Objects_Information_table> 40009528: c2 00 80 01 ld [ %g2 + %g1 ], %g1 4000952c: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40009530: 80 a2 20 00 cmp %o0, 0 40009534: 12 80 00 05 bne 40009548 <_Thread_queue_Timeout+0x7c> 40009538: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 4000953c: 92 10 20 00 clr %o1 <== NOT EXECUTED 40009540: 10 80 00 05 b 40009554 <_Thread_queue_Timeout+0x88> <== NOT EXECUTED 40009544: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40009548: 7f ff f8 5f call 400076c4 <_Objects_Get> 4000954c: 94 07 bf f4 add %fp, -12, %o2 40009550: 92 10 00 08 mov %o0, %o1 Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40009554: c2 07 bf f4 ld [ %fp + -12 ], %g1 40009558: 80 a0 60 00 cmp %g1, 0 4000955c: 12 80 00 18 bne 400095bc <_Thread_queue_Timeout+0xf0> 40009560: 01 00 00 00 nop */ static inline void _Thread_queue_Process_timeout( Thread_Control *the_thread ) { Thread_queue_Control *the_thread_queue = the_thread->Wait.queue; 40009564: c4 02 60 44 ld [ %o1 + 0x44 ], %g2 * 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. */ if ( the_thread_queue->sync_state != THREAD_QUEUE_SYNCHRONIZED && 40009568: c6 00 a0 30 ld [ %g2 + 0x30 ], %g3 4000956c: 80 a0 e0 00 cmp %g3, 0 40009570: 02 80 00 0b be 4000959c <_Thread_queue_Timeout+0xd0> 40009574: 03 10 00 63 sethi %hi(0x40018c00), %g1 40009578: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 40018fcc <_Thread_Executing> <== NOT EXECUTED 4000957c: 80 a2 40 01 cmp %o1, %g1 <== NOT EXECUTED 40009580: 32 80 00 08 bne,a 400095a0 <_Thread_queue_Timeout+0xd4> <== NOT EXECUTED 40009584: c2 00 a0 3c ld [ %g2 + 0x3c ], %g1 <== NOT EXECUTED _Thread_Is_executing( the_thread ) ) { if ( the_thread_queue->sync_state != THREAD_QUEUE_SATISFIED ) 40009588: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 4000958c: 02 80 00 08 be 400095ac <_Thread_queue_Timeout+0xe0> <== NOT EXECUTED 40009590: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED the_thread_queue->sync_state = THREAD_QUEUE_TIMEOUT; 40009594: 10 80 00 06 b 400095ac <_Thread_queue_Timeout+0xe0> <== NOT EXECUTED 40009598: c2 20 a0 30 st %g1, [ %g2 + 0x30 ] <== NOT EXECUTED } else { the_thread->Wait.return_code = the_thread->Wait.queue->timeout_status; 4000959c: c2 00 a0 3c ld [ %g2 + 0x3c ], %g1 _Thread_queue_Extract( the_thread->Wait.queue, the_thread ); 400095a0: d0 02 60 44 ld [ %o1 + 0x44 ], %o0 400095a4: 40 00 0c 86 call 4000c7bc <_Thread_queue_Extract> 400095a8: c2 22 60 34 st %g1, [ %o1 + 0x34 ] */ RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void ) { RTEMS_COMPILER_MEMORY_BARRIER(); _Thread_Dispatch_disable_level -= 1; 400095ac: 05 10 00 63 sethi %hi(0x40018c00), %g2 400095b0: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 400095b4: 82 00 7f ff add %g1, -1, %g1 400095b8: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 400095bc: 81 c7 e0 08 ret 400095c0: 81 e8 00 00 restore 400129cc <_Timer_Server_body>: */ Thread _Timer_Server_body( uint32_t ignored ) { 400129cc: 9d e3 bf 98 save %sp, -104, %sp /* * Initialize the "last time" markers to indicate the timer that * the server was initiated. */ _Timer_Server_ticks_last_time = _Watchdog_Ticks_since_boot; 400129d0: 03 10 00 c9 sethi %hi(0x40032400), %g1 400129d4: c8 00 60 64 ld [ %g1 + 0x64 ], %g4 ! 40032464 <_Watchdog_Ticks_since_boot> _Timer_Server_seconds_last_time = _TOD_Seconds_since_epoch; 400129d8: 03 10 00 c8 sethi %hi(0x40032000), %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400129dc: 07 10 00 c8 sethi %hi(0x40032000), %g3 400129e0: da 00 63 98 ld [ %g1 + 0x398 ], %o5 400129e4: c2 00 e2 e0 ld [ %g3 + 0x2e0 ], %g1 /* * Initialize the "last time" markers to indicate the timer that * the server was initiated. */ _Timer_Server_ticks_last_time = _Watchdog_Ticks_since_boot; 400129e8: 05 10 00 c8 sethi %hi(0x40032000), %g2 400129ec: 82 00 60 01 inc %g1 400129f0: c8 20 a1 ec st %g4, [ %g2 + 0x1ec ] 400129f4: c2 20 e2 e0 st %g1, [ %g3 + 0x2e0 ] _Timer_Server_seconds_last_time = _TOD_Seconds_since_epoch; 400129f8: 03 10 00 c8 sethi %hi(0x40032000), %g1 400129fc: da 20 61 e8 st %o5, [ %g1 + 0x1e8 ] ! 400321e8 <_Timer_Server_seconds_last_time> ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40012a00: 03 10 00 c8 sethi %hi(0x40032000), %g1 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 40012a04: 27 10 00 c8 sethi %hi(0x40032000), %l3 40012a08: ba 10 63 dc or %g1, 0x3dc, %i5 40012a0c: 82 14 e1 dc or %l3, 0x1dc, %g1 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40012a10: ae 00 60 04 add %g1, 4, %l7 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 40012a14: 03 10 00 c8 sethi %hi(0x40032000), %g1 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 40012a18: 25 10 00 c8 sethi %hi(0x40032000), %l2 40012a1c: a2 10 61 fc or %g1, 0x1fc, %l1 40012a20: 82 14 a1 f0 or %l2, 0x1f0, %g1 40012a24: a8 10 00 03 mov %g3, %l4 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40012a28: ac 00 60 04 add %g1, 4, %l6 /* * Block until there is something to do. */ _Thread_Set_state( _Timer_Server, STATES_DELAYING ); 40012a2c: 21 10 00 c9 sethi %hi(0x40032400), %l0 _Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog ); 40012a30: 03 10 00 c8 sethi %hi(0x40032000), %g1 40012a34: aa 10 63 d0 or %g1, 0x3d0, %l5 ! 400323d0 <_Watchdog_Seconds_chain> 40012a38: d0 04 22 98 ld [ %l0 + 0x298 ], %o0 40012a3c: 40 00 10 11 call 40016a80 <_Thread_Set_state> 40012a40: 92 10 20 08 mov 8, %o1 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 40012a44: c2 04 e1 dc ld [ %l3 + 0x1dc ], %g1 _Timer_Server_reset_ticks_timer(); 40012a48: 80 a0 40 17 cmp %g1, %l7 40012a4c: 22 80 00 09 be,a 40012a70 <_Timer_Server_body+0xa4> 40012a50: c2 04 a1 f0 ld [ %l2 + 0x1f0 ], %g1 40012a54: d2 04 22 98 ld [ %l0 + 0x298 ], %o1 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 40012a58: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40012a5c: 90 10 00 1d mov %i5, %o0 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 40012a60: c2 22 60 54 st %g1, [ %o1 + 0x54 ] _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40012a64: 40 00 12 c0 call 40017564 <_Watchdog_Insert> 40012a68: 92 02 60 48 add %o1, 0x48, %o1 40012a6c: c2 04 a1 f0 ld [ %l2 + 0x1f0 ], %g1 _Timer_Server_reset_seconds_timer(); 40012a70: 80 a0 40 16 cmp %g1, %l6 40012a74: 02 80 00 06 be 40012a8c <_Timer_Server_body+0xc0> 40012a78: 92 10 00 11 mov %l1, %o1 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 40012a7c: c2 00 60 10 ld [ %g1 + 0x10 ], %g1 <== NOT EXECUTED 40012a80: c2 24 60 0c st %g1, [ %l1 + 0xc ] <== NOT EXECUTED _Watchdog_Insert( &_Watchdog_Seconds_chain, the_watchdog ); 40012a84: 40 00 12 b8 call 40017564 <_Watchdog_Insert> <== NOT EXECUTED 40012a88: 90 10 00 15 mov %l5, %o0 <== NOT EXECUTED _Thread_Enable_dispatch(); 40012a8c: 7f ff ff c3 call 40012998 <_Thread_Enable_dispatch> 40012a90: 01 00 00 00 nop * At this point, at least one of the timers this task relies * upon has fired. Stop them both while we process any outstanding * timers. Before we block, we will restart them. */ _Timer_Server_stop_ticks_timer(); 40012a94: d0 04 22 98 ld [ %l0 + 0x298 ], %o0 40012a98: 40 00 13 0b call 400176c4 <_Watchdog_Remove> 40012a9c: 90 02 20 48 add %o0, 0x48, %o0 _Timer_Server_stop_seconds_timer(); 40012aa0: 40 00 13 09 call 400176c4 <_Watchdog_Remove> 40012aa4: 90 10 00 11 mov %l1, %o0 40012aa8: c2 05 22 e0 ld [ %l4 + 0x2e0 ], %g1 40012aac: 82 00 60 01 inc %g1 40012ab0: c2 25 22 e0 st %g1, [ %l4 + 0x2e0 ] * This ensures that the primary difference is that _ISR_Nest_level * is 0 for task-based timers and non-zero for the others. */ _Thread_Disable_dispatch(); _Timer_Server_process_ticks_chain(); 40012ab4: 7f ff ff a7 call 40012950 <_Timer_Server_process_ticks_chain> 40012ab8: 01 00 00 00 nop _Timer_Server_process_seconds_chain(); 40012abc: 7f ff ff 8d call 400128f0 <_Timer_Server_process_seconds_chain> 40012ac0: 01 00 00 00 nop /* * Block until there is something to do. */ _Thread_Set_state( _Timer_Server, STATES_DELAYING ); 40012ac4: 10 bf ff de b 40012a3c <_Timer_Server_body+0x70> 40012ac8: d0 04 22 98 ld [ %l0 + 0x298 ], %o0 40012950 <_Timer_Server_process_ticks_chain>: void _Timer_Server_process_ticks_chain(void) { Watchdog_Interval snapshot; Watchdog_Interval ticks; snapshot = _Watchdog_Ticks_since_boot; 40012950: 03 10 00 c9 sethi %hi(0x40032400), %g1 40012954: c4 00 60 64 ld [ %g1 + 0x64 ], %g2 ! 40032464 <_Watchdog_Ticks_since_boot> if ( snapshot >= _Timer_Server_ticks_last_time ) 40012958: 03 10 00 c8 sethi %hi(0x40032000), %g1 4001295c: c2 00 61 ec ld [ %g1 + 0x1ec ], %g1 ! 400321ec <_Timer_Server_ticks_last_time> 40012960: 80 a0 80 01 cmp %g2, %g1 40012964: 1a 80 00 04 bcc 40012974 <_Timer_Server_process_ticks_chain+0x24> 40012968: 94 20 80 01 sub %g2, %g1, %o2 ticks = snapshot - _Timer_Server_ticks_last_time; else ticks = (0xFFFFFFFF - _Timer_Server_ticks_last_time) + snapshot; 4001296c: 82 38 00 01 xnor %g0, %g1, %g1 <== NOT EXECUTED 40012970: 94 00 40 02 add %g1, %g2, %o2 <== NOT EXECUTED _Timer_Server_ticks_last_time = snapshot; 40012974: 03 10 00 c8 sethi %hi(0x40032000), %g1 _Watchdog_Adjust( &_Timer_Ticks_chain, WATCHDOG_FORWARD, ticks ); 40012978: 11 10 00 c8 sethi %hi(0x40032000), %o0 if ( snapshot >= _Timer_Server_ticks_last_time ) ticks = snapshot - _Timer_Server_ticks_last_time; else ticks = (0xFFFFFFFF - _Timer_Server_ticks_last_time) + snapshot; _Timer_Server_ticks_last_time = snapshot; 4001297c: c4 20 61 ec st %g2, [ %g1 + 0x1ec ] _Watchdog_Adjust( &_Timer_Ticks_chain, WATCHDOG_FORWARD, ticks ); 40012980: 90 12 21 dc or %o0, 0x1dc, %o0 40012984: 92 10 20 00 clr %o1 40012988: 82 13 c0 00 mov %o7, %g1 4001298c: 40 00 12 ce call 400174c4 <_Watchdog_Adjust> 40012990: 9e 10 40 00 mov %g1, %o7 40012994: 01 00 00 00 nop 4000b88c <_Timespec_Divide>: const struct timespec *lhs, const struct timespec *rhs, uint32_t *ival_percentage, uint32_t *fval_percentage ) { 4000b88c: 9d e3 bf 98 save %sp, -104, %sp * For math simplicity just convert the timespec to nanoseconds * in a 64-bit integer. */ left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; left += lhs->tv_nsec; right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; 4000b890: c2 06 40 00 ld [ %i1 ], %g1 /* * For math simplicity just convert the timespec to nanoseconds * in a 64-bit integer. */ left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; left += lhs->tv_nsec; 4000b894: de 06 20 04 ld [ %i0 + 4 ], %o7 right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; 4000b898: 96 10 00 01 mov %g1, %o3 4000b89c: 95 38 60 1f sra %g1, 0x1f, %o2 4000b8a0: 83 30 60 1d srl %g1, 0x1d, %g1 4000b8a4: 9b 2a e0 03 sll %o3, 3, %o5 4000b8a8: 99 2a a0 03 sll %o2, 3, %o4 4000b8ac: 98 10 40 0c or %g1, %o4, %o4 4000b8b0: 83 33 60 1b srl %o5, 0x1b, %g1 4000b8b4: 85 2b 20 05 sll %o4, 5, %g2 4000b8b8: 87 2b 60 05 sll %o5, 5, %g3 4000b8bc: 84 10 40 02 or %g1, %g2, %g2 4000b8c0: 86 a0 c0 0d subcc %g3, %o5, %g3 4000b8c4: 83 30 e0 1a srl %g3, 0x1a, %g1 4000b8c8: 84 60 80 0c subx %g2, %o4, %g2 4000b8cc: 9b 28 e0 06 sll %g3, 6, %o5 4000b8d0: 99 28 a0 06 sll %g2, 6, %o4 4000b8d4: 9a a3 40 03 subcc %o5, %g3, %o5 4000b8d8: 98 10 40 0c or %g1, %o4, %o4 4000b8dc: 98 63 00 02 subx %o4, %g2, %o4 4000b8e0: 9a 83 40 0b addcc %o5, %o3, %o5 4000b8e4: 83 33 60 1e srl %o5, 0x1e, %g1 4000b8e8: 98 43 00 0a addx %o4, %o2, %o4 4000b8ec: 87 2b 60 02 sll %o5, 2, %g3 4000b8f0: 85 2b 20 02 sll %o4, 2, %g2 4000b8f4: 9a 83 40 03 addcc %o5, %g3, %o5 4000b8f8: 84 10 40 02 or %g1, %g2, %g2 4000b8fc: 83 33 60 1e srl %o5, 0x1e, %g1 4000b900: 98 43 00 02 addx %o4, %g2, %o4 4000b904: 87 2b 60 02 sll %o5, 2, %g3 4000b908: 85 2b 20 02 sll %o4, 2, %g2 4000b90c: 9a 83 40 03 addcc %o5, %g3, %o5 4000b910: 84 10 40 02 or %g1, %g2, %g2 4000b914: 83 33 60 1e srl %o5, 0x1e, %g1 4000b918: 98 43 00 02 addx %o4, %g2, %o4 4000b91c: 85 2b 20 02 sll %o4, 2, %g2 4000b920: 84 10 40 02 or %g1, %g2, %g2 right += rhs->tv_nsec; 4000b924: c2 06 60 04 ld [ %i1 + 4 ], %g1 * For math simplicity just convert the timespec to nanoseconds * in a 64-bit integer. */ left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; left += lhs->tv_nsec; right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; 4000b928: 87 2b 60 02 sll %o5, 2, %g3 4000b92c: 9a 83 40 03 addcc %o5, %g3, %o5 right += rhs->tv_nsec; 4000b930: 95 38 60 1f sra %g1, 0x1f, %o2 * For math simplicity just convert the timespec to nanoseconds * in a 64-bit integer. */ left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; left += lhs->tv_nsec; right = rhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; 4000b934: 98 43 00 02 addx %o4, %g2, %o4 4000b938: 89 33 60 17 srl %o5, 0x17, %g4 4000b93c: 85 2b 20 09 sll %o4, 9, %g2 4000b940: 87 2b 60 09 sll %o5, 9, %g3 4000b944: 84 11 00 02 or %g4, %g2, %g2 right += rhs->tv_nsec; 4000b948: 96 80 c0 01 addcc %g3, %g1, %o3 4000b94c: 94 40 80 0a addx %g2, %o2, %o2 if ( right == 0 ) { 4000b950: 80 92 80 0b orcc %o2, %o3, %g0 4000b954: 12 80 00 06 bne 4000b96c <_Timespec_Divide+0xe0> 4000b958: f0 06 00 00 ld [ %i0 ], %i0 *ival_percentage = 0; 4000b95c: c0 26 80 00 clr [ %i2 ] <== NOT EXECUTED *fval_percentage = 0; 4000b960: c0 26 c0 00 clr [ %i3 ] <== NOT EXECUTED 4000b964: 81 c7 e0 08 ret <== NOT EXECUTED 4000b968: 81 e8 00 00 restore <== NOT EXECUTED /* * For math simplicity just convert the timespec to nanoseconds * in a 64-bit integer. */ left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; 4000b96c: 83 36 20 1d srl %i0, 0x1d, %g1 4000b970: 9b 2e 20 03 sll %i0, 3, %o5 4000b974: 91 3e 20 1f sra %i0, 0x1f, %o0 4000b978: 99 2a 20 03 sll %o0, 3, %o4 4000b97c: 98 10 40 0c or %g1, %o4, %o4 4000b980: 83 33 60 1b srl %o5, 0x1b, %g1 4000b984: 85 2b 20 05 sll %o4, 5, %g2 4000b988: 87 2b 60 05 sll %o5, 5, %g3 4000b98c: 84 10 40 02 or %g1, %g2, %g2 4000b990: 86 a0 c0 0d subcc %g3, %o5, %g3 4000b994: 83 30 e0 1a srl %g3, 0x1a, %g1 4000b998: 84 60 80 0c subx %g2, %o4, %g2 4000b99c: 9b 28 e0 06 sll %g3, 6, %o5 4000b9a0: 99 28 a0 06 sll %g2, 6, %o4 4000b9a4: 9a a3 40 03 subcc %o5, %g3, %o5 4000b9a8: 98 10 40 0c or %g1, %o4, %o4 4000b9ac: 98 63 00 02 subx %o4, %g2, %o4 4000b9b0: 9a 83 40 18 addcc %o5, %i0, %o5 4000b9b4: 83 33 60 1e srl %o5, 0x1e, %g1 4000b9b8: 98 43 00 08 addx %o4, %o0, %o4 4000b9bc: 87 2b 60 02 sll %o5, 2, %g3 4000b9c0: 85 2b 20 02 sll %o4, 2, %g2 4000b9c4: 9a 83 40 03 addcc %o5, %g3, %o5 4000b9c8: 84 10 40 02 or %g1, %g2, %g2 4000b9cc: 83 33 60 1e srl %o5, 0x1e, %g1 4000b9d0: 98 43 00 02 addx %o4, %g2, %o4 4000b9d4: 87 2b 60 02 sll %o5, 2, %g3 4000b9d8: 85 2b 20 02 sll %o4, 2, %g2 4000b9dc: 9a 83 40 03 addcc %o5, %g3, %o5 4000b9e0: 84 10 40 02 or %g1, %g2, %g2 4000b9e4: 83 33 60 1e srl %o5, 0x1e, %g1 4000b9e8: 98 43 00 02 addx %o4, %g2, %o4 4000b9ec: 87 2b 60 02 sll %o5, 2, %g3 4000b9f0: 85 2b 20 02 sll %o4, 2, %g2 4000b9f4: 9a 83 40 03 addcc %o5, %g3, %o5 4000b9f8: 84 10 40 02 or %g1, %g2, %g2 4000b9fc: 83 33 60 17 srl %o5, 0x17, %g1 4000ba00: 98 43 00 02 addx %o4, %g2, %o4 4000ba04: 93 2b 60 09 sll %o5, 9, %o1 4000ba08: 91 2b 20 09 sll %o4, 9, %o0 * Put it back in the timespec result. * * TODO: Rounding on the last digit of the fval. */ answer = (left * 100000) / right; 4000ba0c: 92 82 40 0f addcc %o1, %o7, %o1 /* * For math simplicity just convert the timespec to nanoseconds * in a 64-bit integer. */ left = lhs->tv_sec * (uint64_t)TOD_NANOSECONDS_PER_SECOND; 4000ba10: 90 10 40 08 or %g1, %o0, %o0 * Put it back in the timespec result. * * TODO: Rounding on the last digit of the fval. */ answer = (left * 100000) / right; 4000ba14: 83 32 60 1e srl %o1, 0x1e, %g1 4000ba18: a1 3b e0 1f sra %o7, 0x1f, %l0 4000ba1c: 87 2a 60 02 sll %o1, 2, %g3 4000ba20: 90 42 00 10 addx %o0, %l0, %o0 4000ba24: 85 2a 20 02 sll %o0, 2, %g2 4000ba28: 84 10 40 02 or %g1, %g2, %g2 4000ba2c: 83 30 e0 1b srl %g3, 0x1b, %g1 4000ba30: 99 28 a0 05 sll %g2, 5, %o4 4000ba34: 9b 28 e0 05 sll %g3, 5, %o5 4000ba38: 98 10 40 0c or %g1, %o4, %o4 4000ba3c: 9a a3 40 03 subcc %o5, %g3, %o5 4000ba40: 98 63 00 02 subx %o4, %g2, %o4 4000ba44: 9a 83 40 09 addcc %o5, %o1, %o5 4000ba48: 83 33 60 1e srl %o5, 0x1e, %g1 4000ba4c: 98 43 00 08 addx %o4, %o0, %o4 4000ba50: 87 2b 60 02 sll %o5, 2, %g3 4000ba54: 85 2b 20 02 sll %o4, 2, %g2 4000ba58: 9a 83 40 03 addcc %o5, %g3, %o5 4000ba5c: 84 10 40 02 or %g1, %g2, %g2 4000ba60: 83 33 60 1e srl %o5, 0x1e, %g1 4000ba64: 87 2b 60 02 sll %o5, 2, %g3 4000ba68: 98 43 00 02 addx %o4, %g2, %o4 4000ba6c: 9a 83 40 03 addcc %o5, %g3, %o5 4000ba70: 85 2b 20 02 sll %o4, 2, %g2 4000ba74: 84 10 40 02 or %g1, %g2, %g2 4000ba78: 83 33 60 1b srl %o5, 0x1b, %g1 4000ba7c: 98 43 00 02 addx %o4, %g2, %o4 4000ba80: 93 2b 60 05 sll %o5, 5, %o1 4000ba84: 91 2b 20 05 sll %o4, 5, %o0 4000ba88: 40 00 32 59 call 400183ec <__udivdi3> 4000ba8c: 90 10 40 08 or %g1, %o0, %o0 *ival_percentage = answer / 1000; 4000ba90: 94 10 20 00 clr %o2 * Put it back in the timespec result. * * TODO: Rounding on the last digit of the fval. */ answer = (left * 100000) / right; 4000ba94: a0 10 00 08 mov %o0, %l0 4000ba98: a2 10 00 09 mov %o1, %l1 *ival_percentage = answer / 1000; 4000ba9c: 96 10 23 e8 mov 0x3e8, %o3 4000baa0: 40 00 32 53 call 400183ec <__udivdi3> 4000baa4: 90 10 00 10 mov %l0, %o0 *fval_percentage = answer % 1000; 4000baa8: 90 10 00 10 mov %l0, %o0 * TODO: Rounding on the last digit of the fval. */ answer = (left * 100000) / right; *ival_percentage = answer / 1000; 4000baac: d2 26 80 00 st %o1, [ %i2 ] *fval_percentage = answer % 1000; 4000bab0: 94 10 20 00 clr %o2 4000bab4: 92 10 00 11 mov %l1, %o1 4000bab8: 40 00 33 2c call 40018768 <__umoddi3> 4000babc: 96 10 23 e8 mov 0x3e8, %o3 4000bac0: d2 26 c0 00 st %o1, [ %i3 ] 4000bac4: 81 c7 e0 08 ret 4000bac8: 81 e8 00 00 restore 40013750 <_Timespec_From_ticks>: void _Timespec_From_ticks( uint32_t ticks, struct timespec *time ) { 40013750: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED uint32_t usecs; usecs = ticks * _TOD_Microseconds_per_tick; 40013754: 03 10 00 9e sethi %hi(0x40027800), %g1 <== NOT EXECUTED 40013758: d2 00 60 cc ld [ %g1 + 0xcc ], %o1 ! 400278cc <_TOD_Microseconds_per_tick> <== NOT EXECUTED 4001375c: 40 00 2e e8 call 4001f2fc <.umul> <== NOT EXECUTED 40013760: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED time->tv_sec = usecs / TOD_MICROSECONDS_PER_SECOND; 40013764: 21 00 03 d0 sethi %hi(0xf4000), %l0 <== NOT EXECUTED struct timespec *time ) { uint32_t usecs; usecs = ticks * _TOD_Microseconds_per_tick; 40013768: a2 10 00 08 mov %o0, %l1 <== NOT EXECUTED time->tv_sec = usecs / TOD_MICROSECONDS_PER_SECOND; 4001376c: 7f ff b8 03 call 40001778 <.udiv> <== NOT EXECUTED 40013770: 92 14 22 40 or %l0, 0x240, %o1 <== NOT EXECUTED time->tv_nsec = (usecs % TOD_MICROSECONDS_PER_SECOND) * 40013774: 92 14 22 40 or %l0, 0x240, %o1 <== NOT EXECUTED { uint32_t usecs; usecs = ticks * _TOD_Microseconds_per_tick; time->tv_sec = usecs / TOD_MICROSECONDS_PER_SECOND; 40013778: d0 26 40 00 st %o0, [ %i1 ] <== NOT EXECUTED time->tv_nsec = (usecs % TOD_MICROSECONDS_PER_SECOND) * 4001377c: 40 00 2f 1a call 4001f3e4 <.urem> <== NOT EXECUTED 40013780: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 40013784: 85 2a 20 02 sll %o0, 2, %g2 <== NOT EXECUTED 40013788: 83 2a 20 07 sll %o0, 7, %g1 <== NOT EXECUTED 4001378c: 82 20 40 02 sub %g1, %g2, %g1 <== NOT EXECUTED 40013790: 82 00 40 08 add %g1, %o0, %g1 <== NOT EXECUTED 40013794: 83 28 60 03 sll %g1, 3, %g1 <== NOT EXECUTED 40013798: c2 26 60 04 st %g1, [ %i1 + 4 ] <== NOT EXECUTED TOD_NANOSECONDS_PER_MICROSECOND; } 4001379c: 81 c7 e0 08 ret <== NOT EXECUTED 400137a0: 81 e8 00 00 restore <== NOT EXECUTED 400137a4 <_Timespec_Is_valid>: boolean _Timespec_Is_valid( const struct timespec *time ) { if ( !time ) 400137a4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 400137a8: 02 80 00 0e be 400137e0 <_Timespec_Is_valid+0x3c> <== NOT EXECUTED 400137ac: 01 00 00 00 nop <== NOT EXECUTED return FALSE; if ( time->tv_sec < 0 ) 400137b0: c2 02 00 00 ld [ %o0 ], %g1 <== NOT EXECUTED 400137b4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 400137b8: 06 80 00 0a bl 400137e0 <_Timespec_Is_valid+0x3c> <== NOT EXECUTED 400137bc: 01 00 00 00 nop <== NOT EXECUTED return FALSE; if ( time->tv_nsec < 0 ) 400137c0: d0 02 20 04 ld [ %o0 + 4 ], %o0 <== NOT EXECUTED 400137c4: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 400137c8: 06 80 00 06 bl 400137e0 <_Timespec_Is_valid+0x3c> <== NOT EXECUTED 400137cc: 03 0e e6 b2 sethi %hi(0x3b9ac800), %g1 <== NOT EXECUTED 400137d0: 82 10 61 ff or %g1, 0x1ff, %g1 ! 3b9ac9ff <== NOT EXECUTED 400137d4: 80 a0 40 08 cmp %g1, %o0 <== NOT EXECUTED 400137d8: 81 c3 e0 08 retl <== NOT EXECUTED 400137dc: 90 60 3f ff subx %g0, -1, %o0 <== NOT EXECUTED if ( time->tv_nsec >= TOD_NANOSECONDS_PER_SECOND ) return FALSE; return TRUE; } 400137e0: 81 c3 e0 08 retl <== NOT EXECUTED 400137e4: 90 10 20 00 clr %o0 <== NOT EXECUTED 400137e8 <_Timespec_To_ticks>: */ uint32_t _Timespec_To_ticks( const struct timespec *time ) { 400137e8: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED uint32_t ticks; if ( (time->tv_sec == 0) && (time->tv_nsec == 0) ) 400137ec: e0 06 00 00 ld [ %i0 ], %l0 <== NOT EXECUTED 400137f0: 80 a4 20 00 cmp %l0, 0 <== NOT EXECUTED 400137f4: 12 80 00 06 bne 4001380c <_Timespec_To_ticks+0x24> <== NOT EXECUTED 400137f8: a4 10 00 18 mov %i0, %l2 <== NOT EXECUTED 400137fc: c2 06 20 04 ld [ %i0 + 4 ], %g1 <== NOT EXECUTED 40013800: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40013804: 02 80 00 13 be 40013850 <_Timespec_To_ticks+0x68> <== NOT EXECUTED 40013808: b0 10 20 00 clr %i0 <== NOT EXECUTED return 0; ticks = time->tv_sec * TOD_TICKS_PER_SECOND; 4001380c: 03 10 00 9e sethi %hi(0x40027800), %g1 <== NOT EXECUTED 40013810: e2 00 60 cc ld [ %g1 + 0xcc ], %l1 ! 400278cc <_TOD_Microseconds_per_tick> <== NOT EXECUTED 40013814: 11 00 03 d0 sethi %hi(0xf4000), %o0 <== NOT EXECUTED 40013818: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED 4001381c: 7f ff b7 d7 call 40001778 <.udiv> <== NOT EXECUTED 40013820: 90 12 22 40 or %o0, 0x240, %o0 <== NOT EXECUTED 40013824: 40 00 2e b6 call 4001f2fc <.umul> <== NOT EXECUTED 40013828: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 4001382c: a0 10 00 08 mov %o0, %l0 <== NOT EXECUTED ticks += (time->tv_nsec / TOD_NANOSECONDS_PER_MICROSECOND) / 40013830: d0 04 a0 04 ld [ %l2 + 4 ], %o0 <== NOT EXECUTED 40013834: 7f ff b7 d1 call 40001778 <.udiv> <== NOT EXECUTED 40013838: 92 10 23 e8 mov 0x3e8, %o1 <== NOT EXECUTED 4001383c: 7f ff b7 cf call 40001778 <.udiv> <== NOT EXECUTED 40013840: 92 10 00 11 mov %l1, %o1 <== NOT EXECUTED _TOD_Microseconds_per_tick; if (ticks) 40013844: b0 82 00 10 addcc %o0, %l0, %i0 <== NOT EXECUTED 40013848: 22 80 00 02 be,a 40013850 <_Timespec_To_ticks+0x68> <== NOT EXECUTED 4001384c: b0 10 20 01 mov 1, %i0 <== NOT EXECUTED return ticks; return 1; } 40013850: 81 c7 e0 08 ret <== NOT EXECUTED 40013854: 81 e8 00 00 restore <== NOT EXECUTED 4000cab0 <_User_extensions_Add_API_set>: */ void _User_extensions_Add_API_set ( User_extensions_Control *the_extension ) { 4000cab0: 9d e3 bf 98 save %sp, -104, %sp _Chain_Append( &_User_extensions_List, &the_extension->Node ); 4000cab4: 11 10 00 64 sethi %hi(0x40019000), %o0 4000cab8: 92 10 00 18 mov %i0, %o1 4000cabc: 7f ff e7 29 call 40006760 <_Chain_Append> 4000cac0: 90 12 21 74 or %o0, 0x174, %o0 /* * If a switch handler is present, append it to the switch chain. */ if ( the_extension->Callouts.thread_switch != NULL ) { 4000cac4: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 4000cac8: 80 a0 60 00 cmp %g1, 0 4000cacc: 02 80 00 06 be 4000cae4 <_User_extensions_Add_API_set+0x34> 4000cad0: b2 06 20 08 add %i0, 8, %i1 the_extension->Switch.thread_switch = the_extension->Callouts.thread_switch; 4000cad4: c2 26 20 10 st %g1, [ %i0 + 0x10 ] _Chain_Append( 4000cad8: 31 10 00 63 sethi %hi(0x40018c00), %i0 4000cadc: 7f ff e7 21 call 40006760 <_Chain_Append> 4000cae0: 91 ee 22 f4 restore %i0, 0x2f4, %o0 4000cae4: 81 c7 e0 08 ret <== NOT EXECUTED 4000cae8: 81 e8 00 00 restore <== NOT EXECUTED 40009c50 <_User_extensions_Fatal>: void _User_extensions_Fatal ( Internal_errors_Source the_source, boolean is_internal, uint32_t the_error ) { 40009c50: 9d e3 bf 98 save %sp, -104, %sp Chain_Node *the_node; User_extensions_Control *the_extension; for ( the_node = _User_extensions_List.last ; 40009c54: 03 10 00 64 sethi %hi(0x40019000), %g1 40009c58: 82 10 61 74 or %g1, 0x174, %g1 ! 40019174 <_User_extensions_List> 40009c5c: e0 00 60 08 ld [ %g1 + 8 ], %l0 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Head( Chain_Control *the_chain ) { return (Chain_Node *) the_chain; 40009c60: 10 80 00 09 b 40009c84 <_User_extensions_Fatal+0x34> 40009c64: a2 10 00 01 mov %g1, %l1 !_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 ) 40009c68: 80 a0 60 00 cmp %g1, 0 40009c6c: 02 80 00 05 be 40009c80 <_User_extensions_Fatal+0x30> 40009c70: 90 10 00 18 mov %i0, %o0 (*the_extension->Callouts.fatal)( the_source, is_internal, the_error ); 40009c74: 92 10 00 19 mov %i1, %o1 <== NOT EXECUTED 40009c78: 9f c0 40 00 call %g1 <== NOT EXECUTED 40009c7c: 94 10 00 1a mov %i2, %o2 <== NOT EXECUTED 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 ) { 40009c80: e0 04 20 04 ld [ %l0 + 4 ], %l0 { Chain_Node *the_node; User_extensions_Control *the_extension; for ( the_node = _User_extensions_List.last ; !_Chain_Is_head( &_User_extensions_List, the_node ) ; 40009c84: 80 a4 00 11 cmp %l0, %l1 40009c88: 32 bf ff f8 bne,a 40009c68 <_User_extensions_Fatal+0x18> 40009c8c: c2 04 20 30 ld [ %l0 + 0x30 ], %g1 the_extension = (User_extensions_Control *) the_node; if ( the_extension->Callouts.fatal != NULL ) (*the_extension->Callouts.fatal)( the_source, is_internal, the_error ); } } 40009c90: 81 c7 e0 08 ret 40009c94: 81 e8 00 00 restore 4000e50c <_User_extensions_Remove_set>: */ void _User_extensions_Remove_set ( User_extensions_Control *the_extension ) { 4000e50c: 9d e3 bf 98 save %sp, -104, %sp <== NOT EXECUTED _Chain_Extract( &the_extension->Node ); 4000e510: 40 00 11 7e call 40012b08 <_Chain_Extract> <== NOT EXECUTED 4000e514: 90 10 00 18 mov %i0, %o0 <== NOT EXECUTED /* * If a switch handler is present, remove it. */ if ( the_extension->Callouts.thread_switch != NULL ) 4000e518: c2 06 20 24 ld [ %i0 + 0x24 ], %g1 <== NOT EXECUTED 4000e51c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000e520: 02 80 00 04 be 4000e530 <_User_extensions_Remove_set+0x24> <== NOT EXECUTED 4000e524: 01 00 00 00 nop <== NOT EXECUTED _Chain_Extract( &the_extension->Switch.Node ); 4000e528: 40 00 11 78 call 40012b08 <_Chain_Extract> <== NOT EXECUTED 4000e52c: 91 ee 20 08 restore %i0, 8, %o0 <== NOT EXECUTED 4000e530: 81 c7 e0 08 ret <== NOT EXECUTED 4000e534: 81 e8 00 00 restore <== NOT EXECUTED 40009e08 <_Watchdog_Insert>: void _Watchdog_Insert( Chain_Control *header, Watchdog_Control *the_watchdog ) { 40009e08: 9d e3 bf 98 save %sp, -104, %sp Watchdog_Control *after; uint32_t insert_isr_nest_level; Watchdog_Interval delta_interval; insert_isr_nest_level = _ISR_Nest_level; 40009e0c: 03 10 00 63 sethi %hi(0x40018c00), %g1 void _Watchdog_Insert( Chain_Control *header, Watchdog_Control *the_watchdog ) { 40009e10: aa 10 00 18 mov %i0, %l5 Watchdog_Control *after; uint32_t insert_isr_nest_level; Watchdog_Interval delta_interval; insert_isr_nest_level = _ISR_Nest_level; 40009e14: e6 00 63 b4 ld [ %g1 + 0x3b4 ], %l3 _ISR_Disable( level ); 40009e18: 7f ff df c9 call 40001d3c 40009e1c: 01 00 00 00 nop 40009e20: b0 10 00 08 mov %o0, %i0 /* * Check to see if the watchdog has just been inserted by a * higher priority interrupt. If so, abandon this insert. */ if ( the_watchdog->state != WATCHDOG_INACTIVE ) { 40009e24: c2 06 60 08 ld [ %i1 + 8 ], %g1 40009e28: 80 a0 60 00 cmp %g1, 0 40009e2c: 02 80 00 03 be 40009e38 <_Watchdog_Insert+0x30> 40009e30: 03 10 00 64 sethi %hi(0x40019000), %g1 _ISR_Enable( level ); 40009e34: 30 80 00 37 b,a 40009f10 <_Watchdog_Insert+0x108> <== NOT EXECUTED return; } the_watchdog->state = WATCHDOG_BEING_INSERTED; _Watchdog_Sync_count++; 40009e38: c4 00 60 70 ld [ %g1 + 0x70 ], %g2 ! 40019070 <_Watchdog_Sync_count> if ( the_watchdog->state != WATCHDOG_INACTIVE ) { _ISR_Enable( level ); return; } the_watchdog->state = WATCHDOG_BEING_INSERTED; 40009e3c: 86 10 20 01 mov 1, %g3 _Watchdog_Sync_count++; 40009e40: 84 00 a0 01 inc %g2 if ( the_watchdog->state != WATCHDOG_INACTIVE ) { _ISR_Enable( level ); return; } the_watchdog->state = WATCHDOG_BEING_INSERTED; 40009e44: c6 26 60 08 st %g3, [ %i1 + 8 ] _Watchdog_Sync_count++; 40009e48: c4 20 60 70 st %g2, [ %g1 + 0x70 ] if ( the_watchdog->state != WATCHDOG_BEING_INSERTED ) { goto exit_insert; } if ( _Watchdog_Sync_level > insert_isr_nest_level ) { 40009e4c: 29 10 00 63 sethi %hi(0x40018c00), %l4 the_watchdog->state = WATCHDOG_BEING_INSERTED; _Watchdog_Sync_count++; restart: delta_interval = the_watchdog->initial; 40009e50: e4 06 60 0c ld [ %i1 + 0xc ], %l2 * cache *header!! * * Till Straumann, 7/2003 (gcc-3.2.2 -O4 on powerpc) * */ for ( after = (Watchdog_Control *) ((volatile Chain_Control *)header)->first ; 40009e54: e2 05 40 00 ld [ %l5 ], %l1 ; after = _Watchdog_Next( after ) ) { if ( delta_interval == 0 || !_Watchdog_Next( after ) ) 40009e58: 80 a4 a0 00 cmp %l2, 0 40009e5c: 22 80 00 1c be,a 40009ecc <_Watchdog_Insert+0xc4> 40009e60: c4 04 60 04 ld [ %l1 + 4 ], %g2 RTEMS_INLINE_ROUTINE Watchdog_Control *_Watchdog_Next( Watchdog_Control *the_watchdog ) { return ( (Watchdog_Control *) the_watchdog->Node.next ); 40009e64: c2 04 40 00 ld [ %l1 ], %g1 40009e68: 80 a0 60 00 cmp %g1, 0 40009e6c: 22 80 00 18 be,a 40009ecc <_Watchdog_Insert+0xc4> 40009e70: c4 04 60 04 ld [ %l1 + 4 ], %g2 break; if ( delta_interval < after->delta_interval ) { 40009e74: e0 04 60 10 ld [ %l1 + 0x10 ], %l0 40009e78: 80 a4 80 10 cmp %l2, %l0 40009e7c: 1a 80 00 04 bcc 40009e8c <_Watchdog_Insert+0x84> 40009e80: 82 24 00 12 sub %l0, %l2, %g1 after->delta_interval -= delta_interval; 40009e84: 10 80 00 11 b 40009ec8 <_Watchdog_Insert+0xc0> 40009e88: c2 24 60 10 st %g1, [ %l1 + 0x10 ] * used around this flash point allowed interrupts to execute * which violated the design assumptions. The critical section * mechanism used here WAS redesigned to address this. */ _ISR_Flash( level ); 40009e8c: 7f ff df b0 call 40001d4c 40009e90: 90 10 00 18 mov %i0, %o0 40009e94: 7f ff df aa call 40001d3c 40009e98: 01 00 00 00 nop if ( the_watchdog->state != WATCHDOG_BEING_INSERTED ) { 40009e9c: c2 06 60 08 ld [ %i1 + 8 ], %g1 40009ea0: 80 a0 60 01 cmp %g1, 1 40009ea4: 12 80 00 15 bne 40009ef8 <_Watchdog_Insert+0xf0> 40009ea8: a4 24 80 10 sub %l2, %l0, %l2 goto exit_insert; } if ( _Watchdog_Sync_level > insert_isr_nest_level ) { 40009eac: c2 05 23 c8 ld [ %l4 + 0x3c8 ], %g1 40009eb0: 80 a0 40 13 cmp %g1, %l3 40009eb4: 28 bf ff e9 bleu,a 40009e58 <_Watchdog_Insert+0x50> 40009eb8: e2 04 40 00 ld [ %l1 ], %l1 _Watchdog_Sync_level = insert_isr_nest_level; 40009ebc: e6 25 23 c8 st %l3, [ %l4 + 0x3c8 ] the_watchdog->state = WATCHDOG_BEING_INSERTED; _Watchdog_Sync_count++; restart: delta_interval = the_watchdog->initial; 40009ec0: 10 bf ff e5 b 40009e54 <_Watchdog_Insert+0x4c> 40009ec4: e4 06 60 0c ld [ %i1 + 0xc ], %l2 _Watchdog_Activate( the_watchdog ); the_watchdog->delta_interval = delta_interval; _Chain_Insert_unprotected( after->Node.previous, &the_watchdog->Node ); 40009ec8: c4 04 60 04 ld [ %l1 + 4 ], %g2 the_watchdog->start_time = _Watchdog_Ticks_since_boot; 40009ecc: 03 10 00 64 sethi %hi(0x40019000), %g1 ) { Chain_Node *before_node; the_node->previous = after_node; before_node = after_node->next; 40009ed0: c6 00 80 00 ld [ %g2 ], %g3 40009ed4: c2 00 60 74 ld [ %g1 + 0x74 ], %g1 after_node->next = the_node; 40009ed8: f2 20 80 00 st %i1, [ %g2 ] Chain_Node *the_node ) { Chain_Node *before_node; the_node->previous = after_node; 40009edc: c4 26 60 04 st %g2, [ %i1 + 4 ] 40009ee0: c2 26 60 14 st %g1, [ %i1 + 0x14 ] } } _Watchdog_Activate( the_watchdog ); the_watchdog->delta_interval = delta_interval; 40009ee4: e4 26 60 10 st %l2, [ %i1 + 0x10 ] RTEMS_INLINE_ROUTINE void _Watchdog_Activate( Watchdog_Control *the_watchdog ) { the_watchdog->state = WATCHDOG_ACTIVE; 40009ee8: 82 10 20 02 mov 2, %g1 before_node = after_node->next; after_node->next = the_node; the_node->next = before_node; before_node->previous = the_node; 40009eec: f2 20 e0 04 st %i1, [ %g3 + 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; 40009ef0: c6 26 40 00 st %g3, [ %i1 ] 40009ef4: c2 26 60 08 st %g1, [ %i1 + 8 ] _Chain_Insert_unprotected( after->Node.previous, &the_watchdog->Node ); the_watchdog->start_time = _Watchdog_Ticks_since_boot; exit_insert: _Watchdog_Sync_level = insert_isr_nest_level; 40009ef8: 03 10 00 63 sethi %hi(0x40018c00), %g1 _Watchdog_Sync_count--; 40009efc: 05 10 00 64 sethi %hi(0x40019000), %g2 _Chain_Insert_unprotected( after->Node.previous, &the_watchdog->Node ); the_watchdog->start_time = _Watchdog_Ticks_since_boot; exit_insert: _Watchdog_Sync_level = insert_isr_nest_level; 40009f00: e6 20 63 c8 st %l3, [ %g1 + 0x3c8 ] _Watchdog_Sync_count--; 40009f04: c2 00 a0 70 ld [ %g2 + 0x70 ], %g1 40009f08: 82 00 7f ff add %g1, -1, %g1 40009f0c: c2 20 a0 70 st %g1, [ %g2 + 0x70 ] _ISR_Enable( level ); 40009f10: 7f ff df 8f call 40001d4c 40009f14: 81 e8 00 00 restore 40009f18: 01 00 00 00 nop 40009f68 <_Watchdog_Remove>: */ Watchdog_States _Watchdog_Remove( Watchdog_Control *the_watchdog ) { 40009f68: 9d e3 bf 98 save %sp, -104, %sp ISR_Level level; Watchdog_States previous_state; Watchdog_Control *next_watchdog; _ISR_Disable( level ); 40009f6c: 7f ff df 74 call 40001d3c 40009f70: 01 00 00 00 nop previous_state = the_watchdog->state; 40009f74: e0 06 20 08 ld [ %i0 + 8 ], %l0 switch ( previous_state ) { 40009f78: 80 a4 20 01 cmp %l0, 1 40009f7c: 22 80 00 1e be,a 40009ff4 <_Watchdog_Remove+0x8c> 40009f80: c0 26 20 08 clr [ %i0 + 8 ] <== NOT EXECUTED 40009f84: 0a 80 00 1d bcs 40009ff8 <_Watchdog_Remove+0x90> 40009f88: 03 10 00 64 sethi %hi(0x40019000), %g1 40009f8c: 80 a4 20 03 cmp %l0, 3 40009f90: 18 80 00 1a bgu 40009ff8 <_Watchdog_Remove+0x90> 40009f94: 01 00 00 00 nop 40009f98: c6 06 00 00 ld [ %i0 ], %g3 break; case WATCHDOG_ACTIVE: case WATCHDOG_REMOVE_IT: the_watchdog->state = WATCHDOG_INACTIVE; 40009f9c: c0 26 20 08 clr [ %i0 + 8 ] next_watchdog = _Watchdog_Next( the_watchdog ); if ( _Watchdog_Next(next_watchdog) ) 40009fa0: c2 00 c0 00 ld [ %g3 ], %g1 40009fa4: 80 a0 60 00 cmp %g1, 0 40009fa8: 02 80 00 07 be 40009fc4 <_Watchdog_Remove+0x5c> 40009fac: 03 10 00 64 sethi %hi(0x40019000), %g1 next_watchdog->delta_interval += the_watchdog->delta_interval; 40009fb0: c2 00 e0 10 ld [ %g3 + 0x10 ], %g1 40009fb4: c4 06 20 10 ld [ %i0 + 0x10 ], %g2 40009fb8: 82 00 40 02 add %g1, %g2, %g1 40009fbc: c2 20 e0 10 st %g1, [ %g3 + 0x10 ] if ( _Watchdog_Sync_count ) 40009fc0: 03 10 00 64 sethi %hi(0x40019000), %g1 40009fc4: c2 00 60 70 ld [ %g1 + 0x70 ], %g1 ! 40019070 <_Watchdog_Sync_count> 40009fc8: 80 a0 60 00 cmp %g1, 0 40009fcc: 22 80 00 07 be,a 40009fe8 <_Watchdog_Remove+0x80> 40009fd0: c4 06 00 00 ld [ %i0 ], %g2 _Watchdog_Sync_level = _ISR_Nest_level; 40009fd4: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40009fd8: c4 00 63 b4 ld [ %g1 + 0x3b4 ], %g2 ! 40018fb4 <_ISR_Nest_level> <== NOT EXECUTED 40009fdc: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40009fe0: c4 20 63 c8 st %g2, [ %g1 + 0x3c8 ] ! 40018fc8 <_Watchdog_Sync_level> <== NOT EXECUTED ) { Chain_Node *next; Chain_Node *previous; next = the_node->next; 40009fe4: c4 06 00 00 ld [ %i0 ], %g2 <== NOT EXECUTED previous = the_node->previous; 40009fe8: c2 06 20 04 ld [ %i0 + 4 ], %g1 next->previous = previous; previous->next = next; 40009fec: c4 20 40 00 st %g2, [ %g1 ] Chain_Node *next; Chain_Node *previous; next = the_node->next; previous = the_node->previous; next->previous = previous; 40009ff0: c2 20 a0 04 st %g1, [ %g2 + 4 ] _Chain_Extract_unprotected( &the_watchdog->Node ); break; } the_watchdog->stop_time = _Watchdog_Ticks_since_boot; 40009ff4: 03 10 00 64 sethi %hi(0x40019000), %g1 40009ff8: c2 00 60 74 ld [ %g1 + 0x74 ], %g1 ! 40019074 <_Watchdog_Ticks_since_boot> 40009ffc: c2 26 20 18 st %g1, [ %i0 + 0x18 ] _ISR_Enable( level ); 4000a000: 7f ff df 53 call 40001d4c 4000a004: b0 10 00 10 mov %l0, %i0 return( previous_state ); } 4000a008: 81 c7 e0 08 ret 4000a00c: 81 e8 00 00 restore 4000a0b4 <_Workspace_Allocate_or_fatal_error>: */ void *_Workspace_Allocate_or_fatal_error( size_t size ) { 4000a0b4: 9d e3 bf 98 save %sp, -104, %sp RTEMS_INLINE_ROUTINE void *_Workspace_Allocate( size_t size ) { return _Heap_Allocate( &_Workspace_Area, size ); 4000a0b8: 11 10 00 63 sethi %hi(0x40018c00), %o0 4000a0bc: 92 10 00 18 mov %i0, %o1 4000a0c0: 7f ff f2 e5 call 40006c54 <_Heap_Allocate> 4000a0c4: 90 12 23 3c or %o0, 0x33c, %o0 void *memory; memory = _Workspace_Allocate( size ); if ( memory == NULL ) 4000a0c8: b0 92 20 00 orcc %o0, 0, %i0 4000a0cc: 12 80 00 04 bne 4000a0dc <_Workspace_Allocate_or_fatal_error+0x28> 4000a0d0: 92 10 20 01 mov 1, %o1 _Internal_error_Occurred( 4000a0d4: 7f ff f4 0b call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 4000a0d8: 94 10 20 04 mov 4, %o2 <== NOT EXECUTED TRUE, INTERNAL_ERROR_WORKSPACE_ALLOCATION ); return memory; } 4000a0dc: 81 c7 e0 08 ret 4000a0e0: 81 e8 00 00 restore 4000a0e4 <_Workspace_Handler_initialization>: void _Workspace_Handler_initialization( void *starting_address, size_t size ) { 4000a0e4: 9d e3 bf 98 save %sp, -104, %sp uint32_t *zero_out_array; uint32_t index; uint32_t memory_available; if ( !starting_address || !_Addresses_Is_aligned( starting_address ) ) 4000a0e8: 80 a6 20 00 cmp %i0, 0 4000a0ec: 02 80 00 04 be 4000a0fc <_Workspace_Handler_initialization+0x18> 4000a0f0: 80 8e 20 07 btst 7, %i0 4000a0f4: 02 80 00 07 be 4000a110 <_Workspace_Handler_initialization+0x2c> 4000a0f8: 03 10 00 63 sethi %hi(0x40018c00), %g1 _Internal_error_Occurred( 4000a0fc: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000a100: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 4000a104: 7f ff f3 ff call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 4000a108: 94 10 20 02 mov 2, %o2 <== NOT EXECUTED INTERNAL_ERROR_CORE, TRUE, INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS ); if ( _CPU_Table.do_zero_of_workspace ) { 4000a10c: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 4000a110: c2 00 63 14 ld [ %g1 + 0x314 ], %g1 ! 40018f14 <_CPU_Table+0x10> 4000a114: 84 10 20 00 clr %g2 4000a118: 80 a0 60 00 cmp %g1, 0 4000a11c: 12 80 00 06 bne 4000a134 <_Workspace_Handler_initialization+0x50> 4000a120: 87 36 60 02 srl %i1, 2, %g3 index < size / sizeof( uint32_t ) ; index++ ) zero_out_array[ index ] = 0; } memory_available = _Heap_Initialize( 4000a124: 10 80 00 08 b 4000a144 <_Workspace_Handler_initialization+0x60> 4000a128: 92 10 00 18 mov %i0, %o1 ); if ( _CPU_Table.do_zero_of_workspace ) { for( zero_out_array = (uint32_t *) starting_address, index = 0 ; index < size / sizeof( uint32_t ) ; index++ ) 4000a12c: 84 00 a0 01 inc %g2 <== NOT EXECUTED zero_out_array[ index ] = 0; 4000a130: c0 20 40 18 clr [ %g1 + %i0 ] <== NOT EXECUTED INTERNAL_ERROR_INVALID_WORKSPACE_ADDRESS ); if ( _CPU_Table.do_zero_of_workspace ) { for( zero_out_array = (uint32_t *) starting_address, index = 0 ; index < size / sizeof( uint32_t ) ; 4000a134: 80 a0 80 03 cmp %g2, %g3 <== NOT EXECUTED 4000a138: 0a bf ff fd bcs 4000a12c <_Workspace_Handler_initialization+0x48> <== NOT EXECUTED 4000a13c: 83 28 a0 02 sll %g2, 2, %g1 <== NOT EXECUTED index++ ) zero_out_array[ index ] = 0; } memory_available = _Heap_Initialize( 4000a140: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 4000a144: 94 10 00 19 mov %i1, %o2 4000a148: 11 10 00 63 sethi %hi(0x40018c00), %o0 4000a14c: 96 10 20 08 mov 8, %o3 4000a150: 7f ff f3 a2 call 40006fd8 <_Heap_Initialize> 4000a154: 90 12 23 3c or %o0, 0x33c, %o0 starting_address, size, CPU_HEAP_ALIGNMENT ); if ( memory_available == 0 ) 4000a158: 80 a2 20 00 cmp %o0, 0 4000a15c: 12 80 00 05 bne 4000a170 <_Workspace_Handler_initialization+0x8c> 4000a160: b0 10 20 00 clr %i0 _Internal_error_Occurred( 4000a164: b2 10 20 01 mov 1, %i1 <== NOT EXECUTED 4000a168: 7f ff f3 e6 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 4000a16c: 95 e8 20 03 restore %g0, 3, %o2 <== NOT EXECUTED 4000a170: 81 c7 e0 08 ret 4000a174: 81 e8 00 00 restore 40005cec : rtems_name name, rtems_attribute attribute_set, uint32_t maximum_waiters, rtems_id *id ) { 40005cec: 9d e3 bf 90 save %sp, -112, %sp Barrier_Control *the_barrier; CORE_barrier_Attributes the_attributes; if ( !rtems_is_name_valid( name ) ) 40005cf0: a2 96 20 00 orcc %i0, 0, %l1 40005cf4: 02 80 00 1b be 40005d60 40005cf8: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !id ) 40005cfc: 80 a6 e0 00 cmp %i3, 0 40005d00: 02 80 00 18 be 40005d60 40005d04: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; /* Initialize core barrier attributes */ if ( _Attributes_Is_barrier_automatic( attribute_set ) ) { 40005d08: 80 8e 60 10 btst 0x10, %i1 40005d0c: 02 80 00 06 be 40005d24 40005d10: 80 a6 a0 00 cmp %i2, 0 the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE; if ( maximum_waiters == 0 ) 40005d14: 02 80 00 13 be 40005d60 40005d18: b0 10 20 0a mov 0xa, %i0 if ( !id ) return RTEMS_INVALID_ADDRESS; /* Initialize core barrier attributes */ if ( _Attributes_Is_barrier_automatic( attribute_set ) ) { the_attributes.discipline = CORE_BARRIER_AUTOMATIC_RELEASE; 40005d1c: 10 80 00 04 b 40005d2c 40005d20: c0 27 bf f0 clr [ %fp + -16 ] if ( maximum_waiters == 0 ) return RTEMS_INVALID_NUMBER; } else the_attributes.discipline = CORE_BARRIER_MANUAL_RELEASE; 40005d24: 82 10 20 01 mov 1, %g1 40005d28: c2 27 bf f0 st %g1, [ %fp + -16 ] rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40005d2c: 05 10 00 73 sethi %hi(0x4001cc00), %g2 40005d30: c2 00 a2 10 ld [ %g2 + 0x210 ], %g1 ! 4001ce10 <_Thread_Dispatch_disable_level> the_attributes.maximum_count = maximum_waiters; 40005d34: f4 27 bf f4 st %i2, [ %fp + -12 ] 40005d38: 82 00 60 01 inc %g1 40005d3c: c2 20 a2 10 st %g1, [ %g2 + 0x210 ] * 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 ); 40005d40: 21 10 00 73 sethi %hi(0x4001cc00), %l0 40005d44: 40 00 09 d5 call 40008498 <_Objects_Allocate> 40005d48: 90 14 20 74 or %l0, 0x74, %o0 ! 4001cc74 <_Barrier_Information> _Thread_Disable_dispatch(); /* prevents deletion */ the_barrier = _Barrier_Allocate(); if ( !the_barrier ) { 40005d4c: b4 92 20 00 orcc %o0, 0, %i2 40005d50: 12 80 00 06 bne 40005d68 40005d54: 90 06 a0 14 add %i2, 0x14, %o0 _Thread_Enable_dispatch(); 40005d58: 7f ff ff d8 call 40005cb8 <_Thread_Enable_dispatch> 40005d5c: b0 10 20 05 mov 5, %i0 40005d60: 81 c7 e0 08 ret 40005d64: 81 e8 00 00 restore return RTEMS_TOO_MANY; } the_barrier->attribute_set = attribute_set; 40005d68: f2 26 a0 10 st %i1, [ %i2 + 0x10 ] _CORE_barrier_Initialize( &the_barrier->Barrier, &the_attributes ); 40005d6c: 40 00 07 17 call 400079c8 <_CORE_barrier_Initialize> 40005d70: 92 07 bf f0 add %fp, -16, %o1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005d74: 90 14 20 74 or %l0, 0x74, %o0 Objects_Name name ) { uint32_t index; index = _Objects_Get_index( the_object->id ); 40005d78: c6 06 a0 08 ld [ %i2 + 8 ], %g3 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005d7c: c4 12 20 10 lduh [ %o0 + 0x10 ], %g2 40005d80: 03 00 00 3f sethi %hi(0xfc00), %g1 40005d84: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40005d88: 82 08 c0 01 and %g3, %g1, %g1 40005d8c: 80 a0 40 02 cmp %g1, %g2 40005d90: 38 80 00 06 bgu,a 40005da8 40005d94: e2 26 a0 0c st %l1, [ %i2 + 0xc ] <== NOT EXECUTED information->local_table[ index ] = the_object; 40005d98: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 40005d9c: 83 28 60 02 sll %g1, 2, %g1 40005da0: f4 20 80 01 st %i2, [ %g2 + %g1 ] if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 40005da4: e2 26 a0 0c st %l1, [ %i2 + 0xc ] &_Barrier_Information, &the_barrier->Object, (Objects_Name) name ); *id = the_barrier->Object.id; 40005da8: c6 26 c0 00 st %g3, [ %i3 ] _Thread_Enable_dispatch(); 40005dac: 7f ff ff c3 call 40005cb8 <_Thread_Enable_dispatch> 40005db0: b0 10 20 00 clr %i0 return RTEMS_SUCCESSFUL; } 40005db4: 81 c7 e0 08 ret 40005db8: 81 e8 00 00 restore 40005dbc : */ rtems_status_code rtems_barrier_delete( rtems_id id ) { 40005dbc: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Get ( Objects_Id id, Objects_Locations *location ) { return (Barrier_Control *) 40005dc0: 21 10 00 73 sethi %hi(0x4001cc00), %l0 40005dc4: 92 10 00 18 mov %i0, %o1 40005dc8: 94 07 bf f4 add %fp, -12, %o2 40005dcc: 40 00 0a f7 call 400089a8 <_Objects_Get> 40005dd0: 90 14 20 74 or %l0, 0x74, %o0 Barrier_Control *the_barrier; Objects_Locations location; the_barrier = _Barrier_Get( id, &location ); switch ( location ) { 40005dd4: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005dd8: 80 a0 60 00 cmp %g1, 0 40005ddc: 02 80 00 07 be 40005df8 40005de0: b0 10 00 08 mov %o0, %i0 40005de4: 80 a0 60 02 cmp %g1, 2 40005de8: 08 80 00 22 bleu 40005e70 40005dec: b0 10 20 04 mov 4, %i0 40005df0: 81 c7 e0 08 ret <== NOT EXECUTED 40005df4: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_REMOTE: case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: _CORE_barrier_Flush( 40005df8: 90 02 20 14 add %o0, 0x14, %o0 40005dfc: 92 10 20 00 clr %o1 40005e00: 40 00 12 25 call 4000a694 <_Thread_queue_Flush> 40005e04: 94 10 20 02 mov 2, %o2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005e08: 90 14 20 74 or %l0, 0x74, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 40005e0c: c2 06 20 08 ld [ %i0 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005e10: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 40005e14: 05 00 00 3f sethi %hi(0xfc00), %g2 40005e18: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 40005e1c: 82 08 40 02 and %g1, %g2, %g1 40005e20: 80 a0 40 03 cmp %g1, %g3 40005e24: 38 80 00 06 bgu,a 40005e3c 40005e28: c0 26 20 0c clr [ %i0 + 0xc ] <== NOT EXECUTED information->local_table[ index ] = the_object; 40005e2c: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 40005e30: 83 28 60 02 sll %g1, 2, %g1 40005e34: c0 20 80 01 clr [ %g2 + %g1 ] uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 40005e38: c0 26 20 0c clr [ %i0 + 0xc ] */ RTEMS_INLINE_ROUTINE void _Barrier_Free ( Barrier_Control *the_barrier ) { _Objects_Free( &_Barrier_Information, &the_barrier->Object ); 40005e3c: 40 00 0a 99 call 400088a0 <_Objects_Free> 40005e40: 92 10 00 18 mov %i0, %o1 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40005e44: 03 10 00 73 sethi %hi(0x4001cc00), %g1 40005e48: c4 00 62 10 ld [ %g1 + 0x210 ], %g2 ! 4001ce10 <_Thread_Dispatch_disable_level> 40005e4c: b0 10 20 00 clr %i0 40005e50: 84 00 bf ff add %g2, -1, %g2 40005e54: c4 20 62 10 st %g2, [ %g1 + 0x210 ] 40005e58: c2 00 62 10 ld [ %g1 + 0x210 ], %g1 40005e5c: 80 a0 60 00 cmp %g1, 0 40005e60: 12 80 00 04 bne 40005e70 40005e64: 01 00 00 00 nop _Thread_Dispatch(); 40005e68: 40 00 0f c4 call 40009d78 <_Thread_Dispatch> 40005e6c: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005e70: 81 c7 e0 08 ret 40005e74: 81 e8 00 00 restore 40005eb0 : rtems_status_code rtems_barrier_release( rtems_id id, uint32_t *released ) { 40005eb0: 9d e3 bf 90 save %sp, -112, %sp 40005eb4: a0 10 00 18 mov %i0, %l0 Barrier_Control *the_barrier; Objects_Locations location; if ( !released ) 40005eb8: 80 a6 60 00 cmp %i1, 0 40005ebc: 02 80 00 1f be 40005f38 40005ec0: b0 10 20 09 mov 9, %i0 RTEMS_INLINE_ROUTINE Barrier_Control *_Barrier_Get ( Objects_Id id, Objects_Locations *location ) { return (Barrier_Control *) 40005ec4: 11 10 00 73 sethi %hi(0x4001cc00), %o0 40005ec8: 92 10 00 10 mov %l0, %o1 40005ecc: 90 12 20 74 or %o0, 0x74, %o0 40005ed0: 40 00 0a b6 call 400089a8 <_Objects_Get> 40005ed4: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_barrier = _Barrier_Get( id, &location ); switch ( location ) { 40005ed8: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005edc: 80 a0 60 00 cmp %g1, 0 40005ee0: 02 80 00 07 be 40005efc 40005ee4: 92 10 00 10 mov %l0, %o1 40005ee8: 80 a0 60 02 cmp %g1, 2 40005eec: 08 80 00 13 bleu 40005f38 40005ef0: b0 10 20 04 mov 4, %i0 40005ef4: 81 c7 e0 08 ret <== NOT EXECUTED 40005ef8: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_REMOTE: case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: *released = _CORE_barrier_Release( &the_barrier->Barrier, id, NULL ); 40005efc: 94 10 20 00 clr %o2 40005f00: 40 00 06 be call 400079f8 <_CORE_barrier_Release> 40005f04: 90 02 20 14 add %o0, 0x14, %o0 40005f08: d0 26 40 00 st %o0, [ %i1 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40005f0c: 03 10 00 73 sethi %hi(0x4001cc00), %g1 40005f10: c4 00 62 10 ld [ %g1 + 0x210 ], %g2 ! 4001ce10 <_Thread_Dispatch_disable_level> 40005f14: b0 10 20 00 clr %i0 40005f18: 84 00 bf ff add %g2, -1, %g2 40005f1c: c4 20 62 10 st %g2, [ %g1 + 0x210 ] 40005f20: c2 00 62 10 ld [ %g1 + 0x210 ], %g1 40005f24: 80 a0 60 00 cmp %g1, 0 40005f28: 12 80 00 04 bne 40005f38 40005f2c: 01 00 00 00 nop _Thread_Dispatch(); 40005f30: 40 00 0f 92 call 40009d78 <_Thread_Dispatch> 40005f34: 01 00 00 00 nop return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005f38: 81 c7 e0 08 ret 40005f3c: 81 e8 00 00 restore 40005f40 : rtems_status_code rtems_barrier_wait( rtems_id id, rtems_interval timeout ) { 40005f40: 9d e3 bf 90 save %sp, -112, %sp 40005f44: 11 10 00 73 sethi %hi(0x4001cc00), %o0 40005f48: 92 10 00 18 mov %i0, %o1 40005f4c: 90 12 20 74 or %o0, 0x74, %o0 40005f50: 40 00 0a 96 call 400089a8 <_Objects_Get> 40005f54: 94 07 bf f4 add %fp, -12, %o2 Barrier_Control *the_barrier; Objects_Locations location; the_barrier = _Barrier_Get( id, &location ); switch ( location ) { 40005f58: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005f5c: 80 a0 60 00 cmp %g1, 0 40005f60: 02 80 00 07 be 40005f7c 40005f64: 96 10 00 19 mov %i1, %o3 40005f68: 80 a0 60 02 cmp %g1, 2 40005f6c: 08 80 00 17 bleu 40005fc8 40005f70: 90 10 20 04 mov 4, %o0 40005f74: 10 80 00 15 b 40005fc8 <== NOT EXECUTED 40005f78: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED case OBJECTS_REMOTE: case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: _CORE_barrier_Wait( 40005f7c: 90 02 20 14 add %o0, 0x14, %o0 40005f80: 92 10 00 18 mov %i0, %o1 40005f84: 94 10 20 01 mov 1, %o2 40005f88: 40 00 06 a7 call 40007a24 <_CORE_barrier_Wait> 40005f8c: 98 10 20 00 clr %o4 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40005f90: 03 10 00 73 sethi %hi(0x4001cc00), %g1 40005f94: c4 00 62 10 ld [ %g1 + 0x210 ], %g2 ! 4001ce10 <_Thread_Dispatch_disable_level> 40005f98: 84 00 bf ff add %g2, -1, %g2 40005f9c: c4 20 62 10 st %g2, [ %g1 + 0x210 ] 40005fa0: c2 00 62 10 ld [ %g1 + 0x210 ], %g1 40005fa4: 80 a0 60 00 cmp %g1, 0 40005fa8: 12 80 00 05 bne 40005fbc 40005fac: 03 10 00 73 sethi %hi(0x4001cc00), %g1 _Thread_Dispatch(); 40005fb0: 40 00 0f 72 call 40009d78 <_Thread_Dispatch> 40005fb4: 01 00 00 00 nop TRUE, timeout, NULL ); _Thread_Enable_dispatch(); return _Barrier_Translate_core_barrier_return_code( 40005fb8: 03 10 00 73 sethi %hi(0x4001cc00), %g1 40005fbc: c2 00 62 ec ld [ %g1 + 0x2ec ], %g1 ! 4001ceec <_Thread_Executing> 40005fc0: 40 00 1c 23 call 4000d04c <_Barrier_Translate_core_barrier_return_code> 40005fc4: d0 00 60 34 ld [ %g1 + 0x34 ], %o0 _Thread_Executing->Wait.return_code ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005fc8: 81 c7 e0 08 ret 40005fcc: 91 e8 00 08 restore %g0, %o0, %o0 40004e14 : rtems_status_code rtems_clock_get( rtems_clock_get_options option, void *time_buffer ) { 40004e14: 9d e3 bf 68 save %sp, -152, %sp 40004e18: 82 10 00 18 mov %i0, %g1 if ( !time_buffer ) 40004e1c: 80 a6 60 00 cmp %i1, 0 40004e20: 02 80 00 47 be 40004f3c 40004e24: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; switch ( option ) { 40004e28: 80 a0 60 04 cmp %g1, 4 40004e2c: 18 80 00 44 bgu 40004f3c 40004e30: b0 10 20 19 mov 0x19, %i0 40004e34: 83 28 60 02 sll %g1, 2, %g1 40004e38: 05 10 00 13 sethi %hi(0x40004c00), %g2 40004e3c: 84 10 a1 c0 or %g2, 0x1c0, %g2 ! 40004dc0 40004e40: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40004e44: 81 c0 40 00 jmp %g1 40004e48: 01 00 00 00 nop case RTEMS_CLOCK_GET_TOD: { struct tm time; struct timeval now; rtems_time_of_day *tmbuf = (rtems_time_of_day *)time_buffer; if ( !_TOD_Is_set ) 40004e4c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40004e50: c2 00 63 2c ld [ %g1 + 0x32c ], %g1 ! 40018f2c <_TOD_Is_set> 40004e54: 80 a0 60 00 cmp %g1, 0 40004e58: 22 80 00 39 be,a 40004f3c 40004e5c: b0 10 20 0b mov 0xb, %i0 return RTEMS_NOT_DEFINED; /* Obtain the current time */ _TOD_Get_timeval( &now ); 40004e60: a0 07 bf f0 add %fp, -16, %l0 40004e64: 7f ff ff dc call 40004dd4 <_TOD_Get_timeval> 40004e68: 90 10 00 10 mov %l0, %o0 /* Split it into a closer format */ gmtime_r( &now.tv_sec, &time ); 40004e6c: 92 07 bf cc add %fp, -52, %o1 40004e70: 40 00 23 96 call 4000dcc8 40004e74: 90 10 00 10 mov %l0, %o0 tmbuf->month = time.tm_mon + 1; tmbuf->day = time.tm_mday; tmbuf->hour = time.tm_hour; tmbuf->minute = time.tm_min; tmbuf->second = time.tm_sec; tmbuf->ticks = now.tv_usec / _TOD_Microseconds_per_tick; 40004e78: 03 10 00 64 sethi %hi(0x40019000), %g1 40004e7c: d2 00 60 cc ld [ %g1 + 0xcc ], %o1 ! 400190cc <_TOD_Microseconds_per_tick> gmtime_r( &now.tv_sec, &time ); /* Now adjust it to the RTEMS format */ tmbuf->year = time.tm_year + 1900; tmbuf->month = time.tm_mon + 1; tmbuf->day = time.tm_mday; 40004e80: c2 07 bf d8 ld [ %fp + -40 ], %g1 tmbuf->hour = time.tm_hour; tmbuf->minute = time.tm_min; tmbuf->second = time.tm_sec; tmbuf->ticks = now.tv_usec / _TOD_Microseconds_per_tick; 40004e84: d0 07 bf f4 ld [ %fp + -12 ], %o0 gmtime_r( &now.tv_sec, &time ); /* Now adjust it to the RTEMS format */ tmbuf->year = time.tm_year + 1900; tmbuf->month = time.tm_mon + 1; tmbuf->day = time.tm_mday; 40004e88: c2 26 60 08 st %g1, [ %i1 + 8 ] tmbuf->hour = time.tm_hour; 40004e8c: c2 07 bf d4 ld [ %fp + -44 ], %g1 40004e90: c2 26 60 0c st %g1, [ %i1 + 0xc ] tmbuf->minute = time.tm_min; 40004e94: c2 07 bf d0 ld [ %fp + -48 ], %g1 40004e98: c2 26 60 10 st %g1, [ %i1 + 0x10 ] tmbuf->second = time.tm_sec; 40004e9c: c2 07 bf cc ld [ %fp + -52 ], %g1 40004ea0: c2 26 60 14 st %g1, [ %i1 + 0x14 ] /* Split it into a closer format */ gmtime_r( &now.tv_sec, &time ); /* Now adjust it to the RTEMS format */ tmbuf->year = time.tm_year + 1900; 40004ea4: c2 07 bf e0 ld [ %fp + -32 ], %g1 40004ea8: 82 00 67 6c add %g1, 0x76c, %g1 40004eac: c2 26 40 00 st %g1, [ %i1 ] tmbuf->month = time.tm_mon + 1; 40004eb0: c2 07 bf dc ld [ %fp + -36 ], %g1 40004eb4: 82 00 60 01 inc %g1 tmbuf->day = time.tm_mday; tmbuf->hour = time.tm_hour; tmbuf->minute = time.tm_min; tmbuf->second = time.tm_sec; tmbuf->ticks = now.tv_usec / _TOD_Microseconds_per_tick; 40004eb8: 40 00 3d dd call 4001462c <.udiv> 40004ebc: c2 26 60 04 st %g1, [ %i1 + 4 ] 40004ec0: 10 80 00 1c b 40004f30 40004ec4: d0 26 60 18 st %o0, [ %i1 + 0x18 ] return RTEMS_SUCCESSFUL; } case RTEMS_CLOCK_GET_SECONDS_SINCE_EPOCH: { rtems_interval *interval = (rtems_interval *)time_buffer; if ( !_TOD_Is_set ) 40004ec8: 03 10 00 63 sethi %hi(0x40018c00), %g1 40004ecc: c2 00 63 2c ld [ %g1 + 0x32c ], %g1 ! 40018f2c <_TOD_Is_set> 40004ed0: 80 a0 60 00 cmp %g1, 0 40004ed4: 02 80 00 19 be 40004f38 40004ed8: 03 10 00 63 sethi %hi(0x40018c00), %g1 return RTEMS_NOT_DEFINED; *interval = _TOD_Seconds_since_epoch; 40004edc: 10 80 00 04 b 40004eec 40004ee0: c2 00 63 a8 ld [ %g1 + 0x3a8 ], %g1 ! 40018fa8 <_TOD_Now> } case RTEMS_CLOCK_GET_TICKS_SINCE_BOOT: { rtems_interval *interval = (rtems_interval *)time_buffer; *interval = _Watchdog_Ticks_since_boot; 40004ee4: 03 10 00 64 sethi %hi(0x40019000), %g1 40004ee8: c2 00 60 74 ld [ %g1 + 0x74 ], %g1 ! 40019074 <_Watchdog_Ticks_since_boot> 40004eec: c2 26 40 00 st %g1, [ %i1 ] 40004ef0: 81 c7 e0 08 ret 40004ef4: 91 e8 20 00 restore %g0, 0, %o0 } case RTEMS_CLOCK_GET_TICKS_PER_SECOND: { rtems_interval *interval = (rtems_interval *)time_buffer; *interval = TOD_MICROSECONDS_PER_SECOND / _TOD_Microseconds_per_tick; 40004ef8: 03 10 00 64 sethi %hi(0x40019000), %g1 40004efc: d2 00 60 cc ld [ %g1 + 0xcc ], %o1 ! 400190cc <_TOD_Microseconds_per_tick> 40004f00: 11 00 03 d0 sethi %hi(0xf4000), %o0 40004f04: 40 00 3d ca call 4001462c <.udiv> 40004f08: 90 12 22 40 or %o0, 0x240, %o0 ! f4240 40004f0c: 10 80 00 09 b 40004f30 40004f10: d0 26 40 00 st %o0, [ %i1 ] } case RTEMS_CLOCK_GET_TIME_VALUE: { struct timeval *time = (struct timeval *)time_buffer; if ( !_TOD_Is_set ) 40004f14: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED 40004f18: c2 00 63 2c ld [ %g1 + 0x32c ], %g1 ! 40018f2c <_TOD_Is_set> <== NOT EXECUTED 40004f1c: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40004f20: 22 80 00 07 be,a 40004f3c <== NOT EXECUTED 40004f24: b0 10 20 0b mov 0xb, %i0 <== NOT EXECUTED return RTEMS_NOT_DEFINED; _TOD_Get_timeval( time ); 40004f28: 7f ff ff ab call 40004dd4 <_TOD_Get_timeval> <== NOT EXECUTED 40004f2c: 90 10 00 19 mov %i1, %o0 <== NOT EXECUTED 40004f30: 81 c7 e0 08 ret 40004f34: 91 e8 20 00 restore %g0, 0, %o0 return RTEMS_SUCCESSFUL; 40004f38: b0 10 20 0b mov 0xb, %i0 <== NOT EXECUTED } } return RTEMS_INTERNAL_ERROR; /* should never get here */ } 40004f3c: 81 c7 e0 08 ret 40004f40: 81 e8 00 00 restore 40004f64 : * * NOTE: This routine only works for leap-years through 2099. */ rtems_status_code rtems_clock_tick( void ) { 40004f64: 9d e3 bf 98 save %sp, -104, %sp _TOD_Tickle_ticks(); 40004f68: 40 00 07 19 call 40006bcc <_TOD_Tickle_ticks> 40004f6c: 01 00 00 00 nop */ RTEMS_INLINE_ROUTINE void _Watchdog_Tickle_ticks( void ) { _Watchdog_Tickle( &_Watchdog_Ticks_chain ); 40004f70: 11 10 00 63 sethi %hi(0x40018c00), %o0 40004f74: 40 00 14 27 call 4000a010 <_Watchdog_Tickle> 40004f78: 90 12 23 ec or %o0, 0x3ec, %o0 ! 40018fec <_Watchdog_Ticks_chain> _Watchdog_Tickle_ticks(); _Thread_Tickle_timeslice(); 40004f7c: 40 00 12 7e call 40009974 <_Thread_Tickle_timeslice> 40004f80: 01 00 00 00 nop * otherwise. */ RTEMS_INLINE_ROUTINE boolean _Thread_Is_context_switch_necessary( void ) { return ( _Context_Switch_necessary ); 40004f84: 03 10 00 63 sethi %hi(0x40018c00), %g1 40004f88: c2 00 63 dc ld [ %g1 + 0x3dc ], %g1 ! 40018fdc <_Context_Switch_necessary> if ( _Thread_Is_context_switch_necessary() && 40004f8c: 80 a0 60 00 cmp %g1, 0 40004f90: 02 80 00 08 be 40004fb0 40004f94: 03 10 00 63 sethi %hi(0x40018c00), %g1 * otherwise. */ RTEMS_INLINE_ROUTINE boolean _Thread_Is_dispatching_enabled( void ) { return ( _Thread_Dispatch_disable_level == 0 ); 40004f98: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 40004f9c: 80 a0 60 00 cmp %g1, 0 40004fa0: 12 80 00 04 bne 40004fb0 40004fa4: 01 00 00 00 nop _Thread_Is_dispatching_enabled() ) _Thread_Dispatch(); 40004fa8: 40 00 0e bb call 40008a94 <_Thread_Dispatch> <== NOT EXECUTED 40004fac: 01 00 00 00 nop <== NOT EXECUTED return RTEMS_SUCCESSFUL; } 40004fb0: 81 c7 e0 08 ret 40004fb4: 91 e8 20 00 restore %g0, 0, %o0 400051c8 : rtems_status_code rtems_event_send( Objects_Id id, rtems_event_set event_in ) { 400051c8: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 400051cc: 92 96 20 00 orcc %i0, 0, %o1 400051d0: 12 80 00 0a bne 400051f8 400051d4: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400051d8: 03 10 00 63 sethi %hi(0x40018c00), %g1 400051dc: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> 400051e0: 84 00 a0 01 inc %g2 400051e4: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 400051e8: 03 10 00 63 sethi %hi(0x40018c00), %g1 400051ec: f0 00 63 cc ld [ %g1 + 0x3cc ], %i0 ! 40018fcc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 400051f0: 10 80 00 18 b 40005250 400051f4: c0 27 bf f4 clr [ %fp + -12 ] */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); 400051f8: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 400051fc: 80 a0 a0 04 cmp %g2, 4 40005200: 18 80 00 0e bgu 40005238 40005204: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40005208: 83 32 60 1b srl %o1, 0x1b, %g1 4000520c: 80 a0 60 01 cmp %g1, 1 40005210: 12 80 00 0a bne 40005238 40005214: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40005218: 83 28 a0 02 sll %g2, 2, %g1 4000521c: 05 10 00 63 sethi %hi(0x40018c00), %g2 40005220: 84 10 a2 50 or %g2, 0x250, %g2 ! 40018e50 <_Objects_Information_table> 40005224: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40005228: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 4000522c: 80 a2 20 00 cmp %o0, 0 40005230: 12 80 00 05 bne 40005244 40005234: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40005238: b0 10 20 00 clr %i0 4000523c: 10 80 00 05 b 40005250 40005240: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40005244: 40 00 09 20 call 400076c4 <_Objects_Get> 40005248: 94 07 bf f4 add %fp, -12, %o2 4000524c: b0 10 00 08 mov %o0, %i0 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40005250: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005254: 80 a0 60 00 cmp %g1, 0 40005258: 02 80 00 06 be 40005270 4000525c: 80 a0 60 02 cmp %g1, 2 40005260: 08 80 00 18 bleu 400052c0 40005264: b0 10 20 04 mov 4, %i0 40005268: 81 c7 e0 08 ret <== NOT EXECUTED 4000526c: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED rtems_event_set *the_event_set ) { ISR_Level level; _ISR_Disable( level ); 40005270: 7f ff f2 b3 call 40001d3c 40005274: e0 06 21 6c ld [ %i0 + 0x16c ], %l0 *the_event_set |= the_new_events; 40005278: c2 04 20 40 ld [ %l0 + 0x40 ], %g1 4000527c: 82 10 40 19 or %g1, %i1, %g1 40005280: c2 24 20 40 st %g1, [ %l0 + 0x40 ] _ISR_Enable( level ); 40005284: 7f ff f2 b2 call 40001d4c 40005288: 01 00 00 00 nop case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; _Event_sets_Post( event_in, &api->pending_events ); _Event_Surrender( the_thread ); 4000528c: 40 00 00 15 call 400052e0 <_Event_Surrender> 40005290: 90 10 00 18 mov %i0, %o0 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40005294: 05 10 00 63 sethi %hi(0x40018c00), %g2 40005298: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 4000529c: b0 10 20 00 clr %i0 400052a0: 82 00 7f ff add %g1, -1, %g1 400052a4: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 400052a8: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 400052ac: 80 a0 60 00 cmp %g1, 0 400052b0: 12 80 00 04 bne 400052c0 400052b4: 01 00 00 00 nop _Thread_Dispatch(); 400052b8: 40 00 0d f7 call 40008a94 <_Thread_Dispatch> 400052bc: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400052c0: 81 c7 e0 08 ret 400052c4: 81 e8 00 00 restore 4000abd0 : rtems_status_code rtems_extension_create( rtems_name name, rtems_extensions_table *extension_table, Objects_Id *id ) { 4000abd0: 9d e3 bf 98 save %sp, -104, %sp Extension_Control *the_extension; if ( !rtems_is_name_valid( name ) ) 4000abd4: a4 96 20 00 orcc %i0, 0, %l2 4000abd8: 02 80 00 0e be 4000ac10 4000abdc: b0 10 20 03 mov 3, %i0 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000abe0: 05 10 00 9d sethi %hi(0x40027400), %g2 4000abe4: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 400276f0 <_Thread_Dispatch_disable_level> 4000abe8: 82 00 60 01 inc %g1 4000abec: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] * the inactive chain of free extension control blocks. */ RTEMS_INLINE_ROUTINE Extension_Control *_Extension_Allocate( void ) { return (Extension_Control *) _Objects_Allocate( &_Extension_Information ); 4000abf0: 23 10 00 9e sethi %hi(0x40027800), %l1 4000abf4: 40 00 03 87 call 4000ba10 <_Objects_Allocate> 4000abf8: 90 14 61 8c or %l1, 0x18c, %o0 ! 4002798c <_Extension_Information> _Thread_Disable_dispatch(); /* to prevent deletion */ the_extension = _Extension_Allocate(); if ( !the_extension ) { 4000abfc: a0 92 20 00 orcc %o0, 0, %l0 4000ac00: 12 80 00 06 bne 4000ac18 4000ac04: 90 04 20 10 add %l0, 0x10, %o0 _Thread_Enable_dispatch(); 4000ac08: 7f ff ff e5 call 4000ab9c <_Thread_Enable_dispatch> <== NOT EXECUTED 4000ac0c: b0 10 20 05 mov 5, %i0 <== NOT EXECUTED 4000ac10: 81 c7 e0 08 ret <== NOT EXECUTED 4000ac14: 81 e8 00 00 restore <== NOT EXECUTED return RTEMS_TOO_MANY; } _User_extensions_Add_set( &the_extension->Extension, extension_table ); 4000ac18: 40 00 0e 03 call 4000e424 <_User_extensions_Add_set> 4000ac1c: 92 10 00 19 mov %i1, %o1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000ac20: 90 14 61 8c or %l1, 0x18c, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000ac24: c2 04 20 08 ld [ %l0 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000ac28: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 4000ac2c: 05 00 00 3f sethi %hi(0xfc00), %g2 4000ac30: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 4000ac34: 82 08 40 02 and %g1, %g2, %g1 4000ac38: 80 a0 40 03 cmp %g1, %g3 4000ac3c: 38 80 00 06 bgu,a 4000ac54 4000ac40: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED information->local_table[ index ] = the_object; 4000ac44: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4000ac48: 83 28 60 02 sll %g1, 2, %g1 4000ac4c: e0 20 80 01 st %l0, [ %g2 + %g1 ] &_Extension_Information, &the_extension->Object, (Objects_Name) name ); *id = the_extension->Object.id; 4000ac50: c2 04 20 08 ld [ %l0 + 8 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 4000ac54: e4 24 20 0c st %l2, [ %l0 + 0xc ] 4000ac58: c2 26 80 00 st %g1, [ %i2 ] _Thread_Enable_dispatch(); 4000ac5c: 7f ff ff d0 call 4000ab9c <_Thread_Enable_dispatch> 4000ac60: b0 10 20 00 clr %i0 return RTEMS_SUCCESSFUL; } 4000ac64: 81 c7 e0 08 ret 4000ac68: 81 e8 00 00 restore 4000ac6c : */ rtems_status_code rtems_extension_delete( Objects_Id id ) { 4000ac6c: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED RTEMS_INLINE_ROUTINE Extension_Control *_Extension_Get ( Objects_Id id, Objects_Locations *location ) { return (Extension_Control *) 4000ac70: 21 10 00 9e sethi %hi(0x40027800), %l0 <== NOT EXECUTED 4000ac74: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 4000ac78: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED 4000ac7c: 40 00 04 a9 call 4000bf20 <_Objects_Get> <== NOT EXECUTED 4000ac80: 90 14 21 8c or %l0, 0x18c, %o0 <== NOT EXECUTED Extension_Control *the_extension; Objects_Locations location; the_extension = _Extension_Get( id, &location ); switch ( location ) { 4000ac84: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 4000ac88: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000ac8c: 02 80 00 07 be 4000aca8 <== NOT EXECUTED 4000ac90: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED 4000ac94: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 4000ac98: 08 80 00 20 bleu 4000ad18 <== NOT EXECUTED 4000ac9c: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED 4000aca0: 81 c7 e0 08 ret <== NOT EXECUTED 4000aca4: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: case OBJECTS_REMOTE: /* should never return this */ return RTEMS_INVALID_ID; case OBJECTS_LOCAL: _User_extensions_Remove_set( &the_extension->Extension ); 4000aca8: 40 00 0e 19 call 4000e50c <_User_extensions_Remove_set> <== NOT EXECUTED 4000acac: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000acb0: 90 14 21 8c or %l0, 0x18c, %o0 <== NOT EXECUTED ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 4000acb4: c2 06 20 08 ld [ %i0 + 8 ], %g1 <== NOT EXECUTED Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000acb8: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 <== NOT EXECUTED 4000acbc: 05 00 00 3f sethi %hi(0xfc00), %g2 <== NOT EXECUTED 4000acc0: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff <== NOT EXECUTED 4000acc4: 82 08 40 02 and %g1, %g2, %g1 <== NOT EXECUTED 4000acc8: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 4000accc: 38 80 00 06 bgu,a 4000ace4 <== NOT EXECUTED 4000acd0: c0 26 20 0c clr [ %i0 + 0xc ] <== NOT EXECUTED information->local_table[ index ] = the_object; 4000acd4: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 <== NOT EXECUTED 4000acd8: 83 28 60 02 sll %g1, 2, %g1 <== NOT EXECUTED 4000acdc: c0 20 80 01 clr [ %g2 + %g1 ] <== NOT EXECUTED uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 4000ace0: c0 26 20 0c clr [ %i0 + 0xc ] <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Extension_Free ( Extension_Control *the_extension ) { _Objects_Free( &_Extension_Information, &the_extension->Object ); 4000ace4: 40 00 04 4d call 4000be18 <_Objects_Free> <== NOT EXECUTED 4000ace8: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000acec: 03 10 00 9d sethi %hi(0x40027400), %g1 <== NOT EXECUTED 4000acf0: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 400276f0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000acf4: b0 10 20 00 clr %i0 <== NOT EXECUTED 4000acf8: 84 00 bf ff add %g2, -1, %g2 <== NOT EXECUTED 4000acfc: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] <== NOT EXECUTED 4000ad00: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 <== NOT EXECUTED 4000ad04: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000ad08: 12 80 00 04 bne 4000ad18 <== NOT EXECUTED 4000ad0c: 01 00 00 00 nop <== NOT EXECUTED _Thread_Dispatch(); 4000ad10: 40 00 09 78 call 4000d2f0 <_Thread_Dispatch> <== NOT EXECUTED 4000ad14: 01 00 00 00 nop <== NOT EXECUTED _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000ad18: 81 c7 e0 08 ret <== NOT EXECUTED 4000ad1c: 81 e8 00 00 restore <== NOT EXECUTED 400064f8 : */ void rtems_fatal_error_occurred( uint32_t the_error ) { 400064f8: 94 10 00 08 mov %o0, %o2 <== NOT EXECUTED _Internal_error_Occurred( INTERNAL_ERROR_RTEMS_API, FALSE, the_error ); 400064fc: 92 10 20 00 clr %o1 <== NOT EXECUTED 40006500: 90 10 20 01 mov 1, %o0 <== NOT EXECUTED 40006504: 82 13 c0 00 mov %o7, %g1 <== NOT EXECUTED 40006508: 40 00 02 fe call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 4000650c: 9e 10 40 00 mov %g1, %o7 <== NOT EXECUTED 40006510: 01 00 00 00 nop 40006514 : #include const char *rtems_get_version_string(void) { return _RTEMS_version; } 40006514: 11 10 00 5f sethi %hi(0x40017c00), %o0 <== NOT EXECUTED 40006518: 81 c3 e0 08 retl <== NOT EXECUTED 4000651c: 90 12 22 88 or %o0, 0x288, %o0 ! 40017e88 <_RTEMS_version> <== NOT EXECUTED 400062bc : rtems_interrupt_level rtems_initialize_executive_early( rtems_configuration_table *configuration_table, rtems_cpu_table *cpu_table ) { 400062bc: 9d e3 bf 80 save %sp, -128, %sp * Dispatching and interrupts are disabled until the end of the * initialization sequence. This prevents an inadvertent context * switch before the executive is initialized. */ _ISR_Disable( bsp_level ); 400062c0: 7f ff ee 9f call 40001d3c 400062c4: 01 00 00 00 nop 400062c8: a4 10 00 08 mov %o0, %l2 if ( configuration_table == NULL ) 400062cc: 80 a6 20 00 cmp %i0, 0 400062d0: 12 80 00 07 bne 400062ec 400062d4: 03 10 00 64 sethi %hi(0x40019000), %g1 _Internal_error_Occurred( 400062d8: 90 10 20 00 clr %o0 <== NOT EXECUTED 400062dc: 92 10 20 01 mov 1, %o1 <== NOT EXECUTED 400062e0: 40 00 03 88 call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 400062e4: 94 10 20 00 clr %o2 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _System_state_Handler_initialization ( boolean is_multiprocessing ) { _System_state_Current = SYSTEM_STATE_BEFORE_INITIALIZATION; 400062e8: 03 10 00 64 sethi %hi(0x40019000), %g1 <== NOT EXECUTED 400062ec: c0 20 60 d0 clr [ %g1 + 0xd0 ] ! 400190d0 <_System_state_Current> _System_state_Is_multiprocessing = is_multiprocessing; 400062f0: 03 10 00 63 sethi %hi(0x40018c00), %g1 /* * Grab our own copy of the user's CPU table. */ _CPU_Table = *cpu_table; 400062f4: 94 10 20 28 mov 0x28, %o2 400062f8: 92 10 00 19 mov %i1, %o1 400062fc: c0 20 63 f8 clr [ %g1 + 0x3f8 ] 40006300: 11 10 00 63 sethi %hi(0x40018c00), %o0 40006304: 40 00 1e 76 call 4000dcdc 40006308: 90 12 23 04 or %o0, 0x304, %o0 ! 40018f04 <_CPU_Table> /* * Provided just for user convenience. */ _Configuration_Table = configuration_table; 4000630c: 03 10 00 63 sethi %hi(0x40018c00), %g1 INTERNAL_ERROR_CORE, TRUE, INTERNAL_ERROR_NO_CPU_TABLE ); _CPU_Initialize( cpu_table, _Thread_Dispatch ); 40006310: 90 10 00 19 mov %i1, %o0 40006314: 13 10 00 22 sethi %hi(0x40008800), %o1 40006318: 92 12 62 94 or %o1, 0x294, %o1 ! 40008a94 <_Thread_Dispatch> 4000631c: 40 00 10 9c call 4000a58c <_CPU_Initialize> 40006320: f0 20 63 b0 st %i0, [ %g1 + 0x3b0 ] /* * Do this as early as possible to insure no debugging output * is even attempted to be printed. */ _Debug_Manager_initialization(); 40006324: 40 00 17 7b call 4000c110 <_Debug_Manager_initialization> 40006328: 01 00 00 00 nop _API_extensions_Initialization(); 4000632c: 40 00 00 cb call 40006658 <_API_extensions_Initialization> 40006330: 01 00 00 00 nop _Thread_Dispatch_initialization(); _Workspace_Handler_initialization( 40006334: d2 06 20 04 ld [ %i0 + 4 ], %o1 40006338: d0 06 00 00 ld [ %i0 ], %o0 * This routine initializes the thread dispatching subsystem. */ RTEMS_INLINE_ROUTINE void _Thread_Dispatch_initialization( void ) { _Thread_Dispatch_disable_level = 1; 4000633c: 84 10 20 01 mov 1, %g2 40006340: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006344: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] ! 40018ef0 <_Thread_Dispatch_disable_level> 40006348: 40 00 0f 67 call 4000a0e4 <_Workspace_Handler_initialization> 4000634c: 23 10 00 63 sethi %hi(0x40018c00), %l1 (void *)configuration_table->work_space_start, configuration_table->work_space_size ); _User_extensions_Handler_initialization( 40006350: d0 06 20 20 ld [ %i0 + 0x20 ], %o0 40006354: 40 00 0e 07 call 40009b70 <_User_extensions_Handler_initialization> 40006358: d2 06 20 24 ld [ %i0 + 0x24 ], %o1 configuration_table->number_of_initial_extensions, configuration_table->User_extension_table ); _ISR_Handler_initialization(); 4000635c: 40 00 03 79 call 40007140 <_ISR_Handler_initialization> 40006360: a0 07 bf e8 add %fp, -24, %l0 _Objects_Handler_initialization( 40006364: 90 10 20 01 mov 1, %o0 40006368: 92 10 20 01 mov 1, %o1 4000636c: 40 00 05 6f call 40007928 <_Objects_Handler_initialization> 40006370: 94 10 20 00 clr %o2 multiprocessing_table->node, multiprocessing_table->maximum_nodes, multiprocessing_table->maximum_global_objects ); _Objects_Information_table[OBJECTS_INTERNAL_API] = _Internal_Objects; 40006374: 05 10 00 63 sethi %hi(0x40018c00), %g2 /* * Initialize the internal allocator Mutex */ _API_Mutex_Initialization( 1 ); 40006378: c0 23 a0 5c clr [ %sp + 0x5c ] multiprocessing_table->node, multiprocessing_table->maximum_nodes, multiprocessing_table->maximum_global_objects ); _Objects_Information_table[OBJECTS_INTERNAL_API] = _Internal_Objects; 4000637c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006380: 82 10 63 30 or %g1, 0x330, %g1 ! 40018f30 <_Internal_Objects> /* * Initialize the internal allocator Mutex */ _API_Mutex_Initialization( 1 ); 40006384: 96 10 20 01 mov 1, %o3 multiprocessing_table->node, multiprocessing_table->maximum_nodes, multiprocessing_table->maximum_global_objects ); _Objects_Information_table[OBJECTS_INTERNAL_API] = _Internal_Objects; 40006388: c2 20 a2 54 st %g1, [ %g2 + 0x254 ] /* * Initialize the internal allocator Mutex */ _API_Mutex_Initialization( 1 ); 4000638c: 98 10 20 74 mov 0x74, %o4 40006390: 9a 10 20 00 clr %o5 40006394: 90 14 63 fc or %l1, 0x3fc, %o0 40006398: 92 10 20 01 mov 1, %o1 4000639c: 40 00 04 ef call 40007758 <_Objects_Initialize_information> 400063a0: 94 10 20 02 mov 2, %o2 _API_Mutex_Allocate( _RTEMS_Allocator_Mutex ); 400063a4: 94 10 20 10 mov 0x10, %o2 400063a8: 13 10 00 5d sethi %hi(0x40017400), %o1 400063ac: 90 10 00 10 mov %l0, %o0 400063b0: 40 00 1e 4b call 4000dcdc 400063b4: 92 12 62 18 or %o1, 0x218, %o1 400063b8: 40 00 03 7f call 400071b4 <_Objects_Allocate> 400063bc: 90 14 63 fc or %l1, 0x3fc, %o0 400063c0: 03 10 00 63 sethi %hi(0x40018c00), %g1 400063c4: 84 10 00 08 mov %o0, %g2 400063c8: 92 10 00 10 mov %l0, %o1 400063cc: c4 20 63 c4 st %g2, [ %g1 + 0x3c4 ] 400063d0: 90 02 20 10 add %o0, 0x10, %o0 400063d4: 40 00 01 03 call 400067e0 <_CORE_mutex_Initialize> 400063d8: 94 10 20 01 mov 1, %o2 RTEMS_INLINE_ROUTINE void _Priority_Handler_initialization( void ) { size_t index; _Priority_Major_bit_map = 0; 400063dc: 03 10 00 63 sethi %hi(0x40018c00), %g1 400063e0: 84 10 20 00 clr %g2 400063e4: c0 30 63 c0 clrh [ %g1 + 0x3c0 ] for ( index=0 ; index <16 ; index++ ) _Priority_Bit_map[ index ] = 0; 400063e8: 03 10 00 64 sethi %hi(0x40019000), %g1 400063ec: 82 10 60 50 or %g1, 0x50, %g1 ! 40019050 <_Priority_Bit_map> 400063f0: c0 30 80 01 clrh [ %g2 + %g1 ] 400063f4: 84 00 a0 02 add %g2, 2, %g2 RTEMS_INLINE_ROUTINE void _Priority_Handler_initialization( void ) { size_t index; _Priority_Major_bit_map = 0; for ( index=0 ; index <16 ; index++ ) 400063f8: 80 a0 a0 20 cmp %g2, 0x20 400063fc: 32 bf ff fe bne,a 400063f4 40006400: c0 30 80 01 clrh [ %g2 + %g1 ] _Priority_Handler_initialization(); _Watchdog_Handler_initialization(); 40006404: 40 00 0e c6 call 40009f1c <_Watchdog_Handler_initialization> 40006408: 01 00 00 00 nop _TOD_Handler_initialization( configuration_table->microseconds_per_tick ); 4000640c: 40 00 01 e1 call 40006b90 <_TOD_Handler_initialization> 40006410: d0 06 20 0c ld [ %i0 + 0xc ], %o0 _Thread_Handler_initialization( 40006414: d2 06 20 08 ld [ %i0 + 8 ], %o1 40006418: d0 06 20 10 ld [ %i0 + 0x10 ], %o0 4000641c: 40 00 0a 5e call 40008d94 <_Thread_Handler_initialization> 40006420: 94 10 20 00 clr %o2 ); #endif /* MANAGERS */ _RTEMS_API_Initialize( configuration_table ); 40006424: 40 00 00 6e call 400065dc <_RTEMS_API_Initialize> 40006428: 90 10 00 18 mov %i0, %o0 _Extension_Manager_initialization( configuration_table->maximum_extensions ); 4000642c: 40 00 00 26 call 400064c4 <_Extension_Manager_initialization> 40006430: d0 06 20 08 ld [ %i0 + 8 ], %o0 _IO_Manager_initialization( 40006434: d0 06 20 1c ld [ %i0 + 0x1c ], %o0 40006438: d4 06 20 14 ld [ %i0 + 0x14 ], %o2 4000643c: 40 00 00 47 call 40006558 <_IO_Manager_initialization> 40006440: d2 06 20 18 ld [ %i0 + 0x18 ], %o1 RTEMS_INLINE_ROUTINE void _System_state_Set ( System_state_Codes state ) { _System_state_Current = state; 40006444: 84 10 20 01 mov 1, %g2 40006448: 03 10 00 64 sethi %hi(0x40019000), %g1 * * At this point all API extensions are in place. After the call to * _Thread_Create_idle() _Thread_Executing and _Thread_Heir will be set. */ _Thread_Create_idle(); 4000644c: 40 00 09 36 call 40008924 <_Thread_Create_idle> 40006450: c4 20 60 d0 st %g2, [ %g1 + 0xd0 ] ! 400190d0 <_System_state_Current> /* * Scheduling can properly occur now as long as we avoid dispatching. */ if ( cpu_table->pretasking_hook ) 40006454: d0 06 40 00 ld [ %i1 ], %o0 40006458: 80 a2 20 00 cmp %o0, 0 4000645c: 02 80 00 04 be 4000646c 40006460: 01 00 00 00 nop (*cpu_table->pretasking_hook)(); 40006464: 9f c2 00 00 call %o0 40006468: 01 00 00 00 nop /* * Run the API and BSPs predriver hook. */ _API_extensions_Run_predriver(); 4000646c: 40 00 00 9a call 400066d4 <_API_extensions_Run_predriver> 40006470: 01 00 00 00 nop if ( _CPU_Table.predriver_hook ) 40006474: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006478: a0 10 63 04 or %g1, 0x304, %l0 ! 40018f04 <_CPU_Table> 4000647c: c2 04 20 04 ld [ %l0 + 4 ], %g1 40006480: 80 a0 60 00 cmp %g1, 0 40006484: 02 80 00 04 be 40006494 40006488: 01 00 00 00 nop (*_CPU_Table.predriver_hook)(); 4000648c: 9f c0 40 00 call %g1 <== NOT EXECUTED 40006490: 01 00 00 00 nop <== NOT EXECUTED * Initialize all the device drivers and initialize the MPCI layer. * * NOTE: The MPCI may be build upon a device driver. */ _IO_Initialize_all_drivers(); 40006494: 40 00 00 23 call 40006520 <_IO_Initialize_all_drivers> 40006498: 01 00 00 00 nop * Run the APIs and BSPs postdriver hooks. * * The API extensions are supposed to create user initialization tasks. */ _API_extensions_Run_postdriver(); 4000649c: 40 00 00 76 call 40006674 <_API_extensions_Run_postdriver> 400064a0: 01 00 00 00 nop if ( _CPU_Table.postdriver_hook ) 400064a4: c2 04 20 08 ld [ %l0 + 8 ], %g1 400064a8: 80 a0 60 00 cmp %g1, 0 400064ac: 02 80 00 04 be 400064bc 400064b0: 01 00 00 00 nop (*_CPU_Table.postdriver_hook)(); 400064b4: 9f c0 40 00 call %g1 400064b8: 01 00 00 00 nop return bsp_level; } 400064bc: 81 c7 e0 08 ret 400064c0: 91 e8 00 12 restore %g0, %l2, %o0 400075b4 : rtems_status_code rtems_io_register_driver( rtems_device_major_number major, rtems_driver_address_table *driver_table, rtems_device_major_number *registered_major ) { 400075b4: 9d e3 bf 98 save %sp, -104, %sp /* * Validate the pointer data and contents passed in */ if ( !driver_table ) 400075b8: 92 96 60 00 orcc %i1, 0, %o1 400075bc: 02 80 00 40 be 400076bc 400075c0: 80 a6 a0 00 cmp %i2, 0 return RTEMS_INVALID_ADDRESS; if ( !registered_major ) 400075c4: 02 80 00 41 be 400076c8 400075c8: 82 10 20 09 mov 9, %g1 return RTEMS_INVALID_ADDRESS; if ( !driver_table->initialization_entry && !driver_table->open_entry ) 400075cc: c2 02 40 00 ld [ %o1 ], %g1 400075d0: 80 a0 60 00 cmp %g1, 0 400075d4: 12 80 00 07 bne 400075f0 400075d8: 03 10 00 73 sethi %hi(0x4001cc00), %g1 400075dc: c2 02 60 04 ld [ %o1 + 4 ], %g1 400075e0: 80 a0 60 00 cmp %g1, 0 400075e4: 22 80 00 39 be,a 400076c8 400075e8: 82 10 20 09 mov 9, %g1 *registered_major = 0; /* * The requested major number is higher than what is configured. */ if ( major >= _IO_Number_of_drivers ) 400075ec: 03 10 00 73 sethi %hi(0x4001cc00), %g1 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; if ( !driver_table->initialization_entry && !driver_table->open_entry ) return RTEMS_INVALID_ADDRESS; *registered_major = 0; 400075f0: c0 26 80 00 clr [ %i2 ] /* * The requested major number is higher than what is configured. */ if ( major >= _IO_Number_of_drivers ) 400075f4: c8 00 61 2c ld [ %g1 + 0x12c ], %g4 400075f8: 80 a6 00 04 cmp %i0, %g4 400075fc: 1a 80 00 33 bcc 400076c8 40007600: 82 10 20 0a mov 0xa, %g1 /* * Test for initialise/open being present to indicate the driver slot is * in use. */ if ( major == 0 ) { 40007604: 80 a6 20 00 cmp %i0, 0 40007608: 12 80 00 18 bne 40007668 4000760c: 03 10 00 73 sethi %hi(0x4001cc00), %g1 boolean found = FALSE; for ( major = _IO_Number_of_drivers - 1 ; major ; major-- ) { 40007610: c6 00 61 30 ld [ %g1 + 0x130 ], %g3 ! 4001cd30 <_IO_Driver_address_table> 40007614: 85 29 20 03 sll %g4, 3, %g2 40007618: 83 29 20 05 sll %g4, 5, %g1 4000761c: b0 01 3f ff add %g4, -1, %i0 40007620: 82 20 40 02 sub %g1, %g2, %g1 40007624: 82 00 7f e8 add %g1, -24, %g1 40007628: 10 80 00 0b b 40007654 4000762c: 84 00 40 03 add %g1, %g3, %g2 if ( !_IO_Driver_address_table[major].initialization_entry && 40007630: 80 a0 60 00 cmp %g1, 0 40007634: 32 80 00 07 bne,a 40007650 40007638: b0 06 3f ff add %i0, -1, %i0 4000763c: c2 00 a0 04 ld [ %g2 + 4 ], %g1 40007640: 80 a0 60 00 cmp %g1, 0 40007644: 02 80 00 09 be 40007668 40007648: 03 10 00 73 sethi %hi(0x4001cc00), %g1 * in use. */ if ( major == 0 ) { boolean found = FALSE; for ( major = _IO_Number_of_drivers - 1 ; major ; major-- ) { 4000764c: b0 06 3f ff add %i0, -1, %i0 <== NOT EXECUTED 40007650: 84 00 bf e8 add %g2, -24, %g2 40007654: 80 a6 20 00 cmp %i0, 0 40007658: 32 bf ff f6 bne,a 40007630 4000765c: c2 00 80 00 ld [ %g2 ], %g1 40007660: 10 80 00 1a b 400076c8 40007664: 82 10 20 05 mov 5, %g1 if ( !found ) return RTEMS_TOO_MANY; } if ( _IO_Driver_address_table[major].initialization_entry || 40007668: c6 00 61 30 ld [ %g1 + 0x130 ], %g3 4000766c: 85 2e 20 03 sll %i0, 3, %g2 40007670: 83 2e 20 05 sll %i0, 5, %g1 40007674: 82 20 40 02 sub %g1, %g2, %g1 40007678: c4 00 40 03 ld [ %g1 + %g3 ], %g2 4000767c: 80 a0 a0 00 cmp %g2, 0 40007680: 12 80 00 11 bne 400076c4 40007684: 90 00 40 03 add %g1, %g3, %o0 40007688: c2 02 20 04 ld [ %o0 + 4 ], %g1 4000768c: 80 a0 60 00 cmp %g1, 0 40007690: 32 80 00 0e bne,a 400076c8 40007694: 82 10 20 0c mov 0xc, %g1 <== NOT EXECUTED _IO_Driver_address_table[major].open_entry ) return RTEMS_RESOURCE_IN_USE; _IO_Driver_address_table[major] = *driver_table; 40007698: 40 00 1d 52 call 4000ebe0 4000769c: 94 10 20 18 mov 0x18, %o2 *registered_major = major; rtems_io_initialize( major, 0, NULL ); 400076a0: 90 10 00 18 mov %i0, %o0 _IO_Driver_address_table[major].open_entry ) return RTEMS_RESOURCE_IN_USE; _IO_Driver_address_table[major] = *driver_table; *registered_major = major; 400076a4: f0 26 80 00 st %i0, [ %i2 ] rtems_io_initialize( major, 0, NULL ); 400076a8: 92 10 20 00 clr %o1 400076ac: 7f ff ff 52 call 400073f4 400076b0: 94 10 20 00 clr %o2 400076b4: 10 80 00 05 b 400076c8 400076b8: 82 10 20 00 clr %g1 return RTEMS_SUCCESSFUL; 400076bc: 10 80 00 03 b 400076c8 400076c0: 82 10 20 09 mov 9, %g1 400076c4: 82 10 20 0c mov 0xc, %g1 } 400076c8: 81 c7 e0 08 ret 400076cc: 91 e8 00 01 restore %g0, %g1, %o0 40008b84 : #include #include void rtems_iterate_over_all_threads(rtems_per_thread_routine routine) { 40008b84: 9d e3 bf 98 save %sp, -104, %sp uint32_t i; uint32_t api_index; Thread_Control *the_thread; Objects_Information *information; if ( !routine ) 40008b88: 80 a6 20 00 cmp %i0, 0 40008b8c: 02 80 00 1d be 40008c00 40008b90: 03 10 00 94 sethi %hi(0x40025000), %g1 return; 40008b94: a4 10 63 64 or %g1, 0x364, %l2 ! 40025364 <_Objects_Information_table+0x4> for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; 40008b98: a6 04 a0 10 add %l2, 0x10, %l3 api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) 40008b9c: c2 04 80 00 ld [ %l2 ], %g1 40008ba0: 80 a0 60 00 cmp %g1, 0 40008ba4: 22 80 00 14 be,a 40008bf4 40008ba8: a4 04 a0 04 add %l2, 4, %l2 continue; information = _Objects_Information_table[ api_index ][ 1 ]; 40008bac: e0 00 60 04 ld [ %g1 + 4 ], %l0 if ( information ) { 40008bb0: 80 a4 20 00 cmp %l0, 0 40008bb4: 12 80 00 0b bne 40008be0 40008bb8: a2 10 20 01 mov 1, %l1 for ( i=1 ; i <= information->maximum ; i++ ) { 40008bbc: 10 80 00 0e b 40008bf4 <== NOT EXECUTED 40008bc0: a4 04 a0 04 add %l2, 4, %l2 <== NOT EXECUTED the_thread = (Thread_Control *)information->local_table[ i ]; 40008bc4: c2 04 20 20 ld [ %l0 + 0x20 ], %g1 40008bc8: d0 00 40 08 ld [ %g1 + %o0 ], %o0 if ( !the_thread ) 40008bcc: 80 a2 20 00 cmp %o0, 0 40008bd0: 02 80 00 04 be 40008be0 40008bd4: a2 04 60 01 inc %l1 continue; (*routine)(the_thread); 40008bd8: 9f c6 00 00 call %i0 40008bdc: 01 00 00 00 nop api_index++ ) { if ( !_Objects_Information_table[ api_index ] ) continue; information = _Objects_Information_table[ api_index ][ 1 ]; if ( information ) { for ( i=1 ; i <= information->maximum ; i++ ) { 40008be0: c2 14 20 10 lduh [ %l0 + 0x10 ], %g1 40008be4: 80 a4 40 01 cmp %l1, %g1 40008be8: 08 bf ff f7 bleu 40008bc4 40008bec: 91 2c 60 02 sll %l1, 2, %o0 40008bf0: a4 04 a0 04 add %l2, 4, %l2 if ( !routine ) return; for ( api_index = 1 ; api_index <= OBJECTS_APIS_LAST ; 40008bf4: 80 a4 80 13 cmp %l2, %l3 40008bf8: 32 bf ff ea bne,a 40008ba0 40008bfc: c2 04 80 00 ld [ %l2 ], %g1 40008c00: 81 c7 e0 08 ret 40008c04: 81 e8 00 00 restore 4000e768 : Objects_Id id, void *buffer, size_t size, uint32_t *count ) { 4000e768: 9d e3 bf 90 save %sp, -112, %sp register Message_queue_Control *the_message_queue; Objects_Locations location; CORE_message_queue_Status core_status; if ( !buffer ) 4000e76c: 80 a6 60 00 cmp %i1, 0 4000e770: 02 80 00 26 be 4000e808 4000e774: 80 a6 e0 00 cmp %i3, 0 return RTEMS_INVALID_ADDRESS; if ( !count ) 4000e778: 02 80 00 24 be 4000e808 4000e77c: 11 10 00 c9 sethi %hi(0x40032400), %o0 RTEMS_INLINE_ROUTINE Message_queue_Control *_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (Message_queue_Control *) 4000e780: 92 10 00 18 mov %i0, %o1 4000e784: 90 12 22 00 or %o0, 0x200, %o0 4000e788: 40 00 18 89 call 400149ac <_Objects_Get> 4000e78c: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { 4000e790: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000e794: 80 a0 60 00 cmp %g1, 0 4000e798: 02 80 00 07 be 4000e7b4 4000e79c: 9a 10 00 1b mov %i3, %o5 4000e7a0: 80 a0 60 02 cmp %g1, 2 4000e7a4: 08 80 00 1a bleu 4000e80c 4000e7a8: 90 10 20 04 mov 4, %o0 4000e7ac: 10 80 00 18 b 4000e80c <== NOT EXECUTED 4000e7b0: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: core_status = _CORE_message_queue_Broadcast( 4000e7b4: 92 10 00 19 mov %i1, %o1 4000e7b8: 94 10 00 1a mov %i2, %o2 4000e7bc: 96 10 00 18 mov %i0, %o3 4000e7c0: 98 10 20 00 clr %o4 4000e7c4: 40 00 13 17 call 40013420 <_CORE_message_queue_Broadcast> 4000e7c8: 90 02 20 14 add %o0, 0x14, %o0 4000e7cc: b6 10 00 08 mov %o0, %i3 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000e7d0: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000e7d4: c4 00 62 e0 ld [ %g1 + 0x2e0 ], %g2 ! 400322e0 <_Thread_Dispatch_disable_level> 4000e7d8: 84 00 bf ff add %g2, -1, %g2 4000e7dc: c4 20 62 e0 st %g2, [ %g1 + 0x2e0 ] 4000e7e0: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 4000e7e4: 80 a0 60 00 cmp %g1, 0 4000e7e8: 12 80 00 04 bne 4000e7f8 4000e7ec: 01 00 00 00 nop _Thread_Dispatch(); 4000e7f0: 40 00 1d 63 call 40015d7c <_Thread_Dispatch> 4000e7f4: 01 00 00 00 nop #endif count ); _Thread_Enable_dispatch(); return 4000e7f8: 40 00 01 2e call 4000ecb0 <_Message_queue_Translate_core_message_queue_return_code> 4000e7fc: 90 10 00 1b mov %i3, %o0 _Message_queue_Translate_core_message_queue_return_code( core_status ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000e800: 81 c7 e0 08 ret 4000e804: 91 e8 00 08 restore %g0, %o0, %o0 #endif count ); _Thread_Enable_dispatch(); return 4000e808: 90 10 20 09 mov 9, %o0 <== NOT EXECUTED _Message_queue_Translate_core_message_queue_return_code( core_status ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000e80c: b0 10 00 08 mov %o0, %i0 4000e810: 81 c7 e0 08 ret 4000e814: 81 e8 00 00 restore 4000e84c : uint32_t count, uint32_t max_message_size, rtems_attribute attribute_set, Objects_Id *id ) { 4000e84c: 9d e3 bf 90 save %sp, -112, %sp CORE_message_queue_Attributes the_msgq_attributes; #if defined(RTEMS_MULTIPROCESSING) boolean is_global; #endif if ( !rtems_is_name_valid( name ) ) 4000e850: a2 96 20 00 orcc %i0, 0, %l1 4000e854: 02 80 00 17 be 4000e8b0 4000e858: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !id ) 4000e85c: 80 a7 20 00 cmp %i4, 0 4000e860: 02 80 00 14 be 4000e8b0 4000e864: b0 10 20 09 mov 9, %i0 if ( (is_global = _Attributes_Is_global( attribute_set ) ) && !_System_state_Is_multiprocessing ) return RTEMS_MP_NOT_CONFIGURED; #endif if ( count == 0 ) 4000e868: 80 a6 60 00 cmp %i1, 0 4000e86c: 02 80 00 11 be 4000e8b0 4000e870: b0 10 20 0a mov 0xa, %i0 return RTEMS_INVALID_NUMBER; if ( max_message_size == 0 ) 4000e874: 80 a6 a0 00 cmp %i2, 0 4000e878: 02 80 00 0e be 4000e8b0 4000e87c: b0 10 20 08 mov 8, %i0 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000e880: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000e884: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000e888: 82 00 60 01 inc %g1 4000e88c: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] #endif #endif _Thread_Disable_dispatch(); /* protects object pointer */ the_message_queue = _Message_queue_Allocate( count, max_message_size ); 4000e890: 90 10 00 19 mov %i1, %o0 4000e894: 40 00 2b 2c call 40019544 <_Message_queue_Allocate> 4000e898: 92 10 00 1a mov %i2, %o1 if ( !the_message_queue ) { 4000e89c: a0 92 20 00 orcc %o0, 0, %l0 4000e8a0: 12 80 00 06 bne 4000e8b8 4000e8a4: 80 8e e0 04 btst 4, %i3 _Thread_Enable_dispatch(); 4000e8a8: 7f ff ff dc call 4000e818 <_Thread_Enable_dispatch> 4000e8ac: b0 10 20 05 mov 5, %i0 4000e8b0: 81 c7 e0 08 ret 4000e8b4: 81 e8 00 00 restore } #endif the_message_queue->attribute_set = attribute_set; if (_Attributes_Is_priority( attribute_set ) ) 4000e8b8: 02 80 00 05 be 4000e8cc 4000e8bc: f6 24 20 10 st %i3, [ %l0 + 0x10 ] the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_PRIORITY; 4000e8c0: 82 10 20 01 mov 1, %g1 4000e8c4: 10 80 00 03 b 4000e8d0 4000e8c8: c2 27 bf f4 st %g1, [ %fp + -12 ] else the_msgq_attributes.discipline = CORE_MESSAGE_QUEUE_DISCIPLINES_FIFO; 4000e8cc: c0 27 bf f4 clr [ %fp + -12 ] if ( ! _CORE_message_queue_Initialize( 4000e8d0: 94 10 00 19 mov %i1, %o2 4000e8d4: 96 10 00 1a mov %i2, %o3 4000e8d8: 90 04 20 14 add %l0, 0x14, %o0 4000e8dc: 40 00 13 1d call 40013550 <_CORE_message_queue_Initialize> 4000e8e0: 92 07 bf f4 add %fp, -12, %o1 4000e8e4: 80 a2 20 00 cmp %o0, 0 4000e8e8: 12 80 00 0a bne 4000e910 4000e8ec: 11 10 00 c9 sethi %hi(0x40032400), %o0 RTEMS_INLINE_ROUTINE void _Message_queue_Free ( Message_queue_Control *the_message_queue ) { _Objects_Free( &_Message_queue_Information, &the_message_queue->Object ); 4000e8f0: 90 12 22 00 or %o0, 0x200, %o0 ! 40032600 <_Message_queue_Information> <== NOT EXECUTED 4000e8f4: 92 10 00 10 mov %l0, %o1 <== NOT EXECUTED 4000e8f8: 40 00 17 d7 call 40014854 <_Objects_Free> <== NOT EXECUTED 4000e8fc: b0 10 20 0d mov 0xd, %i0 <== NOT EXECUTED _Objects_MP_Close( &_Message_queue_Information, the_message_queue->Object.id); #endif _Message_queue_Free( the_message_queue ); _Thread_Enable_dispatch(); 4000e900: 7f ff ff c6 call 4000e818 <_Thread_Enable_dispatch> <== NOT EXECUTED 4000e904: 01 00 00 00 nop <== NOT EXECUTED 4000e908: 81 c7 e0 08 ret <== NOT EXECUTED 4000e90c: 81 e8 00 00 restore <== NOT EXECUTED Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000e910: 90 12 22 00 or %o0, 0x200, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000e914: c2 04 20 08 ld [ %l0 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000e918: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 4000e91c: 05 00 00 3f sethi %hi(0xfc00), %g2 4000e920: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 4000e924: 82 08 40 02 and %g1, %g2, %g1 4000e928: 80 a0 40 03 cmp %g1, %g3 4000e92c: 38 80 00 06 bgu,a 4000e944 4000e930: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED information->local_table[ index ] = the_object; 4000e934: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4000e938: 83 28 60 02 sll %g1, 2, %g1 4000e93c: e0 20 80 01 st %l0, [ %g2 + %g1 ] &_Message_queue_Information, &the_message_queue->Object, (Objects_Name) name ); *id = the_message_queue->Object.id; 4000e940: c2 04 20 08 ld [ %l0 + 8 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 4000e944: e2 24 20 0c st %l1, [ %l0 + 0xc ] 4000e948: c2 27 00 00 st %g1, [ %i4 ] name, 0 ); #endif _Thread_Enable_dispatch(); 4000e94c: 7f ff ff b3 call 4000e818 <_Thread_Enable_dispatch> 4000e950: b0 10 20 00 clr %i0 return RTEMS_SUCCESSFUL; } 4000e954: 81 c7 e0 08 ret 4000e958: 81 e8 00 00 restore 4001247c : */ rtems_status_code rtems_message_queue_delete( Objects_Id id ) { 4001247c: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Message_queue_Control *_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (Message_queue_Control *) 40012480: 21 10 00 9e sethi %hi(0x40027800), %l0 40012484: 92 10 00 18 mov %i0, %o1 40012488: 94 07 bf f4 add %fp, -12, %o2 4001248c: 7f ff e6 a5 call 4000bf20 <_Objects_Get> 40012490: 90 14 22 8c or %l0, 0x28c, %o0 register Message_queue_Control *the_message_queue; Objects_Locations location; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { 40012494: c2 07 bf f4 ld [ %fp + -12 ], %g1 40012498: 80 a0 60 00 cmp %g1, 0 4001249c: 02 80 00 07 be 400124b8 400124a0: b0 10 00 08 mov %o0, %i0 400124a4: 80 a0 60 02 cmp %g1, 2 400124a8: 08 80 00 22 bleu 40012530 400124ac: b0 10 20 04 mov 4, %i0 400124b0: 81 c7 e0 08 ret <== NOT EXECUTED 400124b4: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 400124b8: a0 14 22 8c or %l0, 0x28c, %l0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 400124bc: c2 02 20 08 ld [ %o0 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 400124c0: c6 14 20 10 lduh [ %l0 + 0x10 ], %g3 400124c4: 05 00 00 3f sethi %hi(0xfc00), %g2 400124c8: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 400124cc: 82 08 40 02 and %g1, %g2, %g1 400124d0: 80 a0 40 03 cmp %g1, %g3 400124d4: 18 80 00 05 bgu 400124e8 400124d8: 94 10 20 05 mov 5, %o2 information->local_table[ index ] = the_object; 400124dc: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 400124e0: 83 28 60 02 sll %g1, 2, %g1 400124e4: c0 20 80 01 clr [ %g2 + %g1 ] case OBJECTS_LOCAL: _Objects_Close( &_Message_queue_Information, &the_message_queue->Object ); _CORE_message_queue_Close( 400124e8: 90 06 20 14 add %i0, 0x14, %o0 uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 400124ec: c0 26 20 0c clr [ %i0 + 0xc ] 400124f0: 40 00 01 9e call 40012b68 <_CORE_message_queue_Close> 400124f4: 92 10 20 00 clr %o1 RTEMS_INLINE_ROUTINE void _Message_queue_Free ( Message_queue_Control *the_message_queue ) { _Objects_Free( &_Message_queue_Information, &the_message_queue->Object ); 400124f8: 90 10 00 10 mov %l0, %o0 400124fc: 7f ff e6 47 call 4000be18 <_Objects_Free> 40012500: 92 10 00 18 mov %i0, %o1 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40012504: 03 10 00 9d sethi %hi(0x40027400), %g1 40012508: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 400276f0 <_Thread_Dispatch_disable_level> 4001250c: b0 10 20 00 clr %i0 40012510: 84 00 bf ff add %g2, -1, %g2 40012514: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] 40012518: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 4001251c: 80 a0 60 00 cmp %g1, 0 40012520: 12 80 00 04 bne 40012530 40012524: 01 00 00 00 nop _Thread_Dispatch(); 40012528: 7f ff eb 72 call 4000d2f0 <_Thread_Dispatch> 4001252c: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40012530: 81 c7 e0 08 ret 40012534: 81 e8 00 00 restore 4000ea18 : rtems_status_code rtems_message_queue_flush( Objects_Id id, uint32_t *count ) { 4000ea18: 9d e3 bf 90 save %sp, -112, %sp 4000ea1c: 92 10 00 18 mov %i0, %o1 register Message_queue_Control *the_message_queue; Objects_Locations location; if ( !count ) 4000ea20: 80 a6 60 00 cmp %i1, 0 4000ea24: 02 80 00 1c be 4000ea94 4000ea28: b0 10 20 09 mov 9, %i0 RTEMS_INLINE_ROUTINE Message_queue_Control *_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (Message_queue_Control *) 4000ea2c: 11 10 00 c9 sethi %hi(0x40032400), %o0 4000ea30: 94 07 bf f4 add %fp, -12, %o2 4000ea34: 40 00 17 de call 400149ac <_Objects_Get> 4000ea38: 90 12 22 00 or %o0, 0x200, %o0 return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { 4000ea3c: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000ea40: 80 a0 60 00 cmp %g1, 0 4000ea44: 02 80 00 06 be 4000ea5c 4000ea48: 80 a0 60 02 cmp %g1, 2 4000ea4c: 08 80 00 12 bleu 4000ea94 4000ea50: b0 10 20 04 mov 4, %i0 4000ea54: 81 c7 e0 08 ret <== NOT EXECUTED 4000ea58: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: *count = _CORE_message_queue_Flush( &the_message_queue->message_queue ); 4000ea5c: 40 00 12 9e call 400134d4 <_CORE_message_queue_Flush> 4000ea60: 90 02 20 14 add %o0, 0x14, %o0 4000ea64: d0 26 40 00 st %o0, [ %i1 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000ea68: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000ea6c: c4 00 62 e0 ld [ %g1 + 0x2e0 ], %g2 ! 400322e0 <_Thread_Dispatch_disable_level> 4000ea70: b0 10 20 00 clr %i0 4000ea74: 84 00 bf ff add %g2, -1, %g2 4000ea78: c4 20 62 e0 st %g2, [ %g1 + 0x2e0 ] 4000ea7c: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 4000ea80: 80 a0 60 00 cmp %g1, 0 4000ea84: 12 80 00 04 bne 4000ea94 4000ea88: 01 00 00 00 nop _Thread_Dispatch(); 4000ea8c: 40 00 1c bc call 40015d7c <_Thread_Dispatch> 4000ea90: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000ea94: 81 c7 e0 08 ret 4000ea98: 81 e8 00 00 restore 4000ea9c : rtems_status_code rtems_message_queue_get_number_pending( Objects_Id id, uint32_t *count ) { 4000ea9c: 9d e3 bf 90 save %sp, -112, %sp 4000eaa0: 92 10 00 18 mov %i0, %o1 register Message_queue_Control *the_message_queue; Objects_Locations location; if ( !count ) 4000eaa4: 80 a6 60 00 cmp %i1, 0 4000eaa8: 02 80 00 1b be 4000eb14 4000eaac: b0 10 20 09 mov 9, %i0 4000eab0: 11 10 00 c9 sethi %hi(0x40032400), %o0 4000eab4: 94 07 bf f4 add %fp, -12, %o2 4000eab8: 40 00 17 bd call 400149ac <_Objects_Get> 4000eabc: 90 12 22 00 or %o0, 0x200, %o0 return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { 4000eac0: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000eac4: 80 a0 60 00 cmp %g1, 0 4000eac8: 22 80 00 07 be,a 4000eae4 4000eacc: c2 02 20 5c ld [ %o0 + 0x5c ], %g1 4000ead0: 80 a0 60 02 cmp %g1, 2 4000ead4: 08 80 00 10 bleu 4000eb14 4000ead8: b0 10 20 04 mov 4, %i0 4000eadc: 81 c7 e0 08 ret <== NOT EXECUTED 4000eae0: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: *count = the_message_queue->message_queue.number_of_pending_messages; 4000eae4: c2 26 40 00 st %g1, [ %i1 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000eae8: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000eaec: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000eaf0: b0 10 20 00 clr %i0 4000eaf4: 82 00 7f ff add %g1, -1, %g1 4000eaf8: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] 4000eafc: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 4000eb00: 80 a0 60 00 cmp %g1, 0 4000eb04: 12 80 00 04 bne 4000eb14 4000eb08: 01 00 00 00 nop _Thread_Dispatch(); 4000eb0c: 40 00 1c 9c call 40015d7c <_Thread_Dispatch> 4000eb10: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000eb14: 81 c7 e0 08 ret 4000eb18: 81 e8 00 00 restore 4001256c : void *buffer, size_t *size, uint32_t option_set, rtems_interval timeout ) { 4001256c: 9d e3 bf 90 save %sp, -112, %sp register Message_queue_Control *the_message_queue; Objects_Locations location; boolean wait; if ( !buffer ) 40012570: 80 a6 60 00 cmp %i1, 0 40012574: 02 80 00 28 be 40012614 40012578: 92 10 00 18 mov %i0, %o1 return RTEMS_INVALID_ADDRESS; if ( !size ) 4001257c: 80 a6 a0 00 cmp %i2, 0 40012580: 02 80 00 25 be 40012614 40012584: 11 10 00 9e sethi %hi(0x40027800), %o0 RTEMS_INLINE_ROUTINE Message_queue_Control *_Message_queue_Get ( Objects_Id id, Objects_Locations *location ) { return (Message_queue_Control *) 40012588: 94 07 bf f4 add %fp, -12, %o2 4001258c: 7f ff e6 65 call 4000bf20 <_Objects_Get> 40012590: 90 12 22 8c or %o0, 0x28c, %o0 return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) { 40012594: c2 07 bf f4 ld [ %fp + -12 ], %g1 40012598: 80 a0 60 00 cmp %g1, 0 4001259c: 22 80 00 07 be,a 400125b8 400125a0: d2 02 20 08 ld [ %o0 + 8 ], %o1 400125a4: 80 a0 60 02 cmp %g1, 2 400125a8: 08 80 00 1c bleu 40012618 400125ac: 90 10 20 04 mov 4, %o0 400125b0: 10 80 00 1a b 40012618 <== NOT EXECUTED 400125b4: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED 400125b8: 98 0e e0 01 and %i3, 1, %o4 if ( _Options_Is_no_wait( option_set ) ) wait = FALSE; else wait = TRUE; _CORE_message_queue_Seize( 400125bc: 94 10 00 19 mov %i1, %o2 400125c0: 96 10 00 1a mov %i2, %o3 400125c4: 98 1b 20 01 xor %o4, 1, %o4 400125c8: 9a 10 00 1c mov %i4, %o5 400125cc: 40 00 01 94 call 40012c1c <_CORE_message_queue_Seize> 400125d0: 90 02 20 14 add %o0, 0x14, %o0 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 400125d4: 05 10 00 9d sethi %hi(0x40027400), %g2 400125d8: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 400276f0 <_Thread_Dispatch_disable_level> 400125dc: 82 00 7f ff add %g1, -1, %g1 400125e0: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 400125e4: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 400125e8: 80 a0 60 00 cmp %g1, 0 400125ec: 12 80 00 05 bne 40012600 400125f0: 03 10 00 9d sethi %hi(0x40027400), %g1 _Thread_Dispatch(); 400125f4: 7f ff eb 3f call 4000d2f0 <_Thread_Dispatch> 400125f8: 01 00 00 00 nop size, wait, timeout ); _Thread_Enable_dispatch(); return _Message_queue_Translate_core_message_queue_return_code( 400125fc: 03 10 00 9d sethi %hi(0x40027400), %g1 40012600: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 400277cc <_Thread_Executing> 40012604: 40 00 00 32 call 400126cc <_Message_queue_Translate_core_message_queue_return_code> 40012608: d0 00 60 34 ld [ %g1 + 0x34 ], %o0 ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4001260c: 81 c7 e0 08 ret 40012610: 91 e8 00 08 restore %g0, %o0, %o0 size, wait, timeout ); _Thread_Enable_dispatch(); return _Message_queue_Translate_core_message_queue_return_code( 40012614: 90 10 20 09 mov 9, %o0 <== NOT EXECUTED ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40012618: b0 10 00 08 mov %o0, %i0 4001261c: 81 c7 e0 08 ret 40012620: 81 e8 00 00 restore 40012624 : rtems_status_code rtems_message_queue_send( Objects_Id id, void *buffer, size_t size ) { 40012624: 9d e3 bf 88 save %sp, -120, %sp register Message_queue_Control *the_message_queue; Objects_Locations location; CORE_message_queue_Status status; if ( !buffer ) 40012628: 80 a6 60 00 cmp %i1, 0 4001262c: 02 80 00 26 be 400126c4 40012630: 90 10 20 09 mov 9, %o0 40012634: 11 10 00 9e sethi %hi(0x40027800), %o0 40012638: 92 10 00 18 mov %i0, %o1 4001263c: 90 12 22 8c or %o0, 0x28c, %o0 40012640: 7f ff e6 38 call 4000bf20 <_Objects_Get> 40012644: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) 40012648: c2 07 bf f4 ld [ %fp + -12 ], %g1 4001264c: 80 a0 60 00 cmp %g1, 0 40012650: 22 80 00 07 be,a 4001266c 40012654: 94 10 00 1a mov %i2, %o2 40012658: 80 a0 60 02 cmp %g1, 2 4001265c: 08 80 00 1a bleu 400126c4 40012660: 90 10 20 04 mov 4, %o0 40012664: 10 80 00 18 b 400126c4 <== NOT EXECUTED 40012668: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED CORE_message_queue_API_mp_support_callout api_message_queue_mp_support, boolean wait, Watchdog_Interval timeout ) { return _CORE_message_queue_Submit( 4001266c: c0 23 a0 5c clr [ %sp + 0x5c ] 40012670: c0 23 a0 60 clr [ %sp + 0x60 ] 40012674: 92 10 00 19 mov %i1, %o1 40012678: 96 10 00 18 mov %i0, %o3 4001267c: 98 10 20 00 clr %o4 40012680: 90 02 20 14 add %o0, 0x14, %o0 40012684: 1b 1f ff ff sethi %hi(0x7ffffc00), %o5 40012688: 40 00 01 b2 call 40012d50 <_CORE_message_queue_Submit> 4001268c: 9a 13 63 ff or %o5, 0x3ff, %o5 ! 7fffffff 40012690: b4 10 00 08 mov %o0, %i2 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40012694: 05 10 00 9d sethi %hi(0x40027400), %g2 40012698: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 400276f0 <_Thread_Dispatch_disable_level> 4001269c: 82 00 7f ff add %g1, -1, %g1 400126a0: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 400126a4: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 400126a8: 80 a0 60 00 cmp %g1, 0 400126ac: 12 80 00 04 bne 400126bc 400126b0: 01 00 00 00 nop _Thread_Dispatch(); 400126b4: 7f ff eb 0f call 4000d2f0 <_Thread_Dispatch> 400126b8: 01 00 00 00 nop /* * Since this API does not allow for blocking sends, we can directly * return the returned status. */ return _Message_queue_Translate_core_message_queue_return_code(status); 400126bc: 40 00 00 04 call 400126cc <_Message_queue_Translate_core_message_queue_return_code> 400126c0: 90 10 00 1a mov %i2, %o0 } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400126c4: 81 c7 e0 08 ret 400126c8: 91 e8 00 08 restore %g0, %o0, %o0 400082ac : rtems_status_code rtems_message_queue_urgent( Objects_Id id, void *buffer, size_t size ) { 400082ac: 9d e3 bf 88 save %sp, -120, %sp register Message_queue_Control *the_message_queue; Objects_Locations location; CORE_message_queue_Status status; if ( !buffer ) 400082b0: 80 a6 60 00 cmp %i1, 0 400082b4: 02 80 00 25 be 40008348 400082b8: 90 10 20 09 mov 9, %o0 400082bc: 11 10 00 82 sethi %hi(0x40020800), %o0 400082c0: 92 10 00 18 mov %i0, %o1 400082c4: 90 12 22 08 or %o0, 0x208, %o0 400082c8: 40 00 09 de call 4000aa40 <_Objects_Get> 400082cc: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_message_queue = _Message_queue_Get( id, &location ); switch ( location ) 400082d0: c2 07 bf f4 ld [ %fp + -12 ], %g1 400082d4: 80 a0 60 00 cmp %g1, 0 400082d8: 22 80 00 07 be,a 400082f4 400082dc: 94 10 00 1a mov %i2, %o2 400082e0: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 400082e4: 08 80 00 19 bleu 40008348 <== NOT EXECUTED 400082e8: 90 10 20 04 mov 4, %o0 <== NOT EXECUTED 400082ec: 10 80 00 17 b 40008348 <== NOT EXECUTED 400082f0: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED CORE_message_queue_API_mp_support_callout api_message_queue_mp_support, boolean wait, Watchdog_Interval timeout ) { return _CORE_message_queue_Submit( 400082f4: c0 23 a0 5c clr [ %sp + 0x5c ] 400082f8: c0 23 a0 60 clr [ %sp + 0x60 ] 400082fc: 92 10 00 19 mov %i1, %o1 40008300: 96 10 00 18 mov %i0, %o3 40008304: 98 10 20 00 clr %o4 40008308: 1b 20 00 00 sethi %hi(0x80000000), %o5 4000830c: 40 00 05 c8 call 40009a2c <_CORE_message_queue_Submit> 40008310: 90 02 20 14 add %o0, 0x14, %o0 40008314: b4 10 00 08 mov %o0, %i2 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40008318: 03 10 00 81 sethi %hi(0x40020400), %g1 4000831c: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 400206f0 <_Thread_Dispatch_disable_level> 40008320: 84 00 bf ff add %g2, -1, %g2 40008324: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] 40008328: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 4000832c: 80 a0 60 00 cmp %g1, 0 40008330: 12 80 00 04 bne 40008340 40008334: 01 00 00 00 nop _Thread_Dispatch(); 40008338: 40 00 0e b6 call 4000be10 <_Thread_Dispatch> 4000833c: 01 00 00 00 nop /* * Since this API does not allow for blocking sends, we can directly * return the returned status. */ return _Message_queue_Translate_core_message_queue_return_code(status); 40008340: 7f ff ff d1 call 40008284 <_Message_queue_Translate_core_message_queue_return_code> 40008344: 90 10 00 1a mov %i2, %o0 } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40008348: 81 c7 e0 08 ret 4000834c: 91 e8 00 08 restore %g0, %o0, %o0 4000ed0c : uint32_t length, uint32_t buffer_size, rtems_attribute attribute_set, Objects_Id *id ) { 4000ed0c: 9d e3 bf 98 save %sp, -104, %sp register Partition_Control *the_partition; if ( !rtems_is_name_valid( name ) ) 4000ed10: a6 96 20 00 orcc %i0, 0, %l3 4000ed14: 02 80 00 1e be 4000ed8c 4000ed18: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !starting_address ) 4000ed1c: 80 a6 60 00 cmp %i1, 0 4000ed20: 02 80 00 3d be 4000ee14 4000ed24: 80 a7 60 00 cmp %i5, 0 return RTEMS_INVALID_ADDRESS; if ( !id ) 4000ed28: 02 80 00 3b be 4000ee14 4000ed2c: 80 a6 a0 00 cmp %i2, 0 return RTEMS_INVALID_ADDRESS; if ( length == 0 || buffer_size == 0 || length < buffer_size || 4000ed30: 22 80 00 17 be,a 4000ed8c 4000ed34: b0 10 20 08 mov 8, %i0 4000ed38: 80 a6 e0 00 cmp %i3, 0 4000ed3c: 22 80 00 14 be,a 4000ed8c 4000ed40: b0 10 20 08 mov 8, %i0 4000ed44: 80 a6 80 1b cmp %i2, %i3 4000ed48: 0a 80 00 35 bcs 4000ee1c 4000ed4c: 80 8e e0 07 btst 7, %i3 4000ed50: 12 80 00 33 bne 4000ee1c 4000ed54: 80 8e 60 07 btst 7, %i1 !_Partition_Is_buffer_size_aligned( buffer_size ) ) return RTEMS_INVALID_SIZE; if ( !_Addresses_Is_aligned( starting_address ) ) 4000ed58: 12 80 00 2f bne 4000ee14 4000ed5c: 05 10 00 c8 sethi %hi(0x40032000), %g2 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000ed60: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000ed64: 82 00 60 01 inc %g1 4000ed68: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] * the inactive chain of free partition control blocks. */ RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Allocate ( void ) { return (Partition_Control *) _Objects_Allocate( &_Partition_Information ); 4000ed6c: 25 10 00 c8 sethi %hi(0x40032000), %l2 4000ed70: 40 00 15 b7 call 4001444c <_Objects_Allocate> 4000ed74: 90 14 a0 60 or %l2, 0x60, %o0 ! 40032060 <_Partition_Information> _Thread_Disable_dispatch(); /* prevents deletion */ the_partition = _Partition_Allocate(); if ( !the_partition ) { 4000ed78: a2 92 20 00 orcc %o0, 0, %l1 4000ed7c: 12 80 00 06 bne 4000ed94 4000ed80: 92 10 00 1b mov %i3, %o1 _Thread_Enable_dispatch(); 4000ed84: 7f ff ff d5 call 4000ecd8 <_Thread_Enable_dispatch> 4000ed88: b0 10 20 05 mov 5, %i0 4000ed8c: 81 c7 e0 08 ret 4000ed90: 81 e8 00 00 restore #endif the_partition->starting_address = starting_address; the_partition->length = length; the_partition->buffer_size = buffer_size; the_partition->attribute_set = attribute_set; 4000ed94: f8 24 60 1c st %i4, [ %l1 + 0x1c ] _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } #endif the_partition->starting_address = starting_address; 4000ed98: f2 24 60 10 st %i1, [ %l1 + 0x10 ] the_partition->length = length; 4000ed9c: f4 24 60 14 st %i2, [ %l1 + 0x14 ] the_partition->buffer_size = buffer_size; 4000eda0: f6 24 60 18 st %i3, [ %l1 + 0x18 ] the_partition->attribute_set = attribute_set; the_partition->number_of_used_blocks = 0; 4000eda4: c0 24 60 20 clr [ %l1 + 0x20 ] _Chain_Initialize( &the_partition->Memory, starting_address, 4000eda8: 40 00 52 c2 call 400238b0 <.udiv> 4000edac: 90 10 00 1a mov %i2, %o0 4000edb0: a0 04 60 24 add %l1, 0x24, %l0 4000edb4: 94 10 00 08 mov %o0, %o2 4000edb8: 92 10 00 19 mov %i1, %o1 4000edbc: 90 10 00 10 mov %l0, %o0 4000edc0: 40 00 11 8a call 400133e8 <_Chain_Initialize> 4000edc4: 96 10 00 1b mov %i3, %o3 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000edc8: 90 14 a0 60 or %l2, 0x60, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000edcc: c4 04 60 08 ld [ %l1 + 8 ], %g2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000edd0: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 4000edd4: 03 00 00 3f sethi %hi(0xfc00), %g1 4000edd8: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 4000eddc: 82 08 80 01 and %g2, %g1, %g1 4000ede0: 80 a0 40 03 cmp %g1, %g3 4000ede4: 38 80 00 06 bgu,a 4000edfc 4000ede8: c2 04 60 08 ld [ %l1 + 8 ], %g1 <== NOT EXECUTED information->local_table[ index ] = the_object; 4000edec: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4000edf0: 83 28 60 02 sll %g1, 2, %g1 4000edf4: e2 20 80 01 st %l1, [ %g2 + %g1 ] &_Partition_Information, &the_partition->Object, (Objects_Name) name ); *id = the_partition->Object.id; 4000edf8: c2 04 60 08 ld [ %l1 + 8 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 4000edfc: e6 24 60 0c st %l3, [ %l1 + 0xc ] 4000ee00: c2 27 40 00 st %g1, [ %i5 ] name, 0 /* Not used */ ); #endif _Thread_Enable_dispatch(); 4000ee04: 7f ff ff b5 call 4000ecd8 <_Thread_Enable_dispatch> 4000ee08: b0 10 20 00 clr %i0 4000ee0c: 81 c7 e0 08 ret 4000ee10: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; 4000ee14: 81 c7 e0 08 ret 4000ee18: 91 e8 20 09 restore %g0, 9, %o0 4000ee1c: b0 10 20 08 mov 8, %i0 } 4000ee20: 81 c7 e0 08 ret 4000ee24: 81 e8 00 00 restore 4000ee5c : */ rtems_status_code rtems_partition_delete( Objects_Id id ) { 4000ee5c: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Get ( Objects_Id id, Objects_Locations *location ) { return (Partition_Control *) 4000ee60: 92 10 00 18 mov %i0, %o1 4000ee64: 94 07 bf f4 add %fp, -12, %o2 4000ee68: 31 10 00 c8 sethi %hi(0x40032000), %i0 4000ee6c: 40 00 16 d0 call 400149ac <_Objects_Get> 4000ee70: 90 16 20 60 or %i0, 0x60, %o0 ! 40032060 <_Partition_Information> register Partition_Control *the_partition; Objects_Locations location; the_partition = _Partition_Get( id, &location ); switch ( location ) { 4000ee74: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000ee78: 80 a0 60 00 cmp %g1, 0 4000ee7c: 02 80 00 07 be 4000ee98 4000ee80: 88 10 00 08 mov %o0, %g4 4000ee84: 80 a0 60 02 cmp %g1, 2 4000ee88: 08 80 00 18 bleu 4000eee8 4000ee8c: b0 10 20 04 mov 4, %i0 4000ee90: 81 c7 e0 08 ret <== NOT EXECUTED 4000ee94: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( the_partition->number_of_used_blocks == 0 ) { 4000ee98: c2 02 20 20 ld [ %o0 + 0x20 ], %g1 4000ee9c: 80 a0 60 00 cmp %g1, 0 4000eea0: 12 80 00 14 bne 4000eef0 4000eea4: 90 16 20 60 or %i0, 0x60, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 4000eea8: c2 01 20 08 ld [ %g4 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000eeac: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 4000eeb0: 05 00 00 3f sethi %hi(0xfc00), %g2 4000eeb4: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 4000eeb8: 82 08 40 02 and %g1, %g2, %g1 4000eebc: 80 a0 40 03 cmp %g1, %g3 4000eec0: 18 80 00 05 bgu 4000eed4 4000eec4: 92 10 00 04 mov %g4, %o1 information->local_table[ index ] = the_object; 4000eec8: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4000eecc: 83 28 60 02 sll %g1, 2, %g1 4000eed0: c0 20 80 01 clr [ %g2 + %g1 ] uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 4000eed4: c0 21 20 0c clr [ %g4 + 0xc ] RTEMS_INLINE_ROUTINE void _Partition_Free ( Partition_Control *the_partition ) { _Objects_Free( &_Partition_Information, &the_partition->Object ); 4000eed8: 40 00 16 5f call 40014854 <_Objects_Free> 4000eedc: b0 10 20 00 clr %i0 0 /* Not used */ ); } #endif _Thread_Enable_dispatch(); 4000eee0: 7f ff ff d2 call 4000ee28 <_Thread_Enable_dispatch> 4000eee4: 01 00 00 00 nop 4000eee8: 81 c7 e0 08 ret 4000eeec: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 4000eef0: 7f ff ff ce call 4000ee28 <_Thread_Enable_dispatch> 4000eef4: b0 10 20 0c mov 0xc, %i0 return RTEMS_RESOURCE_IN_USE; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000eef8: 81 c7 e0 08 ret 4000eefc: 81 e8 00 00 restore 4000ef34 : rtems_status_code rtems_partition_get_buffer( Objects_Id id, void **buffer ) { 4000ef34: 9d e3 bf 90 save %sp, -112, %sp 4000ef38: 92 10 00 18 mov %i0, %o1 register Partition_Control *the_partition; Objects_Locations location; void *the_buffer; if ( !buffer ) 4000ef3c: 80 a6 60 00 cmp %i1, 0 4000ef40: 02 80 00 1a be 4000efa8 4000ef44: b0 10 20 09 mov 9, %i0 RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Get ( Objects_Id id, Objects_Locations *location ) { return (Partition_Control *) 4000ef48: 11 10 00 c8 sethi %hi(0x40032000), %o0 4000ef4c: 94 07 bf f4 add %fp, -12, %o2 4000ef50: 40 00 16 97 call 400149ac <_Objects_Get> 4000ef54: 90 12 20 60 or %o0, 0x60, %o0 return RTEMS_INVALID_ADDRESS; the_partition = _Partition_Get( id, &location ); switch ( location ) { 4000ef58: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000ef5c: 80 a0 60 00 cmp %g1, 0 4000ef60: 02 80 00 07 be 4000ef7c 4000ef64: b0 10 00 08 mov %o0, %i0 4000ef68: 80 a0 60 02 cmp %g1, 2 4000ef6c: 08 80 00 0f bleu 4000efa8 4000ef70: b0 10 20 04 mov 4, %i0 4000ef74: 81 c7 e0 08 ret <== NOT EXECUTED 4000ef78: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED RTEMS_INLINE_ROUTINE void *_Partition_Allocate_buffer ( Partition_Control *the_partition ) { return _Chain_Get( &the_partition->Memory ); 4000ef7c: 40 00 11 0b call 400133a8 <_Chain_Get> 4000ef80: 90 02 20 24 add %o0, 0x24, %o0 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: the_buffer = _Partition_Allocate_buffer( the_partition ); if ( the_buffer ) { 4000ef84: a0 92 20 00 orcc %o0, 0, %l0 4000ef88: 02 80 00 0a be 4000efb0 4000ef8c: 01 00 00 00 nop the_partition->number_of_used_blocks += 1; 4000ef90: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 4000ef94: 82 00 60 01 inc %g1 4000ef98: c2 26 20 20 st %g1, [ %i0 + 0x20 ] _Thread_Enable_dispatch(); 4000ef9c: 7f ff ff d9 call 4000ef00 <_Thread_Enable_dispatch> 4000efa0: b0 10 20 00 clr %i0 *buffer = the_buffer; 4000efa4: e0 26 40 00 st %l0, [ %i1 ] 4000efa8: 81 c7 e0 08 ret 4000efac: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 4000efb0: 7f ff ff d4 call 4000ef00 <_Thread_Enable_dispatch> 4000efb4: b0 10 20 0d mov 0xd, %i0 return RTEMS_UNSATISFIED; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000efb8: 81 c7 e0 08 ret 4000efbc: 81 e8 00 00 restore 4000f028 : rtems_status_code rtems_partition_return_buffer( Objects_Id id, void *buffer ) { 4000f028: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Partition_Control *_Partition_Get ( Objects_Id id, Objects_Locations *location ) { return (Partition_Control *) 4000f02c: 11 10 00 c8 sethi %hi(0x40032000), %o0 4000f030: 92 10 00 18 mov %i0, %o1 4000f034: 90 12 20 60 or %o0, 0x60, %o0 4000f038: 40 00 16 5d call 400149ac <_Objects_Get> 4000f03c: 94 07 bf f4 add %fp, -12, %o2 register Partition_Control *the_partition; Objects_Locations location; the_partition = _Partition_Get( id, &location ); switch ( location ) { 4000f040: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000f044: 80 a0 60 00 cmp %g1, 0 4000f048: 02 80 00 07 be 4000f064 4000f04c: b0 10 00 08 mov %o0, %i0 4000f050: 80 a0 60 02 cmp %g1, 2 4000f054: 08 80 00 1a bleu 4000f0bc 4000f058: b0 10 20 04 mov 4, %i0 4000f05c: 81 c7 e0 08 ret <== NOT EXECUTED 4000f060: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED ) { void *starting; void *ending; starting = the_partition->starting_address; 4000f064: c4 02 20 10 ld [ %o0 + 0x10 ], %g2 ending = _Addresses_Add_offset( starting, the_partition->length ); return ( 4000f068: 80 a6 40 02 cmp %i1, %g2 4000f06c: 0a 80 00 16 bcs 4000f0c4 4000f070: 01 00 00 00 nop 4000f074: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 4000f078: 82 00 80 01 add %g2, %g1, %g1 4000f07c: 80 a6 40 01 cmp %i1, %g1 4000f080: 18 80 00 11 bgu 4000f0c4 4000f084: 01 00 00 00 nop 4000f088: d2 02 20 18 ld [ %o0 + 0x18 ], %o1 4000f08c: 40 00 52 b5 call 40023b60 <.urem> 4000f090: 90 26 40 02 sub %i1, %g2, %o0 4000f094: 80 a2 20 00 cmp %o0, 0 4000f098: 12 80 00 0b bne 4000f0c4 4000f09c: 90 06 20 24 add %i0, 0x24, %o0 RTEMS_INLINE_ROUTINE void _Partition_Free_buffer ( Partition_Control *the_partition, Chain_Node *the_buffer ) { _Chain_Append( &the_partition->Memory, the_buffer ); 4000f0a0: 40 00 10 b6 call 40013378 <_Chain_Append> 4000f0a4: 92 10 00 19 mov %i1, %o1 return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( _Partition_Is_buffer_valid( buffer, the_partition ) ) { _Partition_Free_buffer( the_partition, buffer ); the_partition->number_of_used_blocks -= 1; 4000f0a8: c2 06 20 20 ld [ %i0 + 0x20 ], %g1 4000f0ac: 82 00 7f ff add %g1, -1, %g1 4000f0b0: c2 26 20 20 st %g1, [ %i0 + 0x20 ] _Thread_Enable_dispatch(); 4000f0b4: 7f ff ff d0 call 4000eff4 <_Thread_Enable_dispatch> 4000f0b8: b0 10 20 00 clr %i0 4000f0bc: 81 c7 e0 08 ret 4000f0c0: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 4000f0c4: 7f ff ff cc call 4000eff4 <_Thread_Enable_dispatch> 4000f0c8: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000f0cc: 81 c7 e0 08 ret 4000f0d0: 81 e8 00 00 restore 4000ded0 : void *internal_start, void *external_start, uint32_t length, Objects_Id *id ) { 4000ded0: 9d e3 bf 98 save %sp, -104, %sp register Dual_ported_memory_Control *the_port; if ( !rtems_is_name_valid( name) ) 4000ded4: a2 96 20 00 orcc %i0, 0, %l1 4000ded8: 02 80 00 15 be 4000df2c 4000dedc: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !id ) 4000dee0: 80 a7 20 00 cmp %i4, 0 4000dee4: 02 80 00 29 be 4000df88 4000dee8: 80 8e 60 07 btst 7, %i1 return RTEMS_INVALID_ADDRESS; if ( !_Addresses_Is_aligned( internal_start ) || 4000deec: 12 80 00 27 bne 4000df88 4000def0: 80 8e a0 07 btst 7, %i2 4000def4: 32 80 00 0e bne,a 4000df2c 4000def8: b0 10 20 09 mov 9, %i0 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000defc: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000df00: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000df04: 82 00 60 01 inc %g1 4000df08: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] */ RTEMS_INLINE_ROUTINE Dual_ported_memory_Control *_Dual_ported_memory_Allocate ( void ) { return (Dual_ported_memory_Control *) 4000df0c: 21 10 00 c8 sethi %hi(0x40032000), %l0 4000df10: 40 00 19 4f call 4001444c <_Objects_Allocate> 4000df14: 90 14 20 14 or %l0, 0x14, %o0 ! 40032014 <_Dual_ported_memory_Information> _Thread_Disable_dispatch(); /* to prevent deletion */ the_port = _Dual_ported_memory_Allocate(); if ( !the_port ) { 4000df18: 80 a2 20 00 cmp %o0, 0 4000df1c: 12 80 00 06 bne 4000df34 4000df20: 88 14 20 14 or %l0, 0x14, %g4 _Thread_Enable_dispatch(); 4000df24: 7f ff ff de call 4000de9c <_Thread_Enable_dispatch> 4000df28: b0 10 20 05 mov 5, %i0 4000df2c: 81 c7 e0 08 ret 4000df30: 81 e8 00 00 restore ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000df34: c4 02 20 08 ld [ %o0 + 8 ], %g2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000df38: c6 11 20 10 lduh [ %g4 + 0x10 ], %g3 return RTEMS_TOO_MANY; } the_port->internal_base = internal_start; the_port->external_base = external_start; the_port->length = length - 1; 4000df3c: 82 06 ff ff add %i3, -1, %g1 if ( !the_port ) { _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } the_port->internal_base = internal_start; 4000df40: f2 22 20 10 st %i1, [ %o0 + 0x10 ] the_port->external_base = external_start; the_port->length = length - 1; 4000df44: c2 22 20 18 st %g1, [ %o0 + 0x18 ] 4000df48: 03 00 00 3f sethi %hi(0xfc00), %g1 4000df4c: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 4000df50: 82 08 80 01 and %g2, %g1, %g1 4000df54: 80 a0 40 03 cmp %g1, %g3 4000df58: 18 80 00 05 bgu 4000df6c 4000df5c: f4 22 20 14 st %i2, [ %o0 + 0x14 ] information->local_table[ index ] = the_object; 4000df60: c4 01 20 20 ld [ %g4 + 0x20 ], %g2 4000df64: 83 28 60 02 sll %g1, 2, %g1 4000df68: d0 20 80 01 st %o0, [ %g2 + %g1 ] &_Dual_ported_memory_Information, &the_port->Object, (Objects_Name) name ); *id = the_port->Object.id; 4000df6c: c2 02 20 08 ld [ %o0 + 8 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 4000df70: e2 22 20 0c st %l1, [ %o0 + 0xc ] 4000df74: c2 27 00 00 st %g1, [ %i4 ] _Thread_Enable_dispatch(); 4000df78: 7f ff ff c9 call 4000de9c <_Thread_Enable_dispatch> 4000df7c: b0 10 20 00 clr %i0 4000df80: 81 c7 e0 08 ret 4000df84: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; 4000df88: b0 10 20 09 mov 9, %i0 } 4000df8c: 81 c7 e0 08 ret 4000df90: 81 e8 00 00 restore 400063d8 : rtems_status_code rtems_rate_monotonic_create( rtems_name name, Objects_Id *id ) { 400063d8: 9d e3 bf 98 save %sp, -104, %sp Rate_monotonic_Control *the_period; if ( !rtems_is_name_valid( name ) ) 400063dc: a4 96 20 00 orcc %i0, 0, %l2 400063e0: 02 80 00 11 be 40006424 400063e4: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !id ) 400063e8: 80 a6 60 00 cmp %i1, 0 400063ec: 02 80 00 0e be 40006424 400063f0: b0 10 20 09 mov 9, %i0 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400063f4: 05 10 00 75 sethi %hi(0x4001d400), %g2 400063f8: c2 00 a1 e0 ld [ %g2 + 0x1e0 ], %g1 ! 4001d5e0 <_Thread_Dispatch_disable_level> 400063fc: 82 00 60 01 inc %g1 40006400: c2 20 a1 e0 st %g1, [ %g2 + 0x1e0 ] * the inactive chain of free period control blocks. */ RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Allocate( void ) { return (Rate_monotonic_Control *) 40006404: 23 10 00 75 sethi %hi(0x4001d400), %l1 40006408: 40 00 09 b8 call 40008ae8 <_Objects_Allocate> 4000640c: 90 14 60 48 or %l1, 0x48, %o0 ! 4001d448 <_Rate_monotonic_Information> _Thread_Disable_dispatch(); /* to prevent deletion */ the_period = _Rate_monotonic_Allocate(); if ( !the_period ) { 40006410: a0 92 20 00 orcc %o0, 0, %l0 40006414: 12 80 00 06 bne 4000642c 40006418: 03 10 00 75 sethi %hi(0x4001d400), %g1 _Thread_Enable_dispatch(); 4000641c: 7f ff ff e2 call 400063a4 <_Thread_Enable_dispatch> 40006420: b0 10 20 05 mov 5, %i0 40006424: 81 c7 e0 08 ret 40006428: 81 e8 00 00 restore return RTEMS_TOO_MANY; } the_period->owner = _Thread_Executing; 4000642c: c2 00 62 bc ld [ %g1 + 0x2bc ], %g1 the_period->state = RATE_MONOTONIC_INACTIVE; 40006430: c0 24 20 38 clr [ %l0 + 0x38 ] if ( !the_period ) { _Thread_Enable_dispatch(); return RTEMS_TOO_MANY; } the_period->owner = _Thread_Executing; 40006434: c2 24 20 50 st %g1, [ %l0 + 0x50 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40006438: c0 24 20 18 clr [ %l0 + 0x18 ] the_watchdog->routine = routine; 4000643c: c0 24 20 2c clr [ %l0 + 0x2c ] the_watchdog->id = id; 40006440: c0 24 20 30 clr [ %l0 + 0x30 ] the_watchdog->user_data = user_data; 40006444: c0 24 20 34 clr [ %l0 + 0x34 ] the_period->state = RATE_MONOTONIC_INACTIVE; _Watchdog_Initialize( &the_period->Timer, NULL, 0, NULL ); _Rate_monotonic_Reset_statistics( the_period ); 40006448: 90 04 20 54 add %l0, 0x54, %o0 4000644c: 92 10 20 00 clr %o1 40006450: 40 00 25 52 call 4000f998 40006454: 94 10 20 38 mov 0x38, %o2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40006458: 90 14 60 48 or %l1, 0x48, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000645c: c4 04 20 08 ld [ %l0 + 8 ], %g2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40006460: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 40006464: 03 1f ff ff sethi %hi(0x7ffffc00), %g1 40006468: 82 10 63 ff or %g1, 0x3ff, %g1 ! 7fffffff 4000646c: c2 24 20 78 st %g1, [ %l0 + 0x78 ] 40006470: c2 24 20 5c st %g1, [ %l0 + 0x5c ] 40006474: c2 24 20 60 st %g1, [ %l0 + 0x60 ] 40006478: c2 24 20 74 st %g1, [ %l0 + 0x74 ] 4000647c: 03 00 00 3f sethi %hi(0xfc00), %g1 40006480: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40006484: 82 08 80 01 and %g2, %g1, %g1 40006488: 80 a0 40 03 cmp %g1, %g3 4000648c: 38 80 00 06 bgu,a 400064a4 40006490: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED information->local_table[ index ] = the_object; 40006494: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 40006498: 83 28 60 02 sll %g1, 2, %g1 4000649c: e0 20 80 01 st %l0, [ %g2 + %g1 ] &_Rate_monotonic_Information, &the_period->Object, (Objects_Name) name ); *id = the_period->Object.id; 400064a0: c2 04 20 08 ld [ %l0 + 8 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 400064a4: e4 24 20 0c st %l2, [ %l0 + 0xc ] 400064a8: c2 26 40 00 st %g1, [ %i1 ] _Thread_Enable_dispatch(); 400064ac: 7f ff ff be call 400063a4 <_Thread_Enable_dispatch> 400064b0: b0 10 20 00 clr %i0 return RTEMS_SUCCESSFUL; } 400064b4: 81 c7 e0 08 ret 400064b8: 81 e8 00 00 restore 4000f2a4 : */ rtems_status_code rtems_rate_monotonic_delete( Objects_Id id ) { 4000f2a4: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Get ( Objects_Id id, Objects_Locations *location ) { return (Rate_monotonic_Control *) 4000f2a8: 21 10 00 c8 sethi %hi(0x40032000), %l0 4000f2ac: 92 10 00 18 mov %i0, %o1 4000f2b0: 94 07 bf f4 add %fp, -12, %o2 4000f2b4: 40 00 15 be call 400149ac <_Objects_Get> 4000f2b8: 90 14 20 ac or %l0, 0xac, %o0 Rate_monotonic_Control *the_period; Objects_Locations location; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { 4000f2bc: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000f2c0: 80 a0 60 00 cmp %g1, 0 4000f2c4: 02 80 00 08 be 4000f2e4 4000f2c8: b0 10 00 08 mov %o0, %i0 4000f2cc: 82 18 60 02 xor %g1, 2, %g1 4000f2d0: 80 a0 00 01 cmp %g0, %g1 4000f2d4: 82 60 20 00 subx %g0, 0, %g1 4000f2d8: b0 08 60 15 and %g1, 0x15, %i0 4000f2dc: 81 c7 e0 08 ret 4000f2e0: 91 ee 20 04 restore %i0, 4, %o0 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000f2e4: a0 14 20 ac or %l0, 0xac, %l0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 4000f2e8: c2 02 20 08 ld [ %o0 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000f2ec: c6 14 20 10 lduh [ %l0 + 0x10 ], %g3 4000f2f0: 05 00 00 3f sethi %hi(0xfc00), %g2 4000f2f4: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 4000f2f8: 82 08 40 02 and %g1, %g2, %g1 4000f2fc: 80 a0 40 03 cmp %g1, %g3 4000f300: 38 80 00 06 bgu,a 4000f318 4000f304: c0 26 20 0c clr [ %i0 + 0xc ] <== NOT EXECUTED information->local_table[ index ] = the_object; 4000f308: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 4000f30c: 83 28 60 02 sll %g1, 2, %g1 4000f310: c0 20 80 01 clr [ %g2 + %g1 ] uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 4000f314: c0 26 20 0c clr [ %i0 + 0xc ] case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: _Objects_Close( &_Rate_monotonic_Information, &the_period->Object ); (void) _Watchdog_Remove( &the_period->Timer ); 4000f318: 40 00 20 eb call 400176c4 <_Watchdog_Remove> 4000f31c: 90 06 20 10 add %i0, 0x10, %o0 RTEMS_INLINE_ROUTINE void _Rate_monotonic_Free ( Rate_monotonic_Control *the_period ) { _Objects_Free( &_Rate_monotonic_Information, &the_period->Object ); 4000f320: 90 10 00 10 mov %l0, %o0 the_period->state = RATE_MONOTONIC_INACTIVE; 4000f324: c0 26 20 38 clr [ %i0 + 0x38 ] 4000f328: 40 00 15 4b call 40014854 <_Objects_Free> 4000f32c: 92 10 00 18 mov %i0, %o1 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000f330: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000f334: c4 00 62 e0 ld [ %g1 + 0x2e0 ], %g2 ! 400322e0 <_Thread_Dispatch_disable_level> 4000f338: b0 10 20 00 clr %i0 4000f33c: 84 00 bf ff add %g2, -1, %g2 4000f340: c4 20 62 e0 st %g2, [ %g1 + 0x2e0 ] 4000f344: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 4000f348: 80 a0 60 00 cmp %g1, 0 4000f34c: 12 80 00 04 bne 4000f35c 4000f350: 01 00 00 00 nop _Thread_Dispatch(); 4000f354: 40 00 1a 8a call 40015d7c <_Thread_Dispatch> 4000f358: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000f35c: 81 c7 e0 08 ret 4000f360: 81 e8 00 00 restore 4000dab0 : rtems_status_code rtems_rate_monotonic_get_status( Objects_Id id, rtems_rate_monotonic_period_status *status ) { 4000dab0: 9d e3 bf 88 save %sp, -120, %sp 4000dab4: 92 10 00 18 mov %i0, %o1 Objects_Locations location; Rate_monotonic_Control *the_period; if ( !status ) 4000dab8: 80 a6 60 00 cmp %i1, 0 4000dabc: 02 80 00 36 be 4000db94 4000dac0: b0 10 20 09 mov 9, %i0 4000dac4: 11 10 00 75 sethi %hi(0x4001d400), %o0 4000dac8: 94 07 bf f4 add %fp, -12, %o2 4000dacc: 7f ff ed 94 call 4000911c <_Objects_Get> 4000dad0: 90 12 20 48 or %o0, 0x48, %o0 return RTEMS_INVALID_ADDRESS; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { 4000dad4: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000dad8: 80 a0 60 00 cmp %g1, 0 4000dadc: 02 80 00 08 be 4000dafc 4000dae0: b0 10 00 08 mov %o0, %i0 4000dae4: 82 18 60 02 xor %g1, 2, %g1 <== NOT EXECUTED 4000dae8: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED 4000daec: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED 4000daf0: b0 08 60 15 and %g1, 0x15, %i0 <== NOT EXECUTED 4000daf4: 81 c7 e0 08 ret <== NOT EXECUTED 4000daf8: 91 ee 20 04 restore %i0, 4, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: status->owner = ((the_period->owner) ? the_period->owner->Object.id : 0); 4000dafc: c2 02 20 50 ld [ %o0 + 0x50 ], %g1 4000db00: 80 a0 60 00 cmp %g1, 0 4000db04: 02 80 00 03 be 4000db10 4000db08: 84 10 20 00 clr %g2 4000db0c: c4 00 60 08 ld [ %g1 + 8 ], %g2 status->state = the_period->state; 4000db10: c2 06 20 38 ld [ %i0 + 0x38 ], %g1 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: status->owner = ((the_period->owner) ? the_period->owner->Object.id : 0); 4000db14: c4 26 40 00 st %g2, [ %i1 ] status->state = the_period->state; if ( status->state == RATE_MONOTONIC_INACTIVE ) { 4000db18: 80 a0 60 00 cmp %g1, 0 4000db1c: 12 80 00 07 bne 4000db38 4000db20: c2 26 60 04 st %g1, [ %i1 + 4 ] #else status->ticks_since_last_period = 0; #endif #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS status->executed_since_last_period.tv_sec = 0; status->executed_since_last_period.tv_nsec = 0; 4000db24: c0 26 60 14 clr [ %i1 + 0x14 ] <== NOT EXECUTED status->owner = ((the_period->owner) ? the_period->owner->Object.id : 0); status->state = the_period->state; if ( status->state == RATE_MONOTONIC_INACTIVE ) { #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS status->since_last_period.tv_sec = 0; 4000db28: c0 26 60 08 clr [ %i1 + 8 ] <== NOT EXECUTED status->since_last_period.tv_nsec = 0; 4000db2c: c0 26 60 0c clr [ %i1 + 0xc ] <== NOT EXECUTED #else status->ticks_since_last_period = 0; #endif #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS status->executed_since_last_period.tv_sec = 0; 4000db30: 10 80 00 0e b 4000db68 <== NOT EXECUTED 4000db34: c0 26 60 10 clr [ %i1 + 0x10 ] <== NOT EXECUTED * This lets them share one single invocation of _TOD_Get_uptime(). */ #if defined(RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS) || \ defined(RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS) struct timespec uptime; _TOD_Get_uptime( &uptime ); 4000db38: a0 07 bf ec add %fp, -20, %l0 4000db3c: 7f ff ea 49 call 40008460 <_TOD_Get_uptime> 4000db40: 90 10 00 10 mov %l0, %o0 #endif #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS _Timespec_Subtract( 4000db44: 90 06 20 44 add %i0, 0x44, %o0 4000db48: 92 10 00 10 mov %l0, %o1 4000db4c: 7f ff f6 ea call 4000b6f4 <_Timespec_Subtract> 4000db50: 94 06 60 08 add %i1, 8, %o2 status->ticks_since_last_period = _Watchdog_Ticks_since_boot - the_period->time_at_period; #endif #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS _Timespec_Subtract( 4000db54: 11 10 00 75 sethi %hi(0x4001d400), %o0 4000db58: 92 10 00 10 mov %l0, %o1 4000db5c: 94 06 60 10 add %i1, 0x10, %o2 4000db60: 7f ff f6 e5 call 4000b6f4 <_Timespec_Subtract> 4000db64: 90 12 22 c4 or %o0, 0x2c4, %o0 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000db68: 03 10 00 75 sethi %hi(0x4001d400), %g1 4000db6c: c4 00 61 e0 ld [ %g1 + 0x1e0 ], %g2 ! 4001d5e0 <_Thread_Dispatch_disable_level> 4000db70: b0 10 20 00 clr %i0 4000db74: 84 00 bf ff add %g2, -1, %g2 4000db78: c4 20 61 e0 st %g2, [ %g1 + 0x1e0 ] 4000db7c: c2 00 61 e0 ld [ %g1 + 0x1e0 ], %g1 4000db80: 80 a0 60 00 cmp %g1, 0 4000db84: 12 80 00 04 bne 4000db94 4000db88: 01 00 00 00 nop _Thread_Dispatch(); 4000db8c: 7f ff f2 58 call 4000a4ec <_Thread_Dispatch> 4000db90: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000db94: 81 c7 e0 08 ret 4000db98: 81 e8 00 00 restore 400066c4 : rtems_status_code rtems_rate_monotonic_period( Objects_Id id, rtems_interval length ) { 400066c4: 9d e3 bf 80 save %sp, -128, %sp RTEMS_INLINE_ROUTINE Rate_monotonic_Control *_Rate_monotonic_Get ( Objects_Id id, Objects_Locations *location ) { return (Rate_monotonic_Control *) 400066c8: 11 10 00 75 sethi %hi(0x4001d400), %o0 400066cc: 92 10 00 18 mov %i0, %o1 400066d0: 90 12 20 48 or %o0, 0x48, %o0 400066d4: 40 00 0a 92 call 4000911c <_Objects_Get> 400066d8: 94 07 bf f4 add %fp, -12, %o2 rtems_status_code return_value; rtems_rate_monotonic_period_states local_state; ISR_Level level; the_period = _Rate_monotonic_Get( id, &location ); switch ( location ) { 400066dc: c2 07 bf f4 ld [ %fp + -12 ], %g1 400066e0: 80 a0 60 00 cmp %g1, 0 400066e4: 02 80 00 07 be 40006700 400066e8: a2 10 00 08 mov %o0, %l1 400066ec: 80 a0 60 02 cmp %g1, 2 400066f0: 02 80 00 0c be 40006720 400066f4: b0 10 20 04 mov 4, %i0 the_period->state = RATE_MONOTONIC_ACTIVE; the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); _Thread_Enable_dispatch(); return RTEMS_TIMEOUT; 400066f8: 81 c7 e0 08 ret <== NOT EXECUTED 400066fc: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_Thread_Is_executing( the_period->owner ) ) { 40006700: 27 10 00 75 sethi %hi(0x4001d400), %l3 40006704: c4 02 20 50 ld [ %o0 + 0x50 ], %g2 40006708: c2 04 e2 bc ld [ %l3 + 0x2bc ], %g1 4000670c: 80 a0 80 01 cmp %g2, %g1 40006710: 02 80 00 06 be 40006728 40006714: 80 a6 60 00 cmp %i1, 0 _Thread_Enable_dispatch(); 40006718: 7f ff ff 7f call 40006514 <_Thread_Enable_dispatch> 4000671c: b0 10 20 17 mov 0x17, %i0 40006720: 81 c7 e0 08 ret 40006724: 81 e8 00 00 restore return RTEMS_NOT_OWNER_OF_RESOURCE; } if ( length == RTEMS_PERIOD_STATUS ) { 40006728: 12 80 00 11 bne 4000676c 4000672c: 01 00 00 00 nop switch ( the_period->state ) { 40006730: d0 02 20 38 ld [ %o0 + 0x38 ], %o0 40006734: 80 a2 20 02 cmp %o0, 2 40006738: 02 80 00 09 be 4000675c 4000673c: b0 10 20 00 clr %i0 40006740: 80 a2 20 04 cmp %o0, 4 40006744: 02 80 00 06 be 4000675c 40006748: b0 10 20 06 mov 6, %i0 4000674c: 80 a2 20 00 cmp %o0, 0 40006750: 02 80 00 03 be 4000675c 40006754: b0 10 20 0b mov 0xb, %i0 40006758: b0 10 20 19 mov 0x19, %i0 <== NOT EXECUTED break; default: /* unreached -- only to remove warnings */ return_value = RTEMS_INTERNAL_ERROR; break; } _Thread_Enable_dispatch(); 4000675c: 7f ff ff 6e call 40006514 <_Thread_Enable_dispatch> 40006760: 01 00 00 00 nop 40006764: 81 c7 e0 08 ret 40006768: 81 e8 00 00 restore return( return_value ); } _ISR_Disable( level ); 4000676c: 7f ff f0 56 call 400028c4 40006770: 01 00 00 00 nop 40006774: a0 10 00 08 mov %o0, %l0 switch ( the_period->state ) { 40006778: e4 04 60 38 ld [ %l1 + 0x38 ], %l2 4000677c: 80 a4 a0 02 cmp %l2, 2 40006780: 02 80 00 29 be 40006824 40006784: 80 a4 a0 04 cmp %l2, 4 40006788: 02 80 00 43 be 40006894 4000678c: 80 a4 a0 00 cmp %l2, 0 40006790: 32 bf ff e4 bne,a 40006720 40006794: b0 10 20 19 mov 0x19, %i0 <== NOT EXECUTED /* * No need to update statistics -- there are not a period active */ _ISR_Enable( level ); 40006798: 7f ff f0 4f call 400028d4 4000679c: a0 07 bf ec add %fp, -20, %l0 #if defined(RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS) || \ defined(RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS) _TOD_Get_uptime( &uptime ); 400067a0: 40 00 07 30 call 40008460 <_TOD_Get_uptime> 400067a4: 90 10 00 10 mov %l0, %o0 #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS /* * Since the statistics didn't update the starting time, * we do it here. */ the_period->time_at_period = uptime; 400067a8: c2 07 bf ec ld [ %fp + -20 ], %g1 #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS { struct timespec ran; the_period->owner_executed_at_period = 400067ac: c4 04 e2 bc ld [ %l3 + 0x2bc ], %g2 #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS /* * Since the statistics didn't update the starting time, * we do it here. */ the_period->time_at_period = uptime; 400067b0: c2 24 60 44 st %g1, [ %l1 + 0x44 ] 400067b4: c2 07 bf f0 ld [ %fp + -16 ], %g1 the_period->owner_executed_at_period = _Thread_Executing->cpu_time_used; /* How much time time since last context switch */ _Timespec_Subtract( 400067b8: 92 10 00 10 mov %l0, %o1 #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS /* * Since the statistics didn't update the starting time, * we do it here. */ the_period->time_at_period = uptime; 400067bc: c2 24 60 48 st %g1, [ %l1 + 0x48 ] #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS { struct timespec ran; the_period->owner_executed_at_period = 400067c0: c2 00 a0 90 ld [ %g2 + 0x90 ], %g1 _Thread_Executing->cpu_time_used; /* How much time time since last context switch */ _Timespec_Subtract( 400067c4: a0 07 bf e4 add %fp, -28, %l0 #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS { struct timespec ran; the_period->owner_executed_at_period = 400067c8: c2 24 60 3c st %g1, [ %l1 + 0x3c ] 400067cc: c2 00 a0 94 ld [ %g2 + 0x94 ], %g1 _Thread_Executing->cpu_time_used; /* How much time time since last context switch */ _Timespec_Subtract( 400067d0: 94 10 00 10 mov %l0, %o2 #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS { struct timespec ran; the_period->owner_executed_at_period = 400067d4: c2 24 60 40 st %g1, [ %l1 + 0x40 ] _Thread_Executing->cpu_time_used; /* How much time time since last context switch */ _Timespec_Subtract( 400067d8: 11 10 00 75 sethi %hi(0x4001d400), %o0 400067dc: 40 00 13 c6 call 4000b6f4 <_Timespec_Subtract> 400067e0: 90 12 22 c4 or %o0, 0x2c4, %o0 ! 4001d6c4 <_Thread_Time_of_last_context_switch> /* The thread had executed before the last context switch also. * * the_period->owner_executed_at_period += ran */ _Timespec_Add_to( &the_period->owner_executed_at_period, &ran ); 400067e4: 92 10 00 10 mov %l0, %o1 400067e8: 40 00 13 62 call 4000b570 <_Timespec_Add_to> 400067ec: 90 04 60 3c add %l1, 0x3c, %o0 #else the_period->owner_ticks_executed_at_period = _Thread_Executing->ticks_executed; #endif the_period->state = RATE_MONOTONIC_ACTIVE; 400067f0: 82 10 20 02 mov 2, %g1 400067f4: c2 24 60 38 st %g1, [ %l1 + 0x38 ] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; 400067f8: 03 10 00 1b sethi %hi(0x40006c00), %g1 400067fc: 82 10 60 2c or %g1, 0x2c, %g1 ! 40006c2c <_Rate_monotonic_Timeout> NULL ); the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); 40006800: 90 04 60 10 add %l1, 0x10, %o0 40006804: 92 10 00 19 mov %i1, %o1 the_watchdog->id = id; 40006808: f0 24 60 30 st %i0, [ %l1 + 0x30 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 4000680c: c0 24 60 18 clr [ %l1 + 0x18 ] the_watchdog->routine = routine; the_watchdog->id = id; the_watchdog->user_data = user_data; 40006810: c0 24 60 34 clr [ %l1 + 0x34 ] _Rate_monotonic_Timeout, id, NULL ); the_period->next_length = length; 40006814: f2 24 60 4c st %i1, [ %l1 + 0x4c ] _Watchdog_Insert_ticks( &the_period->Timer, length ); 40006818: 7f ff ff 37 call 400064f4 <_Watchdog_Insert_ticks> 4000681c: c2 24 60 2c st %g1, [ %l1 + 0x2c ] 40006820: 30 80 00 19 b,a 40006884 case RATE_MONOTONIC_ACTIVE: /* * Update statistics from the concluding period */ _Rate_monotonic_Update_statistics( the_period ); 40006824: 7f ff ff 49 call 40006548 <_Rate_monotonic_Update_statistics> 40006828: 90 10 00 11 mov %l1, %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; 4000682c: 82 10 20 01 mov 1, %g1 the_period->next_length = length; 40006830: f2 24 60 4c st %i1, [ %l1 + 0x4c ] * 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; 40006834: c2 24 60 38 st %g1, [ %l1 + 0x38 ] the_period->next_length = length; _ISR_Enable( level ); 40006838: 7f ff f0 27 call 400028d4 4000683c: 90 10 00 10 mov %l0, %o0 _Thread_Executing->Wait.id = the_period->Object.id; 40006840: c2 04 e2 bc ld [ %l3 + 0x2bc ], %g1 40006844: c4 04 60 08 ld [ %l1 + 8 ], %g2 _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); 40006848: 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; 4000684c: c4 20 60 20 st %g2, [ %g1 + 0x20 ] _Thread_Set_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); 40006850: 40 00 12 23 call 4000b0dc <_Thread_Set_state> 40006854: 13 00 00 10 sethi %hi(0x4000), %o1 /* * Did the watchdog timer expire while we were actually blocking * on it? */ _ISR_Disable( level ); 40006858: 7f ff f0 1b call 400028c4 4000685c: 01 00 00 00 nop local_state = the_period->state; 40006860: e0 04 60 38 ld [ %l1 + 0x38 ], %l0 the_period->state = RATE_MONOTONIC_ACTIVE; 40006864: e4 24 60 38 st %l2, [ %l1 + 0x38 ] _ISR_Enable( level ); 40006868: 7f ff f0 1b call 400028d4 4000686c: 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 ) 40006870: 80 a4 20 03 cmp %l0, 3 40006874: 12 80 00 04 bne 40006884 40006878: d0 04 e2 bc ld [ %l3 + 0x2bc ], %o0 _Thread_Clear_state( _Thread_Executing, STATES_WAITING_FOR_PERIOD ); 4000687c: 40 00 0e 62 call 4000a204 <_Thread_Clear_state> <== NOT EXECUTED 40006880: 13 00 00 10 sethi %hi(0x4000), %o1 <== NOT EXECUTED _Thread_Enable_dispatch(); 40006884: 7f ff ff 24 call 40006514 <_Thread_Enable_dispatch> 40006888: b0 10 20 00 clr %i0 4000688c: 81 c7 e0 08 ret 40006890: 81 e8 00 00 restore case RATE_MONOTONIC_EXPIRED: /* * Update statistics from the concluding period */ _Rate_monotonic_Update_statistics( the_period ); 40006894: 7f ff ff 2d call 40006548 <_Rate_monotonic_Update_statistics> 40006898: 90 10 00 11 mov %l1, %o0 _ISR_Enable( level ); 4000689c: 7f ff f0 0e call 400028d4 400068a0: 90 10 00 10 mov %l0, %o0 the_period->state = RATE_MONOTONIC_ACTIVE; 400068a4: 82 10 20 02 mov 2, %g1 the_period->next_length = length; _Watchdog_Insert_ticks( &the_period->Timer, length ); 400068a8: 90 04 60 10 add %l1, 0x10, %o0 400068ac: 92 10 00 19 mov %i1, %o1 */ _Rate_monotonic_Update_statistics( the_period ); _ISR_Enable( level ); the_period->state = RATE_MONOTONIC_ACTIVE; 400068b0: c2 24 60 38 st %g1, [ %l1 + 0x38 ] the_period->next_length = length; 400068b4: f2 24 60 4c st %i1, [ %l1 + 0x4c ] _Watchdog_Insert_ticks( &the_period->Timer, length ); 400068b8: 7f ff ff 0f call 400064f4 <_Watchdog_Insert_ticks> 400068bc: b0 10 20 06 mov 6, %i0 _Thread_Enable_dispatch(); 400068c0: 7f ff ff 15 call 40006514 <_Thread_Enable_dispatch> 400068c4: 01 00 00 00 nop 400068c8: 81 c7 e0 08 ret 400068cc: 81 e8 00 00 restore break; } } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400068d0: 81 c7 e0 08 ret <== NOT EXECUTED 400068d4: 81 e8 00 00 restore <== NOT EXECUTED 400068d8 : */ void rtems_rate_monotonic_report_statistics_with_plugin( void *context, rtems_printk_plugin_t print ) { 400068d8: 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 ) 400068dc: 80 a6 60 00 cmp %i1, 0 400068e0: 02 80 00 7f be 40006adc 400068e4: 90 10 00 18 mov %i0, %o0 return; (*print)( context, "Period information by period\n" ); 400068e8: 13 10 00 6b sethi %hi(0x4001ac00), %o1 400068ec: 9f c6 40 00 call %i1 400068f0: 92 12 63 68 or %o1, 0x368, %o1 ! 4001af68 #if defined(RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS) (*print)( context, "--- CPU times are in seconds ---\n" ); 400068f4: 90 10 00 18 mov %i0, %o0 400068f8: 13 10 00 6b sethi %hi(0x4001ac00), %o1 400068fc: 9f c6 40 00 call %i1 40006900: 92 12 63 88 or %o1, 0x388, %o1 ! 4001af88 #endif #if defined(RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS) (*print)( context, "--- Wall times are in seconds ---\n" ); 40006904: 90 10 00 18 mov %i0, %o0 40006908: 13 10 00 6b sethi %hi(0x4001ac00), %o1 4000690c: 9f c6 40 00 call %i1 40006910: 92 12 63 b0 or %o1, 0x3b0, %o1 ! 4001afb0 Be sure to test the various cases. (*print)( context,"\ 1234567890123456789012345678901234567890123456789012345678901234567890123456789\ \n"); */ (*print)( context, " ID OWNER COUNT MISSED " 40006914: 90 10 00 18 mov %i0, %o0 40006918: 13 10 00 6b sethi %hi(0x4001ac00), %o1 4000691c: 9f c6 40 00 call %i1 40006920: 92 12 63 d8 or %o1, 0x3d8, %o1 ! 4001afd8 #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS " " #endif " WALL TIME\n" ); (*print)( context, " " 40006924: 90 10 00 18 mov %i0, %o0 40006928: 13 10 00 6c sethi %hi(0x4001b000), %o1 4000692c: 9f c6 40 00 call %i1 40006930: 92 12 60 28 or %o1, 0x28, %o1 ! 4001b028 /* * 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 ; 40006934: 03 10 00 75 sethi %hi(0x4001d400), %g1 40006938: 82 10 60 48 or %g1, 0x48, %g1 ! 4001d448 <_Rate_monotonic_Information> 4000693c: e4 00 60 08 ld [ %g1 + 8 ], %l2 _Timespec_Divide_by_integer( &the_stats.total_cpu_time, the_stats.count, &cpu_average ); (*print)( context, 40006940: 03 10 00 6c sethi %hi(0x4001b000), %g1 40006944: b4 10 60 90 or %g1, 0x90, %i2 ! 4001b090 _Timespec_Divide_by_integer( &the_stats.total_wall_time, the_stats.count, &wall_average ); (*print)( context, 40006948: 03 10 00 6c sethi %hi(0x4001b000), %g1 * 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++ ) { status = rtems_rate_monotonic_get_statistics( id, &the_stats ); 4000694c: ba 07 bf 98 add %fp, -104, %i5 _Timespec_Divide_by_integer( &the_stats.total_wall_time, the_stats.count, &wall_average ); (*print)( context, 40006950: b6 10 60 b0 or %g1, 0xb0, %i3 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 ); 40006954: ae 07 bf d0 add %fp, -48, %l7 /* * If the count is zero, don't print statistics */ if (the_stats.count == 0) { (*print)( context, "\n" ); 40006958: 03 10 00 6b sethi %hi(0x4001ac00), %g1 /* * Print part of report line that is not dependent on granularity */ (*print)( context, 4000695c: a8 07 bf f3 add %fp, -13, %l4 /* * If the count is zero, don't print statistics */ if (the_stats.count == 0) { (*print)( context, "\n" ); 40006960: b8 10 63 a8 or %g1, 0x3a8, %i4 */ { #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS struct timespec cpu_average; _Timespec_Divide_by_integer( 40006964: ac 07 bf b0 add %fp, -80, %l6 40006968: a6 07 bf e8 add %fp, -24, %l3 * print Wall time part of statistics */ { #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS struct timespec wall_average; _Timespec_Divide_by_integer( 4000696c: 10 80 00 56 b 40006ac4 40006970: aa 07 bf c8 add %fp, -56, %l5 * 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++ ) { status = rtems_rate_monotonic_get_statistics( id, &the_stats ); 40006974: 40 00 1c 2b call 4000da20 40006978: 92 10 00 1d mov %i5, %o1 if ( status != RTEMS_SUCCESSFUL ) 4000697c: 80 a2 20 00 cmp %o0, 0 40006980: 32 80 00 51 bne,a 40006ac4 40006984: a4 04 a0 01 inc %l2 continue; /* If the above passed, so should this but check it anyway */ status = rtems_rate_monotonic_get_status( id, &the_status ); 40006988: 92 10 00 17 mov %l7, %o1 4000698c: 40 00 1c 49 call 4000dab0 40006990: 90 10 00 12 mov %l2, %o0 if ( status != RTEMS_SUCCESSFUL ) 40006994: 80 a2 20 00 cmp %o0, 0 40006998: 32 80 00 4b bne,a 40006ac4 4000699c: a4 04 a0 01 inc %l2 <== NOT EXECUTED continue; name[ 0 ] = '\0'; if ( the_status.owner ) { 400069a0: d0 07 bf d0 ld [ %fp + -48 ], %o0 400069a4: 80 a2 20 00 cmp %o0, 0 400069a8: 02 80 00 05 be 400069bc 400069ac: c0 2f bf f3 clrb [ %fp + -13 ] rtems_object_get_name( the_status.owner, sizeof(name), name ); 400069b0: 94 10 00 14 mov %l4, %o2 400069b4: 40 00 00 c8 call 40006cd4 400069b8: 92 10 20 05 mov 5, %o1 /* * Print part of report line that is not dependent on granularity */ (*print)( context, 400069bc: d8 1f bf 98 ldd [ %fp + -104 ], %o4 400069c0: 94 10 00 12 mov %l2, %o2 400069c4: 96 10 00 14 mov %l4, %o3 400069c8: 13 10 00 6c sethi %hi(0x4001b000), %o1 400069cc: 90 10 00 18 mov %i0, %o0 400069d0: 9f c6 40 00 call %i1 400069d4: 92 12 60 78 or %o1, 0x78, %o1 /* * If the count is zero, don't print statistics */ if (the_stats.count == 0) { 400069d8: c2 07 bf 98 ld [ %fp + -104 ], %g1 */ { #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS struct timespec cpu_average; _Timespec_Divide_by_integer( 400069dc: 94 10 00 13 mov %l3, %o2 400069e0: 90 10 00 16 mov %l6, %o0 /* * If the count is zero, don't print statistics */ if (the_stats.count == 0) { 400069e4: 80 a0 60 00 cmp %g1, 0 400069e8: 12 80 00 06 bne 40006a00 400069ec: 92 10 00 1c mov %i4, %o1 (*print)( context, "\n" ); 400069f0: 9f c6 40 00 call %i1 400069f4: 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 ; id <= _Rate_monotonic_Information.maximum_id ; id++ ) { 400069f8: 10 80 00 33 b 40006ac4 400069fc: a4 04 a0 01 inc %l2 */ { #ifdef RTEMS_ENABLE_NANOSECOND_CPU_USAGE_STATISTICS struct timespec cpu_average; _Timespec_Divide_by_integer( 40006a00: 40 00 12 f4 call 4000b5d0 <_Timespec_Divide_by_integer> 40006a04: 92 10 00 01 mov %g1, %o1 &the_stats.total_cpu_time, the_stats.count, &cpu_average ); (*print)( context, 40006a08: d0 07 bf a4 ld [ %fp + -92 ], %o0 40006a0c: 40 00 44 c7 call 40017d28 <.div> 40006a10: 92 10 23 e8 mov 0x3e8, %o1 40006a14: a2 10 00 08 mov %o0, %l1 40006a18: d0 07 bf ac ld [ %fp + -84 ], %o0 40006a1c: 40 00 44 c3 call 40017d28 <.div> 40006a20: 92 10 23 e8 mov 0x3e8, %o1 40006a24: c2 07 bf e8 ld [ %fp + -24 ], %g1 40006a28: a0 10 00 08 mov %o0, %l0 40006a2c: d0 07 bf ec ld [ %fp + -20 ], %o0 40006a30: c2 23 a0 5c st %g1, [ %sp + 0x5c ] 40006a34: 40 00 44 bd call 40017d28 <.div> 40006a38: 92 10 23 e8 mov 0x3e8, %o1 40006a3c: d8 07 bf a8 ld [ %fp + -88 ], %o4 40006a40: d4 07 bf a0 ld [ %fp + -96 ], %o2 40006a44: 96 10 00 11 mov %l1, %o3 40006a48: 9a 10 00 10 mov %l0, %o5 40006a4c: d0 23 a0 60 st %o0, [ %sp + 0x60 ] 40006a50: 92 10 00 1a mov %i2, %o1 40006a54: 9f c6 40 00 call %i1 40006a58: 90 10 00 18 mov %i0, %o0 * print Wall time part of statistics */ { #ifdef RTEMS_ENABLE_NANOSECOND_RATE_MONOTONIC_STATISTICS struct timespec wall_average; _Timespec_Divide_by_integer( 40006a5c: d2 07 bf 98 ld [ %fp + -104 ], %o1 40006a60: 94 10 00 13 mov %l3, %o2 40006a64: 40 00 12 db call 4000b5d0 <_Timespec_Divide_by_integer> 40006a68: 90 10 00 15 mov %l5, %o0 &the_stats.total_wall_time, the_stats.count, &wall_average ); (*print)( context, 40006a6c: d0 07 bf bc ld [ %fp + -68 ], %o0 40006a70: 40 00 44 ae call 40017d28 <.div> 40006a74: 92 10 23 e8 mov 0x3e8, %o1 40006a78: a2 10 00 08 mov %o0, %l1 40006a7c: d0 07 bf c4 ld [ %fp + -60 ], %o0 40006a80: 40 00 44 aa call 40017d28 <.div> 40006a84: 92 10 23 e8 mov 0x3e8, %o1 40006a88: c2 07 bf e8 ld [ %fp + -24 ], %g1 40006a8c: a0 10 00 08 mov %o0, %l0 40006a90: d0 07 bf ec ld [ %fp + -20 ], %o0 40006a94: 92 10 23 e8 mov 0x3e8, %o1 40006a98: 40 00 44 a4 call 40017d28 <.div> 40006a9c: c2 23 a0 5c st %g1, [ %sp + 0x5c ] 40006aa0: d4 07 bf b8 ld [ %fp + -72 ], %o2 40006aa4: d8 07 bf c0 ld [ %fp + -64 ], %o4 40006aa8: d0 23 a0 60 st %o0, [ %sp + 0x60 ] 40006aac: 96 10 00 11 mov %l1, %o3 40006ab0: 9a 10 00 10 mov %l0, %o5 40006ab4: 90 10 00 18 mov %i0, %o0 40006ab8: 9f c6 40 00 call %i1 40006abc: 92 10 00 1b mov %i3, %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 ; id <= _Rate_monotonic_Information.maximum_id ; id++ ) { 40006ac0: a4 04 a0 01 inc %l2 /* * 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 ; 40006ac4: 05 10 00 75 sethi %hi(0x4001d400), %g2 40006ac8: 84 10 a0 48 or %g2, 0x48, %g2 ! 4001d448 <_Rate_monotonic_Information> 40006acc: c2 00 a0 0c ld [ %g2 + 0xc ], %g1 40006ad0: 80 a4 80 01 cmp %l2, %g1 40006ad4: 08 bf ff a8 bleu 40006974 40006ad8: 90 10 00 12 mov %l2, %o0 40006adc: 81 c7 e0 08 ret 40006ae0: 81 e8 00 00 restore 40006b00 : /* * rtems_rate_monotonic_reset_all_statistics */ void rtems_rate_monotonic_reset_all_statistics( void ) { 40006b00: 9d e3 bf 98 save %sp, -104, %sp rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40006b04: 03 10 00 75 sethi %hi(0x4001d400), %g1 40006b08: c4 00 61 e0 ld [ %g1 + 0x1e0 ], %g2 ! 4001d5e0 <_Thread_Dispatch_disable_level> 40006b0c: 84 00 a0 01 inc %g2 40006b10: c4 20 61 e0 st %g2, [ %g1 + 0x1e0 ] /* * 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 ; 40006b14: 03 10 00 75 sethi %hi(0x4001d400), %g1 40006b18: 82 10 60 48 or %g1, 0x48, %g1 ! 4001d448 <_Rate_monotonic_Information> 40006b1c: e0 00 60 08 ld [ %g1 + 8 ], %l0 id <= _Rate_monotonic_Information.maximum_id ; 40006b20: 10 80 00 04 b 40006b30 40006b24: a2 10 00 01 mov %g1, %l1 id++ ) { status = rtems_rate_monotonic_reset_statistics( id ); 40006b28: 40 00 00 12 call 40006b70 40006b2c: 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 ; id <= _Rate_monotonic_Information.maximum_id ; 40006b30: c2 04 60 0c ld [ %l1 + 0xc ], %g1 40006b34: 80 a4 00 01 cmp %l0, %g1 40006b38: 08 bf ff fc bleu 40006b28 40006b3c: 90 10 00 10 mov %l0, %o0 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40006b40: 03 10 00 75 sethi %hi(0x4001d400), %g1 40006b44: c4 00 61 e0 ld [ %g1 + 0x1e0 ], %g2 ! 4001d5e0 <_Thread_Dispatch_disable_level> 40006b48: 84 00 bf ff add %g2, -1, %g2 40006b4c: c4 20 61 e0 st %g2, [ %g1 + 0x1e0 ] 40006b50: c2 00 61 e0 ld [ %g1 + 0x1e0 ], %g1 40006b54: 80 a0 60 00 cmp %g1, 0 40006b58: 12 80 00 04 bne 40006b68 40006b5c: 01 00 00 00 nop _Thread_Dispatch(); 40006b60: 40 00 0e 63 call 4000a4ec <_Thread_Dispatch> 40006b64: 81 e8 00 00 restore 40006b68: 81 c7 e0 08 ret <== NOT EXECUTED 40006b6c: 81 e8 00 00 restore <== NOT EXECUTED 4000f87c : uint32_t length, uint32_t page_size, rtems_attribute attribute_set, Objects_Id *id ) { 4000f87c: 9d e3 bf 98 save %sp, -104, %sp Region_Control *the_region; if ( !rtems_is_name_valid( name ) ) 4000f880: a4 96 20 00 orcc %i0, 0, %l2 4000f884: 02 80 00 87 be 4000faa0 4000f888: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !starting_address ) 4000f88c: 80 a6 60 00 cmp %i1, 0 4000f890: 02 80 00 c7 be 4000fbac 4000f894: 80 a7 60 00 cmp %i5, 0 return RTEMS_INVALID_ADDRESS; if ( !id ) 4000f898: 02 80 00 c5 be 4000fbac 4000f89c: 80 8e 60 07 btst 7, %i1 return RTEMS_INVALID_ADDRESS; if ( !_Addresses_Is_aligned( starting_address ) ) 4000f8a0: 32 80 00 80 bne,a 4000faa0 4000f8a4: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; _RTEMS_Lock_allocator(); /* to prevent deletion */ 4000f8a8: 7f ff eb 9e call 4000a720 4000f8ac: 01 00 00 00 nop 4000f8b0: a2 10 00 08 mov %o0, %l1 4000f8b4: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000f8b8: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000f8bc: 80 a0 60 00 cmp %g1, 0 4000f8c0: 02 80 00 0b be 4000f8ec 4000f8c4: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000f8c8: 03 10 00 c9 sethi %hi(0x40032400), %g1 <== NOT EXECUTED 4000f8cc: c2 00 60 c0 ld [ %g1 + 0xc0 ], %g1 ! 400324c0 <_System_state_Current> <== NOT EXECUTED 4000f8d0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000f8d4: 08 80 00 05 bleu 4000f8e8 <== NOT EXECUTED 4000f8d8: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000f8dc: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000f8e0: 40 00 12 ae call 40014398 <_Internal_error_Occurred> <== NOT EXECUTED 4000f8e4: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 4000f8e8: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4000f8ec: e0 00 63 b4 ld [ %g1 + 0x3b4 ], %l0 ! 400323b4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 4000f8f0: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000f8f4: c4 00 63 bc ld [ %g1 + 0x3bc ], %g2 ! 400323bc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 4000f8f8: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 4000f8fc: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 4000f900: 80 a0 60 00 cmp %g1, 0 4000f904: 22 80 00 30 be,a 4000f9c4 4000f908: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 4000f90c: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 4000f910: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 4000f914: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; the_mutex->nest_count = 1; 4000f918: 88 10 20 01 mov 1, %g4 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; 4000f91c: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 4000f920: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 4000f924: 80 a0 e0 02 cmp %g3, 2 4000f928: 02 80 00 05 be 4000f93c 4000f92c: c8 24 20 64 st %g4, [ %l0 + 0x64 ] 4000f930: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 4000f934: 12 80 00 07 bne 4000f950 <== NOT EXECUTED 4000f938: 01 00 00 00 nop <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4000f93c: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 4000f940: 80 a0 e0 03 cmp %g3, 3 the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4000f944: 82 00 60 01 inc %g1 if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 4000f948: 02 80 00 03 be 4000f954 4000f94c: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] _ISR_Enable( level ); 4000f950: 30 80 00 2b b,a 4000f9fc */ { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; 4000f954: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED current = executing->current_priority; 4000f958: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 4000f95c: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 4000f960: 12 80 00 03 bne 4000f96c <== NOT EXECUTED 4000f964: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 4000f968: 30 80 00 25 b,a 4000f9fc <== NOT EXECUTED return 0; } if ( current > ceiling ) { 4000f96c: 08 80 00 0f bleu 4000f9a8 <== NOT EXECUTED 4000f970: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000f974: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4000f978: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000f97c: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000f980: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 4000f984: 7f ff eb 6b call 4000a730 <== NOT EXECUTED 4000f988: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 4000f98c: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 4000f990: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 4000f994: 40 00 17 ce call 400158cc <_Thread_Change_priority> <== NOT EXECUTED 4000f998: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 4000f99c: 7f ff ff ab call 4000f848 <_Thread_Enable_dispatch> <== NOT EXECUTED 4000f9a0: 23 10 00 c8 sethi %hi(0x40032000), %l1 <== NOT EXECUTED 4000f9a4: 30 80 00 2f b,a 4000fa60 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 4000f9a8: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 4000f9ac: c8 24 20 60 st %g4, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 4000f9b0: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED executing->resource_count--; /* undo locking above */ 4000f9b4: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 4000f9b8: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 4000f9bc: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 4000f9c0: 30 80 00 0f b,a 4000f9fc <== NOT EXECUTED /* * 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 ) ) { 4000f9c4: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 4000f9c8: 12 80 00 13 bne 4000fa14 <== NOT EXECUTED 4000f9cc: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 4000f9d0: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 <== NOT EXECUTED 4000f9d4: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000f9d8: 22 80 00 07 be,a 4000f9f4 <== NOT EXECUTED 4000f9dc: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 4000f9e0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000f9e4: 32 80 00 0c bne,a 4000fa14 <== NOT EXECUTED 4000f9e8: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 4000f9ec: 10 80 00 08 b 4000fa0c <== NOT EXECUTED 4000f9f0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 4000f9f4: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000f9f8: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 4000f9fc: 7f ff eb 4d call 4000a730 4000fa00: 90 10 00 11 mov %l1, %o0 * the inactive chain of free region control blocks. */ RTEMS_INLINE_ROUTINE Region_Control *_Region_Allocate( void ) { return (Region_Control *) _Objects_Allocate( &_Region_Information ); 4000fa04: 10 80 00 17 b 4000fa60 4000fa08: 23 10 00 c8 sethi %hi(0x40032000), %l1 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 4000fa0c: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 4000fa10: 30 bf ff fb b,a 4000f9fc <== NOT EXECUTED 4000fa14: c6 04 20 08 ld [ %l0 + 8 ], %g3 <== NOT EXECUTED 4000fa18: c8 00 63 bc ld [ %g1 + 0x3bc ], %g4 <== NOT EXECUTED 4000fa1c: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4000fa20: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000fa24: c6 21 20 20 st %g3, [ %g4 + 0x20 ] <== NOT EXECUTED 4000fa28: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000fa2c: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section ( Thread_queue_Control *the_thread_queue ) { the_thread_queue->sync_state = THREAD_QUEUE_NOTHING_HAPPENED; 4000fa30: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 4000fa34: c2 24 20 40 st %g1, [ %l0 + 0x40 ] <== NOT EXECUTED 4000fa38: 82 04 20 10 add %l0, 0x10, %g1 <== NOT EXECUTED 4000fa3c: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 4000fa40: 7f ff eb 3c call 4000a730 <== NOT EXECUTED 4000fa44: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4000fa48: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4000fa4c: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 4000fa50: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000fa54: 40 00 0f bf call 40013950 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 4000fa58: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 4000fa5c: 23 10 00 c8 sethi %hi(0x40032000), %l1 <== NOT EXECUTED 4000fa60: 40 00 12 7b call 4001444c <_Objects_Allocate> 4000fa64: 90 14 60 f8 or %l1, 0xf8, %o0 ! 400320f8 <_Region_Information> the_region = _Region_Allocate(); if ( !the_region ) { 4000fa68: a0 92 20 00 orcc %o0, 0, %l0 4000fa6c: 12 80 00 0f bne 4000faa8 4000fa70: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000fa74: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000fa78: 82 00 60 01 inc %g1 4000fa7c: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _RTEMS_Unlock_allocator(); 4000fa80: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fa84: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4000fa88: 94 10 20 00 clr %o2 4000fa8c: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000fa90: 40 00 0f d2 call 400139d8 <_CORE_mutex_Surrender> 4000fa94: 90 02 20 10 add %o0, 0x10, %o0 4000fa98: 7f ff ff 6c call 4000f848 <_Thread_Enable_dispatch> 4000fa9c: b0 10 20 05 mov 5, %i0 4000faa0: 81 c7 e0 08 ret 4000faa4: 81 e8 00 00 restore return RTEMS_TOO_MANY; } the_region->maximum_segment_size = 4000faa8: 90 04 20 68 add %l0, 0x68, %o0 4000faac: 92 10 00 19 mov %i1, %o1 4000fab0: 94 10 00 1a mov %i2, %o2 4000fab4: 40 00 11 ef call 40014270 <_Heap_Initialize> 4000fab8: 96 10 00 1b mov %i3, %o3 _Heap_Initialize(&the_region->Memory, starting_address, length, page_size); if ( !the_region->maximum_segment_size ) { 4000fabc: 80 a2 20 00 cmp %o0, 0 4000fac0: 12 80 00 13 bne 4000fb0c 4000fac4: d0 24 20 5c st %o0, [ %l0 + 0x5c ] RTEMS_INLINE_ROUTINE void _Region_Free ( Region_Control *the_region ) { _Objects_Free( &_Region_Information, &the_region->Object ); 4000fac8: 90 14 60 f8 or %l1, 0xf8, %o0 4000facc: 40 00 13 62 call 40014854 <_Objects_Free> 4000fad0: 92 10 00 10 mov %l0, %o1 4000fad4: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000fad8: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000fadc: 82 00 60 01 inc %g1 4000fae0: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _Region_Free( the_region ); _RTEMS_Unlock_allocator(); 4000fae4: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fae8: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4000faec: 94 10 20 00 clr %o2 4000faf0: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000faf4: 40 00 0f b9 call 400139d8 <_CORE_mutex_Surrender> 4000faf8: 90 02 20 10 add %o0, 0x10, %o0 4000fafc: 7f ff ff 53 call 4000f848 <_Thread_Enable_dispatch> 4000fb00: b0 10 20 08 mov 8, %i0 4000fb04: 81 c7 e0 08 ret 4000fb08: 81 e8 00 00 restore the_region->length = length; the_region->page_size = page_size; the_region->attribute_set = attribute_set; the_region->number_of_used_blocks = 0; _Thread_queue_Initialize( 4000fb0c: 90 04 20 10 add %l0, 0x10, %o0 _Region_Free( the_region ); _RTEMS_Unlock_allocator(); return RTEMS_INVALID_SIZE; } the_region->starting_address = starting_address; 4000fb10: f2 24 20 50 st %i1, [ %l0 + 0x50 ] the_region->length = length; 4000fb14: f4 24 20 54 st %i2, [ %l0 + 0x54 ] the_region->page_size = page_size; 4000fb18: f6 24 20 58 st %i3, [ %l0 + 0x58 ] the_region->attribute_set = attribute_set; 4000fb1c: f8 24 20 60 st %i4, [ %l0 + 0x60 ] the_region->number_of_used_blocks = 0; 4000fb20: c0 24 20 64 clr [ %l0 + 0x64 ] _Thread_queue_Initialize( 4000fb24: 93 37 20 02 srl %i4, 2, %o1 4000fb28: 94 10 20 40 mov 0x40, %o2 4000fb2c: 92 0a 60 01 and %o1, 1, %o1 4000fb30: 40 00 1a e2 call 400166b8 <_Thread_queue_Initialize> 4000fb34: 96 10 20 06 mov 6, %o3 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000fb38: 90 14 60 f8 or %l1, 0xf8, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000fb3c: c4 04 20 08 ld [ %l0 + 8 ], %g2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000fb40: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 4000fb44: 03 00 00 3f sethi %hi(0xfc00), %g1 4000fb48: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 4000fb4c: 82 08 80 01 and %g2, %g1, %g1 4000fb50: 80 a0 40 03 cmp %g1, %g3 4000fb54: 38 80 00 06 bgu,a 4000fb6c 4000fb58: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED information->local_table[ index ] = the_object; 4000fb5c: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4000fb60: 83 28 60 02 sll %g1, 2, %g1 4000fb64: e0 20 80 01 st %l0, [ %g2 + %g1 ] &_Region_Information, &the_region->Object, (Objects_Name) name ); *id = the_region->Object.id; 4000fb68: c2 04 20 08 ld [ %l0 + 8 ], %g1 4000fb6c: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000fb70: c2 27 40 00 st %g1, [ %i5 ] 4000fb74: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 4000fb78: e4 24 20 0c st %l2, [ %l0 + 0xc ] 4000fb7c: 82 00 60 01 inc %g1 4000fb80: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _RTEMS_Unlock_allocator(); 4000fb84: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fb88: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4000fb8c: 94 10 20 00 clr %o2 4000fb90: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000fb94: 40 00 0f 91 call 400139d8 <_CORE_mutex_Surrender> 4000fb98: 90 02 20 10 add %o0, 0x10, %o0 4000fb9c: 7f ff ff 2b call 4000f848 <_Thread_Enable_dispatch> 4000fba0: b0 10 20 00 clr %i0 4000fba4: 81 c7 e0 08 ret 4000fba8: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; 4000fbac: b0 10 20 09 mov 9, %i0 <== NOT EXECUTED } 4000fbb0: 81 c7 e0 08 ret <== NOT EXECUTED 4000fbb4: 81 e8 00 00 restore <== NOT EXECUTED 4000fbec : */ rtems_status_code rtems_region_delete( Objects_Id id ) { 4000fbec: 9d e3 bf 90 save %sp, -112, %sp register Region_Control *the_region; Objects_Locations location; _RTEMS_Lock_allocator(); 4000fbf0: 7f ff ea cc call 4000a720 4000fbf4: 01 00 00 00 nop 4000fbf8: a2 10 00 08 mov %o0, %l1 4000fbfc: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fc00: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000fc04: 80 a0 60 00 cmp %g1, 0 4000fc08: 02 80 00 0b be 4000fc34 4000fc0c: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fc10: 03 10 00 c9 sethi %hi(0x40032400), %g1 <== NOT EXECUTED 4000fc14: c2 00 60 c0 ld [ %g1 + 0xc0 ], %g1 ! 400324c0 <_System_state_Current> <== NOT EXECUTED 4000fc18: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000fc1c: 08 80 00 05 bleu 4000fc30 <== NOT EXECUTED 4000fc20: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000fc24: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000fc28: 40 00 11 dc call 40014398 <_Internal_error_Occurred> <== NOT EXECUTED 4000fc2c: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 4000fc30: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4000fc34: e0 00 63 b4 ld [ %g1 + 0x3b4 ], %l0 ! 400323b4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 4000fc38: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fc3c: c4 00 63 bc ld [ %g1 + 0x3bc ], %g2 ! 400323bc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 4000fc40: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 4000fc44: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 4000fc48: 80 a0 60 00 cmp %g1, 0 4000fc4c: 22 80 00 33 be,a 4000fd18 4000fc50: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 4000fc54: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 4000fc58: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 4000fc5c: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; 4000fc60: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 4000fc64: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 4000fc68: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 4000fc6c: 80 a0 e0 02 cmp %g3, 2 4000fc70: 02 80 00 05 be 4000fc84 4000fc74: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 4000fc78: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 4000fc7c: 32 80 00 06 bne,a 4000fc94 <== NOT EXECUTED 4000fc80: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4000fc84: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 4000fc88: 82 00 60 01 inc %g1 4000fc8c: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 4000fc90: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 4000fc94: 80 a0 60 03 cmp %g1, 3 4000fc98: 22 80 00 03 be,a 4000fca4 4000fc9c: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 4000fca0: 30 80 00 2c b,a 4000fd50 { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 4000fca4: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 4000fca8: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 4000fcac: 12 80 00 03 bne 4000fcb8 <== NOT EXECUTED 4000fcb0: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 4000fcb4: 30 80 00 27 b,a 4000fd50 <== NOT EXECUTED return 0; } if ( current > ceiling ) { 4000fcb8: 08 80 00 10 bleu 4000fcf8 <== NOT EXECUTED 4000fcbc: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000fcc0: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4000fcc4: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000fcc8: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000fccc: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 4000fcd0: 7f ff ea 98 call 4000a730 <== NOT EXECUTED 4000fcd4: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 4000fcd8: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 4000fcdc: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 4000fce0: 40 00 16 fb call 400158cc <_Thread_Change_priority> <== NOT EXECUTED 4000fce4: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 4000fce8: 7f ff ff b4 call 4000fbb8 <_Thread_Enable_dispatch> <== NOT EXECUTED 4000fcec: 01 00 00 00 nop <== NOT EXECUTED RTEMS_INLINE_ROUTINE Region_Control *_Region_Get ( Objects_Id id, Objects_Locations *location ) { return (Region_Control *) 4000fcf0: 10 80 00 32 b 4000fdb8 <== NOT EXECUTED 4000fcf4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 4000fcf8: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 4000fcfc: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 4000fd00: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 4000fd04: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 4000fd08: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 4000fd0c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 4000fd10: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 4000fd14: 30 80 00 0f b,a 4000fd50 <== NOT EXECUTED /* * 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 ) ) { 4000fd18: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 4000fd1c: 32 80 00 13 bne,a 4000fd68 <== NOT EXECUTED 4000fd20: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 4000fd24: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40032050 <_Dual_ported_memory_Information+0x3c> <== NOT EXECUTED 4000fd28: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 4000fd2c: 22 80 00 07 be,a 4000fd48 <== NOT EXECUTED 4000fd30: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 4000fd34: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000fd38: 12 80 00 0c bne 4000fd68 <== NOT EXECUTED 4000fd3c: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 4000fd40: 10 80 00 08 b 4000fd60 <== NOT EXECUTED 4000fd44: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 4000fd48: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000fd4c: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 4000fd50: 7f ff ea 78 call 4000a730 4000fd54: 90 10 00 11 mov %l1, %o0 4000fd58: 10 80 00 18 b 4000fdb8 4000fd5c: 92 10 00 18 mov %i0, %o1 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 4000fd60: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 4000fd64: 30 bf ff fb b,a 4000fd50 <== NOT EXECUTED 4000fd68: c6 04 23 b4 ld [ %l0 + 0x3b4 ], %g3 <== NOT EXECUTED 4000fd6c: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4000fd70: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 4000fd74: c8 00 63 bc ld [ %g1 + 0x3bc ], %g4 <== NOT EXECUTED 4000fd78: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4000fd7c: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000fd80: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 4000fd84: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000fd88: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 4000fd8c: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 4000fd90: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 4000fd94: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 4000fd98: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 4000fd9c: 7f ff ea 65 call 4000a730 <== NOT EXECUTED 4000fda0: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4000fda4: d0 04 23 b4 ld [ %l0 + 0x3b4 ], %o0 <== NOT EXECUTED 4000fda8: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000fdac: 40 00 0e e9 call 40013950 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 4000fdb0: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 4000fdb4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 4000fdb8: 21 10 00 c8 sethi %hi(0x40032000), %l0 4000fdbc: 94 07 bf f4 add %fp, -12, %o2 4000fdc0: 40 00 12 e7 call 4001495c <_Objects_Get_no_protection> 4000fdc4: 90 14 20 f8 or %l0, 0xf8, %o0 the_region = _Region_Get( id, &location ); switch ( location ) { 4000fdc8: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000fdcc: 80 a0 60 01 cmp %g1, 1 4000fdd0: 02 80 00 0a be 4000fdf8 4000fdd4: 92 10 00 08 mov %o0, %o1 4000fdd8: 80 a0 60 01 cmp %g1, 1 4000fddc: 2a 80 00 22 bcs,a 4000fe64 4000fde0: c2 02 20 64 ld [ %o0 + 0x64 ], %g1 4000fde4: 80 a0 60 02 cmp %g1, 2 4000fde8: 12 80 00 10 bne 4000fe28 4000fdec: b0 10 20 19 mov 0x19, %i0 4000fdf0: 10 80 00 10 b 4000fe30 4000fdf4: 05 10 00 c8 sethi %hi(0x40032000), %g2 case OBJECTS_REMOTE: /* this error cannot be returned */ _RTEMS_Unlock_allocator(); 4000fdf8: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4000fdfc: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 4000fe00: 82 00 60 01 inc %g1 <== NOT EXECUTED 4000fe04: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 4000fe08: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4000fe0c: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 4000fe10: 94 10 20 00 clr %o2 <== NOT EXECUTED 4000fe14: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 4000fe18: 40 00 0e f0 call 400139d8 <_CORE_mutex_Surrender> <== NOT EXECUTED 4000fe1c: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 4000fe20: 7f ff ff 66 call 4000fbb8 <_Thread_Enable_dispatch> <== NOT EXECUTED 4000fe24: b0 10 20 19 mov 0x19, %i0 <== NOT EXECUTED 4000fe28: 81 c7 e0 08 ret <== NOT EXECUTED 4000fe2c: 81 e8 00 00 restore <== NOT EXECUTED 4000fe30: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 4000fe34: 82 00 60 01 inc %g1 4000fe38: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] return RTEMS_INTERNAL_ERROR; case OBJECTS_ERROR: _RTEMS_Unlock_allocator(); 4000fe3c: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000fe40: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4000fe44: 94 10 20 00 clr %o2 4000fe48: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000fe4c: 40 00 0e e3 call 400139d8 <_CORE_mutex_Surrender> 4000fe50: 90 02 20 10 add %o0, 0x10, %o0 4000fe54: 7f ff ff 59 call 4000fbb8 <_Thread_Enable_dispatch> 4000fe58: b0 10 20 04 mov 4, %i0 4000fe5c: 81 c7 e0 08 ret 4000fe60: 81 e8 00 00 restore return RTEMS_INVALID_ID; case OBJECTS_LOCAL: _Region_Debug_Walk( the_region, 5 ); if ( the_region->number_of_used_blocks == 0 ) { 4000fe64: 80 a0 60 00 cmp %g1, 0 4000fe68: 12 80 00 1d bne 4000fedc 4000fe6c: 05 10 00 c8 sethi %hi(0x40032000), %g2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000fe70: 90 14 20 f8 or %l0, 0xf8, %o0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 4000fe74: c2 02 60 08 ld [ %o1 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000fe78: c6 12 20 10 lduh [ %o0 + 0x10 ], %g3 4000fe7c: 05 00 00 3f sethi %hi(0xfc00), %g2 4000fe80: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 4000fe84: 82 08 40 02 and %g1, %g2, %g1 4000fe88: 80 a0 40 03 cmp %g1, %g3 4000fe8c: 18 80 00 04 bgu 4000fe9c 4000fe90: 83 28 60 02 sll %g1, 2, %g1 information->local_table[ index ] = the_object; 4000fe94: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 4000fe98: c0 20 80 01 clr [ %g2 + %g1 ] RTEMS_INLINE_ROUTINE void _Region_Free ( Region_Control *the_region ) { _Objects_Free( &_Region_Information, &the_region->Object ); 4000fe9c: 40 00 12 6e call 40014854 <_Objects_Free> 4000fea0: c0 22 60 0c clr [ %o1 + 0xc ] 4000fea4: 05 10 00 c8 sethi %hi(0x40032000), %g2 4000fea8: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000feac: 82 00 60 01 inc %g1 4000feb0: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _Objects_Close( &_Region_Information, &the_region->Object ); _Region_Free( the_region ); _RTEMS_Unlock_allocator(); 4000feb4: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000feb8: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4000febc: 94 10 20 00 clr %o2 4000fec0: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000fec4: 40 00 0e c5 call 400139d8 <_CORE_mutex_Surrender> 4000fec8: 90 02 20 10 add %o0, 0x10, %o0 4000fecc: 7f ff ff 3b call 4000fbb8 <_Thread_Enable_dispatch> 4000fed0: b0 10 20 00 clr %i0 4000fed4: 81 c7 e0 08 ret 4000fed8: 81 e8 00 00 restore 4000fedc: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 4000fee0: 82 00 60 01 inc %g1 4000fee4: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] return RTEMS_SUCCESSFUL; } _RTEMS_Unlock_allocator(); 4000fee8: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000feec: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4000fef0: 94 10 20 00 clr %o2 4000fef4: d2 02 20 08 ld [ %o0 + 8 ], %o1 4000fef8: 40 00 0e b8 call 400139d8 <_CORE_mutex_Surrender> 4000fefc: 90 02 20 10 add %o0, 0x10, %o0 4000ff00: 7f ff ff 2e call 4000fbb8 <_Thread_Enable_dispatch> 4000ff04: b0 10 20 0c mov 0xc, %i0 return RTEMS_RESOURCE_IN_USE; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000ff08: 81 c7 e0 08 ret 4000ff0c: 81 e8 00 00 restore 4000ff44 : rtems_status_code rtems_region_extend( Objects_Id id, void *starting_address, uint32_t length ) { 4000ff44: 9d e3 bf 90 save %sp, -112, %sp 4000ff48: a4 10 00 18 mov %i0, %l2 Objects_Locations location; uint32_t amount_extended; Heap_Extend_status heap_status; rtems_status_code status; if ( !starting_address ) 4000ff4c: 80 a6 60 00 cmp %i1, 0 4000ff50: 02 80 00 90 be 40010190 4000ff54: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; status = RTEMS_SUCCESSFUL; _RTEMS_Lock_allocator(); /* to prevent deletion */ 4000ff58: 7f ff e9 f2 call 4000a720 4000ff5c: 01 00 00 00 nop 4000ff60: a2 10 00 08 mov %o0, %l1 4000ff64: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000ff68: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4000ff6c: 80 a0 60 00 cmp %g1, 0 4000ff70: 02 80 00 0b be 4000ff9c 4000ff74: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000ff78: 03 10 00 c9 sethi %hi(0x40032400), %g1 <== NOT EXECUTED 4000ff7c: c2 00 60 c0 ld [ %g1 + 0xc0 ], %g1 ! 400324c0 <_System_state_Current> <== NOT EXECUTED 4000ff80: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4000ff84: 08 80 00 05 bleu 4000ff98 <== NOT EXECUTED 4000ff88: 90 10 20 00 clr %o0 <== NOT EXECUTED 4000ff8c: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000ff90: 40 00 11 02 call 40014398 <_Internal_error_Occurred> <== NOT EXECUTED 4000ff94: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 4000ff98: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4000ff9c: e0 00 63 b4 ld [ %g1 + 0x3b4 ], %l0 ! 400323b4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 4000ffa0: 03 10 00 c8 sethi %hi(0x40032000), %g1 4000ffa4: c4 00 63 bc ld [ %g1 + 0x3bc ], %g2 ! 400323bc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 4000ffa8: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 4000ffac: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 4000ffb0: 80 a0 60 00 cmp %g1, 0 4000ffb4: 22 80 00 33 be,a 40010080 4000ffb8: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 4000ffbc: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 4000ffc0: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 4000ffc4: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; 4000ffc8: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 4000ffcc: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 4000ffd0: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 4000ffd4: 80 a0 e0 02 cmp %g3, 2 4000ffd8: 02 80 00 05 be 4000ffec 4000ffdc: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 4000ffe0: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 4000ffe4: 32 80 00 06 bne,a 4000fffc <== NOT EXECUTED 4000ffe8: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4000ffec: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 4000fff0: 82 00 60 01 inc %g1 4000fff4: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 4000fff8: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 4000fffc: 80 a0 60 03 cmp %g1, 3 40010000: 22 80 00 03 be,a 4001000c 40010004: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40010008: 30 80 00 2c b,a 400100b8 { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 4001000c: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40010010: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40010014: 12 80 00 03 bne 40010020 <== NOT EXECUTED 40010018: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 4001001c: 30 80 00 27 b,a 400100b8 <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40010020: 08 80 00 10 bleu 40010060 <== NOT EXECUTED 40010024: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40010028: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4001002c: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40010030: 82 00 60 01 inc %g1 <== NOT EXECUTED 40010034: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 40010038: 7f ff e9 be call 4000a730 <== NOT EXECUTED 4001003c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 40010040: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 40010044: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 40010048: 40 00 16 21 call 400158cc <_Thread_Change_priority> <== NOT EXECUTED 4001004c: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 40010050: 7f ff ff b0 call 4000ff10 <_Thread_Enable_dispatch> <== NOT EXECUTED 40010054: 01 00 00 00 nop <== NOT EXECUTED RTEMS_INLINE_ROUTINE Region_Control *_Region_Get ( Objects_Id id, Objects_Locations *location ) { return (Region_Control *) 40010058: 10 80 00 32 b 40010120 <== NOT EXECUTED 4001005c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40010060: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40010064: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 40010068: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 4001006c: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40010070: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40010074: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40010078: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 4001007c: 30 80 00 0f b,a 400100b8 <== NOT EXECUTED /* * 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 ) ) { 40010080: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 40010084: 32 80 00 13 bne,a 400100d0 <== NOT EXECUTED 40010088: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 4001008c: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40032050 <_Dual_ported_memory_Information+0x3c> <== NOT EXECUTED 40010090: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40010094: 22 80 00 07 be,a 400100b0 <== NOT EXECUTED 40010098: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 4001009c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400100a0: 12 80 00 0c bne 400100d0 <== NOT EXECUTED 400100a4: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 400100a8: 10 80 00 08 b 400100c8 <== NOT EXECUTED 400100ac: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 400100b0: 82 00 60 01 inc %g1 <== NOT EXECUTED 400100b4: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 400100b8: 7f ff e9 9e call 4000a730 400100bc: 90 10 00 11 mov %l1, %o0 400100c0: 10 80 00 18 b 40010120 400100c4: 92 10 00 12 mov %l2, %o1 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 400100c8: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 400100cc: 30 bf ff fb b,a 400100b8 <== NOT EXECUTED 400100d0: c6 04 23 b4 ld [ %l0 + 0x3b4 ], %g3 <== NOT EXECUTED 400100d4: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 400100d8: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 400100dc: c8 00 63 bc ld [ %g1 + 0x3bc ], %g4 <== NOT EXECUTED 400100e0: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 400100e4: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400100e8: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 400100ec: 82 00 60 01 inc %g1 <== NOT EXECUTED 400100f0: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 400100f4: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 400100f8: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 400100fc: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 40010100: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 40010104: 7f ff e9 8b call 4000a730 <== NOT EXECUTED 40010108: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4001010c: d0 04 23 b4 ld [ %l0 + 0x3b4 ], %o0 <== NOT EXECUTED 40010110: 92 10 20 00 clr %o1 <== NOT EXECUTED 40010114: 40 00 0e 0f call 40013950 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 40010118: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 4001011c: 92 10 00 12 mov %l2, %o1 <== NOT EXECUTED 40010120: 11 10 00 c8 sethi %hi(0x40032000), %o0 40010124: 94 07 bf f4 add %fp, -12, %o2 40010128: 40 00 12 0d call 4001495c <_Objects_Get_no_protection> 4001012c: 90 12 20 f8 or %o0, 0xf8, %o0 the_region = _Region_Get( id, &location ); switch ( location ) { 40010130: c2 07 bf f4 ld [ %fp + -12 ], %g1 40010134: 80 a0 60 01 cmp %g1, 1 40010138: 02 80 00 0a be 40010160 4001013c: a0 10 00 08 mov %o0, %l0 40010140: 80 a0 60 01 cmp %g1, 1 40010144: 0a 80 00 22 bcs 400101cc 40010148: 92 10 00 19 mov %i1, %o1 4001014c: 80 a0 60 02 cmp %g1, 2 40010150: 12 80 00 10 bne 40010190 40010154: b0 10 20 19 mov 0x19, %i0 40010158: 10 80 00 10 b 40010198 4001015c: 05 10 00 c8 sethi %hi(0x40032000), %g2 case OBJECTS_REMOTE: /* this error cannot be returned */ _RTEMS_Unlock_allocator(); 40010160: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 40010164: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40010168: 82 00 60 01 inc %g1 <== NOT EXECUTED 4001016c: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 40010170: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 40010174: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 40010178: 94 10 20 00 clr %o2 <== NOT EXECUTED 4001017c: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 40010180: 40 00 0e 16 call 400139d8 <_CORE_mutex_Surrender> <== NOT EXECUTED 40010184: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 40010188: 7f ff ff 62 call 4000ff10 <_Thread_Enable_dispatch> <== NOT EXECUTED 4001018c: b0 10 20 19 mov 0x19, %i0 <== NOT EXECUTED 40010190: 81 c7 e0 08 ret <== NOT EXECUTED 40010194: 81 e8 00 00 restore <== NOT EXECUTED 40010198: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 4001019c: 82 00 60 01 inc %g1 400101a0: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] return RTEMS_INTERNAL_ERROR; case OBJECTS_ERROR: _RTEMS_Unlock_allocator(); 400101a4: 03 10 00 c8 sethi %hi(0x40032000), %g1 400101a8: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 400101ac: 94 10 20 00 clr %o2 400101b0: d2 02 20 08 ld [ %o0 + 8 ], %o1 400101b4: 40 00 0e 09 call 400139d8 <_CORE_mutex_Surrender> 400101b8: 90 02 20 10 add %o0, 0x10, %o0 400101bc: 7f ff ff 55 call 4000ff10 <_Thread_Enable_dispatch> 400101c0: b0 10 20 04 mov 4, %i0 400101c4: 81 c7 e0 08 ret 400101c8: 81 e8 00 00 restore return RTEMS_INVALID_ID; case OBJECTS_LOCAL: heap_status = _Heap_Extend( 400101cc: 94 10 00 1a mov %i2, %o2 400101d0: 90 02 20 68 add %o0, 0x68, %o0 400101d4: 96 07 bf f0 add %fp, -16, %o3 400101d8: 40 00 0f 3b call 40013ec4 <_Heap_Extend> 400101dc: b0 10 20 09 mov 9, %i0 starting_address, length, &amount_extended ); switch ( heap_status ) { 400101e0: 80 a2 20 01 cmp %o0, 1 400101e4: 02 80 00 12 be 4001022c 400101e8: 05 10 00 c8 sethi %hi(0x40032000), %g2 400101ec: 0a 80 00 08 bcs 4001020c 400101f0: c6 07 bf f0 ld [ %fp + -16 ], %g3 400101f4: 82 1a 20 02 xor %o0, 2, %g1 400101f8: 80 a0 00 01 cmp %g0, %g1 400101fc: 82 60 20 00 subx %g0, 0, %g1 40010200: b0 08 7f e8 and %g1, -24, %i0 40010204: 10 80 00 0a b 4001022c 40010208: b0 06 20 18 add %i0, 0x18, %i0 case HEAP_EXTEND_SUCCESSFUL: the_region->length += amount_extended; 4001020c: c4 04 20 54 ld [ %l0 + 0x54 ], %g2 the_region->maximum_segment_size += amount_extended; 40010210: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 &amount_extended ); switch ( heap_status ) { case HEAP_EXTEND_SUCCESSFUL: the_region->length += amount_extended; 40010214: 84 00 80 03 add %g2, %g3, %g2 the_region->maximum_segment_size += amount_extended; 40010218: 82 00 40 03 add %g1, %g3, %g1 &amount_extended ); switch ( heap_status ) { case HEAP_EXTEND_SUCCESSFUL: the_region->length += amount_extended; 4001021c: c4 24 20 54 st %g2, [ %l0 + 0x54 ] the_region->maximum_segment_size += amount_extended; 40010220: c2 24 20 5c st %g1, [ %l0 + 0x5c ] 40010224: b0 10 20 00 clr %i0 40010228: 05 10 00 c8 sethi %hi(0x40032000), %g2 4001022c: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 40010230: 82 00 60 01 inc %g1 40010234: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] break; case HEAP_EXTEND_NOT_IMPLEMENTED: status = RTEMS_NOT_IMPLEMENTED; break; } _RTEMS_Unlock_allocator(); 40010238: 03 10 00 c8 sethi %hi(0x40032000), %g1 4001023c: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 40010240: 94 10 20 00 clr %o2 40010244: d2 02 20 08 ld [ %o0 + 8 ], %o1 40010248: 40 00 0d e4 call 400139d8 <_CORE_mutex_Surrender> 4001024c: 90 02 20 10 add %o0, 0x10, %o0 40010250: 7f ff ff 30 call 4000ff10 <_Thread_Enable_dispatch> 40010254: 01 00 00 00 nop return( status ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40010258: 81 c7 e0 08 ret 4001025c: 81 e8 00 00 restore 40010294 : uint32_t size, rtems_option option_set, rtems_interval timeout, void **segment ) { 40010294: 9d e3 bf 90 save %sp, -112, %sp 40010298: a4 10 00 18 mov %i0, %l2 register Region_Control *the_region; Objects_Locations location; Thread_Control *executing; void *the_segment; if ( !segment ) 4001029c: 80 a7 20 00 cmp %i4, 0 400102a0: 02 80 00 96 be 400104f8 400102a4: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; *segment = NULL; 400102a8: c0 27 00 00 clr [ %i4 ] if ( size == 0 ) 400102ac: 80 a6 60 00 cmp %i1, 0 400102b0: 02 80 00 92 be 400104f8 400102b4: b0 10 20 08 mov 8, %i0 return RTEMS_INVALID_SIZE; _RTEMS_Lock_allocator(); 400102b8: 7f ff e9 1a call 4000a720 400102bc: 01 00 00 00 nop 400102c0: a2 10 00 08 mov %o0, %l1 400102c4: 03 10 00 c8 sethi %hi(0x40032000), %g1 400102c8: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 400102cc: 80 a0 60 00 cmp %g1, 0 400102d0: 02 80 00 0b be 400102fc 400102d4: 03 10 00 c8 sethi %hi(0x40032000), %g1 400102d8: 03 10 00 c9 sethi %hi(0x40032400), %g1 <== NOT EXECUTED 400102dc: c2 00 60 c0 ld [ %g1 + 0xc0 ], %g1 ! 400324c0 <_System_state_Current> <== NOT EXECUTED 400102e0: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400102e4: 08 80 00 05 bleu 400102f8 <== NOT EXECUTED 400102e8: 90 10 20 00 clr %o0 <== NOT EXECUTED 400102ec: 92 10 20 00 clr %o1 <== NOT EXECUTED 400102f0: 40 00 10 2a call 40014398 <_Internal_error_Occurred> <== NOT EXECUTED 400102f4: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 400102f8: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 400102fc: e0 00 63 b4 ld [ %g1 + 0x3b4 ], %l0 ! 400323b4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40010300: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010304: c4 00 63 bc ld [ %g1 + 0x3bc ], %g2 ! 400323bc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 40010308: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 4001030c: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 40010310: 80 a0 60 00 cmp %g1, 0 40010314: 22 80 00 33 be,a 400103e0 40010318: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 4001031c: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 40010320: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 40010324: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; 40010328: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 4001032c: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 40010330: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40010334: 80 a0 e0 02 cmp %g3, 2 40010338: 02 80 00 05 be 4001034c 4001033c: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 40010340: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40010344: 32 80 00 06 bne,a 4001035c <== NOT EXECUTED 40010348: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4001034c: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 40010350: 82 00 60 01 inc %g1 40010354: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 40010358: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 4001035c: 80 a0 60 03 cmp %g1, 3 40010360: 22 80 00 03 be,a 4001036c 40010364: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40010368: 30 80 00 2c b,a 40010418 { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 4001036c: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40010370: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40010374: 12 80 00 03 bne 40010380 <== NOT EXECUTED 40010378: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 4001037c: 30 80 00 27 b,a 40010418 <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40010380: 28 80 00 10 bleu,a 400103c0 <== NOT EXECUTED 40010384: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40010388: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 4001038c: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40010390: 82 00 60 01 inc %g1 <== NOT EXECUTED 40010394: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 40010398: 7f ff e8 e6 call 4000a730 <== NOT EXECUTED 4001039c: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 400103a0: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 400103a4: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 400103a8: 40 00 15 49 call 400158cc <_Thread_Change_priority> <== NOT EXECUTED 400103ac: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 400103b0: 7f ff ff ac call 40010260 <_Thread_Enable_dispatch> <== NOT EXECUTED 400103b4: 01 00 00 00 nop <== NOT EXECUTED executing = _Thread_Executing; 400103b8: 10 80 00 32 b 40010480 <== NOT EXECUTED 400103bc: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 400103c0: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 400103c4: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 400103c8: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 400103cc: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 400103d0: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 400103d4: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 400103d8: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 400103dc: 30 80 00 0f b,a 40010418 <== NOT EXECUTED /* * 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 ) ) { 400103e0: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 400103e4: 32 80 00 13 bne,a 40010430 <== NOT EXECUTED 400103e8: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 400103ec: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40032050 <_Dual_ported_memory_Information+0x3c> <== NOT EXECUTED 400103f0: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 400103f4: 22 80 00 07 be,a 40010410 <== NOT EXECUTED 400103f8: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 400103fc: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40010400: 12 80 00 0c bne 40010430 <== NOT EXECUTED 40010404: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40010408: 10 80 00 08 b 40010428 <== NOT EXECUTED 4001040c: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 40010410: 82 00 60 01 inc %g1 <== NOT EXECUTED 40010414: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 40010418: 7f ff e8 c6 call 4000a730 4001041c: 90 10 00 11 mov %l1, %o0 40010420: 10 80 00 18 b 40010480 40010424: 03 10 00 c8 sethi %hi(0x40032000), %g1 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40010428: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 4001042c: 30 bf ff fb b,a 40010418 <== NOT EXECUTED *segment = NULL; if ( size == 0 ) return RTEMS_INVALID_SIZE; _RTEMS_Lock_allocator(); 40010430: c6 04 23 b4 ld [ %l0 + 0x3b4 ], %g3 <== NOT EXECUTED 40010434: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 40010438: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 4001043c: c8 00 63 bc ld [ %g1 + 0x3bc ], %g4 <== NOT EXECUTED 40010440: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 40010444: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40010448: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 4001044c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40010450: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 40010454: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 40010458: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 4001045c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 40010460: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 40010464: 7f ff e8 b3 call 4000a730 <== NOT EXECUTED 40010468: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 4001046c: d0 04 23 b4 ld [ %l0 + 0x3b4 ], %o0 <== NOT EXECUTED 40010470: 92 10 20 00 clr %o1 <== NOT EXECUTED 40010474: 40 00 0d 37 call 40013950 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 40010478: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED executing = _Thread_Executing; 4001047c: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 40010480: 11 10 00 c8 sethi %hi(0x40032000), %o0 40010484: f0 00 63 bc ld [ %g1 + 0x3bc ], %i0 40010488: 90 12 20 f8 or %o0, 0xf8, %o0 4001048c: 92 10 00 12 mov %l2, %o1 40010490: 40 00 11 33 call 4001495c <_Objects_Get_no_protection> 40010494: 94 07 bf f4 add %fp, -12, %o2 the_region = _Region_Get( id, &location ); switch ( location ) { 40010498: c2 07 bf f4 ld [ %fp + -12 ], %g1 4001049c: 80 a0 60 01 cmp %g1, 1 400104a0: 02 80 00 0a be 400104c8 400104a4: a0 10 00 08 mov %o0, %l0 400104a8: 80 a0 60 01 cmp %g1, 1 400104ac: 2a 80 00 22 bcs,a 40010534 400104b0: c2 02 20 5c ld [ %o0 + 0x5c ], %g1 400104b4: 80 a0 60 02 cmp %g1, 2 400104b8: 12 80 00 10 bne 400104f8 400104bc: b0 10 20 19 mov 0x19, %i0 400104c0: 10 80 00 10 b 40010500 400104c4: 05 10 00 c8 sethi %hi(0x40032000), %g2 case OBJECTS_REMOTE: /* this error cannot be returned */ _RTEMS_Unlock_allocator(); 400104c8: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 400104cc: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400104d0: 82 00 60 01 inc %g1 <== NOT EXECUTED 400104d4: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 400104d8: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 400104dc: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 400104e0: 94 10 20 00 clr %o2 <== NOT EXECUTED 400104e4: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 400104e8: 40 00 0d 3c call 400139d8 <_CORE_mutex_Surrender> <== NOT EXECUTED 400104ec: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 400104f0: 7f ff ff 5c call 40010260 <_Thread_Enable_dispatch> <== NOT EXECUTED 400104f4: b0 10 20 19 mov 0x19, %i0 <== NOT EXECUTED 400104f8: 81 c7 e0 08 ret <== NOT EXECUTED 400104fc: 81 e8 00 00 restore <== NOT EXECUTED 40010500: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 40010504: 82 00 60 01 inc %g1 40010508: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] return RTEMS_INTERNAL_ERROR; case OBJECTS_ERROR: _RTEMS_Unlock_allocator(); 4001050c: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010510: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 40010514: 94 10 20 00 clr %o2 40010518: d2 02 20 08 ld [ %o0 + 8 ], %o1 4001051c: 40 00 0d 2f call 400139d8 <_CORE_mutex_Surrender> 40010520: 90 02 20 10 add %o0, 0x10, %o0 40010524: 7f ff ff 4f call 40010260 <_Thread_Enable_dispatch> 40010528: b0 10 20 04 mov 4, %i0 4001052c: 81 c7 e0 08 ret 40010530: 81 e8 00 00 restore return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( size > the_region->maximum_segment_size ) { 40010534: 80 a6 40 01 cmp %i1, %g1 40010538: 08 80 00 0f bleu 40010574 4001053c: 05 10 00 c8 sethi %hi(0x40032000), %g2 40010540: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 40010544: 82 00 60 01 inc %g1 40010548: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _RTEMS_Unlock_allocator(); 4001054c: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010550: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 40010554: 94 10 20 00 clr %o2 40010558: d2 02 20 08 ld [ %o0 + 8 ], %o1 4001055c: 40 00 0d 1f call 400139d8 <_CORE_mutex_Surrender> 40010560: 90 02 20 10 add %o0, 0x10, %o0 40010564: 7f ff ff 3f call 40010260 <_Thread_Enable_dispatch> 40010568: b0 10 20 08 mov 8, %i0 4001056c: 81 c7 e0 08 ret 40010570: 81 e8 00 00 restore RTEMS_INLINE_ROUTINE void *_Region_Allocate_segment ( Region_Control *the_region, uint32_t size ) { return _Heap_Allocate( &the_region->Memory, size ); 40010574: 90 02 20 68 add %o0, 0x68, %o0 40010578: 40 00 0e 2c call 40013e28 <_Heap_Allocate> 4001057c: 92 10 00 19 mov %i1, %o1 the_segment = _Region_Allocate_segment( the_region, size ); _Region_Debug_Walk( the_region, 2 ); if ( the_segment ) { 40010580: a2 92 20 00 orcc %o0, 0, %l1 40010584: 02 80 00 13 be 400105d0 40010588: 07 10 00 c8 sethi %hi(0x40032000), %g3 the_region->number_of_used_blocks += 1; 4001058c: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 40010590: c4 00 e2 e0 ld [ %g3 + 0x2e0 ], %g2 40010594: 82 00 60 01 inc %g1 40010598: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 4001059c: 84 00 a0 01 inc %g2 400105a0: c4 20 e2 e0 st %g2, [ %g3 + 0x2e0 ] _RTEMS_Unlock_allocator(); 400105a4: 03 10 00 c8 sethi %hi(0x40032000), %g1 400105a8: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 400105ac: 94 10 20 00 clr %o2 400105b0: d2 02 20 08 ld [ %o0 + 8 ], %o1 400105b4: 40 00 0d 09 call 400139d8 <_CORE_mutex_Surrender> 400105b8: 90 02 20 10 add %o0, 0x10, %o0 400105bc: 7f ff ff 29 call 40010260 <_Thread_Enable_dispatch> 400105c0: b0 10 20 00 clr %i0 *segment = the_segment; 400105c4: e2 27 00 00 st %l1, [ %i4 ] 400105c8: 81 c7 e0 08 ret 400105cc: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } if ( _Options_Is_no_wait( option_set ) ) { 400105d0: 80 8e a0 01 btst 1, %i2 400105d4: 05 10 00 c8 sethi %hi(0x40032000), %g2 400105d8: 02 80 00 0e be 40010610 400105dc: 07 10 00 c8 sethi %hi(0x40032000), %g3 400105e0: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 400105e4: 82 00 60 01 inc %g1 400105e8: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _RTEMS_Unlock_allocator(); 400105ec: d0 00 e3 b4 ld [ %g3 + 0x3b4 ], %o0 400105f0: 94 10 20 00 clr %o2 400105f4: d2 02 20 08 ld [ %o0 + 8 ], %o1 400105f8: 40 00 0c f8 call 400139d8 <_CORE_mutex_Surrender> 400105fc: 90 02 20 10 add %o0, 0x10, %o0 40010600: 7f ff ff 18 call 40010260 <_Thread_Enable_dispatch> 40010604: b0 10 20 0d mov 0xd, %i0 40010608: 81 c7 e0 08 ret 4001060c: 81 e8 00 00 restore 40010610: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 40010614: 82 00 60 01 inc %g1 40010618: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] 4001061c: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 40010620: 82 00 60 01 inc %g1 40010624: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] * Switch from using the memory allocation mutex to using a * dispatching disabled critical section. We have to do this * because this thread is going to block. */ _Thread_Disable_dispatch(); _RTEMS_Unlock_allocator(); 40010628: d0 00 e3 b4 ld [ %g3 + 0x3b4 ], %o0 4001062c: 94 10 20 00 clr %o2 40010630: d2 02 20 08 ld [ %o0 + 8 ], %o1 40010634: 40 00 0c e9 call 400139d8 <_CORE_mutex_Surrender> 40010638: 90 02 20 10 add %o0, 0x10, %o0 4001063c: 7f ff ff 09 call 40010260 <_Thread_Enable_dispatch> 40010640: 01 00 00 00 nop executing->Wait.queue = &the_region->Wait_queue; 40010644: 82 04 20 10 add %l0, 0x10, %g1 executing->Wait.count = size; executing->Wait.return_argument = segment; _Thread_queue_Enter_critical_section( &the_region->Wait_queue ); _Thread_queue_Enqueue( &the_region->Wait_queue, timeout ); 40010648: 92 10 00 1b mov %i3, %o1 4001064c: 90 10 00 01 mov %g1, %o0 * because this thread is going to block. */ _Thread_Disable_dispatch(); _RTEMS_Unlock_allocator(); executing->Wait.queue = &the_region->Wait_queue; 40010650: c2 26 20 44 st %g1, [ %i0 + 0x44 ] executing->Wait.count = size; executing->Wait.return_argument = segment; _Thread_queue_Enter_critical_section( &the_region->Wait_queue ); _Thread_queue_Enqueue( &the_region->Wait_queue, timeout ); 40010654: 15 10 00 59 sethi %hi(0x40016400), %o2 40010658: 82 10 20 01 mov 1, %g1 4001065c: 94 12 a3 b4 or %o2, 0x3b4, %o2 */ _Thread_Disable_dispatch(); _RTEMS_Unlock_allocator(); executing->Wait.queue = &the_region->Wait_queue; executing->Wait.id = id; 40010660: e4 26 20 20 st %l2, [ %i0 + 0x20 ] executing->Wait.count = size; 40010664: f2 26 20 24 st %i1, [ %i0 + 0x24 ] executing->Wait.return_argument = segment; 40010668: f8 26 20 28 st %i4, [ %i0 + 0x28 ] _Thread_queue_Enter_critical_section( &the_region->Wait_queue ); _Thread_queue_Enqueue( &the_region->Wait_queue, timeout ); 4001066c: 40 00 17 2c call 4001631c <_Thread_queue_Enqueue_with_handler> 40010670: c2 24 20 40 st %g1, [ %l0 + 0x40 ] _Thread_Enable_dispatch(); 40010674: 7f ff fe fb call 40010260 <_Thread_Enable_dispatch> 40010678: 01 00 00 00 nop return (rtems_status_code) executing->Wait.return_code; 4001067c: f0 06 20 34 ld [ %i0 + 0x34 ], %i0 } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40010680: 81 c7 e0 08 ret 40010684: 81 e8 00 00 restore 400106f4 : rtems_status_code rtems_region_return_segment( Objects_Id id, void *segment ) { 400106f4: 9d e3 bf 90 save %sp, -112, %sp #ifdef RTEMS_REGION_FREE_SHRED_PATTERN uint32_t size; #endif int status; _RTEMS_Lock_allocator(); 400106f8: 7f ff e8 0a call 4000a720 400106fc: 01 00 00 00 nop 40010700: a2 10 00 08 mov %o0, %l1 40010704: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010708: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 4001070c: 80 a0 60 00 cmp %g1, 0 40010710: 02 80 00 0b be 4001073c 40010714: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010718: 03 10 00 c9 sethi %hi(0x40032400), %g1 <== NOT EXECUTED 4001071c: c2 00 60 c0 ld [ %g1 + 0xc0 ], %g1 ! 400324c0 <_System_state_Current> <== NOT EXECUTED 40010720: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40010724: 08 80 00 05 bleu 40010738 <== NOT EXECUTED 40010728: 90 10 20 00 clr %o0 <== NOT EXECUTED 4001072c: 92 10 20 00 clr %o1 <== NOT EXECUTED 40010730: 40 00 0f 1a call 40014398 <_Internal_error_Occurred> <== NOT EXECUTED 40010734: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED 40010738: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 4001073c: e0 00 63 b4 ld [ %g1 + 0x3b4 ], %l0 ! 400323b4 <_RTEMS_Allocator_Mutex> Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40010740: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010744: c4 00 63 bc ld [ %g1 + 0x3bc ], %g2 ! 400323bc <_Thread_Executing> executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 40010748: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 4001074c: c2 04 20 60 ld [ %l0 + 0x60 ], %g1 40010750: 80 a0 60 00 cmp %g1, 0 40010754: 22 80 00 33 be,a 40010820 40010758: c2 04 20 6c ld [ %l0 + 0x6c ], %g1 <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_LOCKED; 4001075c: c0 24 20 60 clr [ %l0 + 0x60 ] the_mutex->holder = executing; the_mutex->holder_id = executing->Object.id; 40010760: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 40010764: c6 04 20 58 ld [ %l0 + 0x58 ], %g3 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; 40010768: c2 24 20 70 st %g1, [ %l0 + 0x70 ] 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; 4001076c: c4 24 20 6c st %g2, [ %l0 + 0x6c ] the_mutex->holder_id = executing->Object.id; the_mutex->nest_count = 1; 40010770: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 40010774: 80 a0 e0 02 cmp %g3, 2 40010778: 02 80 00 05 be 4001078c 4001077c: c2 24 20 64 st %g1, [ %l0 + 0x64 ] 40010780: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 40010784: 32 80 00 06 bne,a 4001079c <== NOT EXECUTED 40010788: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 4001078c: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 40010790: 82 00 60 01 inc %g1 40010794: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 40010798: c2 04 20 58 ld [ %l0 + 0x58 ], %g1 4001079c: 80 a0 60 03 cmp %g1, 3 400107a0: 22 80 00 03 be,a 400107ac 400107a4: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 400107a8: 30 80 00 2c b,a 40010858 { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 400107ac: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 400107b0: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 400107b4: 12 80 00 03 bne 400107c0 <== NOT EXECUTED 400107b8: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 400107bc: 30 80 00 27 b,a 40010858 <== NOT EXECUTED return 0; } if ( current > ceiling ) { 400107c0: 08 80 00 10 bleu 40010800 <== NOT EXECUTED 400107c4: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400107c8: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 400107cc: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 400107d0: 82 00 60 01 inc %g1 <== NOT EXECUTED 400107d4: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 400107d8: 7f ff e7 d6 call 4000a730 <== NOT EXECUTED 400107dc: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED _Thread_Change_priority( 400107e0: d2 04 20 5c ld [ %l0 + 0x5c ], %o1 <== NOT EXECUTED 400107e4: d0 04 20 6c ld [ %l0 + 0x6c ], %o0 <== NOT EXECUTED 400107e8: 40 00 14 39 call 400158cc <_Thread_Change_priority> <== NOT EXECUTED 400107ec: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 400107f0: 7f ff ff b4 call 400106c0 <_Thread_Enable_dispatch> <== NOT EXECUTED 400107f4: 01 00 00 00 nop <== NOT EXECUTED RTEMS_INLINE_ROUTINE Region_Control *_Region_Get ( Objects_Id id, Objects_Locations *location ) { return (Region_Control *) 400107f8: 10 80 00 32 b 400108c0 <== NOT EXECUTED 400107fc: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40010800: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40010804: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 40010808: c0 24 20 64 clr [ %l0 + 0x64 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 4001080c: c2 24 20 60 st %g1, [ %l0 + 0x60 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40010810: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40010814: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40010818: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 4001081c: 30 80 00 0f b,a 40010858 <== NOT EXECUTED /* * 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 ) ) { 40010820: 80 a0 40 02 cmp %g1, %g2 <== NOT EXECUTED 40010824: 32 80 00 13 bne,a 40010870 <== NOT EXECUTED 40010828: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED switch ( the_mutex->Attributes.lock_nesting_behavior ) { 4001082c: c2 04 20 50 ld [ %l0 + 0x50 ], %g1 ! 40032050 <_Dual_ported_memory_Information+0x3c> <== NOT EXECUTED 40010830: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 40010834: 22 80 00 07 be,a 40010850 <== NOT EXECUTED 40010838: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 <== NOT EXECUTED 4001083c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 40010840: 12 80 00 0c bne 40010870 <== NOT EXECUTED 40010844: 21 10 00 c8 sethi %hi(0x40032000), %l0 <== NOT EXECUTED case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40010848: 10 80 00 08 b 40010868 <== NOT EXECUTED 4001084c: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 40010850: 82 00 60 01 inc %g1 <== NOT EXECUTED 40010854: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED _ISR_Enable( level ); 40010858: 7f ff e7 b6 call 4000a730 4001085c: 90 10 00 11 mov %l1, %o0 40010860: 10 80 00 18 b 400108c0 40010864: 92 10 00 18 mov %i0, %o1 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40010868: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 4001086c: 30 bf ff fb b,a 40010858 <== NOT EXECUTED 40010870: c6 04 23 b4 ld [ %l0 + 0x3b4 ], %g3 <== NOT EXECUTED 40010874: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 40010878: da 00 e0 08 ld [ %g3 + 8 ], %o5 <== NOT EXECUTED 4001087c: c8 00 63 bc ld [ %g1 + 0x3bc ], %g4 <== NOT EXECUTED 40010880: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 40010884: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40010888: da 21 20 20 st %o5, [ %g4 + 0x20 ] <== NOT EXECUTED 4001088c: 82 00 60 01 inc %g1 <== NOT EXECUTED 40010890: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 40010894: 82 00 e0 10 add %g3, 0x10, %g1 <== NOT EXECUTED 40010898: c2 21 20 44 st %g1, [ %g4 + 0x44 ] <== NOT EXECUTED 4001089c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED 400108a0: c2 20 e0 40 st %g1, [ %g3 + 0x40 ] <== NOT EXECUTED 400108a4: 7f ff e7 a3 call 4000a730 <== NOT EXECUTED 400108a8: 90 10 00 11 mov %l1, %o0 <== NOT EXECUTED 400108ac: d0 04 23 b4 ld [ %l0 + 0x3b4 ], %o0 <== NOT EXECUTED 400108b0: 92 10 20 00 clr %o1 <== NOT EXECUTED 400108b4: 40 00 0c 27 call 40013950 <_CORE_mutex_Seize_interrupt_blocking> <== NOT EXECUTED 400108b8: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 400108bc: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 400108c0: 11 10 00 c8 sethi %hi(0x40032000), %o0 400108c4: 94 07 bf f4 add %fp, -12, %o2 400108c8: 40 00 10 25 call 4001495c <_Objects_Get_no_protection> 400108cc: 90 12 20 f8 or %o0, 0xf8, %o0 the_region = _Region_Get( id, &location ); switch ( location ) { 400108d0: c2 07 bf f4 ld [ %fp + -12 ], %g1 400108d4: 80 a0 60 01 cmp %g1, 1 400108d8: 02 80 00 0a be 40010900 400108dc: a0 10 00 08 mov %o0, %l0 400108e0: 80 a0 60 01 cmp %g1, 1 400108e4: 0a 80 00 22 bcs 4001096c 400108e8: 92 10 00 19 mov %i1, %o1 400108ec: 80 a0 60 02 cmp %g1, 2 400108f0: 12 80 00 10 bne 40010930 400108f4: b0 10 20 19 mov 0x19, %i0 400108f8: 10 80 00 10 b 40010938 400108fc: 05 10 00 c8 sethi %hi(0x40032000), %g2 case OBJECTS_REMOTE: /* this error cannot be returned */ _RTEMS_Unlock_allocator(); 40010900: 05 10 00 c8 sethi %hi(0x40032000), %g2 <== NOT EXECUTED 40010904: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40010908: 82 00 60 01 inc %g1 <== NOT EXECUTED 4001090c: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] <== NOT EXECUTED 40010910: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 40010914: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> <== NOT EXECUTED 40010918: 94 10 20 00 clr %o2 <== NOT EXECUTED 4001091c: d2 02 20 08 ld [ %o0 + 8 ], %o1 <== NOT EXECUTED 40010920: 40 00 0c 2e call 400139d8 <_CORE_mutex_Surrender> <== NOT EXECUTED 40010924: 90 02 20 10 add %o0, 0x10, %o0 <== NOT EXECUTED 40010928: 7f ff ff 66 call 400106c0 <_Thread_Enable_dispatch> <== NOT EXECUTED 4001092c: b0 10 20 19 mov 0x19, %i0 <== NOT EXECUTED 40010930: 81 c7 e0 08 ret <== NOT EXECUTED 40010934: 81 e8 00 00 restore <== NOT EXECUTED 40010938: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 4001093c: 82 00 60 01 inc %g1 40010940: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] return RTEMS_INTERNAL_ERROR; case OBJECTS_ERROR: _RTEMS_Unlock_allocator(); 40010944: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010948: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 4001094c: 94 10 20 00 clr %o2 40010950: d2 02 20 08 ld [ %o0 + 8 ], %o1 40010954: 40 00 0c 21 call 400139d8 <_CORE_mutex_Surrender> 40010958: 90 02 20 10 add %o0, 0x10, %o0 4001095c: 7f ff ff 59 call 400106c0 <_Thread_Enable_dispatch> 40010960: b0 10 20 04 mov 4, %i0 40010964: 81 c7 e0 08 ret 40010968: 81 e8 00 00 restore RTEMS_INLINE_ROUTINE boolean _Region_Free_segment ( Region_Control *the_region, void *the_segment ) { return _Heap_Free( &the_region->Memory, the_segment ); 4001096c: 40 00 0d 87 call 40013f88 <_Heap_Free> 40010970: 90 02 20 68 add %o0, 0x68, %o0 status = _Region_Free_segment( the_region, segment ); _Region_Debug_Walk( the_region, 4 ); if ( !status ) { 40010974: 80 a2 20 00 cmp %o0, 0 40010978: 12 80 00 0f bne 400109b4 4001097c: 05 10 00 c8 sethi %hi(0x40032000), %g2 40010980: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 40010984: 82 00 60 01 inc %g1 40010988: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] _RTEMS_Unlock_allocator(); 4001098c: 03 10 00 c8 sethi %hi(0x40032000), %g1 40010990: d0 00 63 b4 ld [ %g1 + 0x3b4 ], %o0 ! 400323b4 <_RTEMS_Allocator_Mutex> 40010994: 94 10 20 00 clr %o2 40010998: d2 02 20 08 ld [ %o0 + 8 ], %o1 4001099c: 40 00 0c 0f call 400139d8 <_CORE_mutex_Surrender> 400109a0: 90 02 20 10 add %o0, 0x10, %o0 400109a4: 7f ff ff 47 call 400106c0 <_Thread_Enable_dispatch> 400109a8: b0 10 20 09 mov 9, %i0 400109ac: 81 c7 e0 08 ret 400109b0: 81 e8 00 00 restore return RTEMS_INVALID_ADDRESS; } the_region->number_of_used_blocks -= 1; 400109b4: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 _Region_Process_queue(the_region); /* unlocks allocator internally */ 400109b8: 90 10 00 10 mov %l0, %o0 if ( !status ) { _RTEMS_Unlock_allocator(); return RTEMS_INVALID_ADDRESS; } the_region->number_of_used_blocks -= 1; 400109bc: 82 00 7f ff add %g1, -1, %g1 _Region_Process_queue(the_region); /* unlocks allocator internally */ 400109c0: b0 10 20 00 clr %i0 400109c4: 40 00 23 1a call 4001962c <_Region_Process_queue> 400109c8: c2 24 20 64 st %g1, [ %l0 + 0x64 ] return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400109cc: 81 c7 e0 08 ret 400109d0: 81 e8 00 00 restore 4000559c : uint32_t count, rtems_attribute attribute_set, rtems_task_priority priority_ceiling, rtems_id *id ) { 4000559c: 9d e3 bf 80 save %sp, -128, %sp register Semaphore_Control *the_semaphore; CORE_mutex_Attributes the_mutex_attributes; CORE_semaphore_Attributes the_semaphore_attributes; if ( !rtems_is_name_valid( name ) ) 400055a0: a8 96 20 00 orcc %i0, 0, %l4 400055a4: 02 80 00 2c be 40005654 400055a8: b0 10 20 03 mov 3, %i0 return RTEMS_INVALID_NAME; if ( !id ) 400055ac: 80 a7 20 00 cmp %i4, 0 400055b0: 02 80 00 29 be 40005654 400055b4: b0 10 20 09 mov 9, %i0 return RTEMS_NOT_DEFINED; } else #endif if ( _Attributes_Is_inherit_priority( attribute_set ) || 400055b8: a4 8e a0 40 andcc %i2, 0x40, %l2 400055bc: 12 80 00 06 bne 400055d4 400055c0: 82 0e a0 30 and %i2, 0x30, %g1 400055c4: 80 8e a0 80 btst 0x80, %i2 400055c8: 02 80 00 10 be 40005608 400055cc: a6 0e a0 30 and %i2, 0x30, %l3 RTEMS_INLINE_ROUTINE boolean _Attributes_Is_binary_semaphore( rtems_attribute attribute_set ) { return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_BINARY_SEMAPHORE); 400055d0: 82 0e a0 30 and %i2, 0x30, %g1 _Attributes_Is_priority_ceiling( attribute_set ) ) { if ( ! ( (_Attributes_Is_binary_semaphore( attribute_set ) || 400055d4: 80 a0 60 10 cmp %g1, 0x10 400055d8: 02 80 00 05 be 400055ec 400055dc: 80 8e a0 04 btst 4, %i2 400055e0: 80 a0 60 20 cmp %g1, 0x20 400055e4: 12 80 00 71 bne 400057a8 400055e8: 80 8e a0 04 btst 4, %i2 400055ec: 02 80 00 6f be 400057a8 400055f0: 80 a4 a0 00 cmp %l2, 0 _Attributes_Is_priority( attribute_set ) ) ) return RTEMS_NOT_DEFINED; } if ( _Attributes_Is_inherit_priority( attribute_set ) && 400055f4: 02 80 00 04 be 40005604 400055f8: 80 8e a0 80 btst 0x80, %i2 400055fc: 32 80 00 16 bne,a 40005654 40005600: b0 10 20 0b mov 0xb, %i0 RTEMS_INLINE_ROUTINE boolean _Attributes_Is_counting_semaphore( rtems_attribute attribute_set ) { return ((attribute_set & RTEMS_SEMAPHORE_CLASS) == RTEMS_COUNTING_SEMAPHORE); 40005604: a6 0e a0 30 and %i2, 0x30, %l3 40005608: 80 a0 00 13 cmp %g0, %l3 4000560c: a2 60 3f ff subx %g0, -1, %l1 _Attributes_Is_priority_ceiling( attribute_set ) ) return RTEMS_NOT_DEFINED; if ( !_Attributes_Is_counting_semaphore( attribute_set ) && ( count > 1 ) ) 40005610: 80 a4 60 00 cmp %l1, 0 40005614: 12 80 00 04 bne 40005624 40005618: 80 a6 60 01 cmp %i1, 1 4000561c: 18 80 00 0e bgu 40005654 40005620: b0 10 20 0a mov 0xa, %i0 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40005624: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005628: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> 4000562c: 84 00 a0 01 inc %g2 40005630: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] * the inactive chain of free semaphore control blocks. */ RTEMS_INLINE_ROUTINE Semaphore_Control *_Semaphore_Allocate( void ) { return (Semaphore_Control *) _Objects_Allocate( &_Semaphore_Information ); 40005634: 11 10 00 63 sethi %hi(0x40018c00), %o0 40005638: 40 00 06 df call 400071b4 <_Objects_Allocate> 4000563c: 90 12 21 a4 or %o0, 0x1a4, %o0 ! 40018da4 <_Semaphore_Information> _Thread_Disable_dispatch(); /* prevents deletion */ the_semaphore = _Semaphore_Allocate(); if ( !the_semaphore ) { 40005640: a0 92 20 00 orcc %o0, 0, %l0 40005644: 12 80 00 06 bne 4000565c 40005648: 80 a4 60 00 cmp %l1, 0 _Thread_Enable_dispatch(); 4000564c: 7f ff ff c7 call 40005568 <_Thread_Enable_dispatch> 40005650: b0 10 20 05 mov 5, %i0 40005654: 81 c7 e0 08 ret 40005658: 81 e8 00 00 restore * If it is not a counting semaphore, then it is either a * simple binary semaphore or a more powerful mutex style binary * semaphore. */ if ( !_Attributes_Is_counting_semaphore( attribute_set ) ) { 4000565c: 12 80 00 32 bne 40005724 40005660: f4 24 20 10 st %i2, [ %l0 + 0x10 ] CORE_mutex_Status mutex_status; if ( _Attributes_Is_inherit_priority( attribute_set ) ) 40005664: 80 a4 a0 00 cmp %l2, 0 40005668: 12 80 00 06 bne 40005680 4000566c: 82 10 20 02 mov 2, %g1 the_mutex_attributes.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; else if ( _Attributes_Is_priority_ceiling( attribute_set ) ) 40005670: 80 8e a0 80 btst 0x80, %i2 40005674: 02 80 00 05 be 40005688 40005678: 80 8e a0 04 btst 4, %i2 the_mutex_attributes.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING; 4000567c: 82 10 20 03 mov 3, %g1 <== NOT EXECUTED 40005680: 10 80 00 05 b 40005694 40005684: c2 27 bf e8 st %g1, [ %fp + -24 ] else if ( _Attributes_Is_priority( attribute_set ) ) 40005688: 12 bf ff fe bne 40005680 4000568c: 82 10 20 01 mov 1, %g1 the_mutex_attributes.discipline = CORE_MUTEX_DISCIPLINES_PRIORITY; else the_mutex_attributes.discipline = CORE_MUTEX_DISCIPLINES_FIFO; 40005690: c0 27 bf e8 clr [ %fp + -24 ] if ( _Attributes_Is_binary_semaphore( attribute_set ) ) { 40005694: 80 a4 e0 10 cmp %l3, 0x10 40005698: 12 80 00 0f bne 400056d4 4000569c: 82 10 20 02 mov 2, %g1 the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; switch ( the_mutex_attributes.discipline ) { 400056a0: c2 07 bf e8 ld [ %fp + -24 ], %g1 400056a4: 80 a0 60 01 cmp %g1, 1 400056a8: 08 80 00 07 bleu 400056c4 400056ac: c0 27 bf e0 clr [ %fp + -32 ] 400056b0: 80 a0 60 03 cmp %g1, 3 400056b4: 38 80 00 0b bgu,a 400056e0 400056b8: 82 1e 60 01 xor %i1, 1, %g1 <== NOT EXECUTED case CORE_MUTEX_DISCIPLINES_PRIORITY: the_mutex_attributes.only_owner_release = FALSE; break; case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING: case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT: the_mutex_attributes.only_owner_release = TRUE; 400056bc: 10 80 00 04 b 400056cc 400056c0: 82 10 20 01 mov 1, %g1 the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; switch ( the_mutex_attributes.discipline ) { case CORE_MUTEX_DISCIPLINES_FIFO: case CORE_MUTEX_DISCIPLINES_PRIORITY: the_mutex_attributes.only_owner_release = FALSE; 400056c4: 10 80 00 06 b 400056dc 400056c8: c0 27 bf e4 clr [ %fp + -28 ] break; case CORE_MUTEX_DISCIPLINES_PRIORITY_CEILING: case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT: the_mutex_attributes.only_owner_release = TRUE; 400056cc: 10 80 00 04 b 400056dc 400056d0: c2 27 bf e4 st %g1, [ %fp + -28 ] break; } } else { the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_BLOCKS; the_mutex_attributes.only_owner_release = FALSE; 400056d4: c0 27 bf e4 clr [ %fp + -28 ] case CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT: the_mutex_attributes.only_owner_release = TRUE; break; } } else { the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_BLOCKS; 400056d8: c2 27 bf e0 st %g1, [ %fp + -32 ] the_mutex_attributes.only_owner_release = FALSE; } the_mutex_attributes.priority_ceiling = priority_ceiling; mutex_status = _CORE_mutex_Initialize( 400056dc: 82 1e 60 01 xor %i1, 1, %g1 400056e0: 80 a0 00 01 cmp %g0, %g1 } else { the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_BLOCKS; the_mutex_attributes.only_owner_release = FALSE; } the_mutex_attributes.priority_ceiling = priority_ceiling; 400056e4: f6 27 bf ec st %i3, [ %fp + -20 ] mutex_status = _CORE_mutex_Initialize( 400056e8: 94 60 3f ff subx %g0, -1, %o2 400056ec: 90 04 20 14 add %l0, 0x14, %o0 400056f0: 40 00 04 3c call 400067e0 <_CORE_mutex_Initialize> 400056f4: 92 07 bf e0 add %fp, -32, %o1 &the_semaphore->Core_control.mutex, &the_mutex_attributes, (count == 1) ? CORE_MUTEX_UNLOCKED : CORE_MUTEX_LOCKED ); if ( mutex_status == CORE_MUTEX_STATUS_CEILING_VIOLATED ) { 400056f8: 80 a2 20 06 cmp %o0, 6 400056fc: 12 80 00 17 bne 40005758 40005700: 92 10 00 10 mov %l0, %o1 RTEMS_INLINE_ROUTINE void _Semaphore_Free ( Semaphore_Control *the_semaphore ) { _Objects_Free( &_Semaphore_Information, &the_semaphore->Object ); 40005704: 11 10 00 63 sethi %hi(0x40018c00), %o0 <== NOT EXECUTED 40005708: 90 12 21 a4 or %o0, 0x1a4, %o0 ! 40018da4 <_Semaphore_Information> <== NOT EXECUTED 4000570c: 40 00 07 ac call 400075bc <_Objects_Free> <== NOT EXECUTED 40005710: b0 10 20 13 mov 0x13, %i0 <== NOT EXECUTED _Semaphore_Free( the_semaphore ); _Thread_Enable_dispatch(); 40005714: 7f ff ff 95 call 40005568 <_Thread_Enable_dispatch> <== NOT EXECUTED 40005718: 01 00 00 00 nop <== NOT EXECUTED 4000571c: 81 c7 e0 08 ret <== NOT EXECUTED 40005720: 81 e8 00 00 restore <== NOT EXECUTED return RTEMS_INVALID_PRIORITY; } } else { if ( _Attributes_Is_priority( attribute_set ) ) 40005724: 80 8e a0 04 btst 4, %i2 40005728: 22 80 00 04 be,a 40005738 4000572c: c0 27 bf f4 clr [ %fp + -12 ] the_semaphore_attributes.discipline = CORE_SEMAPHORE_DISCIPLINES_PRIORITY; 40005730: 82 10 20 01 mov 1, %g1 40005734: c2 27 bf f4 st %g1, [ %fp + -12 ] /* * This effectively disables limit checking. */ the_semaphore_attributes.maximum_count = 0xFFFFFFFF; 40005738: 82 10 3f ff mov -1, %g1 /* * The following are just to make Purify happy. */ the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; 4000573c: c0 27 bf e0 clr [ %fp + -32 ] the_mutex_attributes.priority_ceiling = PRIORITY_MINIMUM; 40005740: c0 27 bf ec clr [ %fp + -20 ] _CORE_semaphore_Initialize( 40005744: 94 10 00 19 mov %i1, %o2 /* * This effectively disables limit checking. */ the_semaphore_attributes.maximum_count = 0xFFFFFFFF; 40005748: c2 27 bf f0 st %g1, [ %fp + -16 ] */ the_mutex_attributes.lock_nesting_behavior = CORE_MUTEX_NESTING_ACQUIRES; the_mutex_attributes.priority_ceiling = PRIORITY_MINIMUM; _CORE_semaphore_Initialize( 4000574c: 90 04 20 14 add %l0, 0x14, %o0 40005750: 40 00 04 d3 call 40006a9c <_CORE_semaphore_Initialize> 40005754: 92 07 bf f0 add %fp, -16, %o1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005758: 03 10 00 63 sethi %hi(0x40018c00), %g1 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, the_object ); 4000575c: c6 04 20 08 ld [ %l0 + 8 ], %g3 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005760: 88 10 61 a4 or %g1, 0x1a4, %g4 40005764: c4 11 20 10 lduh [ %g4 + 0x10 ], %g2 40005768: 03 00 00 3f sethi %hi(0xfc00), %g1 4000576c: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40005770: 82 08 c0 01 and %g3, %g1, %g1 40005774: 80 a0 40 02 cmp %g1, %g2 40005778: 38 80 00 06 bgu,a 40005790 4000577c: c2 04 20 08 ld [ %l0 + 8 ], %g1 <== NOT EXECUTED information->local_table[ index ] = the_object; 40005780: c4 01 20 20 ld [ %g4 + 0x20 ], %g2 40005784: 83 28 60 02 sll %g1, 2, %g1 40005788: e0 20 80 01 st %l0, [ %g2 + %g1 ] &_Semaphore_Information, &the_semaphore->Object, (Objects_Name) name ); *id = the_semaphore->Object.id; 4000578c: c2 04 20 08 ld [ %l0 + 8 ], %g1 if ( information->is_string ) /* _Objects_Copy_name_string( name, the_object->name ); */ the_object->name = name; else /* _Objects_Copy_name_raw( name, the_object->name, information->name_length ); */ the_object->name = name; 40005790: e8 24 20 0c st %l4, [ %l0 + 0xc ] 40005794: c2 27 00 00 st %g1, [ %i4 ] the_semaphore->Object.id, name, 0 /* Not used */ ); #endif _Thread_Enable_dispatch(); 40005798: 7f ff ff 74 call 40005568 <_Thread_Enable_dispatch> 4000579c: b0 10 20 00 clr %i0 400057a0: 81 c7 e0 08 ret 400057a4: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; 400057a8: b0 10 20 0b mov 0xb, %i0 } 400057ac: 81 c7 e0 08 ret 400057b0: 81 e8 00 00 restore 400057e8 : #endif rtems_status_code rtems_semaphore_delete( rtems_id id ) { 400057e8: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Semaphore_Control *_Semaphore_Get ( Objects_Id id, Objects_Locations *location ) { return (Semaphore_Control *) 400057ec: 11 10 00 63 sethi %hi(0x40018c00), %o0 400057f0: 92 10 00 18 mov %i0, %o1 400057f4: 90 12 21 a4 or %o0, 0x1a4, %o0 400057f8: 40 00 07 b3 call 400076c4 <_Objects_Get> 400057fc: 94 07 bf f4 add %fp, -12, %o2 register Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { 40005800: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005804: 80 a0 60 00 cmp %g1, 0 40005808: 02 80 00 07 be 40005824 4000580c: b0 10 00 08 mov %o0, %i0 40005810: 80 a0 60 02 cmp %g1, 2 40005814: 08 80 00 10 bleu 40005854 40005818: b0 10 20 04 mov 4, %i0 4000581c: 81 c7 e0 08 ret <== NOT EXECUTED 40005820: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED 40005824: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { 40005828: 84 88 60 30 andcc %g1, 0x30, %g2 4000582c: 22 80 00 12 be,a 40005874 40005830: 90 02 20 14 add %o0, 0x14, %o0 if ( _CORE_mutex_Is_locked( &the_semaphore->Core_control.mutex ) && 40005834: c2 02 20 64 ld [ %o0 + 0x64 ], %g1 40005838: 80 a0 60 00 cmp %g1, 0 4000583c: 12 80 00 08 bne 4000585c 40005840: 80 a0 a0 20 cmp %g2, 0x20 40005844: 02 80 00 07 be 40005860 40005848: 90 06 20 14 add %i0, 0x14, %o0 !_Attributes_Is_simple_binary_semaphore( the_semaphore->attribute_set ) ) { _Thread_Enable_dispatch(); 4000584c: 7f ff ff da call 400057b4 <_Thread_Enable_dispatch> 40005850: b0 10 20 0c mov 0xc, %i0 40005854: 81 c7 e0 08 ret 40005858: 81 e8 00 00 restore return RTEMS_RESOURCE_IN_USE; } _CORE_mutex_Flush( 4000585c: 90 06 20 14 add %i0, 0x14, %o0 40005860: 92 10 20 00 clr %o1 40005864: 40 00 03 db call 400067d0 <_CORE_mutex_Flush> 40005868: 94 10 20 04 mov 4, %o2 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4000586c: 10 80 00 06 b 40005884 40005870: 03 10 00 63 sethi %hi(0x40018c00), %g1 &the_semaphore->Core_control.mutex, SEMAPHORE_MP_OBJECT_WAS_DELETED, CORE_MUTEX_WAS_DELETED ); } else { _CORE_semaphore_Flush( 40005874: 92 10 20 00 clr %o1 40005878: 40 00 04 85 call 40006a8c <_CORE_semaphore_Flush> 4000587c: 94 10 20 02 mov 2, %o2 40005880: 03 10 00 63 sethi %hi(0x40018c00), %g1 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 40005884: c6 06 20 08 ld [ %i0 + 8 ], %g3 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40005888: 90 10 61 a4 or %g1, 0x1a4, %o0 4000588c: c4 12 20 10 lduh [ %o0 + 0x10 ], %g2 40005890: 03 00 00 3f sethi %hi(0xfc00), %g1 40005894: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40005898: 82 08 c0 01 and %g3, %g1, %g1 4000589c: 80 a0 40 02 cmp %g1, %g2 400058a0: 18 80 00 05 bgu 400058b4 400058a4: 92 10 00 18 mov %i0, %o1 information->local_table[ index ] = the_object; 400058a8: c4 02 20 20 ld [ %o0 + 0x20 ], %g2 400058ac: 83 28 60 02 sll %g1, 2, %g1 400058b0: c0 20 80 01 clr [ %g2 + %g1 ] uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 400058b4: c0 26 20 0c clr [ %i0 + 0xc ] RTEMS_INLINE_ROUTINE void _Semaphore_Free ( Semaphore_Control *the_semaphore ) { _Objects_Free( &_Semaphore_Information, &the_semaphore->Object ); 400058b8: 40 00 07 41 call 400075bc <_Objects_Free> 400058bc: b0 10 20 00 clr %i0 0, /* Not used */ 0 /* Not used */ ); } #endif _Thread_Enable_dispatch(); 400058c0: 7f ff ff bd call 400057b4 <_Thread_Enable_dispatch> 400058c4: 01 00 00 00 nop return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400058c8: 81 c7 e0 08 ret 400058cc: 81 e8 00 00 restore 40005d2c : #endif rtems_status_code rtems_semaphore_flush( rtems_id id ) { 40005d2c: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Semaphore_Control *_Semaphore_Get ( Objects_Id id, Objects_Locations *location ) { return (Semaphore_Control *) 40005d30: 11 10 00 6a sethi %hi(0x4001a800), %o0 40005d34: 92 10 00 18 mov %i0, %o1 40005d38: 90 12 20 6c or %o0, 0x6c, %o0 40005d3c: 40 00 08 30 call 40007dfc <_Objects_Get> 40005d40: 94 07 bf f4 add %fp, -12, %o2 register Semaphore_Control *the_semaphore; Objects_Locations location; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { 40005d44: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005d48: 80 a0 60 00 cmp %g1, 0 40005d4c: 22 80 00 07 be,a 40005d68 40005d50: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 40005d54: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 40005d58: 08 80 00 19 bleu 40005dbc <== NOT EXECUTED 40005d5c: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED 40005d60: 81 c7 e0 08 ret <== NOT EXECUTED 40005d64: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { 40005d68: 80 88 60 30 btst 0x30, %g1 40005d6c: 02 80 00 06 be 40005d84 40005d70: 90 02 20 14 add %o0, 0x14, %o0 _CORE_mutex_Flush( 40005d74: 92 10 20 00 clr %o1 40005d78: 40 00 04 64 call 40006f08 <_CORE_mutex_Flush> 40005d7c: 94 10 20 01 mov 1, %o2 40005d80: 30 80 00 04 b,a 40005d90 &the_semaphore->Core_control.mutex, SEND_OBJECT_WAS_DELETED, CORE_MUTEX_STATUS_UNSATISFIED_NOWAIT ); } else { _CORE_semaphore_Flush( 40005d84: 92 10 20 00 clr %o1 <== NOT EXECUTED 40005d88: 40 00 05 0f call 400071c4 <_CORE_semaphore_Flush> <== NOT EXECUTED 40005d8c: 94 10 20 01 mov 1, %o2 <== NOT EXECUTED #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40005d90: 03 10 00 6a sethi %hi(0x4001a800), %g1 40005d94: c4 00 61 c0 ld [ %g1 + 0x1c0 ], %g2 ! 4001a9c0 <_Thread_Dispatch_disable_level> 40005d98: b0 10 20 00 clr %i0 40005d9c: 84 00 bf ff add %g2, -1, %g2 40005da0: c4 20 61 c0 st %g2, [ %g1 + 0x1c0 ] 40005da4: c2 00 61 c0 ld [ %g1 + 0x1c0 ], %g1 40005da8: 80 a0 60 00 cmp %g1, 0 40005dac: 12 80 00 04 bne 40005dbc 40005db0: 01 00 00 00 nop _Thread_Dispatch(); 40005db4: 40 00 0c c7 call 400090d0 <_Thread_Dispatch> 40005db8: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005dbc: 81 c7 e0 08 ret 40005dc0: 81 e8 00 00 restore 40005904 : rtems_status_code rtems_semaphore_obtain( rtems_id id, uint32_t option_set, rtems_interval timeout ) { 40005904: 9d e3 bf 90 save %sp, -112, %sp Objects_Id id, Objects_Locations *location, ISR_Level *level ) { return (Semaphore_Control *) 40005908: 11 10 00 63 sethi %hi(0x40018c00), %o0 4000590c: 92 10 00 18 mov %i0, %o1 40005910: 90 12 21 a4 or %o0, 0x1a4, %o0 40005914: 94 07 bf f4 add %fp, -12, %o2 40005918: 40 00 07 4d call 4000764c <_Objects_Get_isr_disable> 4000591c: 96 07 bf f0 add %fp, -16, %o3 register Semaphore_Control *the_semaphore; Objects_Locations location; ISR_Level level; the_semaphore = _Semaphore_Get_interrupt_disable( id, &location, &level ); switch ( location ) { 40005920: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005924: 80 a0 60 00 cmp %g1, 0 40005928: 02 80 00 07 be 40005944 4000592c: a0 10 00 08 mov %o0, %l0 40005930: 80 a0 60 02 cmp %g1, 2 40005934: 08 80 00 ab bleu 40005be0 40005938: 90 10 20 04 mov 4, %o0 4000593c: 10 80 00 a9 b 40005be0 <== NOT EXECUTED 40005940: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { 40005944: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 40005948: 80 88 60 30 btst 0x30, %g1 4000594c: 02 80 00 7c be 40005b3c 40005950: 03 10 00 63 sethi %hi(0x40018c00), %g1 _CORE_mutex_Seize( 40005954: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005958: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> 4000595c: 80 a0 60 00 cmp %g1, 0 40005960: 02 80 00 0e be 40005998 40005964: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005968: 80 8e 60 01 btst 1, %i1 4000596c: 12 80 00 0c bne 4000599c 40005970: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 40005974: 03 10 00 64 sethi %hi(0x40019000), %g1 40005978: c2 00 60 d0 ld [ %g1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> 4000597c: 80 a0 60 01 cmp %g1, 1 40005980: 08 80 00 05 bleu 40005994 40005984: 90 10 20 00 clr %o0 40005988: 92 10 20 00 clr %o1 <== NOT EXECUTED 4000598c: 40 00 05 dd call 40007100 <_Internal_error_Occurred> <== NOT EXECUTED 40005990: 94 10 20 12 mov 0x12, %o2 <== NOT EXECUTED Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40005994: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005998: c4 00 63 cc ld [ %g1 + 0x3cc ], %g2 ! 40018fcc <_Thread_Executing> CORE_mutex_Control *the_mutex, ISR_Level *level_p ) { Thread_Control *executing; ISR_Level level = *level_p; 4000599c: d0 07 bf f0 ld [ %fp + -16 ], %o0 /* disabled when you get here */ executing = _Thread_Executing; executing->Wait.return_code = CORE_MUTEX_STATUS_SUCCESSFUL; 400059a0: c0 20 a0 34 clr [ %g2 + 0x34 ] if ( !_CORE_mutex_Is_locked( the_mutex ) ) { 400059a4: c2 04 20 64 ld [ %l0 + 0x64 ], %g1 400059a8: 80 a0 60 00 cmp %g1, 0 400059ac: 22 80 00 33 be,a 40005a78 400059b0: c2 04 20 70 ld [ %l0 + 0x70 ], %g1 the_mutex->lock = CORE_MUTEX_LOCKED; 400059b4: c0 24 20 64 clr [ %l0 + 0x64 ] the_mutex->holder = executing; 400059b8: c4 24 20 70 st %g2, [ %l0 + 0x70 ] the_mutex->holder_id = executing->Object.id; 400059bc: c2 00 a0 08 ld [ %g2 + 8 ], %g1 */ RTEMS_INLINE_ROUTINE boolean _CORE_mutex_Is_inherit_priority( CORE_mutex_Attributes *the_attribute ) { return the_attribute->discipline == CORE_MUTEX_DISCIPLINES_PRIORITY_INHERIT; 400059c0: c6 04 20 5c ld [ %l0 + 0x5c ], %g3 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; 400059c4: c2 24 20 74 st %g1, [ %l0 + 0x74 ] the_mutex->nest_count = 1; 400059c8: 82 10 20 01 mov 1, %g1 if ( _CORE_mutex_Is_inherit_priority( &the_mutex->Attributes ) || 400059cc: 80 a0 e0 02 cmp %g3, 2 400059d0: 02 80 00 05 be 400059e4 400059d4: c2 24 20 68 st %g1, [ %l0 + 0x68 ] 400059d8: 80 a0 e0 03 cmp %g3, 3 <== NOT EXECUTED 400059dc: 32 80 00 06 bne,a 400059f4 <== NOT EXECUTED 400059e0: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 <== NOT EXECUTED _CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) executing->resource_count++; 400059e4: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 400059e8: 82 00 60 01 inc %g1 400059ec: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] if ( !_CORE_mutex_Is_priority_ceiling( &the_mutex->Attributes ) ) { 400059f0: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 400059f4: 80 a0 60 03 cmp %g1, 3 400059f8: 22 80 00 03 be,a 40005a04 400059fc: c6 04 20 60 ld [ %l0 + 0x60 ], %g3 <== NOT EXECUTED _ISR_Enable( level ); 40005a00: 30 80 00 2e b,a 40005ab8 { Priority_Control ceiling; Priority_Control current; ceiling = the_mutex->Attributes.priority_ceiling; current = executing->current_priority; 40005a04: c2 00 a0 14 ld [ %g2 + 0x14 ], %g1 <== NOT EXECUTED if ( current == ceiling ) { 40005a08: 80 a0 40 03 cmp %g1, %g3 <== NOT EXECUTED 40005a0c: 12 80 00 03 bne 40005a18 <== NOT EXECUTED 40005a10: 01 00 00 00 nop <== NOT EXECUTED _ISR_Enable( level ); 40005a14: 30 80 00 29 b,a 40005ab8 <== NOT EXECUTED return 0; } if ( current > ceiling ) { 40005a18: 28 80 00 10 bleu,a 40005a58 <== NOT EXECUTED 40005a1c: 82 10 20 06 mov 6, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40005a20: 05 10 00 63 sethi %hi(0x40018c00), %g2 <== NOT EXECUTED 40005a24: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 ! 40018ef0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40005a28: 82 00 60 01 inc %g1 <== NOT EXECUTED 40005a2c: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] <== NOT EXECUTED _Thread_Disable_dispatch(); _ISR_Enable( level ); 40005a30: 7f ff f0 c7 call 40001d4c <== NOT EXECUTED 40005a34: 01 00 00 00 nop <== NOT EXECUTED _Thread_Change_priority( 40005a38: d2 04 20 60 ld [ %l0 + 0x60 ], %o1 <== NOT EXECUTED 40005a3c: d0 04 20 70 ld [ %l0 + 0x70 ], %o0 <== NOT EXECUTED 40005a40: 40 00 0a e9 call 400085e4 <_Thread_Change_priority> <== NOT EXECUTED 40005a44: 94 10 20 00 clr %o2 <== NOT EXECUTED the_mutex->holder, the_mutex->Attributes.priority_ceiling, FALSE ); _Thread_Enable_dispatch(); 40005a48: 7f ff ff a2 call 400058d0 <_Thread_Enable_dispatch> <== NOT EXECUTED 40005a4c: 01 00 00 00 nop <== NOT EXECUTED id, ((_Options_Is_no_wait( option_set )) ? FALSE : TRUE), timeout, level ); return _Semaphore_Translate_core_mutex_return_code( 40005a50: 10 80 00 36 b 40005b28 <== NOT EXECUTED 40005a54: 03 10 00 63 sethi %hi(0x40018c00), %g1 <== NOT EXECUTED return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; 40005a58: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED the_mutex->lock = CORE_MUTEX_UNLOCKED; 40005a5c: 82 10 20 01 mov 1, %g1 <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ 40005a60: c0 24 20 68 clr [ %l0 + 0x68 ] <== NOT EXECUTED _Thread_Enable_dispatch(); return 0; } /* if ( current < ceiling ) */ { executing->Wait.return_code = CORE_MUTEX_STATUS_CEILING_VIOLATED; the_mutex->lock = CORE_MUTEX_UNLOCKED; 40005a64: c2 24 20 64 st %g1, [ %l0 + 0x64 ] <== NOT EXECUTED the_mutex->nest_count = 0; /* undo locking above */ executing->resource_count--; /* undo locking above */ 40005a68: c2 00 a0 1c ld [ %g2 + 0x1c ], %g1 <== NOT EXECUTED 40005a6c: 82 00 7f ff add %g1, -1, %g1 <== NOT EXECUTED 40005a70: c2 20 a0 1c st %g1, [ %g2 + 0x1c ] <== NOT EXECUTED _ISR_Enable( level ); 40005a74: 30 80 00 11 b,a 40005ab8 <== NOT EXECUTED /* * 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 ) ) { 40005a78: 80 a0 40 02 cmp %g1, %g2 40005a7c: 12 80 00 13 bne 40005ac8 40005a80: 80 8e 60 01 btst 1, %i1 switch ( the_mutex->Attributes.lock_nesting_behavior ) { 40005a84: c2 04 20 54 ld [ %l0 + 0x54 ], %g1 40005a88: 80 a0 60 00 cmp %g1, 0 40005a8c: 22 80 00 07 be,a 40005aa8 40005a90: c2 04 20 68 ld [ %l0 + 0x68 ], %g1 40005a94: 80 a0 60 01 cmp %g1, 1 40005a98: 12 80 00 0c bne 40005ac8 40005a9c: 80 8e 60 01 btst 1, %i1 case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; _ISR_Enable( level ); return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40005aa0: 10 80 00 05 b 40005ab4 <== NOT EXECUTED 40005aa4: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED * to nest access. */ if ( _Thread_Is_executing( the_mutex->holder ) ) { switch ( the_mutex->Attributes.lock_nesting_behavior ) { case CORE_MUTEX_NESTING_ACQUIRES: the_mutex->nest_count++; 40005aa8: 82 00 60 01 inc %g1 40005aac: c2 24 20 68 st %g1, [ %l0 + 0x68 ] _ISR_Enable( level ); 40005ab0: 30 80 00 02 b,a 40005ab8 return 0; case CORE_MUTEX_NESTING_IS_ERROR: executing->Wait.return_code = CORE_MUTEX_STATUS_NESTING_NOT_ALLOWED; 40005ab4: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] <== NOT EXECUTED _ISR_Enable( level ); 40005ab8: 7f ff f0 a5 call 40001d4c 40005abc: 01 00 00 00 nop 40005ac0: 10 80 00 1a b 40005b28 40005ac4: 03 10 00 63 sethi %hi(0x40018c00), %g1 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { _CORE_mutex_Seize( 40005ac8: 02 80 00 08 be 40005ae8 40005acc: 23 10 00 63 sethi %hi(0x40018c00), %l1 40005ad0: 7f ff f0 9f call 40001d4c 40005ad4: d0 07 bf f0 ld [ %fp + -16 ], %o0 40005ad8: c4 04 63 cc ld [ %l1 + 0x3cc ], %g2 40005adc: 82 10 20 01 mov 1, %g1 40005ae0: 10 80 00 11 b 40005b24 40005ae4: c2 20 a0 34 st %g1, [ %g2 + 0x34 ] 40005ae8: c6 04 63 cc ld [ %l1 + 0x3cc ], %g3 RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section ( Thread_queue_Control *the_thread_queue ) { the_thread_queue->sync_state = THREAD_QUEUE_NOTHING_HAPPENED; 40005aec: 82 10 20 01 mov 1, %g1 40005af0: 05 10 00 63 sethi %hi(0x40018c00), %g2 40005af4: c2 24 20 44 st %g1, [ %l0 + 0x44 ] 40005af8: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 40005afc: f0 20 e0 20 st %i0, [ %g3 + 0x20 ] 40005b00: 82 00 60 01 inc %g1 40005b04: a0 04 20 14 add %l0, 0x14, %l0 40005b08: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 40005b0c: e0 20 e0 44 st %l0, [ %g3 + 0x44 ] 40005b10: 7f ff f0 8f call 40001d4c 40005b14: d0 07 bf f0 ld [ %fp + -16 ], %o0 40005b18: 90 10 00 10 mov %l0, %o0 40005b1c: 40 00 03 5f call 40006898 <_CORE_mutex_Seize_interrupt_blocking> 40005b20: 92 10 00 1a mov %i2, %o1 id, ((_Options_Is_no_wait( option_set )) ? FALSE : TRUE), timeout, level ); return _Semaphore_Translate_core_mutex_return_code( 40005b24: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005b28: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 40018fcc <_Thread_Executing> 40005b2c: 40 00 00 62 call 40005cb4 <_Semaphore_Translate_core_mutex_return_code> 40005b30: d0 00 60 34 ld [ %g1 + 0x34 ], %o0 return _Semaphore_Translate_core_semaphore_return_code( _Thread_Executing->Wait.return_code ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005b34: 81 c7 e0 08 ret 40005b38: 91 e8 00 08 restore %g0, %o0, %o0 Thread_Control *executing; ISR_Level level = *level_p; /* disabled when you get here */ executing = _Thread_Executing; 40005b3c: e2 00 63 cc ld [ %g1 + 0x3cc ], %l1 Watchdog_Interval timeout, ISR_Level *level_p ) { Thread_Control *executing; ISR_Level level = *level_p; 40005b40: d0 07 bf f0 ld [ %fp + -16 ], %o0 /* disabled when you get here */ executing = _Thread_Executing; executing->Wait.return_code = CORE_SEMAPHORE_STATUS_SUCCESSFUL; 40005b44: c0 24 60 34 clr [ %l1 + 0x34 ] if ( the_semaphore->count != 0 ) { 40005b48: c2 04 20 5c ld [ %l0 + 0x5c ], %g1 40005b4c: 80 a0 60 00 cmp %g1, 0 40005b50: 02 80 00 08 be 40005b70 40005b54: 80 8e 60 01 btst 1, %i1 the_semaphore->count -= 1; 40005b58: 82 00 7f ff add %g1, -1, %g1 40005b5c: c2 24 20 5c st %g1, [ %l0 + 0x5c ] _ISR_Enable( level ); 40005b60: 7f ff f0 7b call 40001d4c 40005b64: 01 00 00 00 nop id, ((_Options_Is_no_wait( option_set )) ? FALSE : TRUE), timeout, &level ); return _Semaphore_Translate_core_semaphore_return_code( 40005b68: 10 80 00 1b b 40005bd4 40005b6c: 03 10 00 63 sethi %hi(0x40018c00), %g1 return; } if ( !wait ) { 40005b70: 02 80 00 07 be 40005b8c 40005b74: 05 10 00 63 sethi %hi(0x40018c00), %g2 _ISR_Enable( level ); 40005b78: 7f ff f0 75 call 40001d4c 40005b7c: 01 00 00 00 nop executing->Wait.return_code = CORE_SEMAPHORE_STATUS_UNSATISFIED_NOWAIT; 40005b80: 82 10 20 01 mov 1, %g1 ! 1 40005b84: 10 80 00 13 b 40005bd0 40005b88: c2 24 60 34 st %g1, [ %l1 + 0x34 ] 40005b8c: c2 00 a2 f0 ld [ %g2 + 0x2f0 ], %g1 40005b90: 82 00 60 01 inc %g1 40005b94: c2 20 a2 f0 st %g1, [ %g2 + 0x2f0 ] 40005b98: 82 10 20 01 mov 1, %g1 40005b9c: c2 24 20 44 st %g1, [ %l0 + 0x44 ] } _Thread_Disable_dispatch(); _Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue ); executing->Wait.queue = &the_semaphore->Wait_queue; executing->Wait.id = id; 40005ba0: f0 24 60 20 st %i0, [ %l1 + 0x20 ] return; } _Thread_Disable_dispatch(); _Thread_queue_Enter_critical_section( &the_semaphore->Wait_queue ); executing->Wait.queue = &the_semaphore->Wait_queue; 40005ba4: a0 04 20 14 add %l0, 0x14, %l0 40005ba8: e0 24 60 44 st %l0, [ %l1 + 0x44 ] executing->Wait.id = id; _ISR_Enable( level ); 40005bac: 7f ff f0 68 call 40001d4c 40005bb0: 01 00 00 00 nop _Thread_queue_Enqueue( &the_semaphore->Wait_queue, timeout ); 40005bb4: 90 10 00 10 mov %l0, %o0 40005bb8: 92 10 00 1a mov %i2, %o1 40005bbc: 15 10 00 25 sethi %hi(0x40009400), %o2 40005bc0: 40 00 0d 1d call 40009034 <_Thread_queue_Enqueue_with_handler> 40005bc4: 94 12 a0 cc or %o2, 0xcc, %o2 ! 400094cc <_Thread_queue_Timeout> _Thread_Enable_dispatch(); 40005bc8: 7f ff ff 42 call 400058d0 <_Thread_Enable_dispatch> 40005bcc: 01 00 00 00 nop 40005bd0: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005bd4: c2 00 63 cc ld [ %g1 + 0x3cc ], %g1 ! 40018fcc <_Thread_Executing> 40005bd8: 40 00 00 41 call 40005cdc <_Semaphore_Translate_core_semaphore_return_code> 40005bdc: d0 00 60 34 ld [ %g1 + 0x34 ], %o0 _Thread_Executing->Wait.return_code ); } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005be0: b0 10 00 08 mov %o0, %i0 40005be4: 81 c7 e0 08 ret 40005be8: 81 e8 00 00 restore 40005c20 : #endif rtems_status_code rtems_semaphore_release( rtems_id id ) { 40005c20: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Semaphore_Control *_Semaphore_Get ( Objects_Id id, Objects_Locations *location ) { return (Semaphore_Control *) 40005c24: 11 10 00 63 sethi %hi(0x40018c00), %o0 40005c28: 92 10 00 18 mov %i0, %o1 40005c2c: 90 12 21 a4 or %o0, 0x1a4, %o0 40005c30: 40 00 06 a5 call 400076c4 <_Objects_Get> 40005c34: 94 07 bf f4 add %fp, -12, %o2 Objects_Locations location; CORE_mutex_Status mutex_status; CORE_semaphore_Status semaphore_status; the_semaphore = _Semaphore_Get( id, &location ); switch ( location ) { 40005c38: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005c3c: 80 a0 60 00 cmp %g1, 0 40005c40: 22 80 00 07 be,a 40005c5c 40005c44: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 40005c48: 80 a0 60 02 cmp %g1, 2 40005c4c: 08 80 00 17 bleu 40005ca8 40005c50: 90 10 20 04 mov 4, %o0 40005c54: 10 80 00 15 b 40005ca8 <== NOT EXECUTED 40005c58: 90 10 20 19 mov 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_Attributes_Is_counting_semaphore(the_semaphore->attribute_set) ) { 40005c5c: 80 88 60 30 btst 0x30, %g1 40005c60: 02 80 00 0b be 40005c8c 40005c64: 90 02 20 14 add %o0, 0x14, %o0 mutex_status = _CORE_mutex_Surrender( 40005c68: 92 10 00 18 mov %i0, %o1 40005c6c: 40 00 03 2d call 40006920 <_CORE_mutex_Surrender> 40005c70: 94 10 20 00 clr %o2 &the_semaphore->Core_control.mutex, id, MUTEX_MP_SUPPORT ); _Thread_Enable_dispatch(); 40005c74: 7f ff ff de call 40005bec <_Thread_Enable_dispatch> 40005c78: a0 10 00 08 mov %o0, %l0 return _Semaphore_Translate_core_mutex_return_code( mutex_status ); 40005c7c: 40 00 00 0e call 40005cb4 <_Semaphore_Translate_core_mutex_return_code> 40005c80: 90 10 00 10 mov %l0, %o0 _Semaphore_Translate_core_semaphore_return_code( semaphore_status ); } } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005c84: 81 c7 e0 08 ret 40005c88: 91 e8 00 08 restore %g0, %o0, %o0 MUTEX_MP_SUPPORT ); _Thread_Enable_dispatch(); return _Semaphore_Translate_core_mutex_return_code( mutex_status ); } else { semaphore_status = _CORE_semaphore_Surrender( 40005c8c: 92 10 00 18 mov %i0, %o1 40005c90: 40 00 03 92 call 40006ad8 <_CORE_semaphore_Surrender> 40005c94: 94 10 20 00 clr %o2 &the_semaphore->Core_control.semaphore, id, MUTEX_MP_SUPPORT ); _Thread_Enable_dispatch(); 40005c98: 7f ff ff d5 call 40005bec <_Thread_Enable_dispatch> 40005c9c: a0 10 00 08 mov %o0, %l0 return 40005ca0: 40 00 00 0f call 40005cdc <_Semaphore_Translate_core_semaphore_return_code> 40005ca4: 90 10 00 10 mov %l0, %o0 _Semaphore_Translate_core_semaphore_return_code( semaphore_status ); } } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005ca8: b0 10 00 08 mov %o0, %i0 40005cac: 81 c7 e0 08 ret 40005cb0: 81 e8 00 00 restore 40016c1c : */ void rtems_shutdown_executive( uint32_t result ) { 40016c1c: 9d e3 bf 98 save %sp, -104, %sp if ( _System_state_Current != SYSTEM_STATE_SHUTDOWN ) { 40016c20: 33 10 00 64 sethi %hi(0x40019000), %i1 40016c24: c2 06 60 d0 ld [ %i1 + 0xd0 ], %g1 ! 400190d0 <_System_state_Current> 40016c28: 80 a0 60 04 cmp %g1, 4 40016c2c: 02 80 00 0c be 40016c5c 40016c30: 11 10 00 5f sethi %hi(0x40017c00), %o0 #if defined(__USE_INIT_FINI__) extern void _fini( void ); atexit( _fini ); 40016c34: 7f ff da 4d call 4000d568 40016c38: 90 12 22 cc or %o0, 0x2cc, %o0 ! 40017ecc <_fini> * routine which initialized the system. */ RTEMS_INLINE_ROUTINE void _Thread_Stop_multitasking( void ) { _Context_Switch( &_Thread_Executing->Registers, &_Thread_BSP_context ); 40016c3c: 03 10 00 63 sethi %hi(0x40018c00), %g1 40016c40: f0 00 63 cc ld [ %g1 + 0x3cc ], %i0 ! 40018fcc <_Thread_Executing> 40016c44: 82 10 20 04 mov 4, %g1 40016c48: b0 06 20 e0 add %i0, 0xe0, %i0 40016c4c: c2 26 60 d0 st %g1, [ %i1 + 0xd0 ] 40016c50: 33 10 00 63 sethi %hi(0x40018c00), %i1 40016c54: 7f ff cd 49 call 4000a178 <_CPU_Context_switch> 40016c58: 93 ee 62 68 restore %i1, 0x268, %o1 40016c5c: 81 c7 e0 08 ret <== NOT EXECUTED 40016c60: 81 e8 00 00 restore <== NOT EXECUTED 400111fc : rtems_status_code rtems_signal_send( Objects_Id id, rtems_signal_set signal_set ) { 400111fc: 9d e3 bf 90 save %sp, -112, %sp 40011200: 92 10 00 18 mov %i0, %o1 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; ASR_Information *asr; if ( !signal_set ) 40011204: 80 a6 60 00 cmp %i1, 0 40011208: 02 80 00 47 be 40011324 4001120c: b0 10 20 0a mov 0xa, %i0 uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40011210: 80 a2 60 00 cmp %o1, 0 40011214: 12 80 00 0a bne 4001123c 40011218: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4001121c: 03 10 00 c8 sethi %hi(0x40032000), %g1 40011220: c4 00 62 e0 ld [ %g1 + 0x2e0 ], %g2 ! 400322e0 <_Thread_Dispatch_disable_level> 40011224: 84 00 a0 01 inc %g2 40011228: c4 20 62 e0 st %g2, [ %g1 + 0x2e0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 4001122c: 03 10 00 c8 sethi %hi(0x40032000), %g1 40011230: f0 00 63 bc ld [ %g1 + 0x3bc ], %i0 ! 400323bc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40011234: 10 80 00 18 b 40011294 40011238: c0 27 bf f4 clr [ %fp + -12 ] */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); 4001123c: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40011240: 80 a0 a0 04 cmp %g2, 4 40011244: 18 80 00 0e bgu 4001127c 40011248: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 4001124c: 83 32 60 1b srl %o1, 0x1b, %g1 40011250: 80 a0 60 01 cmp %g1, 1 40011254: 12 80 00 0a bne 4001127c 40011258: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 4001125c: 83 28 a0 02 sll %g2, 2, %g1 40011260: 05 10 00 c8 sethi %hi(0x40032000), %g2 40011264: 84 10 a2 40 or %g2, 0x240, %g2 ! 40032240 <_Objects_Information_table> 40011268: c2 00 80 01 ld [ %g2 + %g1 ], %g1 4001126c: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40011270: 80 a2 20 00 cmp %o0, 0 40011274: 12 80 00 05 bne 40011288 40011278: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 4001127c: b0 10 20 00 clr %i0 40011280: 10 80 00 05 b 40011294 40011284: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40011288: 40 00 0d c9 call 400149ac <_Objects_Get> 4001128c: 94 07 bf f4 add %fp, -12, %o2 40011290: b0 10 00 08 mov %o0, %i0 return RTEMS_INVALID_NUMBER; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40011294: c2 07 bf f4 ld [ %fp + -12 ], %g1 40011298: 80 a0 60 00 cmp %g1, 0 4001129c: 22 80 00 07 be,a 400112b8 400112a0: d2 06 21 6c ld [ %i0 + 0x16c ], %o1 400112a4: 80 a0 60 02 cmp %g1, 2 400112a8: 08 80 00 1f bleu 40011324 400112ac: b0 10 20 04 mov 4, %i0 400112b0: 81 c7 e0 08 ret <== NOT EXECUTED 400112b4: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; asr = &api->Signal; if ( ! _ASR_Is_null_handler( asr->handler ) ) { 400112b8: c2 02 60 4c ld [ %o1 + 0x4c ], %g1 400112bc: 80 a0 60 00 cmp %g1, 0 400112c0: 02 80 00 1b be 4001132c 400112c4: 01 00 00 00 nop if ( asr->is_enabled ) { 400112c8: c2 02 60 48 ld [ %o1 + 0x48 ], %g1 400112cc: 80 a0 60 00 cmp %g1, 0 400112d0: 02 80 00 11 be 40011314 400112d4: 90 10 00 19 mov %i1, %o0 _ASR_Post_signals( signal_set, &asr->signals_posted ); 400112d8: 7f ff ff b3 call 400111a4 <_ASR_Post_signals> 400112dc: 92 02 60 54 add %o1, 0x54, %o1 the_thread->do_post_task_switch_extension = TRUE; if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) ) 400112e0: 03 10 00 c8 sethi %hi(0x40032000), %g1 400112e4: c2 00 63 a4 ld [ %g1 + 0x3a4 ], %g1 ! 400323a4 <_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; 400112e8: 84 10 20 01 mov 1, %g2 if ( _ISR_Is_in_progress() && _Thread_Is_executing( the_thread ) ) 400112ec: 80 a0 60 00 cmp %g1, 0 400112f0: 02 80 00 0b be 4001131c 400112f4: c4 26 20 78 st %g2, [ %i0 + 0x78 ] 400112f8: 03 10 00 c8 sethi %hi(0x40032000), %g1 <== NOT EXECUTED 400112fc: c2 00 63 bc ld [ %g1 + 0x3bc ], %g1 ! 400323bc <_Thread_Executing> <== NOT EXECUTED 40011300: 80 a6 00 01 cmp %i0, %g1 <== NOT EXECUTED 40011304: 12 80 00 06 bne 4001131c <== NOT EXECUTED 40011308: 03 10 00 c9 sethi %hi(0x40032400), %g1 <== NOT EXECUTED _ISR_Signals_to_thread_executing = TRUE; 4001130c: 10 80 00 04 b 4001131c <== NOT EXECUTED 40011310: c4 20 60 68 st %g2, [ %g1 + 0x68 ] ! 40032468 <_ISR_Signals_to_thread_executing> <== NOT EXECUTED } else { _ASR_Post_signals( signal_set, &asr->signals_pending ); 40011314: 7f ff ff a4 call 400111a4 <_ASR_Post_signals> 40011318: 92 02 60 58 add %o1, 0x58, %o1 } _Thread_Enable_dispatch(); 4001131c: 7f ff ff ab call 400111c8 <_Thread_Enable_dispatch> 40011320: b0 10 20 00 clr %i0 40011324: 81 c7 e0 08 ret 40011328: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 4001132c: 7f ff ff a7 call 400111c8 <_Thread_Enable_dispatch> 40011330: b0 10 20 0b mov 0xb, %i0 return RTEMS_NOT_DEFINED; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40011334: 81 c7 e0 08 ret 40011338: 81 e8 00 00 restore 40005ec4 : */ rtems_status_code rtems_task_delete( Objects_Id id ) { 40005ec4: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40005ec8: 92 96 20 00 orcc %i0, 0, %o1 40005ecc: 12 80 00 0a bne 40005ef4 40005ed0: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40005ed4: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005ed8: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> 40005edc: 84 00 a0 01 inc %g2 40005ee0: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40005ee4: 03 10 00 63 sethi %hi(0x40018c00), %g1 40005ee8: f0 00 63 cc ld [ %g1 + 0x3cc ], %i0 ! 40018fcc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40005eec: 10 80 00 18 b 40005f4c 40005ef0: c0 27 bf f4 clr [ %fp + -12 ] */ RTEMS_INLINE_ROUTINE Objects_APIs _Objects_Get_API( Objects_Id id ) { return (Objects_APIs) ((id >> OBJECTS_API_START_BIT) & OBJECTS_API_VALID_BITS); 40005ef4: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40005ef8: 80 a0 a0 04 cmp %g2, 4 40005efc: 18 80 00 0e bgu 40005f34 40005f00: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40005f04: 83 32 60 1b srl %o1, 0x1b, %g1 40005f08: 80 a0 60 01 cmp %g1, 1 40005f0c: 12 80 00 0a bne 40005f34 40005f10: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40005f14: 83 28 a0 02 sll %g2, 2, %g1 40005f18: 05 10 00 63 sethi %hi(0x40018c00), %g2 40005f1c: 84 10 a2 50 or %g2, 0x250, %g2 ! 40018e50 <_Objects_Information_table> 40005f20: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40005f24: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40005f28: 80 a2 20 00 cmp %o0, 0 40005f2c: 12 80 00 05 bne 40005f40 40005f30: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40005f34: b0 10 20 00 clr %i0 40005f38: 10 80 00 05 b 40005f4c 40005f3c: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40005f40: 40 00 05 e1 call 400076c4 <_Objects_Get> 40005f44: 94 07 bf f4 add %fp, -12, %o2 40005f48: b0 10 00 08 mov %o0, %i0 register Thread_Control *the_thread; Objects_Locations location; Objects_Information *the_information; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40005f4c: c2 07 bf f4 ld [ %fp + -12 ], %g1 40005f50: 80 a0 60 00 cmp %g1, 0 40005f54: 02 80 00 06 be 40005f6c 40005f58: 80 a0 60 02 cmp %g1, 2 40005f5c: 08 80 00 0b bleu 40005f88 40005f60: b0 10 20 04 mov 4, %i0 40005f64: 81 c7 e0 08 ret <== NOT EXECUTED 40005f68: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: the_information = _Objects_Get_information( the_thread->Object.id ); 40005f6c: 7f ff ff c0 call 40005e6c <_Objects_Get_information> 40005f70: d0 06 20 08 ld [ %i0 + 8 ], %o0 if ( !the_information ) { 40005f74: 80 a2 20 00 cmp %o0, 0 40005f78: 12 80 00 06 bne 40005f90 40005f7c: 01 00 00 00 nop _Thread_Enable_dispatch(); 40005f80: 7f ff ff c4 call 40005e90 <_Thread_Enable_dispatch> <== NOT EXECUTED 40005f84: b0 10 20 04 mov 4, %i0 ! 4 <== NOT EXECUTED 40005f88: 81 c7 e0 08 ret 40005f8c: 81 e8 00 00 restore return RTEMS_INVALID_ID; /* This should never happen if _Thread_Get() works right */ } _Thread_Close( the_information, the_thread ); 40005f90: 40 00 0a 3c call 40008880 <_Thread_Close> 40005f94: 92 10 00 18 mov %i0, %o1 40005f98: 7f ff ff b5 call 40005e6c <_Objects_Get_information> 40005f9c: d0 06 20 08 ld [ %i0 + 8 ], %o0 40005fa0: 92 10 00 18 mov %i0, %o1 40005fa4: 40 00 05 86 call 400075bc <_Objects_Free> 40005fa8: b0 10 20 00 clr %i0 0 /* Not used */ ); } #endif _Thread_Enable_dispatch(); 40005fac: 7f ff ff b9 call 40005e90 <_Thread_Enable_dispatch> 40005fb0: 01 00 00 00 nop return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40005fb4: 81 c7 e0 08 ret 40005fb8: 81 e8 00 00 restore 400077d0 : rtems_status_code rtems_task_get_note( Objects_Id id, uint32_t notepad, uint32_t *note ) { 400077d0: 9d e3 bf 90 save %sp, -112, %sp 400077d4: 92 10 00 18 mov %i0, %o1 register Thread_Control *the_thread; Objects_Locations location; RTEMS_API_Control *api; if ( !note ) 400077d8: 80 a6 a0 00 cmp %i2, 0 400077dc: 02 80 00 43 be 400078e8 400077e0: b0 10 20 09 mov 9, %i0 /* * NOTE: There is no check for < RTEMS_NOTEPAD_FIRST because that would * be checking an unsigned number for being negative. */ if ( notepad > RTEMS_NOTEPAD_LAST ) 400077e4: 80 a6 60 0f cmp %i1, 0xf 400077e8: 18 80 00 40 bgu 400078e8 400077ec: b0 10 20 0a mov 0xa, %i0 /* * Optimize the most likely case to avoid the Thread_Dispatch. */ if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) || 400077f0: 80 a2 60 00 cmp %o1, 0 400077f4: 02 80 00 08 be 40007814 400077f8: 03 10 00 78 sethi %hi(0x4001e000), %g1 400077fc: c2 00 62 4c ld [ %g1 + 0x24c ], %g1 ! 4001e24c <_Thread_Executing> 40007800: c2 00 60 08 ld [ %g1 + 8 ], %g1 40007804: 80 a2 40 01 cmp %o1, %g1 40007808: 12 80 00 0a bne 40007830 4000780c: 83 32 60 18 srl %o1, 0x18, %g1 _Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) { api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ]; *note = api->Notepads[ notepad ]; 40007810: 03 10 00 78 sethi %hi(0x4001e000), %g1 <== NOT EXECUTED 40007814: c2 00 62 4c ld [ %g1 + 0x24c ], %g1 ! 4001e24c <_Thread_Executing> 40007818: 85 2e 60 02 sll %i1, 2, %g2 4000781c: c2 00 61 6c ld [ %g1 + 0x16c ], %g1 40007820: c2 00 40 02 ld [ %g1 + %g2 ], %g1 40007824: c2 26 80 00 st %g1, [ %i2 ] 40007828: 81 c7 e0 08 ret 4000782c: 91 e8 20 00 restore %g0, 0, %o0 40007830: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40007834: 80 a0 a0 04 cmp %g2, 4 40007838: 18 80 00 06 bgu 40007850 4000783c: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40007840: 83 32 60 1b srl %o1, 0x1b, %g1 40007844: 80 a0 60 01 cmp %g1, 1 40007848: 02 80 00 05 be 4000785c 4000784c: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40007850: 90 10 20 00 clr %o0 40007854: 10 80 00 0e b 4000788c 40007858: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 4000785c: 83 28 a0 02 sll %g2, 2, %g1 40007860: 05 10 00 78 sethi %hi(0x4001e000), %g2 40007864: 84 10 a0 d0 or %g2, 0xd0, %g2 ! 4001e0d0 <_Objects_Information_table> 40007868: c2 00 80 01 ld [ %g2 + %g1 ], %g1 4000786c: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40007870: 80 a2 20 00 cmp %o0, 0 40007874: 12 80 00 04 bne 40007884 40007878: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 4000787c: 10 80 00 04 b 4000788c <== NOT EXECUTED 40007880: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40007884: 40 00 07 2b call 40009530 <_Objects_Get> 40007888: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_SUCCESSFUL; } the_thread = _Thread_Get( id, &location ); switch ( location ) { 4000788c: c2 07 bf f4 ld [ %fp + -12 ], %g1 40007890: 80 a0 60 00 cmp %g1, 0 40007894: 22 80 00 07 be,a 400078b0 40007898: c4 02 21 6c ld [ %o0 + 0x16c ], %g2 4000789c: 80 a0 60 02 cmp %g1, 2 400078a0: 08 80 00 12 bleu 400078e8 400078a4: b0 10 20 04 mov 4, %i0 400078a8: 81 c7 e0 08 ret <== NOT EXECUTED 400078ac: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; *note = api->Notepads[ notepad ]; 400078b0: 83 2e 60 02 sll %i1, 2, %g1 400078b4: c2 00 80 01 ld [ %g2 + %g1 ], %g1 400078b8: c2 26 80 00 st %g1, [ %i2 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 400078bc: 05 10 00 78 sethi %hi(0x4001e000), %g2 400078c0: c2 00 a1 70 ld [ %g2 + 0x170 ], %g1 ! 4001e170 <_Thread_Dispatch_disable_level> 400078c4: b0 10 20 00 clr %i0 400078c8: 82 00 7f ff add %g1, -1, %g1 400078cc: c2 20 a1 70 st %g1, [ %g2 + 0x170 ] 400078d0: c2 00 a1 70 ld [ %g2 + 0x170 ], %g1 400078d4: 80 a0 60 00 cmp %g1, 0 400078d8: 12 80 00 04 bne 400078e8 400078dc: 01 00 00 00 nop _Thread_Dispatch(); 400078e0: 40 00 0b c9 call 4000a804 <_Thread_Dispatch> 400078e4: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400078e8: 81 c7 e0 08 ret 400078ec: 81 e8 00 00 restore 40006650 : */ rtems_status_code rtems_task_is_suspended( Objects_Id id ) { 40006650: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40006654: 92 96 20 00 orcc %i0, 0, %o1 40006658: 12 80 00 0a bne 40006680 4000665c: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40006660: 03 10 00 6f sethi %hi(0x4001bc00), %g1 <== NOT EXECUTED 40006664: c4 00 63 90 ld [ %g1 + 0x390 ], %g2 ! 4001bf90 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40006668: 84 00 a0 01 inc %g2 <== NOT EXECUTED 4000666c: c4 20 63 90 st %g2, [ %g1 + 0x390 ] <== NOT EXECUTED Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40006670: 03 10 00 70 sethi %hi(0x4001c000), %g1 <== NOT EXECUTED 40006674: d0 00 60 6c ld [ %g1 + 0x6c ], %o0 ! 4001c06c <_Thread_Executing> <== NOT EXECUTED Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40006678: 10 80 00 19 b 400066dc <== NOT EXECUTED 4000667c: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED 40006680: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40006684: 80 a0 a0 04 cmp %g2, 4 40006688: 18 80 00 06 bgu 400066a0 4000668c: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40006690: 83 32 60 1b srl %o1, 0x1b, %g1 40006694: 80 a0 60 01 cmp %g1, 1 40006698: 02 80 00 05 be 400066ac 4000669c: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 400066a0: 90 10 20 00 clr %o0 <== NOT EXECUTED 400066a4: 10 80 00 0e b 400066dc <== NOT EXECUTED 400066a8: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 400066ac: 83 28 a0 02 sll %g2, 2, %g1 400066b0: 05 10 00 6f sethi %hi(0x4001bc00), %g2 400066b4: 84 10 a2 f0 or %g2, 0x2f0, %g2 ! 4001bef0 <_Objects_Information_table> 400066b8: c2 00 80 01 ld [ %g2 + %g1 ], %g1 400066bc: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 400066c0: 80 a2 20 00 cmp %o0, 0 400066c4: 12 80 00 04 bne 400066d4 400066c8: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 400066cc: 10 80 00 04 b 400066dc <== NOT EXECUTED 400066d0: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 400066d4: 40 00 06 31 call 40007f98 <_Objects_Get> 400066d8: 94 07 bf f4 add %fp, -12, %o2 register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { 400066dc: c2 07 bf f4 ld [ %fp + -12 ], %g1 400066e0: 80 a0 60 00 cmp %g1, 0 400066e4: 22 80 00 07 be,a 40006700 400066e8: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 400066ec: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 400066f0: 08 80 00 09 bleu 40006714 <== NOT EXECUTED 400066f4: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED 400066f8: 81 c7 e0 08 ret <== NOT EXECUTED 400066fc: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_States_Is_suspended( the_thread->current_state ) ) { 40006700: 80 88 60 02 btst 2, %g1 40006704: 12 80 00 06 bne 4000671c 40006708: 01 00 00 00 nop _Thread_Enable_dispatch(); 4000670c: 7f ff ff c4 call 4000661c <_Thread_Enable_dispatch> 40006710: b0 10 20 00 clr %i0 ! 0 40006714: 81 c7 e0 08 ret 40006718: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 4000671c: 7f ff ff c0 call 4000661c <_Thread_Enable_dispatch> 40006720: b0 10 20 0f mov 0xf, %i0 return RTEMS_ALREADY_SUSPENDED; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40006724: 81 c7 e0 08 ret 40006728: 81 e8 00 00 restore 40006ca4 : rtems_status_code rtems_task_restart( Objects_Id id, uint32_t argument ) { 40006ca4: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40006ca8: 92 96 20 00 orcc %i0, 0, %o1 40006cac: 12 80 00 0a bne 40006cd4 40006cb0: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40006cb4: 03 10 00 71 sethi %hi(0x4001c400), %g1 40006cb8: c4 00 60 b0 ld [ %g1 + 0xb0 ], %g2 ! 4001c4b0 <_Thread_Dispatch_disable_level> 40006cbc: 84 00 a0 01 inc %g2 40006cc0: c4 20 60 b0 st %g2, [ %g1 + 0xb0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40006cc4: 03 10 00 71 sethi %hi(0x4001c400), %g1 40006cc8: d0 00 61 8c ld [ %g1 + 0x18c ], %o0 ! 4001c58c <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40006ccc: 10 80 00 19 b 40006d30 40006cd0: c0 27 bf f4 clr [ %fp + -12 ] 40006cd4: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40006cd8: 80 a0 a0 04 cmp %g2, 4 40006cdc: 18 80 00 06 bgu 40006cf4 40006ce0: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40006ce4: 83 32 60 1b srl %o1, 0x1b, %g1 40006ce8: 80 a0 60 01 cmp %g1, 1 40006cec: 02 80 00 05 be 40006d00 40006cf0: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40006cf4: 90 10 20 00 clr %o0 40006cf8: 10 80 00 0e b 40006d30 40006cfc: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40006d00: 83 28 a0 02 sll %g2, 2, %g1 40006d04: 05 10 00 71 sethi %hi(0x4001c400), %g2 40006d08: 84 10 a0 10 or %g2, 0x10, %g2 ! 4001c410 <_Objects_Information_table> 40006d0c: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40006d10: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40006d14: 80 a2 20 00 cmp %o0, 0 40006d18: 12 80 00 04 bne 40006d28 40006d1c: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40006d20: 10 80 00 04 b 40006d30 <== NOT EXECUTED 40006d24: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40006d28: 40 00 05 f8 call 40008508 <_Objects_Get> 40006d2c: 94 07 bf f4 add %fp, -12, %o2 register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40006d30: c2 07 bf f4 ld [ %fp + -12 ], %g1 40006d34: 80 a0 60 00 cmp %g1, 0 40006d38: 22 80 00 07 be,a 40006d54 40006d3c: 94 10 00 19 mov %i1, %o2 40006d40: 80 a0 60 02 cmp %g1, 2 40006d44: 08 80 00 0b bleu 40006d70 40006d48: b0 10 20 04 mov 4, %i0 40006d4c: 81 c7 e0 08 ret <== NOT EXECUTED 40006d50: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( _Thread_Restart( the_thread, NULL, argument ) ) { 40006d54: 40 00 0d 6e call 4000a30c <_Thread_Restart> 40006d58: 92 10 20 00 clr %o1 40006d5c: 80 a2 20 00 cmp %o0, 0 40006d60: 02 80 00 06 be 40006d78 40006d64: 01 00 00 00 nop _Thread_Enable_dispatch(); 40006d68: 7f ff ff c2 call 40006c70 <_Thread_Enable_dispatch> 40006d6c: b0 10 20 00 clr %i0 ! 0 40006d70: 81 c7 e0 08 ret 40006d74: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 40006d78: 7f ff ff be call 40006c70 <_Thread_Enable_dispatch> 40006d7c: b0 10 20 0e mov 0xe, %i0 return RTEMS_INCORRECT_STATE; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40006d80: 81 c7 e0 08 ret 40006d84: 81 e8 00 00 restore 40007670 : */ rtems_status_code rtems_task_resume( Objects_Id id ) { 40007670: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40007674: 92 96 20 00 orcc %i0, 0, %o1 40007678: 12 80 00 0a bne 400076a0 4000767c: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40007680: 03 10 00 95 sethi %hi(0x40025400), %g1 40007684: c4 00 60 00 ld [ %g1 ], %g2 40007688: 84 00 a0 01 inc %g2 4000768c: c4 20 60 00 st %g2, [ %g1 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40007690: 03 10 00 95 sethi %hi(0x40025400), %g1 40007694: d0 00 60 dc ld [ %g1 + 0xdc ], %o0 ! 400254dc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40007698: 10 80 00 19 b 400076fc 4000769c: c0 27 bf f4 clr [ %fp + -12 ] 400076a0: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 400076a4: 80 a0 a0 04 cmp %g2, 4 400076a8: 18 80 00 06 bgu 400076c0 400076ac: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 400076b0: 83 32 60 1b srl %o1, 0x1b, %g1 400076b4: 80 a0 60 01 cmp %g1, 1 400076b8: 02 80 00 05 be 400076cc 400076bc: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 400076c0: 90 10 20 00 clr %o0 400076c4: 10 80 00 0e b 400076fc 400076c8: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 400076cc: 83 28 a0 02 sll %g2, 2, %g1 400076d0: 05 10 00 94 sethi %hi(0x40025000), %g2 400076d4: 84 10 a3 60 or %g2, 0x360, %g2 ! 40025360 <_Objects_Information_table> 400076d8: c2 00 80 01 ld [ %g2 + %g1 ], %g1 400076dc: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 400076e0: 80 a2 20 00 cmp %o0, 0 400076e4: 12 80 00 04 bne 400076f4 400076e8: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 400076ec: 10 80 00 04 b 400076fc <== NOT EXECUTED 400076f0: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 400076f4: 40 00 06 d2 call 4000923c <_Objects_Get> 400076f8: 94 07 bf f4 add %fp, -12, %o2 register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { 400076fc: c2 07 bf f4 ld [ %fp + -12 ], %g1 40007700: 80 a0 60 00 cmp %g1, 0 40007704: 22 80 00 07 be,a 40007720 40007708: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 4000770c: 80 a0 60 02 cmp %g1, 2 40007710: 08 80 00 0b bleu 4000773c 40007714: b0 10 20 04 mov 4, %i0 40007718: 81 c7 e0 08 ret <== NOT EXECUTED 4000771c: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( _States_Is_suspended( the_thread->current_state ) ) { 40007720: 80 88 60 02 btst 2, %g1 40007724: 02 80 00 08 be 40007744 40007728: 92 10 20 01 mov 1, %o1 _Thread_Resume( the_thread, TRUE ); 4000772c: 40 00 0e 5b call 4000b098 <_Thread_Resume> 40007730: b0 10 20 00 clr %i0 _Thread_Enable_dispatch(); 40007734: 7f ff ff c2 call 4000763c <_Thread_Enable_dispatch> 40007738: 01 00 00 00 nop 4000773c: 81 c7 e0 08 ret 40007740: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 40007744: 7f ff ff be call 4000763c <_Thread_Enable_dispatch> 40007748: b0 10 20 0e mov 0xe, %i0 return RTEMS_INCORRECT_STATE; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000774c: 81 c7 e0 08 ret 40007750: 81 e8 00 00 restore 40007abc : rtems_status_code rtems_task_set_note( Objects_Id id, uint32_t notepad, uint32_t note ) { 40007abc: 9d e3 bf 90 save %sp, -112, %sp 40007ac0: 92 10 00 18 mov %i0, %o1 /* * NOTE: There is no check for < RTEMS_NOTEPAD_FIRST because that would * be checking an unsigned number for being negative. */ if ( notepad > RTEMS_NOTEPAD_LAST ) 40007ac4: 80 a6 60 0f cmp %i1, 0xf 40007ac8: 18 80 00 3e bgu 40007bc0 40007acc: b0 10 20 0a mov 0xa, %i0 /* * Optimize the most likely case to avoid the Thread_Dispatch. */ if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) || 40007ad0: 80 a2 60 00 cmp %o1, 0 40007ad4: 02 80 00 08 be 40007af4 40007ad8: 03 10 00 78 sethi %hi(0x4001e000), %g1 40007adc: c2 00 62 4c ld [ %g1 + 0x24c ], %g1 ! 4001e24c <_Thread_Executing> 40007ae0: c2 00 60 08 ld [ %g1 + 8 ], %g1 40007ae4: 80 a2 40 01 cmp %o1, %g1 40007ae8: 12 80 00 09 bne 40007b0c 40007aec: 83 32 60 18 srl %o1, 0x18, %g1 _Objects_Are_ids_equal( id, _Thread_Executing->Object.id ) ) { api = _Thread_Executing->API_Extensions[ THREAD_API_RTEMS ]; api->Notepads[ notepad ] = note; 40007af0: 03 10 00 78 sethi %hi(0x4001e000), %g1 <== NOT EXECUTED 40007af4: c2 00 62 4c ld [ %g1 + 0x24c ], %g1 ! 4001e24c <_Thread_Executing> <== NOT EXECUTED 40007af8: 85 2e 60 02 sll %i1, 2, %g2 <== NOT EXECUTED 40007afc: c2 00 61 6c ld [ %g1 + 0x16c ], %g1 <== NOT EXECUTED 40007b00: f4 20 40 02 st %i2, [ %g1 + %g2 ] <== NOT EXECUTED 40007b04: 81 c7 e0 08 ret <== NOT EXECUTED 40007b08: 91 e8 20 00 restore %g0, 0, %o0 <== NOT EXECUTED 40007b0c: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40007b10: 80 a0 a0 04 cmp %g2, 4 40007b14: 18 80 00 06 bgu 40007b2c 40007b18: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40007b1c: 83 32 60 1b srl %o1, 0x1b, %g1 40007b20: 80 a0 60 01 cmp %g1, 1 40007b24: 02 80 00 05 be 40007b38 40007b28: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40007b2c: 90 10 20 00 clr %o0 40007b30: 10 80 00 0e b 40007b68 40007b34: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40007b38: 83 28 a0 02 sll %g2, 2, %g1 40007b3c: 05 10 00 78 sethi %hi(0x4001e000), %g2 40007b40: 84 10 a0 d0 or %g2, 0xd0, %g2 ! 4001e0d0 <_Objects_Information_table> 40007b44: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40007b48: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40007b4c: 80 a2 20 00 cmp %o0, 0 40007b50: 12 80 00 04 bne 40007b60 40007b54: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40007b58: 10 80 00 04 b 40007b68 <== NOT EXECUTED 40007b5c: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40007b60: 40 00 06 74 call 40009530 <_Objects_Get> 40007b64: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_SUCCESSFUL; } the_thread = _Thread_Get( id, &location ); switch ( location ) { 40007b68: c2 07 bf f4 ld [ %fp + -12 ], %g1 40007b6c: 80 a0 60 00 cmp %g1, 0 40007b70: 22 80 00 07 be,a 40007b8c 40007b74: c4 02 21 6c ld [ %o0 + 0x16c ], %g2 40007b78: 80 a0 60 02 cmp %g1, 2 40007b7c: 08 80 00 11 bleu 40007bc0 40007b80: b0 10 20 04 mov 4, %i0 40007b84: 81 c7 e0 08 ret <== NOT EXECUTED 40007b88: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: api = the_thread->API_Extensions[ THREAD_API_RTEMS ]; api->Notepads[ notepad ] = note; 40007b8c: 83 2e 60 02 sll %i1, 2, %g1 40007b90: f4 20 80 01 st %i2, [ %g2 + %g1 ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40007b94: 05 10 00 78 sethi %hi(0x4001e000), %g2 40007b98: c2 00 a1 70 ld [ %g2 + 0x170 ], %g1 ! 4001e170 <_Thread_Dispatch_disable_level> 40007b9c: b0 10 20 00 clr %i0 40007ba0: 82 00 7f ff add %g1, -1, %g1 40007ba4: c2 20 a1 70 st %g1, [ %g2 + 0x170 ] 40007ba8: c2 00 a1 70 ld [ %g2 + 0x170 ], %g1 40007bac: 80 a0 60 00 cmp %g1, 0 40007bb0: 12 80 00 04 bne 40007bc0 40007bb4: 01 00 00 00 nop _Thread_Dispatch(); 40007bb8: 40 00 0b 13 call 4000a804 <_Thread_Dispatch> 40007bbc: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40007bc0: 81 c7 e0 08 ret 40007bc4: 81 e8 00 00 restore 4000a61c : rtems_status_code rtems_task_set_priority( Objects_Id id, rtems_task_priority new_priority, rtems_task_priority *old_priority ) { 4000a61c: 9d e3 bf 90 save %sp, -112, %sp register Thread_Control *the_thread; Objects_Locations location; if ( new_priority != RTEMS_CURRENT_PRIORITY && 4000a620: 80 a6 60 00 cmp %i1, 0 4000a624: 02 80 00 06 be 4000a63c 4000a628: 92 10 00 18 mov %i0, %o1 4000a62c: 82 06 7f ff add %i1, -1, %g1 4000a630: 80 a0 60 fe cmp %g1, 0xfe 4000a634: 18 80 00 49 bgu 4000a758 4000a638: b0 10 20 13 mov 0x13, %i0 !_RTEMS_tasks_Priority_is_valid( new_priority ) ) return RTEMS_INVALID_PRIORITY; if ( !old_priority ) 4000a63c: 80 a6 a0 00 cmp %i2, 0 4000a640: 02 80 00 46 be 4000a758 4000a644: b0 10 20 09 mov 9, %i0 uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 4000a648: 80 a2 60 00 cmp %o1, 0 4000a64c: 12 80 00 0a bne 4000a674 4000a650: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 4000a654: 03 10 00 9d sethi %hi(0x40027400), %g1 4000a658: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 400276f0 <_Thread_Dispatch_disable_level> 4000a65c: 84 00 a0 01 inc %g2 4000a660: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 4000a664: 03 10 00 9d sethi %hi(0x40027400), %g1 4000a668: d0 00 63 cc ld [ %g1 + 0x3cc ], %o0 ! 400277cc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 4000a66c: 10 80 00 19 b 4000a6d0 4000a670: c0 27 bf f4 clr [ %fp + -12 ] 4000a674: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 4000a678: 80 a0 a0 04 cmp %g2, 4 4000a67c: 18 80 00 06 bgu 4000a694 4000a680: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 4000a684: 83 32 60 1b srl %o1, 0x1b, %g1 4000a688: 80 a0 60 01 cmp %g1, 1 4000a68c: 02 80 00 05 be 4000a6a0 4000a690: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 4000a694: 90 10 20 00 clr %o0 4000a698: 10 80 00 0e b 4000a6d0 4000a69c: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 4000a6a0: 83 28 a0 02 sll %g2, 2, %g1 4000a6a4: 05 10 00 9d sethi %hi(0x40027400), %g2 4000a6a8: 84 10 a2 50 or %g2, 0x250, %g2 ! 40027650 <_Objects_Information_table> 4000a6ac: c2 00 80 01 ld [ %g2 + %g1 ], %g1 4000a6b0: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 4000a6b4: 80 a2 20 00 cmp %o0, 0 4000a6b8: 12 80 00 04 bne 4000a6c8 4000a6bc: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 4000a6c0: 10 80 00 04 b 4000a6d0 <== NOT EXECUTED 4000a6c4: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 4000a6c8: 40 00 06 16 call 4000bf20 <_Objects_Get> 4000a6cc: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get( id, &location ); switch ( location ) { 4000a6d0: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000a6d4: 80 a0 60 00 cmp %g1, 0 4000a6d8: 22 80 00 07 be,a 4000a6f4 4000a6dc: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 4000a6e0: 80 a0 60 02 cmp %g1, 2 4000a6e4: 08 80 00 1d bleu 4000a758 4000a6e8: b0 10 20 04 mov 4, %i0 4000a6ec: 81 c7 e0 08 ret <== NOT EXECUTED 4000a6f0: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED return RTEMS_INVALID_ID; case OBJECTS_LOCAL: /* XXX convert from core priority */ *old_priority = the_thread->current_priority; if ( new_priority != RTEMS_CURRENT_PRIORITY ) { 4000a6f4: 80 a6 60 00 cmp %i1, 0 4000a6f8: 02 80 00 0d be 4000a72c 4000a6fc: c2 26 80 00 st %g1, [ %i2 ] the_thread->real_priority = new_priority; if ( the_thread->resource_count == 0 || 4000a700: c2 02 20 1c ld [ %o0 + 0x1c ], %g1 4000a704: 80 a0 60 00 cmp %g1, 0 4000a708: 02 80 00 06 be 4000a720 4000a70c: f2 22 20 18 st %i1, [ %o0 + 0x18 ] 4000a710: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 4000a714: 80 a0 40 19 cmp %g1, %i1 4000a718: 08 80 00 05 bleu 4000a72c 4000a71c: 01 00 00 00 nop the_thread->current_priority > new_priority ) _Thread_Change_priority( the_thread, new_priority, FALSE ); 4000a720: 92 10 00 19 mov %i1, %o1 4000a724: 40 00 09 c7 call 4000ce40 <_Thread_Change_priority> 4000a728: 94 10 20 00 clr %o2 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 4000a72c: 03 10 00 9d sethi %hi(0x40027400), %g1 4000a730: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 400276f0 <_Thread_Dispatch_disable_level> 4000a734: b0 10 20 00 clr %i0 4000a738: 84 00 bf ff add %g2, -1, %g2 4000a73c: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] 4000a740: c2 00 62 f0 ld [ %g1 + 0x2f0 ], %g1 4000a744: 80 a0 60 00 cmp %g1, 0 4000a748: 12 80 00 04 bne 4000a758 4000a74c: 01 00 00 00 nop _Thread_Dispatch(); 4000a750: 40 00 0a e8 call 4000d2f0 <_Thread_Dispatch> 4000a754: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4000a758: 81 c7 e0 08 ret 4000a75c: 81 e8 00 00 restore 40006104 : rtems_status_code rtems_task_start( rtems_id id, rtems_task_entry entry_point, rtems_task_argument argument ) { 40006104: 9d e3 bf 90 save %sp, -112, %sp 40006108: 92 10 00 18 mov %i0, %o1 register Thread_Control *the_thread; Objects_Locations location; if ( entry_point == NULL ) 4000610c: 80 a6 60 00 cmp %i1, 0 40006110: 02 80 00 36 be 400061e8 40006114: b0 10 20 09 mov 9, %i0 uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40006118: 80 a2 60 00 cmp %o1, 0 4000611c: 12 80 00 0a bne 40006144 40006120: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40006124: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006128: c4 00 62 f0 ld [ %g1 + 0x2f0 ], %g2 ! 40018ef0 <_Thread_Dispatch_disable_level> 4000612c: 84 00 a0 01 inc %g2 40006130: c4 20 62 f0 st %g2, [ %g1 + 0x2f0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40006134: 03 10 00 63 sethi %hi(0x40018c00), %g1 40006138: d0 00 63 cc ld [ %g1 + 0x3cc ], %o0 ! 40018fcc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 4000613c: 10 80 00 19 b 400061a0 40006140: c0 27 bf f4 clr [ %fp + -12 ] 40006144: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40006148: 80 a0 a0 04 cmp %g2, 4 4000614c: 18 80 00 06 bgu 40006164 40006150: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40006154: 83 32 60 1b srl %o1, 0x1b, %g1 40006158: 80 a0 60 01 cmp %g1, 1 4000615c: 02 80 00 05 be 40006170 40006160: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40006164: 90 10 20 00 clr %o0 40006168: 10 80 00 0e b 400061a0 4000616c: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40006170: 83 28 a0 02 sll %g2, 2, %g1 40006174: 05 10 00 63 sethi %hi(0x40018c00), %g2 40006178: 84 10 a2 50 or %g2, 0x250, %g2 ! 40018e50 <_Objects_Information_table> 4000617c: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40006180: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40006184: 80 a2 20 00 cmp %o0, 0 40006188: 12 80 00 04 bne 40006198 4000618c: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40006190: 10 80 00 04 b 400061a0 <== NOT EXECUTED 40006194: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40006198: 40 00 05 4b call 400076c4 <_Objects_Get> 4000619c: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get( id, &location ); switch ( location ) { 400061a0: c2 07 bf f4 ld [ %fp + -12 ], %g1 400061a4: 80 a0 60 00 cmp %g1, 0 400061a8: 22 80 00 07 be,a 400061c4 400061ac: 94 10 00 19 mov %i1, %o2 400061b0: 80 a0 60 02 cmp %g1, 2 400061b4: 08 80 00 0d bleu 400061e8 400061b8: b0 10 20 04 mov 4, %i0 400061bc: 81 c7 e0 08 ret <== NOT EXECUTED 400061c0: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( _Thread_Start( 400061c4: 98 10 00 1a mov %i2, %o4 400061c8: 92 10 20 00 clr %o1 400061cc: 40 00 0d d8 call 4000992c <_Thread_Start> 400061d0: 96 10 20 00 clr %o3 400061d4: 80 a2 20 00 cmp %o0, 0 400061d8: 02 80 00 06 be 400061f0 400061dc: 01 00 00 00 nop the_thread, THREAD_START_NUMERIC, entry_point, NULL, argument ) ) { _Thread_Enable_dispatch(); 400061e0: 7f ff ff bc call 400060d0 <_Thread_Enable_dispatch> 400061e4: b0 10 20 00 clr %i0 ! 0 400061e8: 81 c7 e0 08 ret 400061ec: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 400061f0: 7f ff ff b8 call 400060d0 <_Thread_Enable_dispatch> 400061f4: b0 10 20 0e mov 0xe, %i0 return RTEMS_INCORRECT_STATE; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400061f8: 81 c7 e0 08 ret 400061fc: 81 e8 00 00 restore 400078b8 : */ rtems_status_code rtems_task_suspend( Objects_Id id ) { 400078b8: 9d e3 bf 90 save %sp, -112, %sp uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 400078bc: 92 96 20 00 orcc %i0, 0, %o1 400078c0: 12 80 00 0a bne 400078e8 400078c4: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400078c8: 03 10 00 95 sethi %hi(0x40025400), %g1 400078cc: c4 00 60 00 ld [ %g1 ], %g2 400078d0: 84 00 a0 01 inc %g2 400078d4: c4 20 60 00 st %g2, [ %g1 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 400078d8: 03 10 00 95 sethi %hi(0x40025400), %g1 400078dc: d0 00 60 dc ld [ %g1 + 0xdc ], %o0 ! 400254dc <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 400078e0: 10 80 00 19 b 40007944 400078e4: c0 27 bf f4 clr [ %fp + -12 ] 400078e8: 84 08 60 07 and %g1, 7, %g2 tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 400078ec: 80 a0 a0 04 cmp %g2, 4 400078f0: 18 80 00 06 bgu 40007908 400078f4: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 400078f8: 83 32 60 1b srl %o1, 0x1b, %g1 400078fc: 80 a0 60 01 cmp %g1, 1 40007900: 02 80 00 05 be 40007914 40007904: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40007908: 90 10 20 00 clr %o0 4000790c: 10 80 00 0e b 40007944 40007910: c2 27 bf f4 st %g1, [ %fp + -12 ] goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40007914: 83 28 a0 02 sll %g2, 2, %g1 40007918: 05 10 00 94 sethi %hi(0x40025000), %g2 4000791c: 84 10 a3 60 or %g2, 0x360, %g2 ! 40025360 <_Objects_Information_table> 40007920: c2 00 80 01 ld [ %g2 + %g1 ], %g1 40007924: d0 00 60 04 ld [ %g1 + 4 ], %o0 if ( !information ) { 40007928: 80 a2 20 00 cmp %o0, 0 4000792c: 12 80 00 04 bne 4000793c 40007930: 82 10 20 02 mov 2, %g1 *location = OBJECTS_ERROR; 40007934: 10 80 00 04 b 40007944 <== NOT EXECUTED 40007938: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 4000793c: 40 00 06 40 call 4000923c <_Objects_Get> 40007940: 94 07 bf f4 add %fp, -12, %o2 register Thread_Control *the_thread; Objects_Locations location; the_thread = _Thread_Get( id, &location ); switch ( location ) { 40007944: c2 07 bf f4 ld [ %fp + -12 ], %g1 40007948: 80 a0 60 00 cmp %g1, 0 4000794c: 22 80 00 07 be,a 40007968 40007950: c2 02 20 10 ld [ %o0 + 0x10 ], %g1 40007954: 80 a0 60 02 cmp %g1, 2 40007958: 08 80 00 0b bleu 40007984 4000795c: b0 10 20 04 mov 4, %i0 40007960: 81 c7 e0 08 ret <== NOT EXECUTED 40007964: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: if ( !_States_Is_suspended( the_thread->current_state ) ) { 40007968: 80 88 60 02 btst 2, %g1 4000796c: 12 80 00 08 bne 4000798c 40007970: 01 00 00 00 nop _Thread_Suspend( the_thread ); 40007974: 40 00 0e f5 call 4000b548 <_Thread_Suspend> 40007978: b0 10 20 00 clr %i0 ! 0 _Thread_Enable_dispatch(); 4000797c: 7f ff ff c2 call 40007884 <_Thread_Enable_dispatch> 40007980: 01 00 00 00 nop 40007984: 81 c7 e0 08 ret 40007988: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } _Thread_Enable_dispatch(); 4000798c: 7f ff ff be call 40007884 <_Thread_Enable_dispatch> 40007990: b0 10 20 0f mov 0xf, %i0 return RTEMS_ALREADY_SUSPENDED; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40007994: 81 c7 e0 08 ret 40007998: 81 e8 00 00 restore 40018124 : rtems_status_code rtems_task_variable_add( rtems_id tid, void **ptr, void (*dtor)(void *) ) { 40018124: 9d e3 bf 90 save %sp, -112, %sp 40018128: 92 10 00 18 mov %i0, %o1 Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *new; if ( !ptr ) 4001812c: 80 a6 60 00 cmp %i1, 0 40018130: 02 80 00 32 be 400181f8 40018134: b0 10 20 09 mov 9, %i0 uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40018138: 80 a2 60 00 cmp %o1, 0 4001813c: 12 80 00 0a bne 40018164 40018140: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40018144: 03 10 00 e5 sethi %hi(0x40039400), %g1 40018148: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 400397b0 <_Thread_Dispatch_disable_level> 4001814c: 84 00 a0 01 inc %g2 40018150: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40018154: 03 10 00 e6 sethi %hi(0x40039800), %g1 40018158: f0 00 60 8c ld [ %g1 + 0x8c ], %i0 ! 4003988c <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 4001815c: 10 80 00 18 b 400181bc 40018160: c0 27 bf f4 clr [ %fp + -12 ] 40018164: 84 08 60 07 and %g1, 7, %g2 <== NOT EXECUTED tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 40018168: 80 a0 a0 04 cmp %g2, 4 <== NOT EXECUTED 4001816c: 18 80 00 0e bgu 400181a4 <== NOT EXECUTED 40018170: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40018174: 83 32 60 1b srl %o1, 0x1b, %g1 <== NOT EXECUTED 40018178: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 4001817c: 12 80 00 0a bne 400181a4 <== NOT EXECUTED 40018180: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40018184: 83 28 a0 02 sll %g2, 2, %g1 <== NOT EXECUTED 40018188: 05 10 00 e5 sethi %hi(0x40039400), %g2 <== NOT EXECUTED 4001818c: 84 10 a3 10 or %g2, 0x310, %g2 ! 40039710 <_Objects_Information_table> <== NOT EXECUTED 40018190: c2 00 80 01 ld [ %g2 + %g1 ], %g1 <== NOT EXECUTED 40018194: d0 00 60 04 ld [ %g1 + 4 ], %o0 <== NOT EXECUTED if ( !information ) { 40018198: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 4001819c: 12 80 00 05 bne 400181b0 <== NOT EXECUTED 400181a0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; 400181a4: b0 10 20 00 clr %i0 <== NOT EXECUTED 400181a8: 10 80 00 05 b 400181bc <== NOT EXECUTED 400181ac: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 400181b0: 7f ff ca e4 call 4000ad40 <_Objects_Get> <== NOT EXECUTED 400181b4: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED 400181b8: b0 10 00 08 mov %o0, %i0 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); switch (location) { 400181bc: c2 07 bf f4 ld [ %fp + -12 ], %g1 400181c0: 80 a0 60 00 cmp %g1, 0 400181c4: 22 80 00 0f be,a 40018200 400181c8: c4 06 21 7c ld [ %i0 + 0x17c ], %g2 400181cc: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 400181d0: 08 80 00 0a bleu 400181f8 <== NOT EXECUTED 400181d4: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED 400181d8: 81 c7 e0 08 ret <== NOT EXECUTED 400181dc: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED * Figure out if the variable is already in this task's list. */ tvp = the_thread->task_variables; while (tvp) { if (tvp->ptr == ptr) { 400181e0: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED 400181e4: 32 80 00 07 bne,a 40018200 <== NOT EXECUTED 400181e8: c4 00 80 00 ld [ %g2 ], %g2 <== NOT EXECUTED tvp->dtor = dtor; 400181ec: f4 20 a0 10 st %i2, [ %g2 + 0x10 ] <== NOT EXECUTED _Thread_Enable_dispatch(); 400181f0: 7f ff ff c0 call 400180f0 <_Thread_Enable_dispatch> <== NOT EXECUTED 400181f4: b0 10 20 00 clr %i0 <== NOT EXECUTED 400181f8: 81 c7 e0 08 ret <== NOT EXECUTED 400181fc: 81 e8 00 00 restore <== NOT EXECUTED /* * Figure out if the variable is already in this task's list. */ tvp = the_thread->task_variables; while (tvp) { 40018200: 80 a0 a0 00 cmp %g2, 0 40018204: 32 bf ff f7 bne,a 400181e0 40018208: c2 00 a0 04 ld [ %g2 + 4 ], %g1 <== NOT EXECUTED 4001820c: 11 10 00 e5 sethi %hi(0x40039400), %o0 40018210: 92 10 20 14 mov 0x14, %o1 40018214: 7f ff c8 2f call 4000a2d0 <_Heap_Allocate> 40018218: 90 12 23 fc or %o0, 0x3fc, %o0 * Now allocate memory for this task variable. */ new = (rtems_task_variable_t *) _Workspace_Allocate(sizeof(rtems_task_variable_t)); if (new == NULL) { 4001821c: 80 a2 20 00 cmp %o0, 0 40018220: 32 80 00 06 bne,a 40018238 40018224: c4 06 21 7c ld [ %i0 + 0x17c ], %g2 _Thread_Enable_dispatch(); 40018228: 7f ff ff b2 call 400180f0 <_Thread_Enable_dispatch> <== NOT EXECUTED 4001822c: b0 10 20 1a mov 0x1a, %i0 <== NOT EXECUTED 40018230: 81 c7 e0 08 ret <== NOT EXECUTED 40018234: 81 e8 00 00 restore <== NOT EXECUTED return RTEMS_NO_MEMORY; } new->gval = *ptr; 40018238: c2 06 40 00 ld [ %i1 ], %g1 new->ptr = ptr; new->dtor = dtor; new->next = (struct rtems_task_variable_tt *)the_thread->task_variables; the_thread->task_variables = new; 4001823c: d0 26 21 7c st %o0, [ %i0 + 0x17c ] _Workspace_Allocate(sizeof(rtems_task_variable_t)); if (new == NULL) { _Thread_Enable_dispatch(); return RTEMS_NO_MEMORY; } new->gval = *ptr; 40018240: c2 22 20 08 st %g1, [ %o0 + 8 ] new->ptr = ptr; 40018244: f2 22 20 04 st %i1, [ %o0 + 4 ] new->dtor = dtor; 40018248: f4 22 20 10 st %i2, [ %o0 + 0x10 ] new->next = (struct rtems_task_variable_tt *)the_thread->task_variables; 4001824c: c4 22 00 00 st %g2, [ %o0 ] the_thread->task_variables = new; _Thread_Enable_dispatch(); 40018250: 7f ff ff a8 call 400180f0 <_Thread_Enable_dispatch> 40018254: b0 10 20 00 clr %i0 return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40018258: 81 c7 e0 08 ret 4001825c: 81 e8 00 00 restore 40018294 : rtems_status_code rtems_task_variable_delete( rtems_id tid, void **ptr ) { 40018294: 9d e3 bf 90 save %sp, -112, %sp 40018298: 92 10 00 18 mov %i0, %o1 Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp, *prev; if ( !ptr ) 4001829c: 80 a6 60 00 cmp %i1, 0 400182a0: 02 80 00 52 be 400183e8 400182a4: b0 10 20 09 mov 9, %i0 uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 400182a8: 80 a2 60 00 cmp %o1, 0 400182ac: 12 80 00 0a bne 400182d4 400182b0: 83 32 60 18 srl %o1, 0x18, %g1 rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 400182b4: 03 10 00 e5 sethi %hi(0x40039400), %g1 400182b8: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 400397b0 <_Thread_Dispatch_disable_level> 400182bc: 84 00 a0 01 inc %g2 400182c0: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ] Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 400182c4: 03 10 00 e6 sethi %hi(0x40039800), %g1 400182c8: d0 00 60 8c ld [ %g1 + 0x8c ], %o0 ! 4003988c <_Thread_Executing> Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 400182cc: 10 80 00 19 b 40018330 400182d0: c0 27 bf f4 clr [ %fp + -12 ] 400182d4: 84 08 60 07 and %g1, 7, %g2 <== NOT EXECUTED tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 400182d8: 80 a0 a0 04 cmp %g2, 4 <== NOT EXECUTED 400182dc: 18 80 00 06 bgu 400182f4 <== NOT EXECUTED 400182e0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 400182e4: 83 32 60 1b srl %o1, 0x1b, %g1 <== NOT EXECUTED 400182e8: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400182ec: 02 80 00 05 be 40018300 <== NOT EXECUTED 400182f0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; 400182f4: 90 10 20 00 clr %o0 <== NOT EXECUTED 400182f8: 10 80 00 0e b 40018330 <== NOT EXECUTED 400182fc: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 40018300: 83 28 a0 02 sll %g2, 2, %g1 <== NOT EXECUTED 40018304: 05 10 00 e5 sethi %hi(0x40039400), %g2 <== NOT EXECUTED 40018308: 84 10 a3 10 or %g2, 0x310, %g2 ! 40039710 <_Objects_Information_table> <== NOT EXECUTED 4001830c: c2 00 80 01 ld [ %g2 + %g1 ], %g1 <== NOT EXECUTED 40018310: d0 00 60 04 ld [ %g1 + 4 ], %o0 <== NOT EXECUTED if ( !information ) { 40018314: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 40018318: 12 80 00 04 bne 40018328 <== NOT EXECUTED 4001831c: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; 40018320: 10 80 00 04 b 40018330 <== NOT EXECUTED 40018324: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 40018328: 7f ff ca 86 call 4000ad40 <_Objects_Get> <== NOT EXECUTED 4001832c: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; prev = NULL; the_thread = _Thread_Get (tid, &location); switch (location) { 40018330: c2 07 bf f4 ld [ %fp + -12 ], %g1 40018334: 80 a0 60 00 cmp %g1, 0 40018338: 22 80 00 07 be,a 40018354 4001833c: f0 02 21 7c ld [ %o0 + 0x17c ], %i0 40018340: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 40018344: 08 80 00 29 bleu 400183e8 <== NOT EXECUTED 40018348: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED 4001834c: 81 c7 e0 08 ret <== NOT EXECUTED 40018350: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED default: return RTEMS_INTERNAL_ERROR; case OBJECTS_LOCAL: tvp = the_thread->task_variables; 40018354: 10 80 00 28 b 400183f4 40018358: 84 10 20 00 clr %g2 while (tvp) { if (tvp->ptr == ptr) { 4001835c: 80 a0 40 19 cmp %g1, %i1 40018360: 32 80 00 24 bne,a 400183f0 40018364: 84 10 00 18 mov %i0, %g2 <== NOT EXECUTED if (prev) 40018368: 80 a0 a0 00 cmp %g2, 0 4001836c: 02 80 00 04 be 4001837c 40018370: c2 06 00 00 ld [ %i0 ], %g1 prev->next = tvp->next; 40018374: 10 80 00 03 b 40018380 <== NOT EXECUTED 40018378: c2 20 80 00 st %g1, [ %g2 ] <== NOT EXECUTED else the_thread->task_variables = (rtems_task_variable_t *)tvp->next; 4001837c: c2 22 21 7c st %g1, [ %o0 + 0x17c ] if (_Thread_Is_executing(the_thread)) { 40018380: 03 10 00 e6 sethi %hi(0x40039800), %g1 40018384: c2 00 60 8c ld [ %g1 + 0x8c ], %g1 ! 4003988c <_Thread_Executing> 40018388: 80 a2 00 01 cmp %o0, %g1 4001838c: 12 80 00 0c bne 400183bc 40018390: c4 06 20 10 ld [ %i0 + 0x10 ], %g2 if (tvp->dtor) 40018394: 80 a0 a0 00 cmp %g2, 0 40018398: 22 80 00 06 be,a 400183b0 4001839c: c4 06 20 04 ld [ %i0 + 4 ], %g2 (*tvp->dtor)(*tvp->ptr); 400183a0: c2 06 20 04 ld [ %i0 + 4 ], %g1 <== NOT EXECUTED 400183a4: 9f c0 80 00 call %g2 <== NOT EXECUTED 400183a8: d0 00 40 00 ld [ %g1 ], %o0 <== NOT EXECUTED *tvp->ptr = tvp->gval; 400183ac: c4 06 20 04 ld [ %i0 + 4 ], %g2 <== NOT EXECUTED 400183b0: c2 06 20 08 ld [ %i0 + 8 ], %g1 400183b4: 10 80 00 07 b 400183d0 400183b8: c2 20 80 00 st %g1, [ %g2 ] } else { if (tvp->dtor) 400183bc: 80 a0 a0 00 cmp %g2, 0 <== NOT EXECUTED 400183c0: 02 80 00 05 be 400183d4 <== NOT EXECUTED 400183c4: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED (*tvp->dtor)(tvp->tval); 400183c8: 9f c0 80 00 call %g2 <== NOT EXECUTED 400183cc: d0 06 20 0c ld [ %i0 + 0xc ], %o0 <== NOT EXECUTED RTEMS_INLINE_ROUTINE boolean _Workspace_Free( void *block ) { return _Heap_Free( &_Workspace_Area, block ); 400183d0: 92 10 00 18 mov %i0, %o1 400183d4: 11 10 00 e5 sethi %hi(0x40039400), %o0 400183d8: 7f ff c7 e5 call 4000a36c <_Heap_Free> 400183dc: 90 12 23 fc or %o0, 0x3fc, %o0 ! 400397fc <_Workspace_Area> } _Workspace_Free(tvp); _Thread_Enable_dispatch(); 400183e0: 7f ff ff a0 call 40018260 <_Thread_Enable_dispatch> 400183e4: b0 10 20 00 clr %i0 400183e8: 81 c7 e0 08 ret 400183ec: 81 e8 00 00 restore return RTEMS_SUCCESSFUL; } prev = tvp; tvp = (rtems_task_variable_t *)tvp->next; 400183f0: f0 06 00 00 ld [ %i0 ], %i0 <== NOT EXECUTED default: return RTEMS_INTERNAL_ERROR; case OBJECTS_LOCAL: tvp = the_thread->task_variables; while (tvp) { 400183f4: 80 a6 20 00 cmp %i0, 0 400183f8: 32 bf ff d9 bne,a 4001835c 400183fc: c2 06 20 04 ld [ %i0 + 4 ], %g1 return RTEMS_SUCCESSFUL; } prev = tvp; tvp = (rtems_task_variable_t *)tvp->next; } _Thread_Enable_dispatch(); 40018400: 7f ff ff 98 call 40018260 <_Thread_Enable_dispatch> <== NOT EXECUTED 40018404: b0 10 20 09 mov 9, %i0 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40018408: 81 c7 e0 08 ret <== NOT EXECUTED 4001840c: 81 e8 00 00 restore <== NOT EXECUTED 40018444 : rtems_status_code rtems_task_variable_get( rtems_id tid, void **ptr, void **result ) { 40018444: 9d e3 bf 90 save %sp, -112, %sp <== NOT EXECUTED Thread_Control *the_thread; Objects_Locations location; rtems_task_variable_t *tvp; if ( !ptr ) 40018448: 80 a6 60 00 cmp %i1, 0 <== NOT EXECUTED 4001844c: 02 80 00 3f be 40018548 <== NOT EXECUTED 40018450: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; if ( !result ) 40018454: 80 a6 a0 00 cmp %i2, 0 <== NOT EXECUTED 40018458: 02 80 00 3c be 40018548 <== NOT EXECUTED 4001845c: 80 a6 20 00 cmp %i0, 0 <== NOT EXECUTED uint32_t the_api; uint32_t the_class; Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { 40018460: 12 80 00 0a bne 40018488 <== NOT EXECUTED 40018464: 83 36 20 18 srl %i0, 0x18, %g1 <== NOT EXECUTED rtems_fatal_error_occurred( 99 ); } } #endif _Thread_Dispatch_disable_level += 1; 40018468: 03 10 00 e5 sethi %hi(0x40039400), %g1 <== NOT EXECUTED 4001846c: c4 00 63 b0 ld [ %g1 + 0x3b0 ], %g2 ! 400397b0 <_Thread_Dispatch_disable_level> <== NOT EXECUTED 40018470: 84 00 a0 01 inc %g2 <== NOT EXECUTED 40018474: c4 20 63 b0 st %g2, [ %g1 + 0x3b0 ] <== NOT EXECUTED Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; tp = _Thread_Executing; 40018478: 03 10 00 e6 sethi %hi(0x40039800), %g1 <== NOT EXECUTED 4001847c: d0 00 60 8c ld [ %g1 + 0x8c ], %o0 ! 4003988c <_Thread_Executing> <== NOT EXECUTED Objects_Information *information; Thread_Control *tp = (Thread_Control *) 0; if ( _Objects_Are_ids_equal( id, OBJECTS_ID_OF_SELF ) ) { _Thread_Disable_dispatch(); *location = OBJECTS_LOCAL; 40018480: 10 80 00 19 b 400184e4 <== NOT EXECUTED 40018484: c0 27 bf f4 clr [ %fp + -12 ] <== NOT EXECUTED 40018488: 84 08 60 07 and %g1, 7, %g2 <== NOT EXECUTED tp = _Thread_Executing; goto done; } the_api = _Objects_Get_API( id ); if ( the_api && the_api > OBJECTS_APIS_LAST ) { 4001848c: 80 a0 a0 04 cmp %g2, 4 <== NOT EXECUTED 40018490: 18 80 00 06 bgu 400184a8 <== NOT EXECUTED 40018494: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; goto done; } the_class = _Objects_Get_class( id ); if ( the_class != 1 ) { /* threads are always first class :) */ 40018498: 83 36 20 1b srl %i0, 0x1b, %g1 <== NOT EXECUTED 4001849c: 80 a0 60 01 cmp %g1, 1 <== NOT EXECUTED 400184a0: 02 80 00 05 be 400184b4 <== NOT EXECUTED 400184a4: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; 400184a8: 90 10 20 00 clr %o0 <== NOT EXECUTED 400184ac: 10 80 00 0e b 400184e4 <== NOT EXECUTED 400184b0: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } information = _Objects_Information_table[ the_api ][ the_class ]; 400184b4: 83 28 a0 02 sll %g2, 2, %g1 <== NOT EXECUTED 400184b8: 05 10 00 e5 sethi %hi(0x40039400), %g2 <== NOT EXECUTED 400184bc: 84 10 a3 10 or %g2, 0x310, %g2 ! 40039710 <_Objects_Information_table> <== NOT EXECUTED 400184c0: c2 00 80 01 ld [ %g2 + %g1 ], %g1 <== NOT EXECUTED 400184c4: d0 00 60 04 ld [ %g1 + 4 ], %o0 <== NOT EXECUTED if ( !information ) { 400184c8: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 400184cc: 12 80 00 04 bne 400184dc <== NOT EXECUTED 400184d0: 82 10 20 02 mov 2, %g1 <== NOT EXECUTED *location = OBJECTS_ERROR; 400184d4: 10 80 00 04 b 400184e4 <== NOT EXECUTED 400184d8: c2 27 bf f4 st %g1, [ %fp + -12 ] <== NOT EXECUTED goto done; } tp = (Thread_Control *) _Objects_Get( information, id, location ); 400184dc: 7f ff ca 19 call 4000ad40 <_Objects_Get> <== NOT EXECUTED 400184e0: 94 07 bf f4 add %fp, -12, %o2 <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; the_thread = _Thread_Get (tid, &location); switch (location) { 400184e4: c2 07 bf f4 ld [ %fp + -12 ], %g1 <== NOT EXECUTED 400184e8: 80 a0 60 00 cmp %g1, 0 <== NOT EXECUTED 400184ec: 22 80 00 10 be,a 4001852c <== NOT EXECUTED 400184f0: d0 02 21 7c ld [ %o0 + 0x17c ], %o0 <== NOT EXECUTED 400184f4: 80 a0 60 02 cmp %g1, 2 <== NOT EXECUTED 400184f8: 08 80 00 0b bleu 40018524 <== NOT EXECUTED 400184fc: b0 10 20 04 mov 4, %i0 <== NOT EXECUTED 40018500: 81 c7 e0 08 ret <== NOT EXECUTED 40018504: 91 e8 20 19 restore %g0, 0x19, %o0 <== NOT EXECUTED * Figure out if the variable is in this task's list. */ tvp = the_thread->task_variables; while (tvp) { if (tvp->ptr == ptr) { 40018508: 80 a0 40 19 cmp %g1, %i1 <== NOT EXECUTED 4001850c: 32 80 00 08 bne,a 4001852c <== NOT EXECUTED 40018510: d0 02 00 00 ld [ %o0 ], %o0 <== NOT EXECUTED /* * Should this return the current (i.e not the * saved) value if `tid' is the current task? */ *result = tvp->tval; 40018514: c2 02 20 0c ld [ %o0 + 0xc ], %g1 <== NOT EXECUTED _Thread_Enable_dispatch(); 40018518: b0 10 20 00 clr %i0 <== NOT EXECUTED 4001851c: 7f ff ff bd call 40018410 <_Thread_Enable_dispatch> <== NOT EXECUTED 40018520: c2 26 80 00 st %g1, [ %i2 ] <== NOT EXECUTED 40018524: 81 c7 e0 08 ret <== NOT EXECUTED 40018528: 81 e8 00 00 restore <== NOT EXECUTED /* * Figure out if the variable is in this task's list. */ tvp = the_thread->task_variables; while (tvp) { 4001852c: 80 a2 20 00 cmp %o0, 0 <== NOT EXECUTED 40018530: 32 bf ff f6 bne,a 40018508 <== NOT EXECUTED 40018534: c2 02 20 04 ld [ %o0 + 4 ], %g1 <== NOT EXECUTED _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } tvp = (rtems_task_variable_t *)tvp->next; } _Thread_Enable_dispatch(); 40018538: 7f ff ff b6 call 40018410 <_Thread_Enable_dispatch> <== NOT EXECUTED 4001853c: b0 10 20 09 mov 9, %i0 <== NOT EXECUTED 40018540: 81 c7 e0 08 ret <== NOT EXECUTED 40018544: 81 e8 00 00 restore <== NOT EXECUTED return RTEMS_INVALID_ADDRESS; 40018548: b0 10 20 09 mov 9, %i0 <== NOT EXECUTED } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 4001854c: 81 c7 e0 08 ret <== NOT EXECUTED 40018550: 81 e8 00 00 restore <== NOT EXECUTED 400121ec : */ rtems_status_code rtems_timer_delete( Objects_Id id ) { 400121ec: 9d e3 bf 90 save %sp, -112, %sp RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get ( Objects_Id id, Objects_Locations *location ) { return (Timer_Control *) 400121f0: 21 10 00 c9 sethi %hi(0x40032400), %l0 400121f4: 92 10 00 18 mov %i0, %o1 400121f8: 94 07 bf f4 add %fp, -12, %o2 400121fc: 40 00 09 ec call 400149ac <_Objects_Get> 40012200: 90 14 22 4c or %l0, 0x24c, %o0 Timer_Control *the_timer; Objects_Locations location; the_timer = _Timer_Get( id, &location ); switch ( location ) { 40012204: c2 07 bf f4 ld [ %fp + -12 ], %g1 40012208: 80 a0 60 00 cmp %g1, 0 4001220c: 02 80 00 08 be 4001222c 40012210: b0 10 00 08 mov %o0, %i0 40012214: 82 18 60 02 xor %g1, 2, %g1 40012218: 80 a0 00 01 cmp %g0, %g1 4001221c: 82 60 20 00 subx %g0, 0, %g1 40012220: b0 08 60 15 and %g1, 0x15, %i0 40012224: 81 c7 e0 08 ret 40012228: 91 ee 20 04 restore %i0, 4, %o0 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 4001222c: a0 14 22 4c or %l0, 0x24c, %l0 ) { uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); 40012230: c2 02 20 08 ld [ %o0 + 8 ], %g1 Objects_Information *information, uint16_t index, Objects_Control *the_object ) { if ( index <= information->maximum ) 40012234: c6 14 20 10 lduh [ %l0 + 0x10 ], %g3 40012238: 05 00 00 3f sethi %hi(0xfc00), %g2 4001223c: 84 10 a3 ff or %g2, 0x3ff, %g2 ! ffff 40012240: 82 08 40 02 and %g1, %g2, %g1 40012244: 80 a0 40 03 cmp %g1, %g3 40012248: 38 80 00 06 bgu,a 40012260 4001224c: c0 26 20 0c clr [ %i0 + 0xc ] <== NOT EXECUTED information->local_table[ index ] = the_object; 40012250: c4 04 20 20 ld [ %l0 + 0x20 ], %g2 40012254: 83 28 60 02 sll %g1, 2, %g1 40012258: c0 20 80 01 clr [ %g2 + %g1 ] uint32_t index; index = _Objects_Get_index( the_object->id ); _Objects_Set_local_object( information, index, NULL ); /* _Objects_Clear_name( the_object->name, information->name_length ); */ the_object->name = 0; 4001225c: c0 26 20 0c clr [ %i0 + 0xc ] case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: _Objects_Close( &_Timer_Information, &the_timer->Object ); (void) _Watchdog_Remove( &the_timer->Ticker ); 40012260: 40 00 15 19 call 400176c4 <_Watchdog_Remove> 40012264: 90 06 20 10 add %i0, 0x10, %o0 RTEMS_INLINE_ROUTINE void _Timer_Free ( Timer_Control *the_timer ) { _Objects_Free( &_Timer_Information, &the_timer->Object ); 40012268: 90 10 00 10 mov %l0, %o0 4001226c: 40 00 09 7a call 40014854 <_Objects_Free> 40012270: 92 10 00 18 mov %i0, %o1 #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 40012274: 03 10 00 c8 sethi %hi(0x40032000), %g1 40012278: c4 00 62 e0 ld [ %g1 + 0x2e0 ], %g2 ! 400322e0 <_Thread_Dispatch_disable_level> 4001227c: b0 10 20 00 clr %i0 40012280: 84 00 bf ff add %g2, -1, %g2 40012284: c4 20 62 e0 st %g2, [ %g1 + 0x2e0 ] 40012288: c2 00 62 e0 ld [ %g1 + 0x2e0 ], %g1 4001228c: 80 a0 60 00 cmp %g1, 0 40012290: 12 80 00 04 bne 400122a0 40012294: 01 00 00 00 nop _Thread_Dispatch(); 40012298: 40 00 0e b9 call 40015d7c <_Thread_Dispatch> 4001229c: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400122a0: 81 c7 e0 08 ret 400122a4: 81 e8 00 00 restore 400122dc : Objects_Id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { 400122dc: 9d e3 bf 90 save %sp, -112, %sp 400122e0: a4 10 00 18 mov %i0, %l2 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; if ( ticks == 0 ) 400122e4: 80 a6 60 00 cmp %i1, 0 400122e8: 02 80 00 21 be 4001236c 400122ec: b0 10 20 0a mov 0xa, %i0 return RTEMS_INVALID_NUMBER; if ( !routine ) 400122f0: 80 a6 a0 00 cmp %i2, 0 400122f4: 02 80 00 1e be 4001236c 400122f8: b0 10 20 09 mov 9, %i0 RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get ( Objects_Id id, Objects_Locations *location ) { return (Timer_Control *) 400122fc: 11 10 00 c9 sethi %hi(0x40032400), %o0 40012300: 92 10 00 12 mov %l2, %o1 40012304: 90 12 22 4c or %o0, 0x24c, %o0 40012308: 40 00 09 a9 call 400149ac <_Objects_Get> 4001230c: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_ADDRESS; the_timer = _Timer_Get( id, &location ); switch ( location ) { 40012310: c2 07 bf f4 ld [ %fp + -12 ], %g1 40012314: 80 a0 60 00 cmp %g1, 0 40012318: 02 80 00 08 be 40012338 4001231c: a0 10 00 08 mov %o0, %l0 40012320: 82 18 60 02 xor %g1, 2, %g1 40012324: 80 a0 00 01 cmp %g0, %g1 40012328: 82 60 20 00 subx %g0, 0, %g1 4001232c: b0 08 60 15 and %g1, 0x15, %i0 40012330: 81 c7 e0 08 ret 40012334: 91 ee 20 04 restore %i0, 4, %o0 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: (void) _Watchdog_Remove( &the_timer->Ticker ); 40012338: a2 02 20 10 add %o0, 0x10, %l1 4001233c: 40 00 14 e2 call 400176c4 <_Watchdog_Remove> 40012340: 90 10 00 11 mov %l1, %o0 _ISR_Disable( level ); 40012344: 7f ff e0 f7 call 4000a720 40012348: 01 00 00 00 nop /* * Check to see if the watchdog has just been inserted by a * higher priority interrupt. If so, abandon this insert. */ if ( the_timer->Ticker.state != WATCHDOG_INACTIVE ) { 4001234c: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 40012350: 80 a0 60 00 cmp %g1, 0 40012354: 22 80 00 08 be,a 40012374 40012358: f4 24 20 2c st %i2, [ %l0 + 0x2c ] _ISR_Enable( level ); 4001235c: 7f ff e0 f5 call 4000a730 <== NOT EXECUTED 40012360: b0 10 20 00 clr %i0 <== NOT EXECUTED _Thread_Enable_dispatch(); 40012364: 7f ff ff d1 call 400122a8 <_Thread_Enable_dispatch> <== NOT EXECUTED 40012368: 01 00 00 00 nop <== NOT EXECUTED 4001236c: 81 c7 e0 08 ret 40012370: 81 e8 00 00 restore 40012374: e4 24 20 30 st %l2, [ %l0 + 0x30 ] the_watchdog->user_data = user_data; 40012378: f6 24 20 34 st %i3, [ %l0 + 0x34 ] /* * OK. Now we now the timer was not rescheduled by an interrupt * so we can atomically initialize it as in use. */ the_timer->the_class = TIMER_INTERVAL; 4001237c: c0 24 20 38 clr [ %l0 + 0x38 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40012380: c0 24 20 18 clr [ %l0 + 0x18 ] _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); _ISR_Enable( level ); 40012384: 7f ff e0 eb call 4000a730 40012388: b0 10 20 00 clr %i0 ) { the_watchdog->initial = units; _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 4001238c: 92 10 00 11 mov %l1, %o1 40012390: 11 10 00 c8 sethi %hi(0x40032000), %o0 40012394: 90 12 23 dc or %o0, 0x3dc, %o0 ! 400323dc <_Watchdog_Ticks_chain> 40012398: 40 00 14 73 call 40017564 <_Watchdog_Insert> 4001239c: f2 24 20 1c st %i1, [ %l0 + 0x1c ] _Watchdog_Insert_ticks( &the_timer->Ticker, ticks ); _Thread_Enable_dispatch(); 400123a0: 7f ff ff c2 call 400122a8 <_Thread_Enable_dispatch> 400123a4: 01 00 00 00 nop return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400123a8: 81 c7 e0 08 ret 400123ac: 81 e8 00 00 restore 40008044 : rtems_status_code rtems_timer_get_information( Objects_Id id, rtems_timer_information *the_info ) { 40008044: 9d e3 bf 90 save %sp, -112, %sp 40008048: 92 10 00 18 mov %i0, %o1 Timer_Control *the_timer; Objects_Locations location; if ( !the_info ) 4000804c: 80 a6 60 00 cmp %i1, 0 40008050: 02 80 00 22 be 400080d8 40008054: b0 10 20 09 mov 9, %i0 RTEMS_INLINE_ROUTINE Timer_Control *_Timer_Get ( Objects_Id id, Objects_Locations *location ) { return (Timer_Control *) 40008058: 11 10 00 79 sethi %hi(0x4001e400), %o0 4000805c: 94 07 bf f4 add %fp, -12, %o2 40008060: 40 00 07 3f call 40009d5c <_Objects_Get> 40008064: 90 12 22 14 or %o0, 0x214, %o0 return RTEMS_INVALID_ADDRESS; the_timer = _Timer_Get( id, &location ); switch ( location ) { 40008068: c2 07 bf f4 ld [ %fp + -12 ], %g1 4000806c: 80 a0 60 00 cmp %g1, 0 40008070: 22 80 00 08 be,a 40008090 40008074: c2 02 20 1c ld [ %o0 + 0x1c ], %g1 40008078: 82 18 60 02 xor %g1, 2, %g1 <== NOT EXECUTED 4000807c: 80 a0 00 01 cmp %g0, %g1 <== NOT EXECUTED 40008080: 82 60 20 00 subx %g0, 0, %g1 <== NOT EXECUTED 40008084: b0 08 60 15 and %g1, 0x15, %i0 <== NOT EXECUTED 40008088: 81 c7 e0 08 ret <== NOT EXECUTED 4000808c: 91 ee 20 04 restore %i0, 4, %o0 <== NOT EXECUTED case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: the_info->the_class = the_timer->the_class; 40008090: c4 02 20 38 ld [ %o0 + 0x38 ], %g2 the_info->initial = the_timer->Ticker.initial; 40008094: c2 26 60 04 st %g1, [ %i1 + 4 ] the_info->start_time = the_timer->Ticker.start_time; 40008098: c2 02 20 24 ld [ %o0 + 0x24 ], %g1 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: the_info->the_class = the_timer->the_class; 4000809c: c4 26 40 00 st %g2, [ %i1 ] the_info->initial = the_timer->Ticker.initial; the_info->start_time = the_timer->Ticker.start_time; 400080a0: c2 26 60 08 st %g1, [ %i1 + 8 ] the_info->stop_time = the_timer->Ticker.stop_time; 400080a4: c2 02 20 28 ld [ %o0 + 0x28 ], %g1 400080a8: c2 26 60 0c st %g1, [ %i1 + 0xc ] #if ( CPU_INLINE_ENABLE_DISPATCH == TRUE ) RTEMS_INLINE_ROUTINE void _Thread_Enable_dispatch() { RTEMS_COMPILER_MEMORY_BARRIER(); if ( (--_Thread_Dispatch_disable_level) == 0 ) 400080ac: 05 10 00 7a sethi %hi(0x4001e800), %g2 400080b0: c2 00 a0 00 ld [ %g2 ], %g1 400080b4: b0 10 20 00 clr %i0 400080b8: 82 00 7f ff add %g1, -1, %g1 400080bc: c2 20 a0 00 st %g1, [ %g2 ] 400080c0: c2 00 a0 00 ld [ %g2 ], %g1 400080c4: 80 a0 60 00 cmp %g1, 0 400080c8: 12 80 00 04 bne 400080d8 400080cc: 01 00 00 00 nop _Thread_Dispatch(); 400080d0: 40 00 0c 17 call 4000b12c <_Thread_Dispatch> 400080d4: 01 00 00 00 nop _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 400080d8: 81 c7 e0 08 ret 400080dc: 81 e8 00 00 restore 40012acc : rtems_status_code rtems_timer_initiate_server( uint32_t priority, uint32_t stack_size, rtems_attribute attribute_set ) { 40012acc: 9d e3 bf 90 save %sp, -112, %sp /* * Make sure the requested priority is valid. */ _priority = priority; if ( priority == RTEMS_TIMER_SERVER_DEFAULT_PRIORITY ) 40012ad0: 92 10 20 00 clr %o1 40012ad4: 80 a6 3f ff cmp %i0, -1 40012ad8: 02 80 00 07 be 40012af4 40012adc: 94 10 00 19 mov %i1, %o2 _priority = 0; else if ( !_RTEMS_tasks_Priority_is_valid( priority ) ) 40012ae0: 82 06 3f ff add %i0, -1, %g1 40012ae4: 80 a0 60 fe cmp %g1, 0xfe 40012ae8: 18 80 00 48 bgu 40012c08 40012aec: a0 10 20 13 mov 0x13, %l0 40012af0: 92 10 00 18 mov %i0, %o1 <== NOT EXECUTED 40012af4: 05 10 00 c8 sethi %hi(0x40032000), %g2 40012af8: c2 00 a2 e0 ld [ %g2 + 0x2e0 ], %g1 ! 400322e0 <_Thread_Dispatch_disable_level> 40012afc: 82 00 60 01 inc %g1 40012b00: c2 20 a2 e0 st %g1, [ %g2 + 0x2e0 ] * Just to make sure the test versus create/start operation are atomic. */ _Thread_Disable_dispatch(); if ( _Timer_Server ) { 40012b04: 03 10 00 c9 sethi %hi(0x40032400), %g1 40012b08: c2 00 62 98 ld [ %g1 + 0x298 ], %g1 ! 40032698 <_Timer_Server> 40012b0c: 80 a0 60 00 cmp %g1, 0 40012b10: 02 80 00 06 be 40012b28 40012b14: 19 00 00 20 sethi %hi(0x8000), %o4 _Thread_Enable_dispatch(); 40012b18: 7f ff ff a0 call 40012998 <_Thread_Enable_dispatch> <== NOT EXECUTED 40012b1c: a0 10 20 0e mov 0xe, %l0 <== NOT EXECUTED _Watchdog_Initialize( &_Timer_Server->Timer, _Thread_Delay_ended, id, NULL ); _Watchdog_Initialize( &_Timer_Seconds_timer, _Thread_Delay_ended, id, NULL ); _Thread_Enable_dispatch(); return RTEMS_SUCCESSFUL; } 40012b20: 81 c7 e0 08 ret <== NOT EXECUTED 40012b24: 91 e8 00 10 restore %g0, %l0, %o0 <== NOT EXECUTED * Server should run at the same priority as the priority Ada task. * Otherwise, the priority ceiling for the mutex used to protect the * GNAT run-time is violated. */ status = rtems_task_create( 40012b28: 11 15 12 53 sethi %hi(0x54494c00), %o0 40012b2c: 98 16 80 0c or %i2, %o4, %o4 40012b30: 90 12 21 45 or %o0, 0x145, %o0 40012b34: 96 10 21 00 mov 0x100, %o3 40012b38: 7f ff fa 0e call 40011370 40012b3c: 9a 07 bf f4 add %fp, -12, %o5 /* user may want floating point but we need */ /* system task specified for 0 priority */ attribute_set | RTEMS_SYSTEM_TASK, &id /* get the id back */ ); if (status) { 40012b40: a0 92 20 00 orcc %o0, 0, %l0 40012b44: 12 80 00 2f bne 40012c00 40012b48: d0 07 bf f4 ld [ %fp + -12 ], %o0 _Thread_Enable_dispatch(); return status; } status = rtems_task_start( 40012b4c: 13 10 00 4a sethi %hi(0x40012800), %o1 40012b50: 94 10 20 00 clr %o2 40012b54: 7f ff fc 62 call 40011cdc 40012b58: 92 12 61 cc or %o1, 0x1cc, %o1 id, /* the id from create */ (rtems_task_entry) _Timer_Server_body, /* the timer server entry point */ 0 /* there is no argument */ ); if (status) { 40012b5c: a0 92 20 00 orcc %o0, 0, %l0 40012b60: 12 80 00 28 bne 40012c00 40012b64: 03 10 00 c8 sethi %hi(0x40032000), %g1 * * NOTE: Setting the pointer to the Timer Server TCB to a value other than * NULL indicates that task-based timer support is initialized. */ _Timer_Server = (Thread_Control *)_Objects_Get_local_object( 40012b68: c8 07 bf f4 ld [ %fp + -12 ], %g4 RTEMS_INLINE_ROUTINE Objects_Control *_Objects_Get_local_object( Objects_Information *information, uint16_t index ) { if ( index > information->maximum ) 40012b6c: 9a 10 61 90 or %g1, 0x190, %o5 40012b70: c4 13 60 10 lduh [ %o5 + 0x10 ], %g2 40012b74: 03 00 00 3f sethi %hi(0xfc00), %g1 40012b78: 82 10 63 ff or %g1, 0x3ff, %g1 ! ffff 40012b7c: 82 09 00 01 and %g4, %g1, %g1 40012b80: 80 a0 40 02 cmp %g1, %g2 40012b84: 18 80 00 05 bgu 40012b98 40012b88: 86 10 20 00 clr %g3 return NULL; return information->local_table[ index ]; 40012b8c: c4 03 60 20 ld [ %o5 + 0x20 ], %g2 40012b90: 83 28 60 02 sll %g1, 2, %g1 40012b94: c6 00 80 01 ld [ %g2 + %g1 ], %g3 40012b98: 03 10 00 c9 sethi %hi(0x40032400), %g1 40012b9c: c6 20 62 98 st %g3, [ %g1 + 0x298 ] ! 40032698 <_Timer_Server> */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40012ba0: 03 10 00 c8 sethi %hi(0x40032000), %g1 40012ba4: 82 10 61 e0 or %g1, 0x1e0, %g1 ! 400321e0 <_Timer_Ticks_chain+0x4> */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 40012ba8: c2 20 7f fc st %g1, [ %g1 + -4 ] 40012bac: 82 00 7f fc add %g1, -4, %g1 ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; the_watchdog->id = id; the_watchdog->user_data = user_data; 40012bb0: c0 20 e0 6c clr [ %g3 + 0x6c ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40012bb4: c0 20 e0 50 clr [ %g3 + 0x50 ] the_watchdog->routine = routine; the_watchdog->id = id; 40012bb8: c8 20 e0 68 st %g4, [ %g3 + 0x68 ] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; 40012bbc: 05 10 00 57 sethi %hi(0x40015c00), %g2 the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 40012bc0: c2 20 60 08 st %g1, [ %g1 + 8 ] 40012bc4: 84 10 a0 c0 or %g2, 0xc0, %g2 RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL; 40012bc8: c0 20 60 04 clr [ %g1 + 4 ] 40012bcc: c4 20 e0 64 st %g2, [ %g3 + 0x64 ] */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40012bd0: 03 10 00 c8 sethi %hi(0x40032000), %g1 40012bd4: 82 10 61 f4 or %g1, 0x1f4, %g1 ! 400321f4 <_Timer_Seconds_chain+0x4> */ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); 40012bd8: c2 20 7f fc st %g1, [ %g1 + -4 ] 40012bdc: 82 00 7f fc add %g1, -4, %g1 the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain); 40012be0: 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; 40012be4: c0 20 60 04 clr [ %g1 + 4 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40012be8: 03 10 00 c8 sethi %hi(0x40032000), %g1 40012bec: 82 10 61 fc or %g1, 0x1fc, %g1 ! 400321fc <_Timer_Seconds_timer> the_watchdog->routine = routine; 40012bf0: c4 20 60 1c st %g2, [ %g1 + 0x1c ] the_watchdog->id = id; 40012bf4: c8 20 60 20 st %g4, [ %g1 + 0x20 ] the_watchdog->user_data = user_data; 40012bf8: c0 20 60 24 clr [ %g1 + 0x24 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40012bfc: c0 20 60 08 clr [ %g1 + 8 ] */ _Watchdog_Initialize( &_Timer_Server->Timer, _Thread_Delay_ended, id, NULL ); _Watchdog_Initialize( &_Timer_Seconds_timer, _Thread_Delay_ended, id, NULL ); _Thread_Enable_dispatch(); 40012c00: 7f ff ff 66 call 40012998 <_Thread_Enable_dispatch> 40012c04: 01 00 00 00 nop return RTEMS_SUCCESSFUL; } 40012c08: b0 10 00 10 mov %l0, %i0 40012c0c: 81 c7 e0 08 ret 40012c10: 81 e8 00 00 restore 4001265c : Objects_Id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { 4001265c: 9d e3 bf 90 save %sp, -112, %sp Timer_Control *the_timer; Objects_Locations location; ISR_Level level; if ( !_Timer_Server ) 40012660: 25 10 00 c9 sethi %hi(0x40032400), %l2 40012664: c2 04 a2 98 ld [ %l2 + 0x298 ], %g1 ! 40032698 <_Timer_Server> Objects_Id id, rtems_interval ticks, rtems_timer_service_routine_entry routine, void *user_data ) { 40012668: a6 10 00 18 mov %i0, %l3 Timer_Control *the_timer; Objects_Locations location; ISR_Level level; if ( !_Timer_Server ) 4001266c: 80 a0 60 00 cmp %g1, 0 40012670: 02 80 00 24 be 40012700 40012674: b0 10 20 0e mov 0xe, %i0 return RTEMS_INCORRECT_STATE; if ( !routine ) 40012678: 80 a6 a0 00 cmp %i2, 0 4001267c: 02 80 00 21 be 40012700 40012680: b0 10 20 09 mov 9, %i0 return RTEMS_INVALID_ADDRESS; if ( ticks == 0 ) 40012684: 80 a6 60 00 cmp %i1, 0 40012688: 02 80 00 1e be 40012700 4001268c: b0 10 20 0a mov 0xa, %i0 40012690: 11 10 00 c9 sethi %hi(0x40032400), %o0 40012694: 92 10 00 13 mov %l3, %o1 40012698: 90 12 22 4c or %o0, 0x24c, %o0 4001269c: 40 00 08 c4 call 400149ac <_Objects_Get> 400126a0: 94 07 bf f4 add %fp, -12, %o2 return RTEMS_INVALID_NUMBER; the_timer = _Timer_Get( id, &location ); switch ( location ) { 400126a4: c2 07 bf f4 ld [ %fp + -12 ], %g1 400126a8: 80 a0 60 00 cmp %g1, 0 400126ac: 02 80 00 08 be 400126cc 400126b0: a0 10 00 08 mov %o0, %l0 400126b4: 82 18 60 02 xor %g1, 2, %g1 400126b8: 80 a0 00 01 cmp %g0, %g1 400126bc: 82 60 20 00 subx %g0, 0, %g1 400126c0: b0 08 60 15 and %g1, 0x15, %i0 400126c4: 81 c7 e0 08 ret 400126c8: 91 ee 20 04 restore %i0, 4, %o0 case OBJECTS_ERROR: return RTEMS_INVALID_ID; case OBJECTS_LOCAL: (void) _Watchdog_Remove( &the_timer->Ticker ); 400126cc: a2 02 20 10 add %o0, 0x10, %l1 400126d0: 40 00 13 fd call 400176c4 <_Watchdog_Remove> 400126d4: 90 10 00 11 mov %l1, %o0 _ISR_Disable( level ); 400126d8: 7f ff e0 12 call 4000a720 400126dc: 01 00 00 00 nop /* * Check to see if the watchdog has just been inserted by a * higher priority interrupt. If so, abandon this insert. */ if ( the_timer->Ticker.state != WATCHDOG_INACTIVE ) { 400126e0: c2 04 20 18 ld [ %l0 + 0x18 ], %g1 400126e4: 80 a0 60 00 cmp %g1, 0 400126e8: 02 80 00 08 be 40012708 400126ec: 82 10 20 01 mov 1, %g1 _ISR_Enable( level ); 400126f0: 7f ff e0 10 call 4000a730 <== NOT EXECUTED 400126f4: b0 10 20 00 clr %i0 <== NOT EXECUTED _Thread_Enable_dispatch(); 400126f8: 7f ff ff cc call 40012628 <_Thread_Enable_dispatch> <== NOT EXECUTED 400126fc: 01 00 00 00 nop <== NOT EXECUTED 40012700: 81 c7 e0 08 ret 40012704: 81 e8 00 00 restore * so we can atomically initialize it as in use. */ the_timer->the_class = TIMER_INTERVAL_ON_TASK; _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); the_timer->Ticker.initial = ticks; 40012708: f2 24 20 1c st %i1, [ %l0 + 0x1c ] Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; the_watchdog->routine = routine; 4001270c: f4 24 20 2c st %i2, [ %l0 + 0x2c ] the_watchdog->id = id; 40012710: e6 24 20 30 st %l3, [ %l0 + 0x30 ] the_watchdog->user_data = user_data; 40012714: f6 24 20 34 st %i3, [ %l0 + 0x34 ] Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE; 40012718: c0 24 20 18 clr [ %l0 + 0x18 ] /* * OK. Now we now the timer was not rescheduled by an interrupt * so we can atomically initialize it as in use. */ the_timer->the_class = TIMER_INTERVAL_ON_TASK; 4001271c: c2 24 20 38 st %g1, [ %l0 + 0x38 ] _Watchdog_Initialize( &the_timer->Ticker, routine, id, user_data ); the_timer->Ticker.initial = ticks; _ISR_Enable( level ); 40012720: 7f ff e0 04 call 4000a730 40012724: 21 10 00 c8 sethi %hi(0x40032000), %l0 _Timer_Server_stop_ticks_timer(); 40012728: d0 04 a2 98 ld [ %l2 + 0x298 ], %o0 4001272c: 40 00 13 e6 call 400176c4 <_Watchdog_Remove> 40012730: 90 02 20 48 add %o0, 0x48, %o0 _Timer_Server_process_ticks_chain(); 40012734: 40 00 00 87 call 40012950 <_Timer_Server_process_ticks_chain> 40012738: 01 00 00 00 nop _Watchdog_Insert( &_Timer_Ticks_chain, &the_timer->Ticker ); 4001273c: 90 14 21 dc or %l0, 0x1dc, %o0 40012740: 40 00 13 89 call 40017564 <_Watchdog_Insert> 40012744: 92 10 00 11 mov %l1, %o1 */ RTEMS_INLINE_ROUTINE boolean _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain)); 40012748: c4 04 21 dc ld [ %l0 + 0x1dc ], %g2 4001274c: a0 14 21 dc or %l0, 0x1dc, %l0 */ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null; 40012750: a0 04 20 04 add %l0, 4, %l0 _Timer_Server_reset_ticks_timer(); 40012754: 80 a0 80 10 cmp %g2, %l0 40012758: 02 80 00 08 be 40012778 4001275c: c2 04 a2 98 ld [ %l2 + 0x298 ], %g1 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 40012760: c4 00 a0 10 ld [ %g2 + 0x10 ], %g2 _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40012764: 11 10 00 c8 sethi %hi(0x40032000), %o0 40012768: 92 00 60 48 add %g1, 0x48, %o1 Watchdog_Control *the_watchdog, Watchdog_Interval units ) { the_watchdog->initial = units; 4001276c: c4 20 60 54 st %g2, [ %g1 + 0x54 ] _Watchdog_Insert( &_Watchdog_Ticks_chain, the_watchdog ); 40012770: 40 00 13 7d call 40017564 <_Watchdog_Insert> 40012774: 90 12 23 dc or %o0, 0x3dc, %o0 _Thread_Enable_dispatch(); 40012778: 7f ff ff ac call 40012628 <_Thread_Enable_dispatch> 4001277c: b0 10 20 00 clr %i0 return RTEMS_SUCCESSFUL; } return RTEMS_INTERNAL_ERROR; /* unreached - only to remove warnings */ } 40012780: 81 c7 e0 08 ret 40012784: 81 e8 00 00 restore