1/* 2 * Copyright (c) 2011-2013 ARM Limited 3 * Copyright (c) 2013 Advanced Micro Devices, Inc. 4 * All rights reserved 5 * 6 * The license below extends only to copyright in the software and shall 7 * not be construed as granting a license to any other intellectual 8 * property including but not limited to intellectual property relating --- 324 unchanged lines hidden (view full) --- 333 void haltContext(ThreadID tid); 334 335 /** Update The Order In Which We Process Threads. */ 336 void updateThreadPriority(); 337 338 /** Is the CPU draining? */ 339 bool isDraining() const { return drainState() == DrainState::Draining; } 340 |
341 void serializeThread(CheckpointOut &cp, ThreadID tid) const override; 342 void unserializeThread(CheckpointIn &cp, ThreadID tid) override; |
343 344 public: 345 /** Executes a syscall. 346 * @todo: Determine if this needs to be virtual. 347 */ 348 void syscall(int64_t callnum, ThreadID tid); 349 350 /** Starts draining the CPU's pipeline of all instructions in 351 * order to stop all memory accesses. */ |
352 DrainState drain() override; |
353 354 /** Resumes execution after a drain. */ |
355 void drainResume() override; |
356 357 /** 358 * Commit has reached a safe point to drain a thread. 359 * 360 * Commit calls this method to inform the pipeline that it has 361 * reached a point where it is not executed microcode and is about 362 * to squash uncommitted instructions to fully drain the pipeline. 363 */ --- 270 unchanged lines hidden (view full) --- 634 635 /** Changes a stage's status to inactive within the activity recorder. */ 636 void deactivateStage(const StageIdx idx) 637 { activityRec.deactivateStage(idx); } 638 639 /** Wakes the CPU, rescheduling the CPU if it's not already active. */ 640 void wakeCPU(); 641 |
642 virtual void wakeup(ThreadID tid) override; |
643 644 /** Gets a free thread id. Use if thread ids change across system. */ 645 ThreadID getFreeTid(); 646 647 public: 648 /** Returns a pointer to a thread context. */ 649 ThreadContext * 650 tcBase(ThreadID tid) --- 91 unchanged lines hidden --- |