diff options
-rw-r--r-- | content/ppapi_plugin/ppapi_thread.cc | 7 | ||||
-rw-r--r-- | content/renderer/media/crypto/ppapi_decryptor.cc | 10 |
2 files changed, 14 insertions, 3 deletions
diff --git a/content/ppapi_plugin/ppapi_thread.cc b/content/ppapi_plugin/ppapi_thread.cc index c5b2338..3b88a8e 100644 --- a/content/ppapi_plugin/ppapi_thread.cc +++ b/content/ppapi_plugin/ppapi_thread.cc @@ -19,6 +19,7 @@ #include "base/strings/utf_string_conversions.h" #include "base/threading/platform_thread.h" #include "base/time/time.h" +#include "base/trace_event/trace_event.h" #include "content/child/browser_font_resource_trusted.h" #include "content/child/child_discardable_shared_memory_manager.h" #include "content/child/child_process.h" @@ -307,7 +308,11 @@ void PpapiThread::OnLoadPlugin(const base::FilePath& path, if (plugin_entry_points_.initialize_module == NULL) { // Load the plugin from the specified library. base::NativeLibraryLoadError error; - library.Reset(base::LoadNativeLibrary(path, &error)); + { + TRACE_EVENT1("ppapi", "PpapiThread::LoadPlugin", "path", + path.MaybeAsASCII()); + library.Reset(base::LoadNativeLibrary(path, &error)); + } if (!library.is_valid()) { LOG(ERROR) << "Failed to load Pepper module from " << path.value() << " (error: " << error.ToString() << ")"; diff --git a/content/renderer/media/crypto/ppapi_decryptor.cc b/content/renderer/media/crypto/ppapi_decryptor.cc index 099c7ae..4b35c99 100644 --- a/content/renderer/media/crypto/ppapi_decryptor.cc +++ b/content/renderer/media/crypto/ppapi_decryptor.cc @@ -11,6 +11,7 @@ #include "base/logging.h" #include "base/single_thread_task_runner.h" #include "base/thread_task_runner_handle.h" +#include "base/trace_event/trace_event.h" #include "content/renderer/pepper/content_decryptor_delegate.h" #include "content/renderer/pepper/pepper_plugin_instance_impl.h" #include "media/base/audio_decoder_config.h" @@ -38,8 +39,13 @@ void PpapiDecryptor::Create( const media::CdmCreatedCB& cdm_created_cb) { std::string plugin_type = media::GetPepperType(key_system); DCHECK(!plugin_type.empty()); - scoped_ptr<PepperCdmWrapper> pepper_cdm_wrapper = - create_pepper_cdm_cb.Run(plugin_type, security_origin); + + scoped_ptr<PepperCdmWrapper> pepper_cdm_wrapper; + { + TRACE_EVENT0("media", "PpapiDecryptor::CreatePepperCDM"); + pepper_cdm_wrapper = create_pepper_cdm_cb.Run(plugin_type, security_origin); + } + if (!pepper_cdm_wrapper) { std::string message = "Unable to create the CDM for the key system " + key_system + "."; |