[comp.sys.amiga] Memory Management

dillon@CORY.BERKELEY.EDU (Matt Dillon) (11/20/87)

    Virtual memory != EachTaskGetsItsOwnAddressSpace

    As far as the Amiga goes, the only compatible solution is a Linear
virtual address space over the entire system.  I.E. addresses are still
unique, tasks are still scatter loaded, and since tasks do NOT have their
own virtual address space, they all start in unique locations and have
the ability to address everything else running in the system.

    Older programs would be upward compatible and actually run with 
full r/w access to the entire system, while newer programs which know 
about the VM will run protected.

    So adding VM/MMU to the Amiga is perfectly O.K.  There is no reason
why we have to conform to the 'standard' way of doing VM.  The idea of
a Linear virtual address space spanning all system objects was brought
to you by.... Zerox Parc of course.

					-Matt

klm@munsell.UUCP (Kevin [Being Weird Isn't Enough] McBride) (11/24/87)

In article <8711201906.AA25134@cory.Berkeley.EDU> dillon@CORY.BERKELEY.EDU (Matt Dillon) writes:
>
>    Virtual memory != EachTaskGetsItsOwnAddressSpace
>
>    As far as the Amiga goes, the only compatible solution is a Linear
>virtual address space over the entire system.
>[...]


Well, now you're talking!  Here's a case where I agree with you
completely.  So, I'm not going to call you something unpleasant. :-)

This seems like a perfectly rational and compatible way of doing VM on
the Amiga. 

I like it!  I like it!  I wish I had thought of it!

-- 
Kevin McBride, the guy in the brace //       | It's the end of the world
Eikonix - A Kodak Co.              //        |   as we know it,
Billerica, MA                  \\ //  Amiga  | 
{encore,adelie}!munsell!klm     \X/   Rules! | And I feel fine...

oconnor@sunray.steinmetz (Dennis Oconnor) (11/24/87)

In article <...> klm@atkins.UUCP (Kevin [...] McBride) writes:
>In article <...> dillon@CORY.BERKELEY.EDU (Matt Dillon) writes:
>>    Virtual memory != EachTaskGetsItsOwnAddressSpace
>>    As far as the Amiga goes, the only compatible solution is a Linear
>>virtual address space over the entire system.
>
>This seems like a perfectly rational and compatible way of doing VM on
>the Amiga. 
>I like it!  I like it!  I wish I had thought of it!

Well, on the one hand, this means you are still limited to 8.5MB of
memory. Doesn't it? So why bother? Just buy the 8MB and have real speed.
What does 8MB cost, anyway? $1500 ?

OF course, this does leave a wonderful hardware opportunity : the
Virtual Memory RAM Expander. Take some small amount of a RAM ( like a
megabyte ), a cheap small hard disk, a small amount of CAM ( say 256
words, each 12 bits wide ), a small processor ... put it all in a SOTS
box ( just kidding? :-) with it's own power and ... transparent virtual
memory ! Looks like just RAM to the Amiga, but is really mainly Disk!
This would really pay with a 68020 : use a really big disk. "My Amiga
thinks it has 470MByte of RAM ...". Yow!

Other bits : who out there is familiar with Symbolics Lisp Machines
mechanisms for Wrold Loads and Saves? With this setup, you could do
that. Imagine everything you had in memory at powerdown being there
again when you powered up ( or as much as you want, anyway ) as if
you'd never touched the off switch. And VERY non-volatile.

Kinda the opposite of a RAM disk, isn't it? A disk RAM. :-)


--
	Dennis O'Connor 	oconnor@sungoddess.steinmetz.UUCP ??
				ARPA: OCONNORDM@ge-crd.arpa
        "If I have an "s" in my name, am I a PHIL-OSS-IF-FER?"

fish%calypso@Sun.COM (Lorenz Fish) (11/25/87)

I am posting this for Doug Merritt ({ucbvax,sun}!unisoft!certes!doug); I
will forward any replies for him:

In article <1406@atkins.munsell.UUCP> klm@atkins.UUCP (Kevin [Being Weird Isn't Enough] McBride) writes:
>In article <8711201906.AA25134@cory.Berkeley.EDU> dillon@CORY.BERKELEY.EDU (Matt Dillon) writes:
>
>>    As far as the Amiga goes, the only compatible solution is a Linear
>>virtual address space over the entire system.
>
>This seems like a perfectly rational and compatible way of doing VM on
>the Amiga. 

A nice idea, but unfortunately not perfectly compatible. As discussed
here some time ago, there's still the problem of, e.g. cooperating tasks
which have pointers into each others memory space. Message passing is
based on shared memory on the Amiga.

You could certainly rewrite such tasks to use a new method that allowed
for memory protection, but you could not have it work invisibly. I suppose
you could also just take the hit of such programs not working, but more
stuff would die than you might suppose. Cooperating tasks are a very nice
design paradigm on a machine like the Amiga; it would be a shame to give
them up...A big enough shame, in fact, that very few people would end
up adopting this solution.

But wait...maybe there's a bandaid? Perhaps you could rig up a way of
telling the system about tasks that need to share address space. Got
any ideas about this? Any such method would be inconvenient, but might
at least work.
	Doug Merritt		{ucbvax,sun}!unisoft!certes!doug
-------------------------------------------------------------------------

		 o   	Lorenz Fish	{ucbvax}!sun!fish@calypso
		 o
		 o @^_ 
		  <_~_>{
		    V

				Sun Microsystems	Mountain View, CA

		|||   disclaimer:  The company would never say THAT!   |||

daveh@cbmvax.UUCP (Dave Haynie) (11/25/87)

in article <7958@steinmetz.steinmetz.UUCP>, oconnor@sunray.steinmetz (Dennis Oconnor) says:
> In article <...> klm@atkins.UUCP (Kevin [...] McBride) writes:
>>In article <...> dillon@CORY.BERKELEY.EDU (Matt Dillon) writes:
>>>    Virtual memory != EachTaskGetsItsOwnAddressSpace
>>>    As far as the Amiga goes, the only compatible solution is a Linear
>>>virtual address space over the entire system.
>>
>>This seems like a perfectly rational and compatible way of doing VM on
>>the Amiga. 
>>I like it!  I like it!  I wish I had thought of it!
> 
> Well, on the one hand, this means you are still limited to 8.5MB of
> memory. Doesn't it? 

Of course not!  The limits you see are based on the 68000 memory map.  There's
8.5M - 64K of autoconfigure space; leaving the .5M - 64K for I/O, that gives
you the popular 8 megs.  Now add the basic 512K of CHIP RAM, and you're up to
your 8.5 meg.  The A2000 and A500 have an additional 512K of RAM at $C00000,
for a total of 9 megs of real memory.  

Now if you wanted to talk in theoretical maximums for the 68000 based machine,
there's another 1.5 meg of space allocated to CHIP RAM, for a total of 10.5
meg given an as-yet non-existant Agnus to address that 2 meg.  Then there's
an addition 1.25 meg in the $C00000 area, for a total of 11.75 meg that can
be addressed by a 68000 based machine.

But that's for a 68000 based machine.  Anything with an MMU probably has a
68020 attached.  That adds an additional 4 gigabytes - 16 megs of address
space.  I don't forsee anyone hooking up a gig or two of real memory in the
next year.

> So why bother? Just buy the 8MB and have real speed.
> What does 8MB cost, anyway? $1500 ?

Given the above linear address model, which is certainly the one that makes
sense under AmigaOS, you have a virtual memory handler.  If you don't want
to use it, don't.  If you do, you probably have something in your startup
sequence that does:

	AddVMem 20M SWAP:

Or something along those lines.  That adds 20M of virtual memory to the free
memory list, links a SWAP: device like a hard disk to your page fault
server, and you're all done.  If you have 8 megs of real memory on top of that,
and only use 6meg, you never get a fault, and you never page.  If you use
15 megs, though, instead of dying in flames, you get to run, only slower.

> 	Dennis O'Connor 	oconnor@sungoddess.steinmetz.UUCP ??
-- 
Dave Haynie     Commodore-Amiga    Usenet: {ihnp4|uunet|rutgers}!cbmvax!daveh
   "The B2000 Guy"              PLINK : D-DAVE H             BIX   : hazy
		"I can't relax, 'cause I'm a Boinger!"

richard@gryphon.CTS.COM (Richard Sexton) (11/26/87)

Guy in brace writes:

>I like it!  I like it!  I wish I had thought of it!


Don't worry. In a few months, in another newsgroup, you'll say you did.

>Kevin McBride


-- 
Richard J. Sexton
INTERNET:     richard@gryphon.CTS.COM
UUCP:         {hplabs!hp-sdd, sdcsvax, ihnp4, nosc}!crash!gryphon!richard

"It's too dark to put the keys in my ignition..."

peter@sugar.UUCP (11/30/87)

Doug Merritt ({ucbvax,sun}!unisoft!certes!doug) writes:
> >dillon@CORY.BERKELEY.EDU (Matt Dillon) writes:
> >>    As far as the Amiga goes, the only compatible solution is a Linear
> >>virtual address space over the entire system.
> 
> A nice idea, but unfortunately not perfectly compatible. As discussed
> here some time ago, there's still the problem of, e.g. cooperating tasks
> which have pointers into each others memory space. Message passing is
> based on shared memory on the Amiga...

Well, ignoring the paging/mapping/protection confusion...

> But wait...maybe there's a bandaid? Perhaps you could rig up a way of
> telling the system about tasks that need to share address space. Got
> any ideas about this? Any such method would be inconvenient, but might
> at least work.

WHat do you suppose the MEMF_PUBLIC bit is for? Well, I guess it must be
to tell the system that this memory should be publicly available. But all
memory is publicly available anyway, right? Ah! It's a hook for a future
memory-protected version of the operating system!

I hope all you nice people have been scrupulous about where you should and
should not be using MEMF_PUBLIC. (time to add another flag to the Aztec
linker, I guess).

Another thing to note... private memory (non MEMF_PUBLIC) should also be
mappable.
-- 
-- Peter da Silva  `-_-'  ...!hoptoad!academ!uhnix1!sugar!peter
-- Disclaimer: These U aren't mere opinions... these are *values*.

perry@well.UUCP (Perry S. Kivolowitz) (12/02/87)

In article <7958@steinmetz.steinmetz.UUCP> oconnor@sunray.UUCP (Dennis Oconnor) writes:
>Well, on the one hand, this means you are still limited to 8.5MB of
>memory. Doesn't it? So why bother? Just buy the 8MB and have real speed.
>What does 8MB cost, anyway? $1500 ?
>

If you got an average buy at todays prices 64 1 megabut drams would
cost you $1728 by themselves. Then add the board they go on. Labor. Rent.
Packaging. Shipping. Electricity. Insurance. Water and Sewer etc.

Cheers,

Perry

rusty@vertigo.UUCP (12/04/87)

In article <4602@well.UUCP> perry@well.UUCP (Perry S. Kivolowitz) writes:
>In article <7958@steinmetz.steinmetz.UUCP> oconnor@sunray.UUCP (Dennis Oconnor) writes:
>>Well, on the one hand, this means you are still limited to 8.5MB of
>>memory. Doesn't it? So why bother? Just buy the 8MB and have real speed.
>>What does 8MB cost, anyway? $1500 ?
>
>If you got an average buy at todays prices 64 1 megabut drams would
>cost you $1728 by themselves. Then add the board they go on. Labor. Rent.

Perry and anyone interested,

	While not the "average buy" the lowest price I've seen on 1-MBit
DRAM chips is from "JDR Microdevices" is Los Gatos, CA (funny, that name
rings a bell from somewhere :-).  If they hold true to the ad they have
in the December issue of Computer Shopper (pg 525) then 120-ns 1-Meg DRAM
chips can be had for $19.95 a piece in single quantities - no idea about
"quantity" discounts.  Given this, 64 chips for an 8-Megbyte board would
cost $1276.88 (sans tax and any quantity disc.).  Since I already have
2-Meg on my 8-Meg board I can fill it for $957.60.

=====WARNING WILL ROBINSON=====
I've never dealt with "JDR Microdevices" before so Heaven knows if
they're a reasonable supplier.  They do have a toll free (1-800-)
telephone number plus FAX and Telex numbers are given in the ad as
well.  I've also seen their ads in various mags for at least several
(>5) years so... maybe this tells ya something, maybe it doesn't.
=====DR SMITH, DON'T PULL THE ROBOT'S POWER PACK OUT!=====


Then again, it could be that these chips have a funky, not-the-standard-
pin-out-we-need-type of chip.  Is this a possibility with today's
1-Meg DRAMs (given 1048576x1 configuration) ???

				-Rusty-
-- 
Rusty Haddock {{uunet!likewise!}cbosgd,rutgers!moss}!vertigo!rusty
AT&T-IS Consumer Products Laboratories - Human Factors Laboratory
Holmdel, New Joysey  07733		(201) 834-1023
     -- Being schizophrenic is better than living alone. --

john@bby-bc.UUCP (john) (12/06/87)

.
.
.
> =====WARNING WILL ROBINSON=====
> I've never dealt with "JDR Microdevices" before so Heaven knows if
> they're a reasonable supplier.  They do have a toll free (1-800-)

I have dealt with them with somewhat mixed results.  I ordered a memory
board for a machine whose name won't be mentioned in this group.  I
specifically asked the sales person (over the phone) if it would work
in a 10mhz machine - she went away and came back and said the tech people
had said yes.  When I got the board it worked fine a 6mhz but not 10mhz.
I was annoyed but when I called up the guy I talked to said right away
they had never tested it in a machine that fast - he offerred a refund
without further discussion and I got the refund pretty much (as far as I
can tell) as soon as they received the board by return mail.  I was glad
and somewhat surprised that they took my word about the original
conversation.  I think they had a very good attitude towards keeping
a customer happy.

perry@well.UUCP (Perry S. Kivolowitz) (12/09/87)

Rusty,

Sure JDR's advertised price is 19.95. But that is not their deliverable
price. Which is currently $29.

We call them every week.

paulz@hpspdla.HP.COM (Paul Zander) (12/16/87)

I've dealt with JDR several times.  Fortunately, they are a short drive
They have been in business for a number of years.  At one time, they were
big in S-100 machines.  They try to be helpful, but it is too much to
expect their sales people to be experts in every subject.  That is where
their reasonable return policy keeps everyone satisfied.