Compile size increase, DsePreload2 cl/6615559

138 views
Skip to first unread message

Ken Okada

unread,
Jun 4, 2025, 12:14:32 AMJun 4
to bu...@chromium.org, chrome-prerendering
Hi all,

[cl] https://chromium-review.googlesource.com/c/chromium/src/+/6615559/8
[compile_size_deltas.txt] https://logs.chromium.org/logs/chromium/buildbucket/cr-buildbucket/8713087317843773617/+/u/Write_size_results/compile_size_deltas.txt
[BUILD.gn] https://source.chromium.org/chromium/chromium/src/+/main:chrome/browser/preloading/search_preload/BUILD.gn

I faced an error of compile-size bot, delta +3.58 GiB (0.92%).

Looking at the copile_size_deltas.txt, it should be caused by headers. (+2.6MB for many files.)
With BUILD.gn, the possible candidates are

- chrome/browser/preloading/search_preload/search_preload_service.h
- content/browser/preloading/prefetch/prefetch_handle_impl.h
- content/public/browser/prefetch_handle.h

chrome/browser/preloading/search_preload/search_preload_service.h

It shouldn't cause +2.6MB.

content/browser/preloading/prefetch/prefetch_handle_impl.h

`#include "base/functional/callback.h"`? I can't believe that.

content/public/browser/prefetch_handle.h

`#include "services/network/public/mojom/url_response_head.mojom.h"`? I can't believe that.

Do you have any ideas? Thanks!

By the way, I can't believe the +3.58GB increase. Is it the increase of the final binary size?
IIUC, e.g. including header, is resolved by linkers except for badly written header-only libraries.

--
Ken Okada (kenoss)

Kouhei Ueno

unread,
Jun 4, 2025, 12:23:42 AMJun 4
to Ken Okada, Takashi Nakayama, bu...@chromium.org, chrome-prerendering
@Takashi Nakayama i believe you faced with similar issue recently. any ideas?


2025年6月4日(水) 13:14 Ken Okada <ken...@google.com>:
--
You received this message because you are subscribed to the Google Groups "chrome-prerendering" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chrome-prerende...@google.com.
To view this discussion visit https://groups.google.com/a/google.com/d/msgid/chrome-prerendering/CAA0-JzDRwN8ZCj5507-%2BfNYNjowE96m%3DLxeDe63XeetLxYLk3Q%40mail.gmail.com.


--
kouhei

Takashi Nakayama

unread,
Jun 4, 2025, 12:34:44 AMJun 4
to Kouhei Ueno, Ken Okada, bu...@chromium.org, chrome-prerendering
I've only taken a quick look, but my intuition is that the change in `content/public/browser/prefetch_handle.h` is the cause.

+ #include "services/network/public/mojom/url_response_head.mojom.h"

It seems that adding a dependency on a large piece of code like URLResponseHead to a very small header that is transitively included in many places leads to a very large increase in the total compile size.

FYI: You can disable the compile-size builder by writing `Compile-Size: <REASONS>` in the CL description if the increase is inevitable.

2025年6月4日(水) 13:23 Kouhei Ueno <kou...@google.com>:

Takuto Ikuta (生田 拓人)

unread,
Jun 4, 2025, 1:12:41 AMJun 4
to Takashi Nakayama, Kouhei Ueno, Ken Okada, bu...@chromium.org, chrome-prerendering
I suggested using a forward header for mojo class.

You received this message because you are subscribed to the Google Groups "build" group.
To unsubscribe from this group and stop receiving emails from it, send an email to build+un...@chromium.org.
To view this discussion visit https://groups.google.com/a/chromium.org/d/msgid/build/CAG-NJL-PkwAbcDXwKNZ3zohDTPLo%2B50VJ1kiW%3Dzm99uXwVkUaA%40mail.gmail.com.


--
Takuto Ikuta
Software Engineer in Tokyo
Chrome Ops (chrome browser build team)

Ken Okada

unread,
Jun 4, 2025, 11:41:46 PMJun 4
to Takuto Ikuta (生田 拓人), Takashi Nakayama, Kouhei Ueno, bu...@chromium.org, chrome-prerendering
Thanks! The forward header for mojo class resolved it!
--
Ken Okada (kenoss)
Reply all
Reply to author
Forward
0 new messages