The Omni Group
These forums are now read-only. Please visit our new forums to participate in discussion. A new account will be required to post in the new forums. For more info on the switch, see this post. Thank you!

Go Back   The Omni Group Forums > OmniWeb > OmniWeb General
FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
Memory Leaks? Thread Tools Search this Thread Display Modes
I leave my browser running for days, and have noticed OW using upward of 1GB of total memory at times, which I thought was a bit odd, so I decided to track it yesterday. Below is the output from top and it's clear that OW is slowly grabbing more and more memory.

I would expect OW's memory needs to grow as the number of pages I'd viewed increases due to caching etc. but I would also expect that cache to empty once in a while. I can see that if I open many pages and then close them again, it frees up most of the memory used, but it doesn't free it all and the net result is that it keeps munching away at memory.

Any ideas?

Code:
11:32 - 41785 OmniWeb  0.0%  0:01.24  14 144  335 9452K    12M    26M   393M - just opened, 0 tabs
11:33 - 41785 OmniWeb  2.1%  0:04.70  17 165  518   49M    15M    72M   479M - opened 8 tabs
11:34 - 41785 OmniWeb  0.0%  0:06.86  17 165  508   35M    12M    55M   461M - closed all 8 tabs
11:39 - 41785 OmniWeb  0.0%  0:06.87  17 165  482   35M  8864K    55M   412M - not used for 5 mins
11:40 - 41785 OmniWeb  2.1%  0:09.21  17 166  523   50M    12M    73M   431M - reopen same 8 tabs
11:41 - 41785 OmniWeb  0.0%  0:11.31  17 165  502   36M    11M    55M   413M - close all 8 tabs
11:42 - 41785 OmniWeb  0.1%  0:13.46  17 166  582   52M    12M    78M   442M - open different 8 tabs
11:43 - 41785 OmniWeb  0.0%  0:14.56  17 169  553   39M    11M    60M   422M - close 8 tabs
11:59 - 41785 OmniWeb  0.0%  0:14.58  17 169  537   39M    11M    60M   416M - unused for 13mins
12:00 - 41785 OmniWeb  0.0%  0:15.86  18 174  576   41M    11M    68M   426M
12:02 - 41785 OmniWeb  0.0%  0:18.53  18 175  590   41M    11M    70M   427M
13:37 - 41785 OmniWeb  0.0%  1:04.86  19 200  821   78M    18M   108M   473M 
16:17 - 41785 OmniWeb  0.0%  1:39.76  19 204  912   92M    18M   125M   493M - 2 tabs (unused since 1730)
07:58 - 41785 OmniWeb  0.0%  2:25.65  19 206  982  104M    17M   137M   509M
 
Memory leaks are a common problem among all browsers. The usual workaround is to quit the browser and relaunch.
 
How much free and inactive memory do you have? It's a common misconception that when an app is done using memory it automatically releases it. It only releases it if another app requests it.
 
OmniWeb uses 300 MB physical and 900 MB virtual memory in my case. That's quite much!? How does it look like on your mac?
 
OmniWeb - RSize:149M and VSize: 511M ..., this with fifty-two minutes of up time.

I flush cache (option-Command-U) and RSize: 159M, VSize: 483M.

Don't know enough to comment further.

Safari gobbles memory ..., though.
 
After being tired of high OmniWeb memory usage I decided to see if this is a necessary evil in today's heavy-web age. I'm running Tiger and tried to simulate a typical browsing session on several browsers: open 10 tabs to various pages, then open /close several more to NY times, wikipedia, google, etc., ending with the initial 10 tabs open. Here's what I found ("Real memory" in Activity Monitor a couple of minutes after Hiding the app, on a system with ample free memory and no swapping going on):

Immediately after loading first 10 tabs
-------------------------
Code:
Camino 2.0b	 66 MB
Safari 3.1	 69 MB
Opera 9.6	 74 MB
Firefox 3.0	 78 MB
Firefox 2.0	 85 MB
Camino 1.6	 86 MB
OmniWeb 5.8	110 MB
After additionally opening/closing some NYTimes/wikipedia/google pages
--------------------------------------------
Code:
Opera 9.6	78
Camino 2.0b	82
Safari 3.1	128
OmniWeb	5	132
I gave up the test for some of the browsers after the first 10-tab opening. However, even the second test is not sufficiently realistic.
In my experience OmniWeb and Safari both tend to grow to 500+ MB after a day or two of continuous use, and I haven't tested the others yet under these conditions. However, if we assume longer term performance can be extrapolated, what I THINK can be concluded here is:

- WebKit-based browsers have terrible memory mgmt
- Gecko 1.9 made a major advance over 1.8 in this area
- Opera's superiority demonstrates proprietary technology underperforms open source in this area

I'd like to keep using OmniWeb for its best-in-class interface, but with these memory numbers it doesn't cut it on a laptop with 2GB that needs to run other things such as Parallels. Taking up 25-50% of available RAM is not acceptable for any application, not even a web browser.

I don't know if OmniWeb is able to make any improvements due to what looks like a poor base in WebKit. Perhaps it can make explicit efforts to policing the latter's memory usage and get closer to Opera and the new Gecko-based browsers. I hope so.
 
If the Web page contains a large amount of memory to first load up, cache it and hold it for a predetermined amount of time, say half an hour. Then dump it. If a Web page does not contain perhaps more than 500 kb then the browser doesn't cache the page.

Fresh page reloads are faster than cached? Sometimes, perhaps, this is so.
 
I don't really know what the WebKit developers have done but the latest nightlies have a huge improvement in memory management.

Even with 50+ tabs open it doesn't exceed 300-400MB (normal usage, with Flash- and Javascript-heavy sites) and the really nice part about it is, it actually clears out unused memory when you close tabs.

E.g.: I have Safari open with 50 tabs (400MB) then I read all of the articles, watch the YouTube videos and read my mail in GMail. After I clos those tabs I have still 10 tabs open but the memory consumption went down to about 200MB.
 
Quote:
I don't really know what the WebKit developers have done but the latest nightlies have a huge improvement in memory management.
Well, this is good to hear, I hope they will not take too long to release these improvements to both Tiger and Leopard general users. For now I'm going to continue adapting to Opera and/or Camino. Opera in particular I have to say is very impressive -- lowest memory use and fastest to render. For these, I'm willing to put up with the inferior UI.

Quote:
After I clos those tabs I have still 10 tabs open but the memory consumption went down to about 200MB.
This still sounds rather high. I would be curious to hear if you try Opera in such a use case, what you find.

Last edited by ABR; 2009-01-15 at 08:40 AM..
 
Quote:
Originally Posted by ABR View Post
Well, this is good to hear, I hope they will not take too long to release these improvements to both Tiger and Leopard general users. For now I'm going to continue adapting to Opera and/or Camino. Opera in particular I have to say is very impressive -- lowest memory use and fastest to render. For these, I'm willing to put up with the inferior UI.

This still sounds rather high. I would be curious to hear if you try Opera in such a use case, what you find.
Well, Opera is a nice browser on Windows but it's just not well integrated into the OS X system. I live in my browser so I need something that will work with a variety of other OS X apps.

Opera's memory footprint is significantly smaller than any other browser available on the market but I rarely use it.
 
 


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to track the memory leaks in any iOS application? iFuturzInc Omni Lounge 0 2012-06-01 01:44 AM
Omni Memory Hog spalkot OmniWeb General 1 2007-10-20 02:19 PM
memory leaks dustman OmniWeb Bug Reports 9 2007-03-23 06:12 PM
GMail CPU/Memory Hog? troutoil OmniWeb General 10 2006-11-28 10:23 AM
Memory Leak only120xs OmniWeb Bug Reports 8 2006-10-17 08:40 AM


All times are GMT -8. The time now is 07:16 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2022, vBulletin Solutions, Inc.