This is tracking bug to reduce size of mojo related header files. Design doc: https://docs.google.com/document/d/1OR8qBH9HgmCKeQiaSa5NwJsQWnWPof2-kPKfAFPBL4E/edit?usp=sharing Currently I'm planning to introduce mojom-forward.h in parallel to minimize size of header files.
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/d51ebd693a614093b052b6273a48f2058f35d922 commit d51ebd693a614093b052b6273a48f2058f35d922 Author: Takuto Ikuta <tikuta@chromium.org> Date: Fri Jan 18 05:01:16 2019 [mojo] move definition of operator<< for enum to mojom-shared.cc This is to make mojo header file smaller for the file having many enum values. e.g. https://cs.chromium.org/chromium/src/out/Debug/gen/third_party/blink/public/platform/web_feature.mojom-shared.h This reduced total size of *.mojom-shared.h when building chrome on linux from 10099430 bytes to 9510524 bytes. Bug: 922875 Change-Id: I3183b184102cbbe3b5a971660f046e784ff1b771 Reviewed-on: https://chromium-review.googlesource.com/c/1415246 Reviewed-by: Scott Violet <sky@chromium.org> Reviewed-by: Ken Rockot <rockot@google.com> Commit-Queue: Takuto Ikuta <tikuta@chromium.org> Cr-Commit-Position: refs/heads/master@{#624012} [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/content/public/common/BUILD.gn [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/mojo/public/tools/bindings/generators/cpp_templates/enum_macros.tmpl [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/mojo/public/tools/bindings/generators/cpp_templates/module-shared.cc.tmpl [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/mojo/public/tools/bindings/generators/cpp_templates/module-shared.h.tmpl [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/third_party/blink/public/BUILD.gn [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/third_party/blink/public/mojom/BUILD.gn [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/ui/accessibility/BUILD.gn [modify] https://crrev.com/d51ebd693a614093b052b6273a48f2058f35d922/ui/base/ime/chromeos/public/interfaces/BUILD.gn
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/54133cb004ffaba872b9a6449b2725a16bb0feab commit 54133cb004ffaba872b9a6449b2725a16bb0feab Author: Abhishek Arya <inferno@chromium.org> Date: Tue Jan 22 18:22:44 2019 Revert "[mojo] move definition of operator<< for enum to mojom-shared.cc" This reverts commit d51ebd693a614093b052b6273a48f2058f35d922. Reason for revert: Broke linux ASan builds Original change's description: > [mojo] move definition of operator<< for enum to mojom-shared.cc > > This is to make mojo header file smaller for the file having many enum values. > e.g. > https://cs.chromium.org/chromium/src/out/Debug/gen/third_party/blink/public/platform/web_feature.mojom-shared.h > > This reduced total size of *.mojom-shared.h when building chrome on linux > from 10099430 bytes to 9510524 bytes. > > Bug: 922875 > Change-Id: I3183b184102cbbe3b5a971660f046e784ff1b771 > Reviewed-on: https://chromium-review.googlesource.com/c/1415246 > Reviewed-by: Scott Violet <sky@chromium.org> > Reviewed-by: Ken Rockot <rockot@google.com> > Commit-Queue: Takuto Ikuta <tikuta@chromium.org> > Cr-Commit-Position: refs/heads/master@{#624012} TBR=sky@chromium.org,rockot@google.com,tikuta@chromium.org # Not skipping CQ checks because original CL landed > 1 day ago. Bug: 922875 Change-Id: Id0b5d6ec5fb97e961972d421d7af1c29212b87fd Reviewed-on: https://chromium-review.googlesource.com/c/1426861 Reviewed-by: Abhishek Arya <inferno@chromium.org> Commit-Queue: Abhishek Arya <inferno@chromium.org> Cr-Commit-Position: refs/heads/master@{#624840} [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/content/public/common/BUILD.gn [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/mojo/public/tools/bindings/generators/cpp_templates/enum_macros.tmpl [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/mojo/public/tools/bindings/generators/cpp_templates/module-shared.cc.tmpl [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/mojo/public/tools/bindings/generators/cpp_templates/module-shared.h.tmpl [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/third_party/blink/public/BUILD.gn [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/third_party/blink/public/mojom/BUILD.gn [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/ui/accessibility/BUILD.gn [modify] https://crrev.com/54133cb004ffaba872b9a6449b2725a16bb0feab/ui/base/ime/chromeos/public/interfaces/BUILD.gn
Comment 1 by bugdroid1@chromium.org
, Jan 18 (5 days ago)