Skip to content

flags: drop defaults and leave pgo to official builds - #482

Open
dumbmoron wants to merge 1 commit into
mainfrom
gn-flags
Open

dumbmoron wants to merge 1 commit into
mainfrom
gn-flags

Conversation

@dumbmoron

Copy link
Copy Markdown
Member

most of flags.linux.gn restated gn defaults or now comes from flags.gn. official builds use pgo by default, so only turn it off when there's no profile to use, and stop setting v8_target_cpu, which follows target_cpu. kerberos was off for no clear reason; chromium only loads gssapi when a server asks for negotiate auth

most of flags.linux.gn restated gn defaults or now comes from flags.gn.
official builds use pgo by default, so only turn it off when there's
no profile to use, and stop setting v8_target_cpu, which follows
target_cpu. kerberos was off for no clear reason; chromium only loads
gssapi when a server asks for negotiate auth
@greptile-apps

greptile-apps Bot commented Nov 27, 2026 •

Copy link
Copy Markdown

This PR appears safe to merge; no actionable defects were found.RetriggerView in Greptile

[Medium impact] This PR appears safe to merge; no actionable defects were found.

Reviews (1) · Last reviewed commit: "flags: drop defaults and leave pgo to of..." · Reviewed by Greptile

@helium-gardener

Copy link
Copy Markdown

Possibly related issues

These relationships were inferred from the effective change and may need maintainer confirmation:

  • May be resolved by this PR: imputnet/helium-linux#468 — The PR inherits Chromium's enabled 'use_kerberos' default and compiles the Linux Negotiate/SPNEGO handler requested by the issue. Kerberos authentication becomes available for proxies and allowlisted origins with system GSSAPI and valid credentials.

@helium-gardener helium-gardener Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The PR removes H.264 and AAC playback from Linux builds, breaks Siso selection for source tarballs, and exposes a persistent network-service sandbox downgrade through Kerberos negotiation. It also disables x64 PGO and changes the debug symbols produced by release and development builds.

Findings without a GitHub diff anchor

  • high: Preserve H.264 and AAC playback in Linux builds — Removing proprietary_codecs=true and ffmpeg_branding="Chrome" drops H.264 video and AAC audio support on x64 and arm64. is_official_build=true controls optimization, and Helium still uses Chromium's unbranded configuration. Keep both overrides so Chromium advertises those codecs and FFmpeg can decode them. (build/config/features.gni:31)

  • high: Keep Siso selected for Linux source tarballs — Removing use_siso=true sends clean tarball builds down the Ninja path. autoninja.py cannot identify the unpacked Chromium tree as its project, so it also misses the Ninja binary bundled there. Builds without Ninja on PATH stop, and builds configured with SISO_REAPI_ADDRESS select Reclient instead of the configured Siso backend. Keep the explicit use_siso=true argument for the tarball workflow. (third_party/depot_tools/autoninja.py:162)

  • high: Honor explicit network sandbox settings when enabling Kerberos — Enabling use_kerberos lets a remote Negotiate challenge persistently disable the Linux network-service sandbox, even when an administrator explicitly enabled it. The browser records the request before checking whether the origin may use default credentials, so the downgrade can happen without a Kerberos ticket or successful authentication. Preserve explicit sandbox settings and require local opt-in for any GSSAPI path that needs an unsandboxed service. (chrome/browser/net/system_network_context_manager.cc:292)

  • medium: Preserve Linux release and development symbol levels — Removing symbol_level=1 and blink_symbol_level=0 makes official Linux builds generate full debug info, including for Blink. That adds compiler and linker work and increases the debug data carried through CI caches. The same removal makes non-debug component builds from he setup lose the line-table info they previously generated. Keep both overrides to preserve the existing release and development behavior. (build/config/compiler/compiler.gni:131)

Review walkthrough

Changes

Files Summary
flags.linux.gn
chromium/build/config/features.gni
chromium/third_party/ffmpeg/ffmpeg_options.gni
chromium/net/features.gni
The Linux flag cleanup inherits Chromium's unbranded codec defaults and enables the Linux Negotiate authentication handler.
flags.linux.gn
chromium/build/config/compiler/compiler.gni
chromium/third_party/blink/renderer/config.gni
repository/scripts/dev.sh
Deleting the symbol overrides enables full release debug info and removes line-table info from the development component build.
flags.linux.gn
repository/downloads.ini
repository/.github/scripts/build.sh
chromium/third_party/depot_tools/autoninja.py
Removing the explicit Siso argument makes builder selection depend on checkout discovery, which fails for the clean tarball layout.
scripts/shared.sh
helium/flags.gn
chromium/build/config/compiler/pgo/pgo.gni
chromium/build/config/v8_target_cpu.gni
The generator leaves the shared PGO opt-out in effect for x64. GN derives the V8 CPU from the target CPU on supported Linux toolchains.

Review checks

Check Result Notes
Scope ✅ Passed The merge-base diff matches the request's two changed paths. The scripts/dev.sh difference in change.diff comes from base-only commit 2499c4a (#479). Both revisions pin the same Helium checkout.
Project Policy ✅ Passed The PR changes Linux build configuration and GN argument generation outside the Chromium patch series. Upstream tests are outside the effective diff.
Correctness And Safety ⚠️ Finding The effective flags change codec support, sandbox behavior, build-tool selection, x64 PGO, and release and development symbols.
Chromium Idioms ⚠️ Finding Chromium's Siso autodetection assumes a discoverable checkout. Its explicit use_siso argument supports the tarball workflow.
Simplicity And Decomposition ✅ Passed The GN generator uses one shared path for CI, Docker, and development. The findings identify where that path needs explicit settings to preserve behavior.
Patch Organization ➖ Not applicable The platform and shared patch stacks are outside the merge-base diff.

Analysis record

  • Changed files considered: 2
  • Findings: 5 new, 0 retained, 0 resolved
  • Source snapshot: cefb5acc15c1
  • Codex: gpt-6.2-sol, reasoning xhigh, requested tier ultrafast, web search cached
  • Patch application: clean
  • Chromium context tool calls: none
  • Maintainer conventions applied: ground-validation-in-reachable-failures, justify-patch-structure-changes, preserve-incremental-loading, preserve-privacy-boundaries, preserve-shared-tab-state, script-resource-lifecycle, stop-work-after-failure, ui-command-contexts, validate-supported-ui-paths, verify-constrained-layouts, verify-current-revision, verify-runtime-selection-paths, verify-shipped-data-before-migration, verify-storage-references-before-deletion, visible-ui-anchors

Limitations

  • Validation was static. GN generation, builds, and browser behavior were reviewed through their source paths.
  • The exact-version archive manifest was unavailable. The Siso finding uses the materialized source layout and the archive publisher's packaging and preparation code.

Comment thread scripts/shared.sh
if [ "$_has_pgo" = true ]; then
echo "chrome_pgo_phase = 2" | tee -a "${_out_dir}/args.gn"
# Official builds default to PGO; Chromium only ships an x64 Linux profile.
if [ "$_has_pgo" != true ]; then

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium: Keep PGO enabled for x64 release builds

The generated args.gn already sets chrome_pgo_phase=0 through the pinned shared flags. Removing the explicit phase-2 assignment disables PGO for x64 release CI and for local --pgo builds, even when a profile is present. Keep the phase-2 override when _has_pgo is true.

Evidence: helium/flags.gn:1 sets chrome_pgo_phase=0, and scripts/shared.sh:112 copies it into args.gn. .github/scripts/build.sh:16 requests PGO, and scripts/shared.sh:51 enables _has_pgo for x64. The new branch at line 116 leaves the shared zero in place for that case, overriding the official-build default in build/config/compiler/pgo/pgo.gni:26.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant