scheduler.hh (13176:76f52e8d8c6a) | scheduler.hh (13182:9e030f636a8c) |
---|---|
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 --- 319 unchanged lines hidden (view full) --- 328 void schedulePause(); 329 void scheduleStop(bool finish_delta); 330 331 bool paused() { return _paused; } 332 bool stopped() { return _stopped; } 333 334 uint64_t changeStamp() { return _changeStamp; } 335 | 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 --- 319 unchanged lines hidden (view full) --- 328 void schedulePause(); 329 void scheduleStop(bool finish_delta); 330 331 bool paused() { return _paused; } 332 bool stopped() { return _stopped; } 333 334 uint64_t changeStamp() { return _changeStamp; } 335 |
336 void throwToScMain(const ::sc_core::sc_report *r=nullptr); 337 |
|
336 private: 337 typedef const EventBase::Priority Priority; 338 static Priority DefaultPriority = EventBase::Default_Pri; 339 340 static Priority StopPriority = DefaultPriority - 1; 341 static Priority PausePriority = DefaultPriority + 1; 342 static Priority MaxTickPriority = DefaultPriority + 2; 343 static Priority ReadyPriority = DefaultPriority + 3; --- 28 unchanged lines hidden (view full) --- 372 void runReady(); 373 EventWrapper<Scheduler, &Scheduler::runReady> readyEvent; 374 void scheduleReadyEvent(); 375 376 void pause(); 377 void stop(); 378 EventWrapper<Scheduler, &Scheduler::pause> pauseEvent; 379 EventWrapper<Scheduler, &Scheduler::stop> stopEvent; | 338 private: 339 typedef const EventBase::Priority Priority; 340 static Priority DefaultPriority = EventBase::Default_Pri; 341 342 static Priority StopPriority = DefaultPriority - 1; 343 static Priority PausePriority = DefaultPriority + 1; 344 static Priority MaxTickPriority = DefaultPriority + 2; 345 static Priority ReadyPriority = DefaultPriority + 3; --- 28 unchanged lines hidden (view full) --- 374 void runReady(); 375 EventWrapper<Scheduler, &Scheduler::runReady> readyEvent; 376 void scheduleReadyEvent(); 377 378 void pause(); 379 void stop(); 380 EventWrapper<Scheduler, &Scheduler::pause> pauseEvent; 381 EventWrapper<Scheduler, &Scheduler::stop> stopEvent; |
382 |
|
380 Fiber *scMain; | 383 Fiber *scMain; |
384 const ::sc_core::sc_report *_throwToScMain; |
|
381 382 bool 383 starved() 384 { 385 return (readyListMethods.empty() && readyListThreads.empty() && 386 updateList.empty() && deltas.empty() && 387 (timeSlots.empty() || timeSlots.begin()->first > maxTick) && 388 initList.empty()); --- 43 unchanged lines hidden (view full) --- 432inline void 433Scheduler::TimeSlot::process() 434{ 435 while (!events.empty()) 436 events.front()->run(); 437 scheduler.completeTimeSlot(this); 438} 439 | 385 386 bool 387 starved() 388 { 389 return (readyListMethods.empty() && readyListThreads.empty() && 390 updateList.empty() && deltas.empty() && 391 (timeSlots.empty() || timeSlots.begin()->first > maxTick) && 392 initList.empty()); --- 43 unchanged lines hidden (view full) --- 436inline void 437Scheduler::TimeSlot::process() 438{ 439 while (!events.empty()) 440 events.front()->run(); 441 scheduler.completeTimeSlot(this); 442} 443 |
444const ::sc_core::sc_report *reportifyException(); 445 |
|
440} // namespace sc_gem5 441 442#endif // __SYSTEMC_CORE_SCHEDULER_H__ | 446} // namespace sc_gem5 447 448#endif // __SYSTEMC_CORE_SCHEDULER_H__ |