diff options
| author | 2018-09-23 17:51:53 -0400 | |
|---|---|---|
| committer | 2018-09-23 17:51:53 -0400 | |
| commit | 6b05f71b671268e15ce0fd83fd7adbef8896a491 (patch) | |
| tree | 1763dadf5559f41231fc2da5842c74a32fe96f31 /src | |
| parent | Merge pull request #1385 from FearlessTobi/port-4214 (diff) | |
| parent | common/thread: remove YieldCPU() (diff) | |
| download | yuzu-6b05f71b671268e15ce0fd83fd7adbef8896a491.tar.gz yuzu-6b05f71b671268e15ce0fd83fd7adbef8896a491.tar.xz yuzu-6b05f71b671268e15ce0fd83fd7adbef8896a491.zip | |
Merge pull request #1387 from FearlessTobi/port-4245
Port citra-emu/citra#4245: "common/thread: remove YieldCPU()"
Diffstat (limited to 'src')
| -rw-r--r-- | src/common/thread.h | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/src/common/thread.h b/src/common/thread.h index 12a1c095c..6cbdb96a3 100644 --- a/src/common/thread.h +++ b/src/common/thread.h | |||
| @@ -87,14 +87,6 @@ private: | |||
| 87 | 87 | ||
| 88 | void SleepCurrentThread(int ms); | 88 | void SleepCurrentThread(int ms); |
| 89 | void SwitchCurrentThread(); // On Linux, this is equal to sleep 1ms | 89 | void SwitchCurrentThread(); // On Linux, this is equal to sleep 1ms |
| 90 | |||
| 91 | // Use this function during a spin-wait to make the current thread | ||
| 92 | // relax while another thread is working. This may be more efficient | ||
| 93 | // than using events because event functions use kernel calls. | ||
| 94 | inline void YieldCPU() { | ||
| 95 | std::this_thread::yield(); | ||
| 96 | } | ||
| 97 | |||
| 98 | void SetCurrentThreadName(const char* name); | 90 | void SetCurrentThreadName(const char* name); |
| 99 | 91 | ||
| 100 | } // namespace Common | 92 | } // namespace Common |