Annotated Report
02006a28 <_POSIX_Condition_variables_Wait_support>: pthread_cond_t *cond, pthread_mutex_t *mutex, Watchdog_Interval timeout, bool already_timedout ) {
2006a28: 9d e3 bf 98 save %sp, -104, %sp
register POSIX_Condition_variables_Control *the_cond; Objects_Locations location; int status; int mutex_status; if ( !_POSIX_Mutex_Get( mutex, &location ) ) {
2006a2c: a0 07 bf fc add %fp, -4, %l0 2006a30: 90 10 00 19 mov %i1, %o0 2006a34: 40 00 00 7e call 2006c2c <_POSIX_Mutex_Get> 2006a38: 92 10 00 10 mov %l0, %o1 2006a3c: 80 a2 20 00 cmp %o0, 0 2006a40: 22 80 00 18 be,a 2006aa0 <_POSIX_Condition_variables_Wait_support+0x78> 2006a44: b0 10 20 16 mov 0x16, %i0
*/ RTEMS_INLINE_ROUTINE void _Thread_Unnest_dispatch( void ) { RTEMS_COMPILER_MEMORY_BARRIER(); _Thread_Dispatch_disable_level -= 1;
2006a48: 03 00 80 7a sethi %hi(0x201e800), %g1 2006a4c: c4 00 61 30 ld [ %g1 + 0x130 ], %g2 ! 201e930 <_Thread_Dispatch_disable_level>
return EINVAL; } _Thread_Unnest_dispatch(); the_cond = _POSIX_Condition_variables_Get( cond, &location );
2006a50: 92 10 00 10 mov %l0, %o1 2006a54: 84 00 bf ff add %g2, -1, %g2 2006a58: 90 10 00 18 mov %i0, %o0 2006a5c: c4 20 61 30 st %g2, [ %g1 + 0x130 ] 2006a60: 7f ff ff 74 call 2006830 <_POSIX_Condition_variables_Get> 2006a64: 01 00 00 00 nop
switch ( location ) {
2006a68: c2 07 bf fc ld [ %fp + -4 ], %g1 2006a6c: 80 a0 60 00 cmp %g1, 0
2006a70: 12 80 00 34 bne 2006b40 <_POSIX_Condition_variables_Wait_support+0x118>
2006a74: a0 10 00 08 mov %o0, %l0
case OBJECTS_LOCAL: if ( the_cond->Mutex && ( the_cond->Mutex != *mutex ) ) {
2006a78: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 2006a7c: 80 a0 60 00 cmp %g1, 0
2006a80: 02 80 00 0a be 2006aa8 <_POSIX_Condition_variables_Wait_support+0x80>
2006a84: 01 00 00 00 nop 2006a88: c4 06 40 00 ld [ %i1 ], %g2 2006a8c: 80 a0 40 02 cmp %g1, %g2
2006a90: 02 80 00 06 be 2006aa8 <_POSIX_Condition_variables_Wait_support+0x80>
2006a94: 01 00 00 00 nop
_Thread_Enable_dispatch();
2006a98: 40 00 0c ba call 2009d80 <_Thread_Enable_dispatch> 2006a9c: b0 10 20 16 mov 0x16, %i0 ! 16 <PROM_START+0x16>
return EINVAL;
2006aa0: 81 c7 e0 08 ret 2006aa4: 81 e8 00 00 restore
} (void) pthread_mutex_unlock( mutex );
2006aa8: 40 00 00 f2 call 2006e70 <pthread_mutex_unlock> 2006aac: 90 10 00 19 mov %i1, %o0
_Thread_Enable_dispatch(); return EINVAL; } */ if ( !already_timedout ) {
2006ab0: 80 8e e0 ff btst 0xff, %i3
2006ab4: 12 80 00 1c bne 2006b24 <_POSIX_Condition_variables_Wait_support+0xfc>
2006ab8: 23 00 80 7a sethi %hi(0x201e800), %l1
the_cond->Mutex = *mutex;
2006abc: c4 06 40 00 ld [ %i1 ], %g2
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0;
2006ac0: c2 04 61 f0 ld [ %l1 + 0x1f0 ], %g1
return EINVAL; } */ if ( !already_timedout ) { the_cond->Mutex = *mutex;
2006ac4: c4 24 20 14 st %g2, [ %l0 + 0x14 ]
_Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0;
2006ac8: c0 20 60 34 clr [ %g1 + 0x34 ]
_Thread_Executing->Wait.queue = &the_cond->Wait_queue; _Thread_Executing->Wait.id = *cond;
2006acc: c6 06 00 00 ld [ %i0 ], %g3
if ( !already_timedout ) { the_cond->Mutex = *mutex; _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0; _Thread_Executing->Wait.queue = &the_cond->Wait_queue;
2006ad0: 84 04 20 18 add %l0, 0x18, %g2
_Thread_Executing->Wait.id = *cond;
2006ad4: c6 20 60 20 st %g3, [ %g1 + 0x20 ]
if ( !already_timedout ) { the_cond->Mutex = *mutex; _Thread_queue_Enter_critical_section( &the_cond->Wait_queue ); _Thread_Executing->Wait.return_code = 0; _Thread_Executing->Wait.queue = &the_cond->Wait_queue;
2006ad8: c4 20 60 44 st %g2, [ %g1 + 0x44 ]
_Thread_Executing->Wait.id = *cond; _Thread_queue_Enqueue( &the_cond->Wait_queue, timeout );
2006adc: 92 10 00 1a mov %i2, %o1
RTEMS_INLINE_ROUTINE void _Thread_queue_Enter_critical_section ( Thread_queue_Control *the_thread_queue ) { the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
2006ae0: 82 10 20 01 mov 1, %g1 2006ae4: 90 10 00 02 mov %g2, %o0 2006ae8: 15 00 80 29 sethi %hi(0x200a400), %o2 2006aec: 94 12 a2 ec or %o2, 0x2ec, %o2 ! 200a6ec <_Thread_queue_Timeout> 2006af0: 40 00 0e 09 call 200a314 <_Thread_queue_Enqueue_with_handler> 2006af4: c2 24 20 48 st %g1, [ %l0 + 0x48 ]
_Thread_Enable_dispatch();
2006af8: 40 00 0c a2 call 2009d80 <_Thread_Enable_dispatch> 2006afc: 01 00 00 00 nop
/* * Switch ourself out because we blocked as a result of the * _Thread_queue_Enqueue. */ status = _Thread_Executing->Wait.return_code;
2006b00: c2 04 61 f0 ld [ %l1 + 0x1f0 ], %g1 2006b04: f0 00 60 34 ld [ %g1 + 0x34 ], %i0
if ( status && status != ETIMEDOUT )
2006b08: 80 a6 20 74 cmp %i0, 0x74
2006b0c: 02 80 00 08 be 2006b2c <_POSIX_Condition_variables_Wait_support+0x104>
2006b10: 80 a6 20 00 cmp %i0, 0
2006b14: 02 80 00 06 be 2006b2c <_POSIX_Condition_variables_Wait_support+0x104>
2006b18: 01 00 00 00 nop
2006b1c: 81 c7 e0 08 ret <== NOT EXECUTED 2006b20: 81 e8 00 00 restore <== NOT EXECUTED
return status; } else { _Thread_Enable_dispatch();
2006b24: 40 00 0c 97 call 2009d80 <_Thread_Enable_dispatch> 2006b28: b0 10 20 74 mov 0x74, %i0
/* * When we get here the dispatch disable level is 0. */ mutex_status = pthread_mutex_lock( mutex );
2006b2c: 40 00 00 b0 call 2006dec <pthread_mutex_lock> 2006b30: 90 10 00 19 mov %i1, %o0
if ( mutex_status )
2006b34: 80 a2 20 00 cmp %o0, 0
2006b38: 02 80 00 03 be 2006b44 <_POSIX_Condition_variables_Wait_support+0x11c>
2006b3c: 01 00 00 00 nop 2006b40: b0 10 20 16 mov 0x16, %i0 ! 16 <PROM_START+0x16>
case OBJECTS_ERROR: break; } return EINVAL; }
2006b44: 81 c7 e0 08 ret 2006b48: 81 e8 00 00 restore
0200b70c <_POSIX_Threads_Sporadic_budget_callout>: ) { POSIX_API_Control *api; uint32_t new_priority; api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200b70c: c4 02 21 6c ld [ %o0 + 0x16c ], %g2
RTEMS_INLINE_ROUTINE Priority_Control _POSIX_Priority_To_core( int priority ) { return (Priority_Control) (POSIX_SCHEDULER_MAXIMUM_PRIORITY - priority + 1);
200b710: c6 00 a0 88 ld [ %g2 + 0x88 ], %g3 200b714: 05 00 80 6c sethi %hi(0x201b000), %g2 200b718: d2 08 a2 04 ldub [ %g2 + 0x204 ], %o1 ! 201b204 <rtems_maximum_priority>
*/ #if 0 printk( "callout %d %d %d\n", the_thread->resource_count, the_thread->current_priority, new_priority ); #endif if ( the_thread->resource_count == 0 ) {
200b71c: c4 02 20 1c ld [ %o0 + 0x1c ], %g2 200b720: 92 22 40 03 sub %o1, %g3, %o1
/* * This will prevent the thread from consuming its entire "budget" * while at low priority. */ the_thread->cpu_time_budget = 0xFFFFFFFF; /* XXX should be based on MAX_U32 */
200b724: 86 10 3f ff mov -1, %g3
new_priority = _POSIX_Priority_To_core(api->schedparam.sched_ss_low_priority); the_thread->real_priority = new_priority;
200b728: d2 22 20 18 st %o1, [ %o0 + 0x18 ]
*/ #if 0 printk( "callout %d %d %d\n", the_thread->resource_count, the_thread->current_priority, new_priority ); #endif if ( the_thread->resource_count == 0 ) {
200b72c: 80 a0 a0 00 cmp %g2, 0
200b730: 12 80 00 09 bne 200b754 <_POSIX_Threads_Sporadic_budget_callout+0x48>
200b734: c6 22 20 78 st %g3, [ %o0 + 0x78 ]
/* * Make sure we are actually lowering it. If they have lowered it * to logically lower than sched_ss_low_priority, then we do not want to * change it. */ if ( the_thread->current_priority < new_priority ) {
200b738: c2 02 20 14 ld [ %o0 + 0x14 ], %g1 200b73c: 80 a0 40 09 cmp %g1, %o1
200b740: 1a 80 00 05 bcc 200b754 <_POSIX_Threads_Sporadic_budget_callout+0x48>
200b744: 94 10 20 01 mov 1, %o2
_Thread_Change_priority( the_thread, new_priority, true );
200b748: 82 13 c0 00 mov %o7, %g1 200b74c: 7f ff ef b2 call 2007614 <_Thread_Change_priority> 200b750: 9e 10 40 00 mov %g1, %o7
200b754: 81 c3 e0 08 retl <== NOT EXECUTED
02007d20 <_Thread_Initialize>: Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
2007d20: 9d e3 bf a0 save %sp, -96, %sp 2007d24: c2 07 a0 6c ld [ %fp + 0x6c ], %g1
/* * Zero out all the allocated memory fields */ for ( i=0 ; i <= THREAD_API_LAST ; i++ ) the_thread->API_Extensions[i] = NULL;
2007d28: c0 26 61 68 clr [ %i1 + 0x168 ] 2007d2c: c0 26 61 6c clr [ %i1 + 0x16c ] 2007d30: c0 26 61 70 clr [ %i1 + 0x170 ]
extensions_area = NULL; the_thread->libc_reent = NULL;
2007d34: c0 26 61 64 clr [ %i1 + 0x164 ]
Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
2007d38: e0 00 40 00 ld [ %g1 ], %l0
if ( !actual_stack_size || actual_stack_size < stack_size ) return false; /* stack allocation failed */ stack = the_thread->Start.stack; #else if ( !stack_area ) {
2007d3c: 80 a6 a0 00 cmp %i2, 0
Thread_CPU_budget_algorithms budget_algorithm, Thread_CPU_budget_algorithm_callout budget_callout, uint32_t isr_level, Objects_Name name ) {
2007d40: e2 07 a0 60 ld [ %fp + 0x60 ], %l1
if ( !actual_stack_size || actual_stack_size < stack_size ) return false; /* stack allocation failed */ stack = the_thread->Start.stack; #else if ( !stack_area ) { 2007d44: 12 80 00 0f bne 2007d80 <_Thread_Initialize+0x60>
2007d48: e4 0f a0 5f ldub [ %fp + 0x5f ], %l2
actual_stack_size = _Thread_Stack_Allocate( the_thread, stack_size );
2007d4c: 90 10 00 19 mov %i1, %o0 2007d50: 40 00 02 ab call 20087fc <_Thread_Stack_Allocate> 2007d54: 92 10 00 1b mov %i3, %o1
if ( !actual_stack_size || actual_stack_size < stack_size )
2007d58: 80 a2 00 1b cmp %o0, %i3
2007d5c: 0a 80 00 04 bcs 2007d6c <_Thread_Initialize+0x4c>
2007d60: 80 a2 20 00 cmp %o0, 0
2007d64: 12 80 00 04 bne 2007d74 <_Thread_Initialize+0x54>
2007d68: 82 10 20 01 mov 1, %g1 2007d6c: 81 c7 e0 08 ret 2007d70: 91 e8 20 00 restore %g0, 0, %o0
return false; /* stack allocation failed */ stack = the_thread->Start.stack;
2007d74: f4 06 60 d0 ld [ %i1 + 0xd0 ], %i2
the_thread->Start.core_allocated_stack = true;
2007d78: 10 80 00 04 b 2007d88 <_Thread_Initialize+0x68> 2007d7c: c2 2e 60 c0 stb %g1, [ %i1 + 0xc0 ]
} else { stack = stack_area; actual_stack_size = stack_size; the_thread->Start.core_allocated_stack = false;
2007d80: c0 2e 60 c0 clrb [ %i1 + 0xc0 ] 2007d84: 90 10 00 1b mov %i3, %o0
Stack_Control *the_stack, void *starting_address, size_t size ) { the_stack->area = starting_address;
2007d88: f4 26 60 c8 st %i2, [ %i1 + 0xc8 ]
the_stack->size = size;
2007d8c: d0 26 60 c4 st %o0, [ %i1 + 0xc4 ]
/* * Allocate the floating point area for this thread */ #if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( is_fp ) {
2007d90: 80 8f 20 ff btst 0xff, %i4
2007d94: 02 80 00 08 be 2007db4 <_Thread_Initialize+0x94>
2007d98: b4 10 20 00 clr %i2
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE );
2007d9c: 90 10 20 88 mov 0x88, %o0 2007da0: 40 00 04 d7 call 20090fc <_Workspace_Allocate> 2007da4: b6 10 20 00 clr %i3
if ( !fp_area )
2007da8: b4 92 20 00 orcc %o0, 0, %i2 2007dac: 22 80 00 42 be,a 2007eb4 <_Thread_Initialize+0x194> 2007db0: d0 06 61 64 ld [ %i1 + 0x164 ], %o0
#endif /* * Allocate the extensions area for this thread */ if ( _Thread_Maximum_extensions ) {
2007db4: 03 00 80 6f sethi %hi(0x201bc00), %g1 2007db8: d0 00 61 c0 ld [ %g1 + 0x1c0 ], %o0 ! 201bdc0 <_Thread_Maximum_extensions>
fp_area = _Workspace_Allocate( CONTEXT_FP_SIZE ); if ( !fp_area ) goto failed; fp_area = _Context_Fp_start( fp_area, 0 ); } the_thread->fp_context = fp_area;
2007dbc: f4 26 61 60 st %i2, [ %i1 + 0x160 ]
the_thread->Start.fp_context = fp_area;
2007dc0: f4 26 60 cc st %i2, [ %i1 + 0xcc ]
Watchdog_Service_routine_entry routine, Objects_Id id, void *user_data ) { the_watchdog->state = WATCHDOG_INACTIVE;
2007dc4: c0 26 60 50 clr [ %i1 + 0x50 ]
the_watchdog->routine = routine;
2007dc8: c0 26 60 64 clr [ %i1 + 0x64 ]
the_watchdog->id = id;
2007dcc: c0 26 60 68 clr [ %i1 + 0x68 ]
the_watchdog->user_data = user_data;
2007dd0: c0 26 60 6c clr [ %i1 + 0x6c ]
#endif /* * Allocate the extensions area for this thread */ if ( _Thread_Maximum_extensions ) {
2007dd4: 80 a2 20 00 cmp %o0, 0
2007dd8: 02 80 00 08 be 2007df8 <_Thread_Initialize+0xd8>
2007ddc: b6 10 20 00 clr %i3
extensions_area = _Workspace_Allocate(
2007de0: 90 02 20 01 inc %o0 2007de4: 40 00 04 c6 call 20090fc <_Workspace_Allocate> 2007de8: 91 2a 20 02 sll %o0, 2, %o0
(_Thread_Maximum_extensions + 1) * sizeof( void * ) ); if ( !extensions_area )
2007dec: b6 92 20 00 orcc %o0, 0, %i3 2007df0: 22 80 00 31 be,a 2007eb4 <_Thread_Initialize+0x194> 2007df4: d0 06 61 64 ld [ %i1 + 0x164 ], %o0
* if they are linked to the thread. An extension user may * create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) {
2007df8: 80 a6 e0 00 cmp %i3, 0
2007dfc: 02 80 00 0c be 2007e2c <_Thread_Initialize+0x10c>
2007e00: f6 26 61 74 st %i3, [ %i1 + 0x174 ]
for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2007e04: 03 00 80 6f sethi %hi(0x201bc00), %g1 2007e08: c4 00 61 c0 ld [ %g1 + 0x1c0 ], %g2 ! 201bdc0 <_Thread_Maximum_extensions> 2007e0c: 10 80 00 05 b 2007e20 <_Thread_Initialize+0x100> 2007e10: 82 10 20 00 clr %g1
the_thread->extensions[i] = NULL;
2007e14: 87 28 60 02 sll %g1, 2, %g3
* create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) { for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2007e18: 82 00 60 01 inc %g1
the_thread->extensions[i] = NULL;
2007e1c: c0 21 00 03 clr [ %g4 + %g3 ]
* create the extension long after tasks have been created * so they cannot rely on the thread create user extension * call. */ if ( the_thread->extensions ) { for ( i = 0; i <= _Thread_Maximum_extensions ; i++ )
2007e20: 80 a0 40 02 cmp %g1, %g2 2007e24: 28 bf ff fc bleu,a 2007e14 <_Thread_Initialize+0xf4> 2007e28: c8 06 61 74 ld [ %i1 + 0x174 ], %g4
* General initialization */ the_thread->Start.is_preemptible = is_preemptible; the_thread->Start.budget_algorithm = budget_algorithm; the_thread->Start.budget_callout = budget_callout;
2007e2c: c2 07 a0 64 ld [ %fp + 0x64 ], %g1
/* * General initialization */ the_thread->Start.is_preemptible = is_preemptible;
2007e30: e4 2e 60 ac stb %l2, [ %i1 + 0xac ]
the_thread->Start.budget_algorithm = budget_algorithm; the_thread->Start.budget_callout = budget_callout;
2007e34: c2 26 60 b4 st %g1, [ %i1 + 0xb4 ]
switch ( budget_algorithm ) {
2007e38: 80 a4 60 02 cmp %l1, 2
2007e3c: 12 80 00 05 bne 2007e50 <_Thread_Initialize+0x130>
2007e40: e2 26 60 b0 st %l1, [ %i1 + 0xb0 ]
case THREAD_CPU_BUDGET_ALGORITHM_NONE: case THREAD_CPU_BUDGET_ALGORITHM_RESET_TIMESLICE: break; #if defined(RTEMS_SCORE_THREAD_ENABLE_EXHAUST_TIMESLICE) case THREAD_CPU_BUDGET_ALGORITHM_EXHAUST_TIMESLICE: the_thread->cpu_time_budget = _Thread_Ticks_per_timeslice;
2007e44: 03 00 80 6f sethi %hi(0x201bc00), %g1 2007e48: c2 00 60 78 ld [ %g1 + 0x78 ], %g1 ! 201bc78 <_Thread_Ticks_per_timeslice> 2007e4c: c2 26 60 78 st %g1, [ %i1 + 0x78 ]
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: break; #endif } the_thread->Start.isr_level = isr_level;
2007e50: c2 07 a0 68 ld [ %fp + 0x68 ], %g1
#if defined(RTEMS_ITRON_API) the_thread->suspend_count = 0; #endif the_thread->real_priority = priority; the_thread->Start.initial_priority = priority; _Thread_Set_priority( the_thread, priority );
2007e54: 92 10 00 1d mov %i5, %o1
case THREAD_CPU_BUDGET_ALGORITHM_CALLOUT: break; #endif } the_thread->Start.isr_level = isr_level;
2007e58: c2 26 60 b8 st %g1, [ %i1 + 0xb8 ]
the_thread->current_state = STATES_DORMANT;
2007e5c: 82 10 20 01 mov 1, %g1
#if defined(RTEMS_ITRON_API) the_thread->suspend_count = 0; #endif the_thread->real_priority = priority; the_thread->Start.initial_priority = priority; _Thread_Set_priority( the_thread, priority );
2007e60: 90 10 00 19 mov %i1, %o0
#endif } the_thread->Start.isr_level = isr_level; the_thread->current_state = STATES_DORMANT;
2007e64: c2 26 60 10 st %g1, [ %i1 + 0x10 ]
the_thread->Wait.queue = NULL;
2007e68: c0 26 60 44 clr [ %i1 + 0x44 ]
the_thread->resource_count = 0;
2007e6c: c0 26 60 1c clr [ %i1 + 0x1c ]
#if defined(RTEMS_ITRON_API) the_thread->suspend_count = 0; #endif the_thread->real_priority = priority;
2007e70: fa 26 60 18 st %i5, [ %i1 + 0x18 ]
the_thread->Start.initial_priority = priority; _Thread_Set_priority( the_thread, priority );
2007e74: 40 00 01 c0 call 2008574 <_Thread_Set_priority> 2007e78: fa 26 60 bc st %i5, [ %i1 + 0xbc ]
#if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object;
2007e7c: c2 16 60 0a lduh [ %i1 + 0xa ], %g1 2007e80: c4 06 20 1c ld [ %i0 + 0x1c ], %g2 2007e84: 83 28 60 02 sll %g1, 2, %g1
information, _Objects_Get_index( the_object->id ), the_object ); the_object->name = name;
2007e88: e0 26 60 0c st %l0, [ %i1 + 0xc ]
#if defined(RTEMS_DEBUG) if ( index > information->maximum ) return; #endif information->local_table[ index ] = the_object;
2007e8c: f2 20 80 01 st %i1, [ %g2 + %g1 ]
/* * Initialize the CPU usage statistics */ #ifndef __RTEMS_USE_TICKS_FOR_STATISTICS__ _Timestamp_Set_to_zero( &the_thread->cpu_time_used );
2007e90: c0 26 60 84 clr [ %i1 + 0x84 ] 2007e94: c0 26 60 88 clr [ %i1 + 0x88 ]
* enabled when we get here. We want to be able to run the * user extensions with dispatching enabled. The Allocator * Mutex provides sufficient protection to let the user extensions * run safely. */ extension_status = _User_extensions_Thread_create( the_thread );
2007e98: 90 10 00 19 mov %i1, %o0 2007e9c: 40 00 03 8c call 2008ccc <_User_extensions_Thread_create> 2007ea0: b0 10 20 01 mov 1, %i0
if ( extension_status )
2007ea4: 80 8a 20 ff btst 0xff, %o0
2007ea8: 12 80 00 27 bne 2007f44 <_Thread_Initialize+0x224>
2007eac: 01 00 00 00 nop
return true; failed: if ( the_thread->libc_reent )
2007eb0: d0 06 61 64 ld [ %i1 + 0x164 ], %o0 2007eb4: 80 a2 20 00 cmp %o0, 0 2007eb8: 22 80 00 05 be,a 2007ecc <_Thread_Initialize+0x1ac> 2007ebc: d0 06 61 68 ld [ %i1 + 0x168 ], %o0
_Workspace_Free( the_thread->libc_reent );
2007ec0: 40 00 04 98 call 2009120 <_Workspace_Free> 2007ec4: 01 00 00 00 nop
for ( i=0 ; i <= THREAD_API_LAST ; i++ ) if ( the_thread->API_Extensions[i] )
2007ec8: d0 06 61 68 ld [ %i1 + 0x168 ], %o0 2007ecc: 80 a2 20 00 cmp %o0, 0 2007ed0: 22 80 00 05 be,a 2007ee4 <_Thread_Initialize+0x1c4> 2007ed4: d0 06 61 6c ld [ %i1 + 0x16c ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2007ed8: 40 00 04 92 call 2009120 <_Workspace_Free> 2007edc: 01 00 00 00 nop
failed: if ( the_thread->libc_reent ) _Workspace_Free( the_thread->libc_reent ); for ( i=0 ; i <= THREAD_API_LAST ; i++ ) if ( the_thread->API_Extensions[i] )
2007ee0: d0 06 61 6c ld [ %i1 + 0x16c ], %o0 2007ee4: 80 a2 20 00 cmp %o0, 0 2007ee8: 22 80 00 05 be,a 2007efc <_Thread_Initialize+0x1dc> 2007eec: d0 06 61 70 ld [ %i1 + 0x170 ], %o0
_Workspace_Free( the_thread->API_Extensions[i] );
2007ef0: 40 00 04 8c call 2009120 <_Workspace_Free> 2007ef4: 01 00 00 00 nop
failed: if ( the_thread->libc_reent ) _Workspace_Free( the_thread->libc_reent ); for ( i=0 ; i <= THREAD_API_LAST ; i++ ) if ( the_thread->API_Extensions[i] )
2007ef8: d0 06 61 70 ld [ %i1 + 0x170 ], %o0 2007efc: 80 a2 20 00 cmp %o0, 0
2007f00: 02 80 00 05 be 2007f14 <_Thread_Initialize+0x1f4>
2007f04: 80 a6 e0 00 cmp %i3, 0
_Workspace_Free( the_thread->API_Extensions[i] );
2007f08: 40 00 04 86 call 2009120 <_Workspace_Free> <== NOT EXECUTED 2007f0c: 01 00 00 00 nop <== NOT EXECUTED
if ( extensions_area )
2007f10: 80 a6 e0 00 cmp %i3, 0 <== NOT EXECUTED
2007f14: 02 80 00 05 be 2007f28 <_Thread_Initialize+0x208>
2007f18: 80 a6 a0 00 cmp %i2, 0
(void) _Workspace_Free( extensions_area );
2007f1c: 40 00 04 81 call 2009120 <_Workspace_Free> 2007f20: 90 10 00 1b mov %i3, %o0
#if ( CPU_HARDWARE_FP == TRUE ) || ( CPU_SOFTWARE_FP == TRUE ) if ( fp_area )
2007f24: 80 a6 a0 00 cmp %i2, 0
2007f28: 02 80 00 05 be 2007f3c <_Thread_Initialize+0x21c>
2007f2c: 90 10 00 19 mov %i1, %o0
(void) _Workspace_Free( fp_area );
2007f30: 40 00 04 7c call 2009120 <_Workspace_Free> 2007f34: 90 10 00 1a mov %i2, %o0
#endif _Thread_Stack_Free( the_thread );
2007f38: 90 10 00 19 mov %i1, %o0 2007f3c: 40 00 02 47 call 2008858 <_Thread_Stack_Free> 2007f40: b0 10 20 00 clr %i0
return false; }
2007f44: 81 c7 e0 08 ret 2007f48: 81 e8 00 00 restore
02008268 <_Thread_queue_Enqueue_priority>: Thread_blocking_operation_States _Thread_queue_Enqueue_priority ( Thread_queue_Control *the_thread_queue, Thread_Control *the_thread, ISR_Level *level_p ) {
2008268: 9d e3 bf a0 save %sp, -96, %sp
Priority_Control priority; States_Control block_state; _Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority;
200826c: e0 06 60 14 ld [ %i1 + 0x14 ], %l0
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
2008270: 82 06 60 3c add %i1, 0x3c, %g1
the_chain->permanent_null = NULL;
2008274: 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);
2008278: c2 26 60 38 st %g1, [ %i1 + 0x38 ]
the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain);
200827c: 82 06 60 38 add %i1, 0x38, %g1 2008280: c2 26 60 40 st %g1, [ %i1 + 0x40 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
2008284: 2d 00 80 6c sethi %hi(0x201b000), %l6
_Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; header_index = _Thread_queue_Header_number( priority ); header = &the_thread_queue->Queues.Priority[ header_index ];
2008288: 83 34 20 06 srl %l0, 6, %g1
block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) )
200828c: 80 8c 20 20 btst 0x20, %l0
_Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; header_index = _Thread_queue_Header_number( priority ); header = &the_thread_queue->Queues.Priority[ header_index ];
2008290: a7 28 60 04 sll %g1, 4, %l3
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
2008294: ac 15 a2 04 or %l6, 0x204, %l6
_Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; header_index = _Thread_queue_Header_number( priority ); header = &the_thread_queue->Queues.Priority[ header_index ];
2008298: 83 28 60 02 sll %g1, 2, %g1
block_state = the_thread_queue->state;
200829c: ea 06 20 38 ld [ %i0 + 0x38 ], %l5
_Chain_Initialize_empty( &the_thread->Wait.Block2n ); priority = the_thread->current_priority; header_index = _Thread_queue_Header_number( priority ); header = &the_thread_queue->Queues.Priority[ header_index ];
20082a0: a6 24 c0 01 sub %l3, %g1, %l3
block_state = the_thread_queue->state; if ( _Thread_queue_Is_reverse_search( priority ) ) 20082a4: 12 80 00 28 bne 2008344 <_Thread_queue_Enqueue_priority+0xdc>
20082a8: a6 06 00 13 add %i0, %l3, %l3
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
20082ac: ac 04 e0 04 add %l3, 4, %l6
goto restart_reverse_search; restart_forward_search: search_priority = PRIORITY_MINIMUM - 1; _ISR_Disable( level );
20082b0: 7f ff e7 c0 call 20021b0 <sparc_disable_interrupts> 20082b4: 01 00 00 00 nop 20082b8: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->first;
20082bc: a8 10 3f ff mov -1, %l4
while ( !_Chain_Is_tail( header, (Chain_Node *)search_thread ) ) {
20082c0: 10 80 00 10 b 2008300 <_Thread_queue_Enqueue_priority+0x98> 20082c4: e2 04 c0 00 ld [ %l3 ], %l1
search_priority = search_thread->current_priority; if ( priority <= search_priority )
20082c8: 80 a4 00 14 cmp %l0, %l4 20082cc: 28 80 00 11 bleu,a 2008310 <_Thread_queue_Enqueue_priority+0xa8> 20082d0: c2 06 20 30 ld [ %i0 + 0x30 ], %g1
break; search_priority = search_thread->current_priority; if ( priority <= search_priority ) break; #endif _ISR_Flash( level );
20082d4: 7f ff e7 bb call 20021c0 <sparc_enable_interrupts> 20082d8: 90 10 00 12 mov %l2, %o0 20082dc: 7f ff e7 b5 call 20021b0 <sparc_disable_interrupts> 20082e0: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
20082e4: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 20082e8: 80 8d 40 01 btst %l5, %g1 20082ec: 32 80 00 05 bne,a 2008300 <_Thread_queue_Enqueue_priority+0x98> 20082f0: e2 04 40 00 ld [ %l1 ], %l1
_ISR_Enable( level );
20082f4: 7f ff e7 b3 call 20021c0 <sparc_enable_interrupts> <== NOT EXECUTED 20082f8: 90 10 00 12 mov %l2, %o0 <== NOT EXECUTED
goto restart_forward_search;
20082fc: 30 bf ff ed b,a 20082b0 <_Thread_queue_Enqueue_priority+0x48><== 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 ) ) {
2008300: 80 a4 40 16 cmp %l1, %l6 2008304: 32 bf ff f1 bne,a 20082c8 <_Thread_queue_Enqueue_priority+0x60> 2008308: e8 04 60 14 ld [ %l1 + 0x14 ], %l4
} search_thread = (Thread_Control *)search_thread->Object.Node.next; } if ( the_thread_queue->sync_state !=
200830c: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 2008310: 80 a0 60 01 cmp %g1, 1
2008314: 12 80 00 3c bne 2008404 <_Thread_queue_Enqueue_priority+0x19c>
2008318: 90 10 00 12 mov %l2, %o0
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority )
200831c: 80 a4 00 14 cmp %l0, %l4
2008320: 02 80 00 2e be 20083d8 <_Thread_queue_Enqueue_priority+0x170>
2008324: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority; search_node = (Chain_Node *) search_thread; previous_node = search_node->previous;
2008328: c2 04 60 04 ld [ %l1 + 4 ], %g1
the_node = (Chain_Node *) the_thread; the_node->next = search_node;
200832c: e2 26 40 00 st %l1, [ %i1 ]
the_node->previous = previous_node;
2008330: 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;
2008334: 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;
2008338: f2 20 40 00 st %i1, [ %g1 ]
search_node->previous = the_node;
200833c: f2 24 60 04 st %i1, [ %l1 + 4 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
2008340: 30 80 00 2d b,a 20083f4 <_Thread_queue_Enqueue_priority+0x18c>
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1; _ISR_Disable( level );
2008344: 7f ff e7 9b call 20021b0 <sparc_disable_interrupts> 2008348: e8 0d 80 00 ldub [ %l6 ], %l4
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level ); return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; restart_reverse_search: search_priority = PRIORITY_MAXIMUM + 1;
200834c: a8 05 20 01 inc %l4
_ISR_Disable( level );
2008350: a4 10 00 08 mov %o0, %l2
search_thread = (Thread_Control *) header->last; while ( !_Chain_Is_head( header, (Chain_Node *)search_thread ) ) {
2008354: 10 80 00 10 b 2008394 <_Thread_queue_Enqueue_priority+0x12c> 2008358: e2 04 e0 08 ld [ %l3 + 8 ], %l1
search_priority = search_thread->current_priority; if ( priority >= search_priority )
200835c: 80 a4 00 14 cmp %l0, %l4 2008360: 3a 80 00 11 bcc,a 20083a4 <_Thread_queue_Enqueue_priority+0x13c> 2008364: c2 06 20 30 ld [ %i0 + 0x30 ], %g1
break; search_priority = search_thread->current_priority; if ( priority >= search_priority ) break; #endif _ISR_Flash( level );
2008368: 7f ff e7 96 call 20021c0 <sparc_enable_interrupts> 200836c: 90 10 00 12 mov %l2, %o0 2008370: 7f ff e7 90 call 20021b0 <sparc_disable_interrupts> 2008374: 01 00 00 00 nop
if ( !_States_Are_set( search_thread->current_state, block_state) ) {
2008378: c2 04 60 10 ld [ %l1 + 0x10 ], %g1 200837c: 80 8d 40 01 btst %l5, %g1 2008380: 32 80 00 05 bne,a 2008394 <_Thread_queue_Enqueue_priority+0x12c> 2008384: e2 04 60 04 ld [ %l1 + 4 ], %l1
_ISR_Enable( level );
2008388: 7f ff e7 8e call 20021c0 <sparc_enable_interrupts> 200838c: 90 10 00 12 mov %l2, %o0
goto restart_reverse_search;
2008390: 30 bf ff ed b,a 2008344 <_Thread_queue_Enqueue_priority+0xdc>
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 ) ) {
2008394: 80 a4 40 13 cmp %l1, %l3 2008398: 32 bf ff f1 bne,a 200835c <_Thread_queue_Enqueue_priority+0xf4> 200839c: e8 04 60 14 ld [ %l1 + 0x14 ], %l4
} search_thread = (Thread_Control *) search_thread->Object.Node.previous; } if ( the_thread_queue->sync_state !=
20083a0: c2 06 20 30 ld [ %i0 + 0x30 ], %g1 20083a4: 80 a0 60 01 cmp %g1, 1
20083a8: 12 80 00 17 bne 2008404 <_Thread_queue_Enqueue_priority+0x19c>
20083ac: 90 10 00 12 mov %l2, %o0
THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED ) goto synchronize; the_thread_queue->sync_state = THREAD_BLOCKING_OPERATION_SYNCHRONIZED; if ( priority == search_priority )
20083b0: 80 a4 00 14 cmp %l0, %l4
20083b4: 02 80 00 09 be 20083d8 <_Thread_queue_Enqueue_priority+0x170>
20083b8: c0 26 20 30 clr [ %i0 + 0x30 ]
goto equal_priority; search_node = (Chain_Node *) search_thread; next_node = search_node->next;
20083bc: c2 04 40 00 ld [ %l1 ], %g1
the_node = (Chain_Node *) the_thread; the_node->next = next_node; the_node->previous = search_node;
20083c0: e2 26 60 04 st %l1, [ %i1 + 4 ]
search_node = (Chain_Node *) search_thread; next_node = search_node->next; the_node = (Chain_Node *) the_thread; the_node->next = next_node;
20083c4: 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;
20083c8: 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;
20083cc: f2 24 40 00 st %i1, [ %l1 ]
next_node->previous = the_node;
20083d0: f2 20 60 04 st %i1, [ %g1 + 4 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
20083d4: 30 80 00 08 b,a 20083f4 <_Thread_queue_Enqueue_priority+0x18c> 20083d8: a2 04 60 3c add %l1, 0x3c, %l1
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED; equal_priority: /* add at end of priority group */ search_node = _Chain_Tail( &search_thread->Wait.Block2n ); previous_node = search_node->previous;
20083dc: c2 04 60 04 ld [ %l1 + 4 ], %g1
the_node = (Chain_Node *) the_thread; the_node->next = search_node;
20083e0: e2 26 40 00 st %l1, [ %i1 ]
the_node->previous = previous_node;
20083e4: 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;
20083e8: 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;
20083ec: f2 20 40 00 st %i1, [ %g1 ]
search_node->previous = the_node;
20083f0: f2 24 60 04 st %i1, [ %l1 + 4 ]
the_thread->Wait.queue = the_thread_queue; _ISR_Enable( level );
20083f4: 7f ff e7 73 call 20021c0 <sparc_enable_interrupts> 20083f8: b0 10 20 01 mov 1, %i0
return THREAD_BLOCKING_OPERATION_NOTHING_HAPPENED;
20083fc: 81 c7 e0 08 ret 2008400: 81 e8 00 00 restore
* the mutex by an ISR or timed out. * * WARNING! Returning with interrupts disabled! */ *level_p = level; return the_thread_queue->sync_state;
2008404: f0 06 20 30 ld [ %i0 + 0x30 ], %i0
* For example, the blocking thread could have been given * the mutex by an ISR or timed out. * * WARNING! Returning with interrupts disabled! */ *level_p = level;
2008408: d0 26 80 00 st %o0, [ %i2 ]
return the_thread_queue->sync_state; }
200840c: 81 c7 e0 08 ret 2008410: 81 e8 00 00 restore
02015554 <_Timer_server_Body>: * @a arg points to the corresponding timer server control block. */ static rtems_task _Timer_server_Body( rtems_task_argument arg ) {
2015554: 9d e3 bf 88 save %sp, -120, %sp
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
2015558: 35 00 80 f2 sethi %hi(0x203c800), %i2 201555c: b2 07 bf f4 add %fp, -12, %i1 2015560: ac 07 bf f8 add %fp, -8, %l6 2015564: a2 07 bf e8 add %fp, -24, %l1 2015568: a6 07 bf ec add %fp, -20, %l3
static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
201556c: 37 00 80 f2 sethi %hi(0x203c800), %i3 2015570: 2b 00 80 f2 sethi %hi(0x203c800), %l5
RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain); the_chain->permanent_null = NULL;
2015574: c0 27 bf f8 clr [ %fp + -8 ] 2015578: c0 27 bf ec clr [ %fp + -20 ]
the_chain->last = _Chain_Head(the_chain);
201557c: f2 27 bf fc st %i1, [ %fp + -4 ]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
2015580: ec 27 bf f4 st %l6, [ %fp + -12 ]
the_chain->permanent_null = NULL; the_chain->last = _Chain_Head(the_chain);
2015584: e2 27 bf f0 st %l1, [ %fp + -16 ]
*/ RTEMS_INLINE_ROUTINE void _Chain_Initialize_empty( Chain_Control *the_chain ) { the_chain->first = _Chain_Tail(the_chain);
2015588: e6 27 bf e8 st %l3, [ %fp + -24 ]
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
201558c: b4 16 a2 04 or %i2, 0x204, %i2
static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
2015590: b6 16 e1 44 or %i3, 0x144, %i3 2015594: aa 15 60 b0 or %l5, 0xb0, %l5
*/ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
2015598: a8 06 20 30 add %i0, 0x30, %l4
/* * This path is for normal forward movement and cases where the * TOD has been set forward. */ delta = snapshot - last_snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
201559c: a4 06 20 68 add %i0, 0x68, %l2
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
20155a0: b8 06 20 08 add %i0, 8, %i4
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
20155a4: ba 06 20 40 add %i0, 0x40, %i5
_Thread_Set_state( ts->thread, STATES_DELAYING ); _Timer_server_Reset_interval_system_watchdog( ts ); _Timer_server_Reset_tod_system_watchdog( ts ); _Thread_Enable_dispatch(); ts->active = true;
20155a8: ae 10 20 01 mov 1, %l7
{ /* * Afterwards all timer inserts are directed to this chain and the interval * and TOD chains will be no more modified by other parties. */ ts->insert_chain = insert_chain;
20155ac: f2 26 20 78 st %i1, [ %i0 + 0x78 ]
static void _Timer_server_Process_interval_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = _Watchdog_Ticks_since_boot;
20155b0: c2 06 80 00 ld [ %i2 ], %g1
/* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot;
20155b4: d2 06 20 3c ld [ %i0 + 0x3c ], %o1
watchdogs->last_snapshot = snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20155b8: 94 10 00 11 mov %l1, %o2
/* * We assume adequate unsigned arithmetic here. */ Watchdog_Interval delta = snapshot - watchdogs->last_snapshot; watchdogs->last_snapshot = snapshot;
20155bc: c2 26 20 3c st %g1, [ %i0 + 0x3c ]
_Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20155c0: 92 20 40 09 sub %g1, %o1, %o1 20155c4: 40 00 11 a5 call 2019c58 <_Watchdog_Adjust_to_chain> 20155c8: 90 10 00 14 mov %l4, %o0
Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch(); Watchdog_Interval last_snapshot = watchdogs->last_snapshot;
20155cc: d4 06 20 74 ld [ %i0 + 0x74 ], %o2
static void _Timer_server_Process_tod_watchdogs( Timer_server_Watchdogs *watchdogs, Chain_Control *fire_chain ) { Watchdog_Interval snapshot = (Watchdog_Interval) _TOD_Seconds_since_epoch();
20155d0: e0 06 c0 00 ld [ %i3 ], %l0
/* * Process the seconds chain. Start by checking that the Time * of Day (TOD) has not been set backwards. If it has then * we want to adjust the watchdogs->Chain to indicate this. */ if ( snapshot > last_snapshot ) {
20155d4: 80 a4 00 0a cmp %l0, %o2
20155d8: 08 80 00 06 bleu 20155f0 <_Timer_server_Body+0x9c>
20155dc: 92 24 00 0a sub %l0, %o2, %o1
/* * This path is for normal forward movement and cases where the * TOD has been set forward. */ delta = snapshot - last_snapshot; _Watchdog_Adjust_to_chain( &watchdogs->Chain, delta, fire_chain );
20155e0: 90 10 00 12 mov %l2, %o0 20155e4: 40 00 11 9d call 2019c58 <_Watchdog_Adjust_to_chain> 20155e8: 94 10 00 11 mov %l1, %o2 20155ec: 30 80 00 06 b,a 2015604 <_Timer_server_Body+0xb0>
} else if ( snapshot < last_snapshot ) { 20155f0: 1a 80 00 05 bcc 2015604 <_Timer_server_Body+0xb0>
20155f4: 94 22 80 10 sub %o2, %l0, %o2
/* * The current TOD is before the last TOD which indicates that * TOD has been set backwards. */ delta = last_snapshot - snapshot; _Watchdog_Adjust( &watchdogs->Chain, WATCHDOG_BACKWARD, delta );
20155f8: 90 10 00 12 mov %l2, %o0 20155fc: 40 00 11 70 call 2019bbc <_Watchdog_Adjust> 2015600: 92 10 20 01 mov 1, %o1
} watchdogs->last_snapshot = snapshot;
2015604: e0 26 20 74 st %l0, [ %i0 + 0x74 ]
} static void _Timer_server_Process_insertions( Timer_server_Control *ts ) { while ( true ) { Timer_Control *timer = (Timer_Control *) _Chain_Get( ts->insert_chain );
2015608: d0 06 20 78 ld [ %i0 + 0x78 ], %o0 201560c: 40 00 02 7e call 2016004 <_Chain_Get> 2015610: 01 00 00 00 nop
if ( timer == NULL ) {
2015614: 80 a2 20 00 cmp %o0, 0
2015618: 02 80 00 0f be 2015654 <_Timer_server_Body+0x100>
201561c: 01 00 00 00 nop
static void _Timer_server_Insert_timer( Timer_server_Control *ts, Timer_Control *timer ) { if ( timer->the_class == TIMER_INTERVAL_ON_TASK ) {
2015620: c2 02 20 38 ld [ %o0 + 0x38 ], %g1 2015624: 80 a0 60 01 cmp %g1, 1
2015628: 12 80 00 05 bne 201563c <_Timer_server_Body+0xe8>
201562c: 80 a0 60 03 cmp %g1, 3
_Watchdog_Insert( &ts->Interval_watchdogs.Chain, &timer->Ticker );
2015630: 92 02 20 10 add %o0, 0x10, %o1 2015634: 10 80 00 05 b 2015648 <_Timer_server_Body+0xf4> 2015638: 90 10 00 14 mov %l4, %o0
} else if ( timer->the_class == TIMER_TIME_OF_DAY_ON_TASK ) { 201563c: 12 bf ff f3 bne 2015608 <_Timer_server_Body+0xb4>
2015640: 92 02 20 10 add %o0, 0x10, %o1
_Watchdog_Insert( &ts->TOD_watchdogs.Chain, &timer->Ticker );
2015644: 90 10 00 12 mov %l2, %o0 2015648: 40 00 11 b9 call 2019d2c <_Watchdog_Insert> 201564c: 01 00 00 00 nop 2015650: 30 bf ff ee b,a 2015608 <_Timer_server_Body+0xb4>
* of zero it will be processed in the next iteration of the timer server * body loop. */ _Timer_server_Process_insertions( ts ); _ISR_Disable( level );
2015654: 7f ff e5 06 call 200ea6c <sparc_disable_interrupts> 2015658: 01 00 00 00 nop
if ( _Chain_Is_empty( insert_chain ) ) {
201565c: c2 07 bf f4 ld [ %fp + -12 ], %g1 2015660: 80 a0 40 16 cmp %g1, %l6
2015664: 12 80 00 0a bne 201568c <_Timer_server_Body+0x138>
2015668: 01 00 00 00 nop
ts->insert_chain = NULL;
201566c: c0 26 20 78 clr [ %i0 + 0x78 ]
_ISR_Enable( level );
2015670: 7f ff e5 03 call 200ea7c <sparc_enable_interrupts> 2015674: 01 00 00 00 nop
_Chain_Initialize_empty( &fire_chain ); while ( true ) { _Timer_server_Get_watchdogs_that_fire_now( ts, &insert_chain, &fire_chain ); if ( !_Chain_Is_empty( &fire_chain ) ) {
2015678: c2 07 bf e8 ld [ %fp + -24 ], %g1 201567c: 80 a0 40 13 cmp %g1, %l3
2015680: 12 80 00 06 bne 2015698 <_Timer_server_Body+0x144>
2015684: 01 00 00 00 nop 2015688: 30 80 00 1a b,a 20156f0 <_Timer_server_Body+0x19c>
ts->insert_chain = NULL; _ISR_Enable( level ); break; } else { _ISR_Enable( level );
201568c: 7f ff e4 fc call 200ea7c <sparc_enable_interrupts> <== NOT EXECUTED 2015690: 01 00 00 00 nop <== NOT EXECUTED 2015694: 30 bf ff c7 b,a 20155b0 <_Timer_server_Body+0x5c> <== NOT EXECUTED
/* * It is essential that interrupts are disable here since an interrupt * service routine may remove a watchdog from the chain. */ _ISR_Disable( level );
2015698: 7f ff e4 f5 call 200ea6c <sparc_disable_interrupts> 201569c: 01 00 00 00 nop 20156a0: 84 10 00 08 mov %o0, %g2
*/ RTEMS_INLINE_ROUTINE bool _Chain_Is_empty( Chain_Control *the_chain ) { return (the_chain->first == _Chain_Tail(the_chain));
20156a4: e0 07 bf e8 ld [ %fp + -24 ], %l0
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Get_unprotected( Chain_Control *the_chain ) { if ( !_Chain_Is_empty(the_chain))
20156a8: 80 a4 00 13 cmp %l0, %l3
20156ac: 02 80 00 0e be 20156e4 <_Timer_server_Body+0x190>
20156b0: 80 a4 20 00 cmp %l0, 0
{ Chain_Node *return_node; Chain_Node *new_first; return_node = the_chain->first; new_first = return_node->next;
20156b4: c2 04 00 00 ld [ %l0 ], %g1
the_chain->first = new_first;
20156b8: c2 27 bf e8 st %g1, [ %fp + -24 ]
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { 20156bc: 02 80 00 0a be 20156e4 <_Timer_server_Body+0x190>
20156c0: e2 20 60 04 st %l1, [ %g1 + 4 ]
watchdog->state = WATCHDOG_INACTIVE;
20156c4: c0 24 20 08 clr [ %l0 + 8 ]
_ISR_Enable( level );
20156c8: 7f ff e4 ed call 200ea7c <sparc_enable_interrupts> 20156cc: 01 00 00 00 nop
/* * The timer server may block here and wait for resources or time. * The system watchdogs are inactive and will remain inactive since * the active flag of the timer server is true. */ (*watchdog->routine)( watchdog->id, watchdog->user_data );
20156d0: d2 04 20 24 ld [ %l0 + 0x24 ], %o1 20156d4: c2 04 20 1c ld [ %l0 + 0x1c ], %g1 20156d8: 9f c0 40 00 call %g1 20156dc: d0 04 20 20 ld [ %l0 + 0x20 ], %o0
}
20156e0: 30 bf ff ee b,a 2015698 <_Timer_server_Body+0x144>
watchdog = (Watchdog_Control *) _Chain_Get_unprotected( &fire_chain ); if ( watchdog != NULL ) { watchdog->state = WATCHDOG_INACTIVE; _ISR_Enable( level ); } else { _ISR_Enable( level );
20156e4: 7f ff e4 e6 call 200ea7c <sparc_enable_interrupts> 20156e8: 90 10 00 02 mov %g2, %o0 20156ec: 30 bf ff b0 b,a 20155ac <_Timer_server_Body+0x58>
* the active flag of the timer server is true. */ (*watchdog->routine)( watchdog->id, watchdog->user_data ); } } else { ts->active = false;
20156f0: c0 2e 20 7c clrb [ %i0 + 0x7c ] 20156f4: c2 05 40 00 ld [ %l5 ], %g1 20156f8: 82 00 60 01 inc %g1 20156fc: c2 25 40 00 st %g1, [ %l5 ]
/* * Block until there is something to do. */ _Thread_Disable_dispatch(); _Thread_Set_state( ts->thread, STATES_DELAYING );
2015700: d0 06 00 00 ld [ %i0 ], %o0 2015704: 40 00 0e 8b call 2019130 <_Thread_Set_state> 2015708: 92 10 20 08 mov 8, %o1
_Timer_server_Reset_interval_system_watchdog( ts );
201570c: 7f ff ff 68 call 20154ac <_Timer_server_Reset_interval_system_watchdog> 2015710: 90 10 00 18 mov %i0, %o0
_Timer_server_Reset_tod_system_watchdog( ts );
2015714: 7f ff ff 7b call 2015500 <_Timer_server_Reset_tod_system_watchdog> 2015718: 90 10 00 18 mov %i0, %o0
_Thread_Enable_dispatch();
201571c: 40 00 0b af call 20185d8 <_Thread_Enable_dispatch> 2015720: 01 00 00 00 nop
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
2015724: 90 10 00 1c mov %i4, %o0
_Thread_Set_state( ts->thread, STATES_DELAYING ); _Timer_server_Reset_interval_system_watchdog( ts ); _Timer_server_Reset_tod_system_watchdog( ts ); _Thread_Enable_dispatch(); ts->active = true;
2015728: ee 2e 20 7c stb %l7, [ %i0 + 0x7c ]
static void _Timer_server_Stop_interval_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->Interval_watchdogs.System_watchdog );
201572c: 40 00 11 dd call 2019ea0 <_Watchdog_Remove> 2015730: 01 00 00 00 nop
static void _Timer_server_Stop_tod_system_watchdog( Timer_server_Control *ts ) { _Watchdog_Remove( &ts->TOD_watchdogs.System_watchdog );
2015734: 40 00 11 db call 2019ea0 <_Watchdog_Remove> 2015738: 90 10 00 1d mov %i5, %o0 201573c: 30 bf ff 9c b,a 20155ac <_Timer_server_Body+0x58>
0200e81c <killinfo>: int killinfo( pid_t pid, int sig, const union sigval *value ) {
200e81c: 9d e3 bf 90 save %sp, -112, %sp
POSIX_signals_Siginfo_node *psiginfo; /* * Only supported for the "calling process" (i.e. this node). */ if ( pid != getpid() )
200e820: 7f ff fb f6 call 200d7f8 <getpid> 200e824: 01 00 00 00 nop 200e828: 80 a6 00 08 cmp %i0, %o0
200e82c: 02 80 00 06 be 200e844 <killinfo+0x28>
200e830: 80 a6 60 00 cmp %i1, 0
rtems_set_errno_and_return_minus_one( ESRCH );
200e834: 40 00 01 97 call 200ee90 <__errno> 200e838: 01 00 00 00 nop 200e83c: 10 80 00 07 b 200e858 <killinfo+0x3c> 200e840: 82 10 20 03 mov 3, %g1 ! 3 <PROM_START+0x3>
/* * Validate the signal passed. */ if ( !sig ) 200e844: 12 80 00 08 bne 200e864 <killinfo+0x48>
200e848: 82 06 7f ff add %i1, -1, %g1
rtems_set_errno_and_return_minus_one( EINVAL );
200e84c: 40 00 01 91 call 200ee90 <__errno> 200e850: 01 00 00 00 nop 200e854: 82 10 20 16 mov 0x16, %g1 ! 16 <PROM_START+0x16> 200e858: c2 22 00 00 st %g1, [ %o0 ] 200e85c: 10 80 00 a5 b 200eaf0 <killinfo+0x2d4> 200e860: 90 10 3f ff mov -1, %o0
if ( !is_valid_signo(sig) )
200e864: 80 a0 60 1f cmp %g1, 0x1f
200e868: 18 bf ff f9 bgu 200e84c <killinfo+0x30>
200e86c: 85 2e 60 02 sll %i1, 2, %g2
rtems_set_errno_and_return_minus_one( EINVAL ); /* * If the signal is being ignored, then we are out of here. */ if ( _POSIX_signals_Vectors[ sig ].sa_handler == SIG_IGN )
200e870: 87 2e 60 04 sll %i1, 4, %g3 200e874: 86 20 c0 02 sub %g3, %g2, %g3 200e878: 05 00 80 70 sethi %hi(0x201c000), %g2 200e87c: 84 10 a2 b4 or %g2, 0x2b4, %g2 ! 201c2b4 <_POSIX_signals_Vectors> 200e880: 84 00 80 03 add %g2, %g3, %g2 200e884: c4 00 a0 08 ld [ %g2 + 8 ], %g2 200e888: 80 a0 a0 01 cmp %g2, 1
200e88c: 02 80 00 99 be 200eaf0 <killinfo+0x2d4>
200e890: 90 10 20 00 clr %o0
/* * P1003.1c/Draft 10, p. 33 says that certain signals should always * be directed to the executing thread such as those caused by hardware * faults. */ if ( (sig == SIGFPE) || (sig == SIGILL) || (sig == SIGSEGV ) )
200e894: 80 a6 60 04 cmp %i1, 4
200e898: 02 80 00 06 be 200e8b0 <killinfo+0x94>
200e89c: 80 a6 60 08 cmp %i1, 8
200e8a0: 02 80 00 04 be 200e8b0 <killinfo+0x94>
200e8a4: 80 a6 60 0b cmp %i1, 0xb
200e8a8: 12 80 00 08 bne 200e8c8 <killinfo+0xac>
200e8ac: a0 10 20 01 mov 1, %l0
return pthread_kill( pthread_self(), sig );
200e8b0: 40 00 01 4f call 200edec <pthread_self> 200e8b4: 01 00 00 00 nop 200e8b8: 40 00 01 11 call 200ecfc <pthread_kill> 200e8bc: 92 10 00 19 mov %i1, %o1 200e8c0: 81 c7 e0 08 ret 200e8c4: 91 e8 00 08 restore %g0, %o0, %o0
/* * Build up a siginfo structure */ siginfo = &siginfo_struct; siginfo->si_signo = sig;
200e8c8: f2 27 bf f4 st %i1, [ %fp + -12 ]
siginfo->si_code = SI_USER;
200e8cc: e0 27 bf f8 st %l0, [ %fp + -8 ]
if ( !value ) {
200e8d0: 80 a6 a0 00 cmp %i2, 0
200e8d4: 12 80 00 04 bne 200e8e4 <killinfo+0xc8>
200e8d8: a1 2c 00 01 sll %l0, %g1, %l0
siginfo->si_value.sival_int = 0;
200e8dc: 10 80 00 04 b 200e8ec <killinfo+0xd0> 200e8e0: c0 27 bf fc clr [ %fp + -4 ]
} else { siginfo->si_value = *value;
200e8e4: c2 06 80 00 ld [ %i2 ], %g1 200e8e8: c2 27 bf fc st %g1, [ %fp + -4 ] 200e8ec: 03 00 80 6f sethi %hi(0x201bc00), %g1 200e8f0: c4 00 61 20 ld [ %g1 + 0x120 ], %g2 ! 201bd20 <_Thread_Dispatch_disable_level> 200e8f4: 84 00 a0 01 inc %g2 200e8f8: c4 20 61 20 st %g2, [ %g1 + 0x120 ]
/* * Is the currently executing thread interested? If so then it will * get it an execute it as soon as the dispatcher executes. */ the_thread = _Thread_Executing;
200e8fc: 03 00 80 6f sethi %hi(0x201bc00), %g1 200e900: c2 00 61 e0 ld [ %g1 + 0x1e0 ], %g1 ! 201bde0 <_Thread_Executing>
api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200e904: c4 00 61 6c ld [ %g1 + 0x16c ], %g2 200e908: c4 00 a0 cc ld [ %g2 + 0xcc ], %g2 200e90c: 80 ac 00 02 andncc %l0, %g2, %g0
200e910: 12 80 00 4e bne 200ea48 <killinfo+0x22c>
200e914: 07 00 80 71 sethi %hi(0x201c400), %g3
/* XXX violation of visibility -- need to define thread queue support */ the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo; for ( the_node = the_chain->first ;
200e918: 03 00 80 71 sethi %hi(0x201c400), %g1 200e91c: c4 00 60 40 ld [ %g1 + 0x40 ], %g2 ! 201c440 <_POSIX_signals_Wait_queue> 200e920: 10 80 00 0b b 200e94c <killinfo+0x130> 200e924: 86 10 e0 44 or %g3, 0x44, %g3
!_Chain_Is_tail( the_chain, the_node ) ; the_node = the_node->next ) { the_thread = (Thread_Control *)the_node; api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200e928: c8 00 a1 6c ld [ %g2 + 0x16c ], %g4
#endif /* * Is this thread is actually blocked waiting for the signal? */ if (the_thread->Wait.option & mask)
200e92c: 80 8c 00 01 btst %l0, %g1
200e930: 12 80 00 46 bne 200ea48 <killinfo+0x22c>
200e934: 82 10 00 02 mov %g2, %g1
/* * Is this thread is blocked waiting for another signal but has * not blocked this one? */ if (~api->signals_blocked & mask)
200e938: c8 01 20 cc ld [ %g4 + 0xcc ], %g4 200e93c: 80 ac 00 04 andncc %l0, %g4, %g0 200e940: 32 80 00 43 bne,a 200ea4c <killinfo+0x230> 200e944: 84 10 20 01 mov 1, %g2
the_chain = &_POSIX_signals_Wait_queue.Queues.Fifo; for ( the_node = the_chain->first ; !_Chain_Is_tail( the_chain, the_node ) ; the_node = the_node->next ) {
200e948: c4 00 80 00 ld [ %g2 ], %g2
*/ RTEMS_INLINE_ROUTINE Chain_Node *_Chain_Tail( Chain_Control *the_chain ) { return (Chain_Node *) &the_chain->permanent_null;
200e94c: 80 a0 80 03 cmp %g2, %g3 200e950: 32 bf ff f6 bne,a 200e928 <killinfo+0x10c> 200e954: c2 00 a0 30 ld [ %g2 + 0x30 ], %g1
* NOTES: * * + rtems internal threads do not receive signals. */ interested = NULL; interested_priority = PRIORITY_MAXIMUM + 1;
200e958: 03 00 80 6c sethi %hi(0x201b000), %g1 200e95c: c8 08 62 04 ldub [ %g1 + 0x204 ], %g4 ! 201b204 <rtems_maximum_priority> 200e960: 05 00 80 6f sethi %hi(0x201bc00), %g2 200e964: 88 01 20 01 inc %g4 200e968: 84 10 a0 88 or %g2, 0x88, %g2
*/ #define _POSIX_signals_Is_interested( _api, _mask ) \ ( ~(_api)->signals_blocked & (_mask) ) int killinfo(
200e96c: 82 10 20 00 clr %g1 200e970: 90 00 a0 0c add %g2, 0xc, %o0
continue; } DEBUG_STEP("6"); /* prefer blocked/interruptible over blocked/not interruptible */ if ( !_States_Is_interruptible_by_signal(interested->current_state) ) {
200e974: 17 04 00 00 sethi %hi(0x10000000), %o3
for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) { /* * This can occur when no one is interested and ITRON is not configured. */ if ( !_Objects_Information_table[ the_api ] )
200e978: c6 00 80 00 ld [ %g2 ], %g3 200e97c: 80 a0 e0 00 cmp %g3, 0 200e980: 22 80 00 2c be,a 200ea30 <killinfo+0x214> 200e984: 84 00 a0 04 add %g2, 4, %g2
continue; the_info = _Objects_Information_table[ the_api ][ 1 ];
200e988: c6 00 e0 04 ld [ %g3 + 4 ], %g3
if ( !the_info ) continue; #endif maximum = the_info->maximum; object_table = the_info->local_table;
200e98c: 9a 10 20 01 mov 1, %o5 200e990: f4 00 e0 1c ld [ %g3 + 0x1c ], %i2
for ( index = 1 ; index <= maximum ; index++ ) {
200e994: 10 80 00 23 b 200ea20 <killinfo+0x204> 200e998: de 10 e0 10 lduh [ %g3 + 0x10 ], %o7
the_thread = (Thread_Control *) object_table[ index ];
200e99c: c6 06 80 03 ld [ %i2 + %g3 ], %g3
if ( !the_thread )
200e9a0: 80 a0 e0 00 cmp %g3, 0
200e9a4: 02 80 00 1d be 200ea18 <killinfo+0x1fc>
200e9a8: 98 10 00 04 mov %g4, %o4
/* * If this thread is of lower priority than the interested thread, * go on to the next thread. */ if ( the_thread->current_priority > interested_priority )
200e9ac: d8 00 e0 14 ld [ %g3 + 0x14 ], %o4 200e9b0: 80 a3 00 04 cmp %o4, %g4 200e9b4: 38 80 00 19 bgu,a 200ea18 <killinfo+0x1fc> 200e9b8: 98 10 00 04 mov %g4, %o4
DEBUG_STEP("2"); /* * If this thread is not interested, then go on to the next thread. */ api = the_thread->API_Extensions[ THREAD_API_POSIX ];
200e9bc: d4 00 e1 6c ld [ %g3 + 0x16c ], %o2 200e9c0: d4 02 a0 cc ld [ %o2 + 0xcc ], %o2 200e9c4: 80 ac 00 0a andncc %l0, %o2, %g0 200e9c8: 22 80 00 14 be,a 200ea18 <killinfo+0x1fc> 200e9cc: 98 10 00 04 mov %g4, %o4
* * NOTE: We initialized interested_priority to PRIORITY_MAXIMUM + 1 * so we never have to worry about deferencing a NULL * interested thread. */ if ( the_thread->current_priority < interested_priority ) {
200e9d0: 80 a3 00 04 cmp %o4, %g4 200e9d4: 2a 80 00 11 bcs,a 200ea18 <killinfo+0x1fc> 200e9d8: 82 10 00 03 mov %g3, %g1
* and blocking interruptibutable by signal. * * If the interested thread is ready, don't think about changing. */ if ( !_States_Is_ready( interested->current_state ) ) {
200e9dc: d2 00 60 10 ld [ %g1 + 0x10 ], %o1 200e9e0: 80 a2 60 00 cmp %o1, 0 200e9e4: 22 80 00 0d be,a 200ea18 <killinfo+0x1fc>
200e9e8: 98 10 00 04 mov %g4, %o4 <== NOT EXECUTED
/* preferred ready over blocked */ DEBUG_STEP("5"); if ( _States_Is_ready( the_thread->current_state ) ) {
200e9ec: d4 00 e0 10 ld [ %g3 + 0x10 ], %o2 200e9f0: 80 a2 a0 00 cmp %o2, 0 200e9f4: 22 80 00 09 be,a 200ea18 <killinfo+0x1fc> 200e9f8: 82 10 00 03 mov %g3, %g1
continue; } DEBUG_STEP("6"); /* prefer blocked/interruptible over blocked/not interruptible */ if ( !_States_Is_interruptible_by_signal(interested->current_state) ) {
200e9fc: 80 8a 40 0b btst %o1, %o3 200ea00: 32 80 00 06 bne,a 200ea18 <killinfo+0x1fc> 200ea04: 98 10 00 04 mov %g4, %o4
DEBUG_STEP("7"); if ( _States_Is_interruptible_by_signal(the_thread->current_state) ) {
200ea08: 80 8a 80 0b btst %o2, %o3 200ea0c: 32 80 00 03 bne,a 200ea18 <killinfo+0x1fc> 200ea10: 82 10 00 03 mov %g3, %g1 200ea14: 98 10 00 04 mov %g4, %o4
#endif maximum = the_info->maximum; object_table = the_info->local_table; for ( index = 1 ; index <= maximum ; index++ ) {
200ea18: 9a 03 60 01 inc %o5 200ea1c: 88 10 00 0c mov %o4, %g4 200ea20: 80 a3 40 0f cmp %o5, %o7 200ea24: 28 bf ff de bleu,a 200e99c <killinfo+0x180> 200ea28: 87 2b 60 02 sll %o5, 2, %g3 200ea2c: 84 00 a0 04 add %g2, 4, %g2
* + rtems internal threads do not receive signals. */ interested = NULL; interested_priority = PRIORITY_MAXIMUM + 1; for (the_api = OBJECTS_CLASSIC_API; the_api <= OBJECTS_APIS_LAST; the_api++) {
200ea30: 80 a0 80 08 cmp %g2, %o0 200ea34: 32 bf ff d2 bne,a 200e97c <killinfo+0x160> 200ea38: c6 00 80 00 ld [ %g2 ], %g3
} } } } if ( interested ) {
200ea3c: 80 a0 60 00 cmp %g1, 0
200ea40: 02 80 00 0b be 200ea6c <killinfo+0x250>
200ea44: 01 00 00 00 nop
* thread needs to do the post context switch extension so it can * evaluate the signals pending. */ process_it: the_thread->do_post_task_switch_extension = true;
200ea48: 84 10 20 01 mov 1, %g2 ! 1 <PROM_START+0x1>
/* * Returns true if the signal was synchronously given to a thread * blocked waiting for the signal. */ if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
200ea4c: 90 10 00 01 mov %g1, %o0
* thread needs to do the post context switch extension so it can * evaluate the signals pending. */ process_it: the_thread->do_post_task_switch_extension = true;
200ea50: c4 28 60 74 stb %g2, [ %g1 + 0x74 ]
/* * Returns true if the signal was synchronously given to a thread * blocked waiting for the signal. */ if ( _POSIX_signals_Unblock_thread( the_thread, sig, siginfo ) ) {
200ea54: 92 10 00 19 mov %i1, %o1 200ea58: 40 00 00 5d call 200ebcc <_POSIX_signals_Unblock_thread> 200ea5c: 94 07 bf f4 add %fp, -12, %o2 200ea60: 80 8a 20 ff btst 0xff, %o0
200ea64: 12 80 00 20 bne 200eae4 <killinfo+0x2c8>
200ea68: 01 00 00 00 nop
/* * We may have woken up a thread but we definitely need to post the * signal to the process wide information set. */ _POSIX_signals_Set_process_signals( mask );
200ea6c: 40 00 00 47 call 200eb88 <_POSIX_signals_Set_process_signals> 200ea70: 90 10 00 10 mov %l0, %o0
if ( _POSIX_signals_Vectors[ sig ].sa_flags == SA_SIGINFO ) {
200ea74: 83 2e 60 04 sll %i1, 4, %g1 200ea78: b3 2e 60 02 sll %i1, 2, %i1 200ea7c: b2 20 40 19 sub %g1, %i1, %i1 200ea80: 03 00 80 70 sethi %hi(0x201c000), %g1 200ea84: 82 10 62 b4 or %g1, 0x2b4, %g1 ! 201c2b4 <_POSIX_signals_Vectors> 200ea88: c2 00 40 19 ld [ %g1 + %i1 ], %g1 200ea8c: 80 a0 60 02 cmp %g1, 2
200ea90: 12 80 00 15 bne 200eae4 <killinfo+0x2c8>
200ea94: 11 00 80 71 sethi %hi(0x201c400), %o0
psiginfo = (POSIX_signals_Siginfo_node *)
200ea98: 7f ff f4 bc call 200bd88 <_Chain_Get> 200ea9c: 90 12 20 34 or %o0, 0x34, %o0 ! 201c434 <_POSIX_signals_Inactive_siginfo>
_Chain_Get( &_POSIX_signals_Inactive_siginfo ); if ( !psiginfo ) {
200eaa0: a0 92 20 00 orcc %o0, 0, %l0
200eaa4: 12 80 00 08 bne 200eac4 <killinfo+0x2a8>
200eaa8: 92 07 bf f4 add %fp, -12, %o1
_Thread_Enable_dispatch();
200eaac: 7f ff e4 65 call 2007c40 <_Thread_Enable_dispatch> 200eab0: 01 00 00 00 nop
rtems_set_errno_and_return_minus_one( EAGAIN );
200eab4: 40 00 00 f7 call 200ee90 <__errno> 200eab8: 01 00 00 00 nop 200eabc: 10 bf ff 67 b 200e858 <killinfo+0x3c> 200eac0: 82 10 20 0b mov 0xb, %g1 ! b <PROM_START+0xb>
} psiginfo->Info = *siginfo;
200eac4: 90 04 20 08 add %l0, 8, %o0 200eac8: 40 00 03 2e call 200f780 <memcpy> 200eacc: 94 10 20 0c mov 0xc, %o2
_Chain_Append( &_POSIX_signals_Siginfo[ sig ], &psiginfo->Node );
200ead0: 11 00 80 71 sethi %hi(0x201c400), %o0 200ead4: 92 10 00 10 mov %l0, %o1 200ead8: 90 12 20 ac or %o0, 0xac, %o0 200eadc: 7f ff de 6a call 2006484 <_Chain_Append> 200eae0: 90 02 00 19 add %o0, %i1, %o0
} DEBUG_STEP("\n"); _Thread_Enable_dispatch();
200eae4: 7f ff e4 57 call 2007c40 <_Thread_Enable_dispatch> 200eae8: 01 00 00 00 nop 200eaec: 90 10 20 00 clr %o0 ! 0 <PROM_START>
return 0; }
200eaf0: b0 10 00 08 mov %o0, %i0 200eaf4: 81 c7 e0 08 ret 200eaf8: 81 e8 00 00 restore