Built binary is slower than downloaded binary

154 views
Skip to first unread message

Venkatesan Srinivasan

unread,
Jul 15, 2025, 3:46:33 PM7/15/25
to Chromium-dev
Hi,
I'm using puppeteer to launch headless chromium and run a bunch of JS on the HTMLs. I noticed that the same JS runs in ~300ms when I use the chromium downloaded from https://storage.googleapis.com/chromium-browser-snapshots/index.html?prefix=Linux_x64/1148123/.

However, if I download the source and build the tag 115.0.5790.102 with the gn args is_debug = false and disable_fieldtrial_testing_config=true it takes ~840ms to finish. I also noticed that the chrome binary size is bigger by ~70mb. Am I missing any other args? Looking for pointers on what could be different.


--
Thanks and Regards,
S.Venkatesan

Christian Biesinger

unread,
Jul 15, 2025, 3:55:00 PM7/15/25
to vija...@gmail.com, Chromium-dev
You should use `is_official_build = true`.

Christian

Venkatesan Srinivasan

unread,
Jul 16, 2025, 9:44:50 AM7/16/25
to Chromium-dev, Christian Biesinger, Chromium-dev, vija...@gmail.com
The Chromium documentation says "This build requires that you are a Googler with src-internal checked out." Is that just for the branding?

Nico Weber

unread,
Jul 16, 2025, 9:52:56 AM7/16/25
to vija...@gmail.com, Chromium-dev, Christian Biesinger
Yes, src-internal is only required for is_chrome_branded = true, not for is_official_build = true.

--
--
Chromium Developers mailing list: chromi...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-dev
---
You received this message because you are subscribed to the Google Groups "Chromium-dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email to chromium-dev...@chromium.org.
To view this discussion visit https://groups.google.com/a/chromium.org/d/msgid/chromium-dev/985c1523-4c7d-45af-8d2b-e4350c4125e1n%40chromium.org.

K. Moon

unread,
Jul 16, 2025, 9:58:42 AM7/16/25
to vija...@gmail.com, Chromium-dev, Christian Biesinger
I do think the practice of using "is_official_build" to mean, "build with optimizations" is confusing, but yes, only Chrome-branded requires internal sources.

You may or may not want to turn off PGO as well. PGO makes the code faster in some cases, but can be a pessimization if your code doesn't match the profile. It also takes a lot longer to build.

--

Nico Weber

unread,
Jul 16, 2025, 10:34:19 AM7/16/25
to km...@chromium.org, vija...@gmail.com, Chromium-dev, Christian Biesinger
On Wed, Jul 16, 2025 at 9:55 AM K. Moon <km...@chromium.org> wrote:
I do think the practice of using "is_official_build" to mean, "build with optimizations" is confusing, but yes, only Chrome-branded requires internal sources.

You may or may not want to turn off PGO as well. PGO makes the code faster in some cases, but can be a pessimization if your code doesn't match the profile. It also takes a lot longer to build.

(PGO shouldn't affect build times a lot. ThinLTO is what makes official builds take longer.)
 

K. Moon

unread,
Jul 16, 2025, 11:01:02 AM7/16/25
to Nico Weber, vija...@gmail.com, Chromium-dev, Christian Biesinger
Good information, thanks! Forgot about the difference.

Venkatesan Srinivasan

unread,
Jul 21, 2025, 8:53:30 AM7/21/25
to Chromium-dev, K. Moon, Chromium-dev, Christian Biesinger, vija...@gmail.com
Thanks folks. "is_official_build" worked. I had to also use "chrome_pgo_phase = 0" and set "sudo sysctl -w vm.max_map_count=262144" as per the documentation.
Reply all
Reply to author
Forward
0 new messages