New issue
Advanced search Search tips

Issue 912017 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug



Sign in to add a comment

Reduce compile time of v8_window.cc and v8_window_partial.cc

Project Member Reported by tikuta@chromium.org, Dec 5

Issue description

Currently, v8 binding class has wrapper_type_info static member variable.
And v8_window.cc and v8_window_partial.cc refer many of them.
These 2 C++ files include many header files for wrapper_type_info and it causes long compile time.
* 23.2s for v8_window_partial.cc
* 22.0s for v8_window.c

I will use forward declaration for wrapper_type_info to remove many of header includes.

This is an effort similar to
https://chromium-review.googlesource.com/c/chromium/src/+/1352110

 
Project Member

Comment 1 by bugdroid1@chromium.org, Dec 5

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/1a190384a53efaef2bea3a2ee0033b69cf629c6d

commit 1a190384a53efaef2bea3a2ee0033b69cf629c6d
Author: Takuto Ikuta <tikuta@chromium.org>
Date: Wed Dec 05 14:13:47 2018

[bindings] add GetWrapperTypeInfo() to v8 bindings class

Currently, v8 binding class has wrapper_type_info static member variable.
And v8_window.cc and v8_window_partial.cc refer many of them.
These 2 C++ files include many header files for wrapper_type_info and it causes long compile time.
* 23.2s for v8_window_partial.cc
* 22.0s for v8_window.cc

In this CL, I introduced global variable for wrapper_type_info with constexpr static member function to get wrapper_type_info in each binding interface.

I will use forward declaration of global wrapper_type_info variable in other CL to remove many of header includes.
This is preparation for that.

Bug: 912017
Change-Id: I8598e2b42c22de503b1524f2b81457f7ed19cc4f
Reviewed-on: https://chromium-review.googlesource.com/c/1360495
Reviewed-by: Yuki Shiino <yukishiino@chromium.org>
Reviewed-by: Kentaro Hara <haraken@chromium.org>
Reviewed-by: Hitoshi Yoshida <peria@chromium.org>
Commit-Queue: Takuto Ikuta <tikuta@chromium.org>
Cr-Commit-Position: refs/heads/master@{#613959}
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/binding_security.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/custom/v8_message_channel_custom.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/custom/v8_readable_stream_custom.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/custom/v8_writable_stream_custom.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/serialization/v8_script_value_serializer.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/v0_custom_element_constructor_builder.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/v8_binding_for_core.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/v8_context_snapshot.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/v8_html_constructor.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/core/v8/v8_initializer.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/modules/v8/custom/v8_extendable_message_event_custom.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/modules/v8/serialization/v8_script_value_serializer_for_modules.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/attributes.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/callback_interface.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/callback_interface.h.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/external_reference_table.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/interface.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/interface.h.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/interface_base.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/methods.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/origin_trial_features_for_core.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/templates/origin_trial_features_for_modules.cc.tmpl
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/origin_trial_features_for_core.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_array_buffer.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_array_buffer.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_array_buffer_view.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_array_buffer_view.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_data_view.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_data_view.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_svg_test_interface.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_svg_test_interface.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_attributes.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_attributes.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_callback_functions.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_callback_functions.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_constants.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_constants.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_integer_indexed.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_integer_indexed.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_integer_indexed_global.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_integer_indexed_global.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_2.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_2.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_3.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_3.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_check_security.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_check_security.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_conditional_secure_context.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_conditional_secure_context.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor_2.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor_2.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor_3.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor_3.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor_4.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_constructor_4.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_custom_constructor.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_custom_constructor.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_document.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_document.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_empty.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_empty.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_event_init_constructor.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_event_init_constructor.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_event_target.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_event_target.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_named_constructor.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_named_constructor.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_named_constructor_2.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_named_constructor_2.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_node.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_node.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_origin_trial_enabled.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_origin_trial_enabled.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_secure_context.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_interface_secure_context.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_legacy_callback_interface.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_legacy_callback_interface.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_node.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_node.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_object.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_object.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_special_operations.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_special_operations.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_special_operations_not_enumerable.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_special_operations_not_enumerable.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_typedefs.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_typedefs.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_variadic_constructor_arguments.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_test_variadic_constructor_arguments.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_uint8_clamped_array.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/core/v8_uint8_clamped_array.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_inherited_legacy_unenumerable_named_properties.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_inherited_legacy_unenumerable_named_properties.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_interface_5.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_interface_5.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_interface_partial.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_not_enumerable_named_getter.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_not_enumerable_named_getter.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_sub_object.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/bindings/tests/results/modules/v8_test_sub_object.h
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/core/testing/v8/web_core_test_support.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/core/trustedtypes/trusted_type_policy_factory.cc
[modify] https://crrev.com/1a190384a53efaef2bea3a2ee0033b69cf629c6d/third_party/blink/renderer/core/typed_arrays/dom_typed_array.cc

Cc: tikuta@chromium.org
Owner: peria@chromium.org
Status: Assigned (was: Started)
To do forward declaration of wrapper_type_info, I need to know attribute is partial or not in or around v8_attribtes.py.
https://cs.chromium.org/chromium/src/third_party/blink/renderer/bindings/scripts/v8_attributes.py?l=136&rcl=6afc4880a78e888a32df06df328386b1f7b31308

Because wrapper_type_info become both const and non-const and it depends on whether it is partial or not.

peria-san, let me assign this bug to you until you found the way to handle this.
Owner: tikuta@chromium.org
Chatting with peria-san, it is difficult to decide partial around v8_attributes.py, so I will take the information from higher layer.

Sign in to add a comment