Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(11)

Unified Diff: cc/trees/latency_info_swap_promise_monitor.cc

Issue 1089643002: Make ScrollUpdate LatencyInfo's sequence number less likely to have conflicts (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cast to uint64 Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/trees/latency_info_swap_promise_monitor.cc
diff --git a/cc/trees/latency_info_swap_promise_monitor.cc b/cc/trees/latency_info_swap_promise_monitor.cc
index 64613e9bce5b56cb1bcadfe289cb1b23069caad5..2b56f68cc2a681a1045f4f9cc807914f544df3da 100644
--- a/cc/trees/latency_info_swap_promise_monitor.cc
+++ b/cc/trees/latency_info_swap_promise_monitor.cc
@@ -71,9 +71,11 @@ void LatencyInfoSwapPromiseMonitor::OnForwardScrollUpdateToMainThreadOnImpl() {
it != latency_->latency_components.end(); ++it) {
if (it->first.first == ui::INPUT_EVENT_LATENCY_BEGIN_RWH_COMPONENT) {
new_sequence_number =
- (static_cast<int64>(base::PlatformThread::CurrentId()) << 32) |
+ ((static_cast<int64>(base::PlatformThread::CurrentId()) << 32) ^
+ (reinterpret_cast<uint64>(this) << 32)) |
(it->second.sequence_number & 0xffffffff);
- DCHECK(new_sequence_number != it->second.sequence_number);
+ if (new_sequence_number == it->second.sequence_number)
+ return;
break;
}
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698