Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | |
| 2 // Use of this source code is governed by a BSD-style license that can be | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #include "blimp/engine/app/blimp_engine_crash_keys.h" | |
| 6 | |
| 7 #include <vector> | |
| 8 | |
| 9 #include "base/debug/crash_logging.h" | |
| 10 #include "components/crash/core/common/crash_keys.h" | |
| 11 | |
| 12 namespace blimp { | |
| 13 namespace engine { | |
| 14 | |
| 15 size_t RegisterEngineCrashKeys() { | |
| 16 // For now these need to be kept relatively up to date with those in | |
| 17 // //chrome/common/crash_keys.cc::RegisterChromeCrashKeys() | |
| 18 // All of the keys used in //content and //components/crash must show up | |
| 19 // here. | |
| 20 // TODO(marcinjb): Change the approach when http://crbug.com/598854 is | |
| 21 // resolved. | |
| 22 const std::vector<base::debug::CrashKey> engine_keys = { | |
| 23 { ::crash_keys::kClientId, ::crash_keys::kSmallSize }, | |
|
Robert Sesek
2016/04/28 21:37:30
Do you need to prefix everything with :: ?
marcinjb
2016/04/28 22:00:34
Hmm, I think I originally had an additional nested
Robert Sesek
2016/04/28 22:02:50
Right, and the compiler probably would want them t
| |
| 24 { ::crash_keys::kChannel, ::crash_keys::kSmallSize }, | |
| 25 { ::crash_keys::kNumVariations, ::crash_keys::kSmallSize }, | |
| 26 { ::crash_keys::kVariations, ::crash_keys::kLargeSize }, | |
| 27 | |
| 28 // //content crash keys | |
| 29 { "discardable-memory-allocated", ::crash_keys::kSmallSize }, | |
| 30 { "discardable-memory-free", ::crash_keys::kSmallSize }, | |
| 31 { "ppapi_path", ::crash_keys::kMediumSize }, | |
| 32 { "subresource_url", ::crash_keys::kLargeSize }, | |
| 33 { "total-discardable-memory-allocated", ::crash_keys::kSmallSize }, | |
| 34 { "channel_error_bt", ::crash_keys::kMediumSize }, | |
| 35 { "remove_route_bt", ::crash_keys::kMediumSize }, | |
| 36 { "rwhvm_window", ::crash_keys::kMediumSize }, | |
| 37 | |
| 38 // Temporary for http://crbug.com/575245. | |
| 39 { "swapout_frame_id", ::crash_keys::kSmallSize }, | |
| 40 { "swapout_proxy_id", ::crash_keys::kSmallSize }, | |
| 41 { "swapout_view_id", ::crash_keys::kSmallSize }, | |
| 42 { "commit_frame_id", ::crash_keys::kSmallSize }, | |
| 43 { "commit_proxy_id", ::crash_keys::kSmallSize }, | |
| 44 { "commit_view_id", ::crash_keys::kSmallSize }, | |
| 45 { "commit_main_render_frame_id", ::crash_keys::kSmallSize }, | |
| 46 { "newproxy_proxy_id", ::crash_keys::kSmallSize }, | |
| 47 { "newproxy_view_id", ::crash_keys::kSmallSize }, | |
| 48 { "newproxy_opener_id", ::crash_keys::kSmallSize }, | |
| 49 { "newproxy_parent_id", ::crash_keys::kSmallSize }, | |
| 50 { "rvinit_view_id", ::crash_keys::kSmallSize }, | |
| 51 { "rvinit_proxy_id", ::crash_keys::kSmallSize }, | |
| 52 { "rvinit_main_frame_id", ::crash_keys::kSmallSize }, | |
| 53 { "initrf_frame_id", ::crash_keys::kSmallSize }, | |
| 54 { "initrf_proxy_id", ::crash_keys::kSmallSize }, | |
| 55 { "initrf_view_id", ::crash_keys::kSmallSize }, | |
| 56 { "initrf_main_frame_id", ::crash_keys::kSmallSize }, | |
| 57 { "initrf_view_is_live", ::crash_keys::kSmallSize }, | |
| 58 | |
| 59 // Temporary for https://crbug.com/591478. | |
| 60 { "initrf_parent_proxy_exists", ::crash_keys::kSmallSize }, | |
| 61 { "initrf_render_view_is_live", ::crash_keys::kSmallSize }, | |
| 62 { "initrf_parent_is_in_same_site_instance", ::crash_keys::kSmallSize}, | |
| 63 { "initrf_parent_process_is_live", ::crash_keys::kSmallSize}, | |
| 64 { "initrf_root_is_in_same_site_instance", ::crash_keys::kSmallSize}, | |
| 65 { "initrf_root_is_in_same_site_instance_as_parent", | |
| 66 ::crash_keys::kSmallSize}, | |
| 67 { "initrf_root_process_is_live", ::crash_keys::kSmallSize}, | |
| 68 { "initrf_root_proxy_is_live", ::crash_keys::kSmallSize}, | |
| 69 }; | |
| 70 | |
| 71 return base::debug::InitCrashKeys(&engine_keys.at(0), engine_keys.size(), | |
| 72 ::crash_keys::kChunkMaxLength); | |
| 73 } | |
| 74 | |
| 75 } // namespace engine | |
| 76 } // namespace blimp | |
| OLD | NEW |