mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Use swap() instead of load()/store() in get_and_reset_text_shaping_performance_counter()
Signed-off-by: Mattias de los Rios Rogers <delosrogers@gmail.com>
This commit is contained in:
parent
3a8cb5b37d
commit
b1d72f65ee
1 changed files with 1 additions and 2 deletions
|
@ -522,8 +522,7 @@ impl RunMetrics {
|
|||
}
|
||||
|
||||
pub fn get_and_reset_text_shaping_performance_counter() -> usize {
|
||||
let value = TEXT_SHAPING_PERFORMANCE_COUNTER.load(Ordering::SeqCst);
|
||||
TEXT_SHAPING_PERFORMANCE_COUNTER.store(0, Ordering::SeqCst);
|
||||
let value = TEXT_SHAPING_PERFORMANCE_COUNTER.swap(0,Ordering::SeqCst);
|
||||
value
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue