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

Side by Side Diff: ipc/ipc_channel_proxy.cc

Issue 10919023: Add async trace events to trace progress of IPC messages (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix SpellCheckProviderTest.MultiLineText Created 8 years, 3 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « ipc/ipc_channel_posix.cc ('k') | ipc/ipc_channel_reader.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/bind.h" 5 #include "base/bind.h"
6 #include "base/compiler_specific.h" 6 #include "base/compiler_specific.h"
7 #include "base/debug/trace_event.h" 7 #include "base/debug/trace_event.h"
8 #include "base/location.h" 8 #include "base/location.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after
344 context_->Clear(); 344 context_->Clear();
345 345
346 if (context_->ipc_task_runner()) { 346 if (context_->ipc_task_runner()) {
347 context_->ipc_task_runner()->PostTask( 347 context_->ipc_task_runner()->PostTask(
348 FROM_HERE, base::Bind(&Context::OnChannelClosed, context_.get())); 348 FROM_HERE, base::Bind(&Context::OnChannelClosed, context_.get()));
349 } 349 }
350 } 350 }
351 351
352 bool ChannelProxy::Send(Message* message) { 352 bool ChannelProxy::Send(Message* message) {
353 DCHECK(did_init_); 353 DCHECK(did_init_);
354 message->TraceMessageStep();
354 if (outgoing_message_filter()) 355 if (outgoing_message_filter())
355 message = outgoing_message_filter()->Rewrite(message); 356 message = outgoing_message_filter()->Rewrite(message);
356 357
357 #ifdef IPC_MESSAGE_LOG_ENABLED 358 #ifdef IPC_MESSAGE_LOG_ENABLED
358 Logging::GetInstance()->OnSendMessage(message, context_->channel_id()); 359 Logging::GetInstance()->OnSendMessage(message, context_->channel_id());
359 #endif 360 #endif
360 361
361 context_->ipc_task_runner()->PostTask( 362 context_->ipc_task_runner()->PostTask(
362 FROM_HERE, 363 FROM_HERE,
363 base::Bind(&ChannelProxy::Context::OnSendMessage, 364 base::Bind(&ChannelProxy::Context::OnSendMessage,
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
400 Channel* channel = context_.get()->channel_.get(); 401 Channel* channel = context_.get()->channel_.get();
401 // Channel must have been created first. 402 // Channel must have been created first.
402 DCHECK(channel) << context_.get()->channel_id_; 403 DCHECK(channel) << context_.get()->channel_id_;
403 return channel->GetClientEuid(client_euid); 404 return channel->GetClientEuid(client_euid);
404 } 405 }
405 #endif 406 #endif
406 407
407 //----------------------------------------------------------------------------- 408 //-----------------------------------------------------------------------------
408 409
409 } // namespace IPC 410 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/ipc_channel_posix.cc ('k') | ipc/ipc_channel_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698