Lines Matching refs:profile

311 		info->profile.sample_area = -1;  in init_thread_debug_info()
312 info->profile.interval = 0; in init_thread_debug_info()
313 info->profile.samples = NULL; in init_thread_debug_info()
314 info->profile.flush_needed = false; in init_thread_debug_info()
315 info->profile.installed_timer = NULL; in init_thread_debug_info()
328 if (info->profile.installed_timer != NULL) { in clear_thread_debug_info()
329 cancel_timer(info->profile.installed_timer); in clear_thread_debug_info()
330 info->profile.installed_timer->hook = NULL; in clear_thread_debug_info()
331 info->profile.installed_timer = NULL; in clear_thread_debug_info()
340 info->profile.sample_area = -1; in clear_thread_debug_info()
341 info->profile.interval = 0; in clear_thread_debug_info()
342 info->profile.samples = NULL; in clear_thread_debug_info()
343 info->profile.flush_needed = false; in clear_thread_debug_info()
352 area_id sampleArea = info->profile.sample_area; in destroy_thread_debug_info()
865 if (thread->debug_info.profile.samples == NULL) in user_debug_pre_syscall()
866 thread->debug_info.profile.syscall_start_time = system_time(); in user_debug_pre_syscall()
881 if (thread->debug_info.profile.flush_needed) in user_debug_post_syscall()
892 if (thread->debug_info.profile.samples == NULL) { in user_debug_post_syscall()
893 startTime = thread->debug_info.profile.syscall_start_time; in user_debug_post_syscall()
894 thread->debug_info.profile.syscall_start_time = 0; in user_debug_post_syscall()
1186 if (threadDebugInfo.profile.samples == NULL) in user_debug_thread_exiting()
1189 area_id sampleArea = threadDebugInfo.profile.sample_area; in user_debug_thread_exiting()
1190 int32 sampleCount = threadDebugInfo.profile.sample_count; in user_debug_thread_exiting()
1191 int32 droppedTicks = threadDebugInfo.profile.dropped_ticks; in user_debug_thread_exiting()
1192 int32 stackDepth = threadDebugInfo.profile.stack_depth; in user_debug_thread_exiting()
1193 bool variableStackDepth = threadDebugInfo.profile.variable_stack_depth; in user_debug_thread_exiting()
1194 int32 imageEvent = threadDebugInfo.profile.image_event; in user_debug_thread_exiting()
1195 threadDebugInfo.profile.sample_area = -1; in user_debug_thread_exiting()
1196 threadDebugInfo.profile.samples = NULL; in user_debug_thread_exiting()
1197 threadDebugInfo.profile.flush_needed = false; in user_debug_thread_exiting()
1328 thread->debug_info.profile.installed_timer = timer; in schedule_profiling_timer()
1329 thread->debug_info.profile.timer_end = system_time() + interval; in schedule_profiling_timer()
1341 return thread->debug_info.profile.timer_end - system_time(); in profiling_timer_left()
1355 if (debugInfo.profile.samples == NULL) in profiling_do_sample()
1360 int32 maxSamples = debugInfo.profile.max_samples; in profiling_do_sample()
1361 int32 sampleCount = debugInfo.profile.sample_count; in profiling_do_sample()
1362 int32 stackDepth = debugInfo.profile.stack_depth; in profiling_do_sample()
1364 if (debugInfo.profile.sample_count > 0) { in profiling_do_sample()
1365 if (debugInfo.profile.last_image_event < imageEvent in profiling_do_sample()
1366 && debugInfo.profile.variable_stack_depth in profiling_do_sample()
1370 addr_t* event = debugInfo.profile.samples + sampleCount; in profiling_do_sample()
1374 debugInfo.profile.sample_count = sampleCount; in profiling_do_sample()
1375 debugInfo.profile.last_image_event = imageEvent; in profiling_do_sample()
1378 if (debugInfo.profile.last_image_event < imageEvent in profiling_do_sample()
1379 || debugInfo.profile.flush_threshold - sampleCount < stackDepth) { in profiling_do_sample()
1380 debugInfo.profile.flush_needed = true; in profiling_do_sample()
1385 debugInfo.profile.dropped_ticks++; in profiling_do_sample()
1391 debugInfo.profile.image_event = imageEvent; in profiling_do_sample()
1392 debugInfo.profile.last_image_event = imageEvent; in profiling_do_sample()
1398 if (debugInfo.profile.profile_kernel) { in profiling_do_sample()
1403 addr_t* returnAddresses = debugInfo.profile.samples in profiling_do_sample()
1404 + debugInfo.profile.sample_count; in profiling_do_sample()
1405 if (debugInfo.profile.variable_stack_depth) { in profiling_do_sample()
1410 debugInfo.profile.sample_count += *returnAddresses + 1; in profiling_do_sample()
1413 if (stackDepth > 1 || !debugInfo.profile.profile_kernel) { in profiling_do_sample()
1422 debugInfo.profile.sample_count += stackDepth; in profiling_do_sample()
1444 if (debugInfo.profile.samples != NULL && debugInfo.profile.flush_needed) { in profiling_flush()
1445 int32 sampleCount = debugInfo.profile.sample_count; in profiling_flush()
1446 int32 droppedTicks = debugInfo.profile.dropped_ticks; in profiling_flush()
1447 int32 stackDepth = debugInfo.profile.stack_depth; in profiling_flush()
1448 bool variableStackDepth = debugInfo.profile.variable_stack_depth; in profiling_flush()
1449 int32 imageEvent = debugInfo.profile.image_event; in profiling_flush()
1452 bigtime_t interval = debugInfo.profile.interval; in profiling_flush()
1453 if (debugInfo.profile.installed_timer != NULL) { in profiling_flush()
1455 cancel_timer(debugInfo.profile.installed_timer); in profiling_flush()
1456 debugInfo.profile.installed_timer->hook = NULL; in profiling_flush()
1457 debugInfo.profile.installed_timer = NULL; in profiling_flush()
1459 debugInfo.profile.interval_left = -1; in profiling_flush()
1462 debugInfo.profile.sample_count = 0; in profiling_flush()
1463 debugInfo.profile.dropped_ticks = 0; in profiling_flush()
1464 debugInfo.profile.flush_needed = false; in profiling_flush()
1483 if (debugInfo.profile.samples != NULL) in profiling_flush()
1502 debugInfo.profile.installed_timer->hook = NULL; in profiling_event()
1503 debugInfo.profile.installed_timer = NULL; in profiling_event()
1510 if (debugInfo.profile.flush_needed in profiling_event()
1517 debugInfo.profile.interval_left = -1; in profiling_event()
1519 schedule_profiling_timer(thread, debugInfo.profile.interval); in profiling_event()
1535 struct timer* timer = thread->debug_info.profile.installed_timer; in user_debug_thread_unscheduled()
1539 thread->debug_info.profile.interval_left = max_c(left, 0); in user_debug_thread_unscheduled()
1540 thread->debug_info.profile.installed_timer->hook = NULL; in user_debug_thread_unscheduled()
1541 thread->debug_info.profile.installed_timer = NULL; in user_debug_thread_unscheduled()
1561 if (thread->debug_info.profile.samples != NULL in user_debug_thread_scheduled()
1562 && thread->debug_info.profile.interval_left >= 0) { in user_debug_thread_scheduled()
1565 thread->debug_info.profile.interval_left); in user_debug_thread_scheduled()
2367 if (threadDebugInfo.profile.samples == NULL) { in debug_nub_thread()
2368 threadDebugInfo.profile.interval = interval; in debug_nub_thread()
2369 threadDebugInfo.profile.sample_area in debug_nub_thread()
2371 threadDebugInfo.profile.samples = (addr_t*)samples; in debug_nub_thread()
2372 threadDebugInfo.profile.max_samples in debug_nub_thread()
2374 threadDebugInfo.profile.flush_threshold in debug_nub_thread()
2375 = threadDebugInfo.profile.max_samples in debug_nub_thread()
2378 threadDebugInfo.profile.sample_count = 0; in debug_nub_thread()
2379 threadDebugInfo.profile.dropped_ticks = 0; in debug_nub_thread()
2380 threadDebugInfo.profile.stack_depth = stackDepth; in debug_nub_thread()
2381 threadDebugInfo.profile.variable_stack_depth in debug_nub_thread()
2383 threadDebugInfo.profile.profile_kernel = profileKernel; in debug_nub_thread()
2384 threadDebugInfo.profile.flush_needed = false; in debug_nub_thread()
2385 threadDebugInfo.profile.interval_left = interval; in debug_nub_thread()
2386 threadDebugInfo.profile.installed_timer = NULL; in debug_nub_thread()
2387 threadDebugInfo.profile.image_event = imageEvent; in debug_nub_thread()
2388 threadDebugInfo.profile.last_image_event in debug_nub_thread()
2444 if (threadDebugInfo.profile.samples != NULL) { in debug_nub_thread()
2445 sampleArea = threadDebugInfo.profile.sample_area; in debug_nub_thread()
2446 samples = threadDebugInfo.profile.samples; in debug_nub_thread()
2447 sampleCount = threadDebugInfo.profile.sample_count; in debug_nub_thread()
2448 droppedTicks = threadDebugInfo.profile.dropped_ticks; in debug_nub_thread()
2449 stackDepth = threadDebugInfo.profile.stack_depth; in debug_nub_thread()
2451 = threadDebugInfo.profile.variable_stack_depth; in debug_nub_thread()
2452 imageEvent = threadDebugInfo.profile.image_event; in debug_nub_thread()
2453 threadDebugInfo.profile.sample_area = -1; in debug_nub_thread()
2454 threadDebugInfo.profile.samples = NULL; in debug_nub_thread()
2455 threadDebugInfo.profile.flush_needed = false; in debug_nub_thread()
2456 threadDebugInfo.profile.dropped_ticks = 0; in debug_nub_thread()