scheduler.cc (12987:97fbdee919d8) | scheduler.cc (12995:3421144dd03e) |
---|---|
1/* 2 * Copyright 2018 Google, Inc. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are 6 * met: redistributions of source code must retain the above copyright 7 * notice, this list of conditions and the following disclaimer; 8 * redistributions in binary form must reproduce the above copyright --- 103 unchanged lines hidden (view full) --- 112 _current->popListNode(); 113 // Switch to whatever Fiber is supposed to run this process. All 114 // Fibers which aren't running should be parked at this line. 115 _current->fiber()->run(); 116 // If the current process needs to be manually started, start it. 117 if (_current && _current->needsStart()) 118 _current->run(); 119 } | 1/* 2 * Copyright 2018 Google, Inc. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions are 6 * met: redistributions of source code must retain the above copyright 7 * notice, this list of conditions and the following disclaimer; 8 * redistributions in binary form must reproduce the above copyright --- 103 unchanged lines hidden (view full) --- 112 _current->popListNode(); 113 // Switch to whatever Fiber is supposed to run this process. All 114 // Fibers which aren't running should be parked at this line. 115 _current->fiber()->run(); 116 // If the current process needs to be manually started, start it. 117 if (_current && _current->needsStart()) 118 _current->run(); 119 } |
120 if (_current && _current->excWrapper) { 121 // Make sure this isn't a method process. 122 assert(!_current->needsStart()); 123 auto ew = _current->excWrapper; 124 _current->excWrapper = nullptr; 125 ew->throw_it(); 126 } |
|
120} 121 122void 123Scheduler::ready(Process *p) 124{ 125 // Clump methods together to minimize context switching. 126 if (p->procKind() == ::sc_core::SC_METHOD_PROC_) 127 readyList.pushFirst(p); --- 152 unchanged lines hidden --- | 127} 128 129void 130Scheduler::ready(Process *p) 131{ 132 // Clump methods together to minimize context switching. 133 if (p->procKind() == ::sc_core::SC_METHOD_PROC_) 134 readyList.pushFirst(p); --- 152 unchanged lines hidden --- |