Re: Netsurf Cache -- relocation tangent

2016-04-13 Thread lists
In article <1fd5ae6f55@abbeypress.net>,
   Jim Nagel  wrote:
> Several months ago I got fed up with this, and also with time wasted 
> by !Locate searching through all of !Cache.  So on all my machines I 
> made a new directory that comes alphabetically last:   $._

I haven't actually got !Locate so I don't have that problem.

-- 
Stuart Winsor

Tools With A Mission
sending tools across the world
http://www.twam.co.uk/



Netsurf Cache

2016-04-13 Thread Martin Avison
In article <20160413104528.ga24...@kyllikki.org>,
   Vincent Sanders  wrote:

> I will go over how this feature works once again. 

[Snip]

Thanks Vincent for the long and detailed explanation of how Netsurf uses
the cache.

After over 45 years working with computers I understand that the use of
any computer resource is a trade-off with other resources, all of which
have to be balanced for optimum performance.
 
I have now delated the whole cache, and reset Netsurf to the default
values for disc of 1024MB and 28 days, and memory is set to 50MB. 

I have also created a new directory called ~Temporary and moved !Cache
into it, and ensured it is seen during Boot. The ~Temporary directory can
be omitted from any backps, searches etc.
 
Time will tell what the effects of this are!

Thanks
Martin




Re: Netsurf refresh

2016-04-13 Thread Rob Kendrick
On Wed, Apr 13, 2016 at 08:35:01PM +0100, Jim Nagel wrote:
> Vince M Hudd  wrote on 13 Apr:
> > Ctrl-F5 - which may be unfamiliar, but is standard on all the browsers
> > I use (including NetSurf) - is the keystroke I use to reload pages
> > when working on websites because it *does* fetch a new version of the
> > page, rather than just reload it from a cache.
> 
> Interactive help for the item on the Netsurf buttonbar does say 
> "Reload".  Does it do the same thing as Ctrl-F5 or not?

Vince's email is pretty clear.

B.



Re: Netsurf refresh

2016-04-13 Thread Jim Nagel
Vince M Hudd  wrote on 13 Apr:
> Ctrl-F5 - which may be unfamiliar, but is standard on all the browsers
> I use (including NetSurf) - is the keystroke I use to reload pages
> when working on websites because it *does* fetch a new version of the
> page, rather than just reload it from a cache.

Interactive help for the item on the Netsurf buttonbar does say 
"Reload".  Does it do the same thing as Ctrl-F5 or not?

-- 
Jim Nagelwww.archivemag.co.uk



Re: Netsurf refresh

2016-04-13 Thread Vince M Hudd
Jim Nagel  wrote:


[Reloading a page didn't load a new version]

> (Hmm, just noticed from a search of Netsurf menu that the shortcut for
> "Navigate > Reload page" is Ctrl-F5 -- I didn't try that unfamiliar
> keystroke, but presume it does same as above.

FWIW, Ctril-F5 - which may be unfamiliar, but is standard on all the
browsers I use (including NetSurf) - is the keystroke I use to reload pages
when working on websites because it *does* fetch a new version of the page,
rather than just reload it from a cache.

-- 
Vince M Hudd
Soft Rock Software



Netsurf refresh

2016-04-13 Thread Jim Nagel
This might or might not be related to the issues Vincent Sanders talks 
about in the current thread "Netsurf cache".

I recently updated the home page of my own website.  Then tested 
viewing it with Netsurf.  It kept serving up the old page, despite my 
clicking Netsurf's Reload button -- with Select (to reload page), then 
again with Adjust (to "reload page and all the objects it contains").

Is this non-update to be expected?  Am I misunderstanding the use of 
Reload?

(Hmm, just noticed from a search of Netsurf menu that the shortcut for 
"Navigate > Reload page" is Ctrl-F5 -- I didn't try that unfamiliar 
keystroke, but presume it does same as above.  Is Ctrl-R used at all?)

I finally deleted the history file; then my revised page displayed. 
Shouldn't reload trump history?

Using Netsurf #3433 at the moment.

-- 
Jim Nagelwww.archivemag.co.uk



Re: Netsurf Cache

2016-04-13 Thread Rob Kendrick
On Wed, Apr 13, 2016 at 12:06:04PM +0100, David Pitt wrote:
> 
> How about this from a Titanium :-
> 
> (75142.82) content/llcache.c:3402 llcache_finalise: Backing store wrote
> 2590212 bytes in 1394 ms (average 1858114 bytes/second)

1.8MB/sec to an SSD is nothing to write home about.  I'd expect at least
20MB/sec from a modern OS on a spinning disc.

B.



Re: Netsurf Cache

2016-04-13 Thread David Pitt
Vincent Sanders, on 13 Apr, wrote:

> On Tue, Apr 12, 2016 at 02:49:39PM +0100, nets...@avisoft.f9.co.uk wrote:
> > There was much discussion about a year ago about the cache performance
> > on RISC OS, and there were some code changes, but I would like to add
> > the results of some investigations of the Netsurf v3.4 cache on my
> > Iyonix, running RISC OS 5.23 (11 Oct 2015).
> 
> I am beginning to think this feature should never have been enabled
>  for hoplessly legacy operating systems such as RISC OS.

OTOH as RISC OS lumbers into the 21st century with modern hardware that
cache comes into its own.

How about this from a Titanium :-

(75142.82) content/llcache.c:3402 llcache_finalise: Backing store wrote
2590212 bytes in 1394 ms (average 1858114 bytes/second)

I haven't done anything scientific but my impression is that the cache is of
worthwhile benefit to NetSurf on the Titanium. (The Titanium has RISC OS on
an SSD via ADFS and SATA.)

HTH. 
-- 
David Pitt



Re: Netsurf Cache

2016-04-13 Thread Vincent Sanders
On Tue, Apr 12, 2016 at 02:49:39PM +0100, nets...@avisoft.f9.co.uk wrote:
> There was much discussion about a year ago about the cache performance on
> RISC OS, and there were some code changes, but I would like to add the
> results of some investigations of the Netsurf v3.4 cache on my Iyonix,
> running RISC OS 5.23 (11 Oct 2015).

I am beginning to think this feature should never have been enabled
 for hoplessly legacy operating systems such as RISC OS.

I will go over how this feature works once again. This is in response
 to this message but is, as usual, aimed at all users.

To be clear a cache in any computer program trades one resource for
 another. 

Generally a web browser will have numerous caches for different
uses. In NetSurf we have three main caches:

 1. one held in RAM for decoded images

 This cache trades processor time (used to decode images from
  compressed source formats like jpegs) for memory (to hold the
  decoded images).

 Without this cache scrolling a page would be glacial as every
  time an image needs to be plotted, even if it is only a single
  pixel of it, we would need to decode the entire source image

 2. a cache for source objects (the stuff downloaded from web servers) held in 
memory 

 This cache trades memory for network bandwidth used downloading
 source objects.

 Without this every time a page navigation happens within a
  website all the css, images, javascript etc that did not chnage
  must be downloaded again which would quickly make browsing
  unusable.

 3. a cache of source objects held on disc.

 This cache trades disc space and bandwidth for memory.

 Although not immediately obvious the memory is that from the
  previous cache and indirectly could be seen as network bandwidth
  used. This is known as a cache hierachy where one cache backs
  another.

The memory cache size setting deals with the first two of these caches
 and the disc cache settings the third.

> 
> In the past I had problems with the cache taking large amounts of disc
> space, and the resulting long backup times for !Boot, so my current
> settings are 10MB space, expiring after 2 days. 

The average web page is now well over 2 megabytes [1] and is growing
 rapidly all the time. You would be much better served having no
 persistant storage (disc) cache enabled at all by setting its size to
 zero than by a small one like this.

As I keep emphasising again and again the cache is a trade of one
 resource for another in an attempt to reduce the oveall time to
 perform the action of visiting a web page. If you are not able to make
 that trade a net profitable transaction you are better off not doing
 it at all.

The RAM, CPU and disc overhead for enabling the cache greatly exceeds
 your settings which probably require a minimum of a few hundred
 megabytes and several weeks to make the trade worthwile on RISC
 OS. In fact I will add a feature request to the tracker to have a
 minimum viable size for the cache size options.

I fear your expectations around sizes of resources are a little out of
 date. The default cache sizes on PC platforms is 128 megabytes of
 memory and a gigabyte of disc. Even these are pretty restrained, for
 example: my desktop has a recently started copy of chrome with a
 handful of tabs open and thats reporting well over a gigabyte of
 memory used and several gigabytes of disc.

It is not uncommon for standard PCs to have 8 gigabytes of memory and
 a terrabyte of hard drive space accessed at rates measured in
 hundreds of megabytes a second. I know RISC OS has no hope of getting
 anywhere near such resources but it must be understood that the
 modern web is orientated around systems of this magnitude of capability.

[1] http://www.soasta.com/blog/page-bloat-average-web-page-2-mb/

> 
> However, the actual space usage was 45MB (as measured by Filer Count),
> and it contained 210 files. What was more difficult to find was that
> there were 7,298 directories with 8 levels, which occupied another 14MB,
> of which 6,412 contained no files at any lower level. So only 886
> directories actually contained the 210 files of cached data. Enumeration
> of the cache took about 2 minutes.
> 

It is possible you had a cache left over from an earlier version of
 NetSurf where small files were stored in separate files. Cache
 improvements merge all smaller files into a few large index files and
 only use the directories for larger files.

Regardless the directories are not accounted for as on most OS they
 are a very low cost resource and are never enumerated. There is a well
 known "cache" indicator file created which on most systems is used to
 indicate to other software that the contents of the directory are not
 at all "valuble" and may be discarded at will and should not be
 enumerated.

> I decided to delete all 6,412 directories that contained no data, saving
> about 12MB of disc space. More importantly, counting