Skip to content

Enable cosmetic filter benchmarks, add resources #500

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

Merged
merged 2 commits into from
Aug 13, 2025

Conversation

atuchin-m
Copy link
Collaborator

@atuchin-m atuchin-m commented Aug 12, 2025

The PR improves benchmarks to support future work on cosmetic filters:

  • adds a resource file brave-resources.json to use in the benchmarks. It's use in bench_cosmetic_filters and bench_memory (that results in "regression");
  • adopts the script to update brave-resources.json;
  • enables and updates cosmetic filters benchmarks

NOTE: this PR intentionally makes memory-usage/brave-list-initial worse by taking into account resources.json

@atuchin-m atuchin-m requested a review from boocmp August 12, 2025 15:44
@atuchin-m atuchin-m self-assigned this Aug 12, 2025
@atuchin-m atuchin-m requested a review from antonok-edm as a code owner August 12, 2025 15:44
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Rust Benchmark

Benchmark suite Current: 7912a9c Previous: d2e870c Ratio
rule-match-browserlike/brave-list 2237973262 ns/iter (± 18291880) 2218369928 ns/iter (± 12441920) 1.01
rule-match-first-request/brave-list 989267 ns/iter (± 8020) 993380 ns/iter (± 27500) 1.00
blocker_new/brave-list 149383525 ns/iter (± 1655705) 150901091 ns/iter (± 1059000) 0.99
blocker_new/brave-list-deserialize 62665902 ns/iter (± 1075987) 63992983 ns/iter (± 1761826) 0.98
memory-usage/brave-list-initial 18831613 ns/iter (± 3) 16225933 ns/iter (± 3) 1.16
memory-usage/brave-list-initial/max 64817658 ns/iter (± 3) 64817658 ns/iter (± 3) 1
memory-usage/brave-list-initial/alloc-count 1515544 ns/iter (± 3) 1514650 ns/iter (± 3) 1.00
memory-usage/brave-list-1000-requests 2505592 ns/iter (± 3) 2505592 ns/iter (± 3) 1
memory-usage/brave-list-1000-requests/alloc-count 66139 ns/iter (± 3) 66070 ns/iter (± 3) 1.00
url_cosmetic_resources/brave-list 210439 ns/iter (± 3262)
cosmetic-class-id-match/brave-list 4283928 ns/iter (± 1184172)

This comment was automatically generated by workflow using github-action-benchmark.

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

⚠️ Performance Alert ⚠️

Possible performance regression was detected for benchmark 'Rust Benchmark'.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.10.

Benchmark suite Current: 7912a9c Previous: d2e870c Ratio
memory-usage/brave-list-initial 18831613 ns/iter (± 3) 16225933 ns/iter (± 3) 1.16

This comment was automatically generated by workflow using github-action-benchmark.

@atuchin-m atuchin-m force-pushed the enable-cosmetic-filter-benches branch from 1d81d9b to 6734e0b Compare August 13, 2025 07:19
@atuchin-m atuchin-m merged commit 5f5fe77 into master Aug 13, 2025
8 of 9 checks passed
@atuchin-m atuchin-m deleted the enable-cosmetic-filter-benches branch August 13, 2025 07:36
atuchin-m added a commit that referenced this pull request Aug 13, 2025
* Enable cosmetic filter benchmarks, add resources
* Update the component name
atuchin-m added a commit that referenced this pull request Aug 13, 2025
* Enable cosmetic filter benchmarks, add resources
* Update the component name
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.

4 participants