Changeset e873838 for libcfa/src/concurrency/kernel
- Timestamp:
- Nov 2, 2020, 12:44:43 PM (3 years ago)
- Branches:
- ADT, arm-eh, ast-experimental, enum, forall-pointer-decay, jacob/cs343-translation, master, new-ast-unique-expr, pthread-emulation, qualifiedEnum
- Children:
- 58688bf, 82f791f
- Parents:
- f7136f7
- Location:
- libcfa/src/concurrency/kernel
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
libcfa/src/concurrency/kernel/fwd.hfa
rf7136f7 re873838 35 35 extern "Cforall" { 36 36 extern __attribute__((aligned(128))) thread_local struct KernelThreadData { 37 struct $thread * volatile this_thread; 38 struct processor * volatile this_processor; 39 struct __stats_t * volatile this_stats; 37 struct $thread * volatile this_thread; 38 struct processor * volatile this_processor; 39 struct __processor_id_t * volatile this_proc_id; 40 struct __stats_t * volatile this_stats; 40 41 41 42 struct { -
libcfa/src/concurrency/kernel/startup.cfa
rf7136f7 re873838 122 122 NULL, 123 123 NULL, 124 NULL, 124 125 { 1, false, false }, 125 126 }; … … 212 213 //initialize the global state variables 213 214 kernelTLS.this_processor = mainProcessor; 215 kernelTLS.this_proc_id = (__processor_id_t*)mainProcessor; 214 216 kernelTLS.this_thread = mainThread; 215 217 … … 227 229 // Add the main thread to the ready queue 228 230 // once resume is called on mainProcessor->runner the mainThread needs to be scheduled like any normal thread 229 __schedule_thread( (__processor_id_t *)mainProcessor,mainThread);231 __schedule_thread(mainThread); 230 232 231 233 // SKULLDUGGERY: Force a context switch to the main processor to set the main thread's context to the current UNIX … … 324 326 processor * proc = (processor *) arg; 325 327 kernelTLS.this_processor = proc; 328 kernelTLS.this_proc_id = (__processor_id_t*)proc; 326 329 kernelTLS.this_thread = 0p; 327 330 kernelTLS.preemption_state.[enabled, disable_count] = [false, 1];
Note: See TracChangeset
for help on using the changeset viewer.