| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent 8eeae28 commit df608e0
5 files changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -87,7 +87,7 @@ | |||
| 87 | 87 | 'v8_enable_external_code_space%': 0, | |
| 88 | 88 | 'v8_enable_sandbox%': 0, | |
| 89 | 89 | 'v8_enable_v8_checks%': 0, | |
| 90 | - 'v8_use_perfetto': 0, | ||
| 90 | + 'v8_use_perfetto%': 0, | ||
| 91 | 91 | 'tsan%': 0, | |
| 92 | 92 | ||
| 93 | 93 | ##### end V8 defaults ##### | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1117,6 +1117,12 @@ | |||
| 1117 | 1117 | default=None, | |
| 1118 | 1118 | help='disable the V8 inspector protocol') | |
| 1119 | 1119 | ||
| 1120 | + parser.add_argument('--with-perfetto', | ||
| 1121 | + action='store_true', | ||
| 1122 | + dest='with_perfetto', | ||
| 1123 | + default=None, | ||
| 1124 | + help='enable perfetto support') | ||
| 1125 | + | ||
| 1120 | 1126 | parser.add_argument('--shared', | |
| 1121 | 1127 | action='store_true', | |
| 1122 | 1128 | dest='shared', | |
@@ -2217,6 +2223,7 @@ def configure_v8(o, configs): | |||
| 2217 | 2223 | options.v8_disable_temporal_support = True | |
| 2218 | 2224 | o['variables']['v8_enable_temporal_support'] = 0 if options.v8_disable_temporal_support else 1 | |
| 2219 | 2225 | o['variables']['v8_trace_maps'] = 1 if options.trace_maps else 0 | |
| 2226 | + o['variables']['v8_use_perfetto'] = 1 if options.with_perfetto else 0 | ||
| 2220 | 2227 | o['variables']['node_use_v8_platform'] = b(not options.without_v8_platform) | |
| 2221 | 2228 | o['variables']['node_use_bundled_v8'] = b(not options.without_bundled_v8) | |
| 2222 | 2229 | o['variables']['force_dynamic_crt'] = 1 if options.shared else 0 | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1443,6 +1443,14 @@ | |||
| 1443 | 1443 | }, { | |
| 1444 | 1444 | 'sources!': [ '<@(node_cctest_quic_sources)' ], | |
| 1445 | 1445 | }], | |
| 1446 | + [ 'v8_use_perfetto==1', { | ||
| 1447 | + 'defines': [ | ||
| 1448 | + 'PERFETTO_ENABLE_LEGACY_TRACE_EVENTS=1' | ||
| 1449 | + ], | ||
| 1450 | + 'dependencies': [ | ||
| 1451 | + 'deps/perfetto/perfetto.gyp:perfetto_sdk', | ||
| 1452 | + ], | ||
| 1453 | + }], | ||
| 1446 | 1454 | ['v8_enable_inspector==1', { | |
| 1447 | 1455 | 'defines': [ | |
| 1448 | 1456 | 'HAVE_INSPECTOR=1', | |
@@ -1764,6 +1772,14 @@ | |||
| 1764 | 1772 | 'NODE_USE_NODE_CODE_CACHE=1', | |
| 1765 | 1773 | ], | |
| 1766 | 1774 | }], | |
| 1775 | + [ 'v8_use_perfetto==1', { | ||
| 1776 | + 'defines': [ | ||
| 1777 | + 'PERFETTO_ENABLE_LEGACY_TRACE_EVENTS=1' | ||
| 1778 | + ], | ||
| 1779 | + 'dependencies': [ | ||
| 1780 | + 'deps/perfetto/perfetto.gyp:perfetto_sdk', | ||
| 1781 | + ], | ||
| 1782 | + }], | ||
| 1767 | 1783 | ['v8_enable_inspector==1', { | |
| 1768 | 1784 | 'defines': [ | |
| 1769 | 1785 | 'HAVE_INSPECTOR=1', | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -200,8 +200,7 @@ | |||
| 200 | 200 | # Enable seeded array index hash. | |
| 201 | 201 | 'v8_enable_seeded_array_index_hash%': 1, | |
| 202 | 202 | ||
| 203 | - # Use Perfetto (https://perfetto.dev) as the default TracingController. Not | ||
| 204 | - # currently implemented. | ||
| 203 | + # Use Perfetto (https://perfetto.dev) as the default TracingController. | ||
| 205 | 204 | 'v8_use_perfetto%': 0, | |
| 206 | 205 | ||
| 207 | 206 | # Enable map packing & unpacking (sets -dV8_MAP_PACKING). | |
@@ -463,7 +462,10 @@ | |||
| 463 | 462 | 'defines': ['ENABLE_VERIFY_CSA',], | |
| 464 | 463 | }], | |
| 465 | 464 | ['v8_use_perfetto==1', { | |
| 466 | - 'defines': ['V8_USE_PERFETTO',], | ||
| 465 | + 'defines': [ | ||
| 466 | + 'V8_USE_PERFETTO', | ||
| 467 | + 'V8_USE_PERFETTO_SDK', | ||
| 468 | + ], | ||
| 467 | 469 | }], | |
| 468 | 470 | ['v8_enable_map_packing==1', { | |
| 469 | 471 | 'defines': ['V8_MAP_PACKING',], | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -38,6 +38,7 @@ | |||
| 38 | 38 | ], | |
| 39 | 39 | }], | |
| 40 | 40 | ], | |
| 41 | + 'perfetto_gyp_file': '../../deps/perfetto/perfetto.gyp', | ||
| 41 | 42 | }, | |
| 42 | 43 | 'includes': ['toolchain.gypi', 'features.gypi'], | |
| 43 | 44 | 'target_defaults': { | |
@@ -292,6 +293,13 @@ | |||
| 292 | 293 | 'sources': [ | |
| 293 | 294 | '<(V8_ROOT)/src/init/setup-isolate-full.cc', | |
| 294 | 295 | ], | |
| 296 | + 'conditions': [ | ||
| 297 | + ['v8_use_perfetto==1', { | ||
| 298 | + 'dependencies': [ | ||
| 299 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 300 | + ], | ||
| 301 | + }], | ||
| 302 | + ], | ||
| 295 | 303 | }, # v8_init | |
| 296 | 304 | { | |
| 297 | 305 | 'target_name': 'v8_initializers', | |
@@ -312,6 +320,11 @@ | |||
| 312 | 320 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_initializers.*?sources = ")', | |
| 313 | 321 | ], | |
| 314 | 322 | 'conditions': [ | |
| 323 | + ['v8_use_perfetto==1', { | ||
| 324 | + 'dependencies': [ | ||
| 325 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 326 | + ], | ||
| 327 | + }], | ||
| 315 | 328 | ['v8_enable_webassembly==1', { | |
| 316 | 329 | 'sources': [ | |
| 317 | 330 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_initializers.*?v8_enable_webassembly.*?sources \\+= ")', | |
@@ -479,6 +492,11 @@ | |||
| 479 | 492 | }, | |
| 480 | 493 | ], | |
| 481 | 494 | 'conditions': [ | |
| 495 | + ['v8_use_perfetto==1', { | ||
| 496 | + 'dependencies': [ | ||
| 497 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 498 | + ], | ||
| 499 | + }], | ||
| 482 | 500 | ['want_separate_host_toolset', { | |
| 483 | 501 | 'dependencies': [ | |
| 484 | 502 | 'generate_bytecode_builtins_list', | |
@@ -678,6 +696,14 @@ | |||
| 678 | 696 | }], | |
| 679 | 697 | ], | |
| 680 | 698 | }], | |
| 699 | + ['v8_use_perfetto==1', { | ||
| 700 | + 'sources!': [ | ||
| 701 | + '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_use_perfetto.*?sources \\-= ")', | ||
| 702 | + ], | ||
| 703 | + 'sources': [ | ||
| 704 | + '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_use_perfetto.*?sources \\+= ")', | ||
| 705 | + ], | ||
| 706 | + }], | ||
| 681 | 707 | ['v8_enable_webassembly==1', { | |
| 682 | 708 | 'sources': [ | |
| 683 | 709 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?v8_enable_webassembly.*?sources \\+= ")', | |
@@ -960,6 +986,11 @@ | |||
| 960 | 986 | 'abseil.gyp:abseil', | |
| 961 | 987 | ], | |
| 962 | 988 | 'conditions': [ | |
| 989 | + ['v8_use_perfetto==1', { | ||
| 990 | + 'dependencies': [ | ||
| 991 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 992 | + ], | ||
| 993 | + }], | ||
| 963 | 994 | ['v8_enable_maglev==0', { | |
| 964 | 995 | 'sources': [ | |
| 965 | 996 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_header_set.\\"v8_internal_headers\\".*?!v8_enable_maglev.*?sources \\+= ")', | |
@@ -1090,6 +1121,14 @@ | |||
| 1090 | 1121 | '<@(inspector_all_sources)', | |
| 1091 | 1122 | ], | |
| 1092 | 1123 | 'conditions': [ | |
| 1124 | + ['v8_use_perfetto==1', { | ||
| 1125 | + 'sources': [ | ||
| 1126 | + '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_use_perfetto.*?sources \\+= ")', | ||
| 1127 | + ], | ||
| 1128 | + 'dependencies': [ | ||
| 1129 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 1130 | + ], | ||
| 1131 | + }], | ||
| 1093 | 1132 | ['v8_enable_snapshot_compression==1', { | |
| 1094 | 1133 | 'sources': [ | |
| 1095 | 1134 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_base_without_compiler.*?v8_enable_snapshot_compression.*?sources \\+= ")', | |
@@ -1707,8 +1746,7 @@ | |||
| 1707 | 1746 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "\\"v8_libplatform.*?v8_use_perfetto.*?sources += ")', | |
| 1708 | 1747 | ], | |
| 1709 | 1748 | 'dependencies': [ | |
| 1710 | - '<(V8_ROOT)/third_party/perfetto:libperfetto', | ||
| 1711 | - '<(V8_ROOT)/third_party/perfetto/protos/perfetto/trace:lite', | ||
| 1749 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 1712 | 1750 | ], | |
| 1713 | 1751 | }], | |
| 1714 | 1752 | ['v8_enable_system_instrumentation==1 and is_win', { | |
@@ -1818,6 +1856,11 @@ | |||
| 1818 | 1856 | }, | |
| 1819 | 1857 | }, | |
| 1820 | 1858 | 'conditions': [ | |
| 1859 | + ['v8_use_perfetto==1', { | ||
| 1860 | + 'dependencies': [ | ||
| 1861 | + '<(perfetto_gyp_file):perfetto_sdk', | ||
| 1862 | + ], | ||
| 1863 | + }], | ||
| 1821 | 1864 | ['want_separate_host_toolset', { | |
| 1822 | 1865 | 'toolsets': ['host'], | |
| 1823 | 1866 | }], | |
@@ -2028,6 +2071,13 @@ | |||
| 2028 | 2071 | 'sources': [ | |
| 2029 | 2072 | '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_source_set.\\"cppgc_base.*?sources = ")', | |
| 2030 | 2073 | ], | |
| 2074 | + 'conditions': [ | ||
| 2075 | + ['v8_use_perfetto==1', { | ||
| 2076 | + 'sources': [ | ||
| 2077 | + '<!@pymod_do_main(GN-scraper "<(V8_ROOT)/BUILD.gn" "v8_source_set.\\"cppgc_base.*?if .v8_use_perfetto.*?sources \\+= ")', | ||
| 2078 | + ], | ||
| 2079 | + }], | ||
| 2080 | + ], | ||
| 2031 | 2081 | }, | |
| 2032 | 2082 | }, # cppgc_base | |
| 2033 | 2083 | { | |
| Back | FazBrowse Home | New Git URL |
0 commit comments