Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable system_health.mobile* perf tests #21430

Merged
merged 6 commits into from
Dec 28, 2023

Conversation

atuchin-m
Copy link
Collaborator

@atuchin-m atuchin-m commented Dec 20, 2023

Resolves brave/brave-browser#35024

The PR:

  • adds support for fetching the result profile from an Android device;
  • adds a special benchmark and a page set to update the source profile;
  • adds new brave pages to system_health with WPR files;
  • adds brave/chrome Android "typical" profiles;
  • changes the way we patch telemetry paths;
  • clean loading.desktop page set from the update profile logic.

Submitter Checklist:

  • I confirm that no security/privacy review is needed and no other type of reviews are needed, or that I have requested them
  • There is a ticket for my issue
  • Used Github auto-closing keywords in the PR description above
  • Wrote a good PR/commit description
  • Squashed any review feedback or "fixup" commits before merge, so that history is a record of what happened in the repo, not your PR
  • Added appropriate labels (QA/Yes or QA/No; release-notes/include or release-notes/exclude; OS/...) to the associated issue
  • Checked the PR locally:
    • npm run test -- brave_browser_tests, npm run test -- brave_unit_tests wiki
    • npm run lint, npm run presubmit wiki, npm run gn_check, npm run tslint
  • Ran git rebase master (if needed)

Reviewer Checklist:

  • A security review is not needed, or a link to one is included in the PR description
  • New files have MPL-2.0 license header
  • Adequate test coverage exists to prevent regressions
  • Major classes, functions and non-trivial code blocks are well-commented
  • Changes in component dependencies are properly reflected in gn
  • Code follows the style guide
  • Test plan is specified in PR before merging

After-merge Checklist:

Test Plan:

@atuchin-m atuchin-m self-assigned this Dec 20, 2023
@atuchin-m atuchin-m force-pushed the enable-system-health-mobile-perf branch from a575e85 to cf2b9c5 Compare December 20, 2023 14:53
@atuchin-m atuchin-m force-pushed the enable-system-health-mobile-perf branch 18 times, most recently from 5e2a3a7 to 2f1eb68 Compare December 22, 2023 11:19
@atuchin-m atuchin-m force-pushed the enable-system-health-mobile-perf branch from 2f1eb68 to 207a489 Compare December 22, 2023 11:22
@atuchin-m atuchin-m marked this pull request as ready for review December 22, 2023 11:26
@atuchin-m atuchin-m requested review from a team as code owners December 22, 2023 11:26
@atuchin-m atuchin-m force-pushed the enable-system-health-mobile-perf branch from 1d6cfad to e015e7e Compare December 25, 2023 10:04
@atuchin-m atuchin-m force-pushed the enable-system-health-mobile-perf branch from 9ec0c0e to 3f209d5 Compare December 25, 2023 16:08
Copy link
Contributor

[puLL-Merge] - brave/brave-core@21430

Description

The pull request introduces a significant restructuring of the performance benchmarking and page set handling within the Brave browser's codebase. This restructuring includes the addition of new files, the deletion of others, and a series of patches to existing files. The motivation for these changes is not explicitly stated, but it appears to be in pursuit of updating benchmark testing and adapting to newly defined page sets for performance metrics.

Changes

Changes

New Files

  • chromium_src/third_party/catapult/common/py_utils/py_utils/discover.py - New Python file added.
  • chromium_src/tools/perf/benchmarks/system_health.py - New Python file for system health benchmarks.
  • tools/perf/brave_benchmarks/__init__.py - New __init__.py added for brave_benchmarks.
  • tools/perf/brave_benchmarks/brave_loading_desktop.py - New benchmark file for desktop loading performance.
  • tools/perf/brave_benchmarks/brave_utils_benchmarks.py - New benchmark file for brave-specific utility functions.

Deleted Files

  • chromium_src/tools/perf/benchmarks/loading.py - Python file deleted.
  • chromium_src/tools/perf/page_sets/__init__.py - Python __init__.py file deleted.
  • patches/tools-perf-benchmarks-loading.py.patch - Patch file deleted.
  • patches/tools-perf-page_sets-__init__.py.patch - Patch file deleted.

Patches Added

  • patches/third_party/catapult/common-py_utils-py_utils-discover.py.patch - New patch file for discover.py.
  • patches/tools-perf-benchmarks-system_health.py.patch - New patch file for system_health.py.

Patches Deleted

  • patches/tools-perf-benchmarks-loading.py.patch - Deleted patch for loading.py.
  • patches/tools-perf-page_sets-__init__.py.patch - Deleted patch for page_sets/init.py.
  • Other patch files related to tool/perf and page_sets have been modified or renamed.

Renamed Files

  • tools/perf/brave_page_sets/brave_loading_desktop.py to tools/perf/brave_page_sets/brave_loading_desktop_pages.py
    Renamed and content updated to modify the page set for loading.desktop benchmark.

New SHA1 Files

  • tools/perf/profiles/brave-typical-android-v1.63.zip.sha1
  • tools/perf/profiles/chrome-typical-android-121.zip.sha1

Modified Files

Several other files in the tools/perf directory have been updated with new configurations and profiles. In addition, various JSON5 configuration files have been added or modified to tailor performance testing for different platforms and conditions.

Security Hotspots

  • The addition of new Python files and patches could introduce risks if user input is handled improperly or if sensitive data is exposed through logs or error messages. Proper input validation and sanitization should be enforced.
  • Changes to the performance benchmarking scripts and handling of profiles need to be reviewed for any potential timing attacks or inadvertent resource exposure, especially when involving profile data.
  • Deletion of .gitignore entries within tools/perf/page_sets/data/.gitignore must be thoroughly reviewed to ensure no sensitive data is accidentally included in future commits.
  • The utilization of shell commands within Python scripts, such as those observed in tools/perf/update_profile.py, should be handled cautiously to prevent any command injection vulnerabilities.

@atuchin-m atuchin-m force-pushed the enable-system-health-mobile-perf branch from a6f74e9 to 888fe06 Compare December 28, 2023 08:17
@atuchin-m atuchin-m enabled auto-merge (squash) December 28, 2023 09:46
@atuchin-m atuchin-m merged commit acea8fb into master Dec 28, 2023
18 checks passed
@atuchin-m atuchin-m deleted the enable-system-health-mobile-perf branch December 28, 2023 10:06
@github-actions github-actions bot added this to the 1.63.x - Nightly milestone Dec 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Android advanced perf tests: system_health.mobile*
3 participants