You conclusion about the Windows design goals are correct.

Hardware Destroyer (power saving) was invented for the same reason (to maximize 
the rate of hardware failure through imposition of unnecessary thermal and 
mechanical stresses on all system components, causing early failure and 
increasing profits due to replacement by consumers).  

Microsoft optimizes for "maximum busyness" of the CPU and I/O channels. and 
"minimum busyness" of RAM and other cache's.

This is, of course, 100% opposite of the correct way to design a computer 
system.  However, it is Microsoft and no one (except a fanbois) ever claimed 
they possessed any common (or other) sense whatsoever.


> -----Original Message-----
> From: sqlite-users-bounces at mailinglists.sqlite.org [mailto:sqlite-users-
> bounces at mailinglists.sqlite.org] On Behalf Of Howard Chu
> Sent: Wednesday, 3 February, 2016 16:53
> To: SQLite mailing list
> Subject: Re: [sqlite] IS a SQLite db of small size as good as reliable
> cache?
> 
> GB wrote:
> > So where have you got this wisdom from? It's just plain Bullshit!
> >
> > Just as most cache managers do, Windows cache manager uses some sort of
> LRU
> > caching scheme. So all data once read from file is kept in memory until
> either
> > some memory pressure occurs or it is simply pushed out by newer data.
> 
> No. Windows will toss clean pages out even in the total absence of memory
> pressure. It is moronic, but true. You can repeat the steps I outlined for
> yourself and see.
> 
> https://groups.google.com/d/msg/comp.os.ms-
> windows.nt.misc/449tdNYPoX0/it4cx8Gvv2AJ
> 
> > Actually, from what I've experienced, I'd recommend to size sqlite's
> memory to
> > fit for your largest transactions and leave most of the caching to the
> OS.
> >
> > And yes, unlike in many *NIX implementations, Windows'
> FlushFileBuffers() call
> > DOES issue according write commands to the hardware, so setting PRAGMA
> > synchronous ON/OFF makes a big difference in write performance on
> Windows
> > systems.
> >
> > Howard Chu schrieb am 30.01.2016 um 23:23:
> >> dpb wrote:
> >>> Dear Community,
> >>>
> >>> Assuming that SQLite would arrange the database table contents on page
> >>> boundary and
> >>>
> >>> 1)  if db is small let us say maximum 5MB,
> >>>
> >>> 2  further if such a db is part of windows service / application
> running
> >>> continuously then may be pages will remain in the memory under normal
> >>> conditions.
> >>>
> >>> Q1) Operating System like Windows would cache the series of pages, is
> this
> >>> behavior not almost same as that of Cache?
> >> The Windows cache manager is quite aggressive at evicting cached pages
> from
> >> RAM. It used to be tunable back in Win2000, but none of those tuning
> knobs
> >> survived past WinXP. Generally, if you access some data, leave it for
> more
> >> than 5-10 seconds, don't expect to be able to reference it again
> without
> >> incurring a hard page fault.
> >>
> >> Note that the cache eviction runs quite frequently - once every 5
> seconds or
> >> so, and evicts pages regardless of whether there's any memory pressure
> in the
> >> system. It's quite possibly the stupidest cache manager ever written.
> 
> --
>    -- Howard Chu
>    CTO, Symas Corp.           http://www.symas.com
>    Director, Highland Sun     http://highlandsun.com/hyc/
>    Chief Architect, OpenLDAP  http://www.openldap.org/project/
> _______________________________________________
> sqlite-users mailing list
> sqlite-users at mailinglists.sqlite.org
> http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users



Reply via email to