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

Side by Side Diff: base/debug/task_annotator.cc

Issue 1549043002: Switch to standard integer types in base/debug/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 unified diff | Download patch
« no previous file with comments | « base/debug/task_annotator.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/debug/task_annotator.h" 5 #include "base/debug/task_annotator.h"
6 6
7 #include "base/debug/alias.h" 7 #include "base/debug/alias.h"
8 #include "base/pending_task.h" 8 #include "base/pending_task.h"
9 #include "base/trace_event/trace_event.h" 9 #include "base/trace_event/trace_event.h"
10 #include "base/tracked_objects.h" 10 #include "base/tracked_objects.h"
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
48 const void* program_counter = pending_task.posted_from.program_counter(); 48 const void* program_counter = pending_task.posted_from.program_counter();
49 debug::Alias(&program_counter); 49 debug::Alias(&program_counter);
50 50
51 pending_task.task.Run(); 51 pending_task.task.Run();
52 52
53 stopwatch.Stop(); 53 stopwatch.Stop();
54 tracked_objects::ThreadData::TallyRunOnNamedThreadIfTracking( 54 tracked_objects::ThreadData::TallyRunOnNamedThreadIfTracking(
55 pending_task, stopwatch); 55 pending_task, stopwatch);
56 } 56 }
57 57
58 uint64 TaskAnnotator::GetTaskTraceID(const PendingTask& task) const { 58 uint64_t TaskAnnotator::GetTaskTraceID(const PendingTask& task) const {
59 return (static_cast<uint64>(task.sequence_num) << 32) | 59 return (static_cast<uint64_t>(task.sequence_num) << 32) |
60 ((static_cast<uint64>(reinterpret_cast<intptr_t>(this)) << 32) >> 32); 60 ((static_cast<uint64_t>(reinterpret_cast<intptr_t>(this)) << 32) >>
61 32);
61 } 62 }
62 63
63 } // namespace debug 64 } // namespace debug
64 } // namespace base 65 } // namespace base
OLDNEW
« no previous file with comments | « base/debug/task_annotator.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698