Changeset 640 for trunk/kernel/kern/thread.c
- Timestamp:
- Oct 1, 2019, 1:19:00 PM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/kernel/kern/thread.c
r637 r640 890 890 core_t * core = thread->core; 891 891 892 #if DEBUG_THREAD_DESTROY 893 uint32_t cycle = (uint32_t)hal_get_cycles(); 892 893 #if DEBUG_THREAD_DESTROY || CONFIG_INSTRUMENTATION_PGFAULTS 894 uint32_t cycle; 894 895 thread_t * this = CURRENT_THREAD; 896 #endif 897 898 #if (DEBUG_THREAD_DESTROY & 1) 899 cycle = (uint32_t)hal_get_cycles(); 895 900 if( DEBUG_THREAD_DESTROY < cycle ) 896 901 printk("\n[%s] thread[%x,%x] enter to destroy thread[%x,%x] / cycle %d\n", … … 902 907 903 908 #if CONFIG_INSTRUMENTATION_PGFAULTS 904 process->vmm.false_pgfault_nr += thread->info.false_pgfault_nr; 905 process->vmm.local_pgfault_nr += thread->info.local_pgfault_nr; 906 process->vmm.global_pgfault_nr += thread->info.global_pgfault_nr; 907 process->vmm.false_pgfault_cost += thread->info.false_pgfault_cost; 908 process->vmm.local_pgfault_cost += thread->info.local_pgfault_cost; 909 process->vmm.global_pgfault_cost += thread->info.global_pgfault_cost; 909 process->vmm.false_pgfault_nr += thread->info.false_pgfault_nr; 910 process->vmm.local_pgfault_nr += thread->info.local_pgfault_nr; 911 process->vmm.global_pgfault_nr += thread->info.global_pgfault_nr; 912 process->vmm.false_pgfault_cost += thread->info.false_pgfault_cost; 913 process->vmm.local_pgfault_cost += thread->info.local_pgfault_cost; 914 process->vmm.global_pgfault_cost += thread->info.global_pgfault_cost; 915 #endif 916 917 #if (CONFIG_INSTRUMENTATION_PGFAULTS & 1) 918 uint32_t false_nr = thread->info.false_pgfault_nr; 919 uint32_t local_nr = thread->info.local_pgfault_nr; 920 uint32_t global_nr = thread->info.global_pgfault_nr; 921 uint32_t false_cost = thread->info.false_pgfault_cost; 922 uint32_t local_cost = thread->info.local_pgfault_cost; 923 uint32_t global_cost = thread->info.global_pgfault_cost; 924 printk("***** thread[%x,%x] page-faults\n" 925 " - false %d ( %d cycles )\n" 926 " - local %d ( %d cycles )\n" 927 " - global %d ( %d cycles )\n", 928 this->process->pid, this->trdid, 929 false_nr , false_cost / false_nr, 930 local_nr , local_cost / local_nr, 931 global_nr, global_cost / global_nr ); 910 932 #endif 911 933 … … 1270 1292 cycle = (uint32_t)hal_get_cycles(); 1271 1293 if( DEBUG_THREAD_IDLE < cycle ) 1272 sched_ display(CURRENT_THREAD->core->lid );1294 sched_remote_display( local_cxy , CURRENT_THREAD->core->lid ); 1273 1295 #endif 1274 1296 // search a runable thread
Note: See TracChangeset
for help on using the changeset viewer.