brave / brave-browser

Brave browser for Android, iOS, Linux, macOS, Windows.
https://brave.com
Mozilla Public License 2.0
17.95k stars 2.35k forks source link

High memory usage using Filter lists and custom Filter Lists #30543

Open ChitranshuV opened 1 year ago

ChitranshuV commented 1 year ago

Description

The memort footprint of "browser" process in the Brave in-built task-manager reports very high value when using additional filters list from the pre-selected options or by adding custom lists. This is visible even without opening any website and just being on the homepage (Brave Dashboard)

Memory usage without any filter list = < 200 MB Memory usage with only 5-6 filter list from the options = ~ 650 MB Memory usage with 5-6 filter list and 6 additional custom filter list = 800 - 1000 MB

Filter List that I am using:

Custom Filter List that I was using:

Steps to Reproduce

Desktop Brave version:

Brave 1.52.109 Chromium: 114.0.5735.26 (Official Build) beta (64-bit)
Revision 7075cbb66f0542ac3e01ddfde6b813e7d61118a5-refs/branch-heads/5735@{#454}
OS Linux

System Information

Operating System: Arch Linux KDE Plasma Version: 5.27.5 KDE Frameworks Version: 5.106.0 Qt Version: 5.15.9 Kernel Version: 6.3.3-arch1-1 (64-bit) Graphics Platform: Wayland Processors: 12 × AMD Ryzen 5 5600H with Radeon Graphics Memory: 15.0 GiB of RAM Graphics Processor: AMD Radeon Graphics Manufacturer: HP Product Name: Victus by HP Laptop 16-e0xxx

ChitranshuV commented 8 months ago

This problem still exists and still causes huge memory usage when using custom lists. uBlock Origin also sees a spike in memory usage when using custom lists, but the increase is quite modest; about 20 to 30MB.

The difference between not using custom lists and using them in Brave is quite huge: 224MB vs. 616MB in my case.

This is my current setup:

These are the following custom lists that I am using:

How to Reproduce - Please see the memory usage of 'Browser' in the Brave Task Manager

See the screenshots below:

Enabling custom list image

Disabling custom list image

ChitranshuV commented 2 months ago

Bumping up this issue again.

Issue still persisting in

Brave           1.70.94 Chromium: 128.0.6613.114 (Official Build) beta (64-bit) 
Revision    7ee7ec28264896bd8a9aff39cdb9432da38be028
OS          Linux
JavaScript  V8 12.8.374.24
$ inxi -S
System:
  Host: fedora Kernel: 6.10.6-200.fc40.x86_64 arch: x86_64 bits: 64
  Desktop: Cinnamon v: 6.2.9 Distro: Fedora Linux 40 (Cinnamon)

I'm sure some overhead is inevitable when you have more blocklists than the default one, but as you can see in the screenshot below, there is almost 300 MB difference in memory usage of "Browser" process before and after enabling three popular custom blocklists.

Screenshot from 2024-09-04 17-50-06

Screenshot from 2024-09-04 17-50-22