Re: Memory intensive processes

Richard B. Johnson (
Thu, 12 Dec 1996 13:37:15 -0500 (EST)

On Thu, 12 Dec 1996, Mark H. Wood wrote:
> On Wed, 11 Dec 1996, William Burrow wrote:
> > On Wed, 11 Dec 1996, Richard B. Johnson wrote:
> > > to exist at all! This is called "demand-zero" paging and has been used
> > > in VAXen forever.
> But don't the (possibly hundreds of thousands of) PTEs still have to
> exist? They can all point to the same page, but the hardware still wants
> them to be there. A virtual address beyond the end of the current page
> table is invalid. Those PTEs add up to a lot of memory. That's one
> reason for the larger (in some models, *much* larger) pages in the AXP chip.

That is correct. But the minimum size of a Page Table Entry is 8 bytes. It
contains a base address, a limit, and entries showing the type such as
read/execute, read/write, present, etc. That's all the processor needs to
know. However the operating system needs to know more, so there are other

Having larger pages is a "severe" tradeoff. You usually waste RAM.

> >
> > > Note that I don't advocate copying Digital's mistakes. However we can
> > > learn a lot about performance by understanding how these things work. One
> > > of the problems with "Digital security" is that if you extend a file, the
> > > data is written to zero before you are allowed to access that file. That
> > > takes a lot of CPU cycles and hurts performance.
> >
> > Hmm, I thought I read in a DEC system manual that files could contain
> > junk from previous files.
> By default a volume is INITIALIZEd to enable "high-water marking": you
> cannot allocate disk blocks to a file and the read them without first
> having written them. You can disable this (SET VOLUME
> /NOHIGHWATER_MARKING) if you don't like this. You can also set
> erase-on-delete (write erasure bit-patterns on deleted blocks) at the
> volume and file level, or DSE a whole piece of medium when you
> INITIALIZE it. /ERASE is the more costly of the two and is *not* the
> default.

All true.

> I seem to recall that VMS charges a process for its page tables as well
> as user pages. Does Linux also do this? (I know, I know, UTSL....)
VMS keeps the process header in "user space". You need CMKRNL privs to
change it, but it is an artificial protection enforced to prevent users
from changing their privs. As such, its allocation is subject to quotas.
You can set a process quota so that:

o Too little CPU time to get started.
o Too few pages to get started.
o ...etc.

This is a favorite trick we low-life would pay on the "System Manager"
once we learned the system password. Of course once the Corporate
Manager-types got real jobs, we were able to do our own thing. I have
three old VAXen and all accounts have the "SETPRV" bit available for
all the users. Sure cuts down on the phone calls.

> Mark H. Wood, Lead System Programmer MWOOD@INDYVAX.IUPUI.EDU
> Those who will not learn from history are doomed to reimplement it.
Very very true ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Dick Johnson
Richard B. Johnson
Project Engineer
Analogic Corporation
Voice : (508) 977-3000 ext. 3754
Fax : (508) 532-6097
Modem : (508) 977-6870
Ftp :
Email :,
Penguin : Linux version 2.1.14 on an i586 machine.
Warning : It's hard to remain at the trailing edge of technology.