mirror of
https://github.com/RPCS3/rpcs3.git
synced 2025-07-15 19:28:43 +12:00
rsx: Lower performance hit due to frequency fetch
This commit is contained in:
parent
7e8c93bea2
commit
0244c4046e
1 changed files with 4 additions and 2 deletions
|
@ -9,9 +9,11 @@ namespace rsx
|
|||
{
|
||||
static inline u64 uclock()
|
||||
{
|
||||
if (const u64 freq = (utils::get_tsc_freq() / 1000000))
|
||||
static const ullong s_tsc_scaled_freq = (utils::get_tsc_freq() / 1000000);
|
||||
|
||||
if (s_tsc_scaled_freq)
|
||||
{
|
||||
return utils::get_tsc() / freq;
|
||||
return utils::get_tsc() / s_tsc_scaled_freq;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue