• Please review our updated Terms and Rules here

Educate me on multitasking under MPM - what do I need for "power user" usage?

MrImprovement

Experienced Member
Joined
Jan 7, 2023
Messages
134
So CPM is nice, I like the apps etc. I am building a Z80 SBC and I also have an eZTiny that connects over USB.

How do I run MPM? Do I need more than 64KB? The "specs" on MPM look interesting in terms of what was able to be supported (memory protection etc.) but what would I actually encounter in daily usage?
Note: I haven't installed MPM yet on anything.
 
The standard OEM installation of MP/M on 8" floppy was configured to run on an Intel MDS-800 with 64K of RAM. The second console was the current-loop serial port. Without multiple consoles, MP/M had no real advantage over CP/M 3.0.

As the x80 architecture doesn't have any memory protection hardware, there is no memory protection.
The usual configuration is banked memory in 16KB hunks.

The thing to know about MP/M is that it's multi-user. Interrupt-driven hardware is definitely a plus in this mode--another user can be doing useful work while the first is waiting on I/O. Executables can be written to use page-relocatable mode (.PRL files); otherwise, they're tied to a given address space. Users are assigned a specific disk user area by default.

For what it is, it works but is best used in a setup that involves a limited number of tested applications, such as a retail setup.
 
You could try CP/M 3 which offers most of the advantages of MPM for a single user system. Buffers and some of the BDOS could be placed in different banks providing a slightly larger TPA for loaded programs (60K vs 52K). However, this will need considerably more than 64K and a lot of the memory assigned to the other banks won't get used. Not exactly a problem now but expensive when CP/M 3 was new.
 
Note, MP/M has uses even with one console. You can run jobs in the background, and run things like a CP/NET server. Multi-user and multi-process. You can write programs that spawn multiple processes and perform various "interesting" tasks.
 
Yes, but 64K non-bankswitched is about the minimum practical configuration, though I think it will run in 48K; like 20K CP/M 2.2. Enough to build a system and run basic utilities, but not useful in most practical situations.
What I find more interesting is the multi-CPU/memory setups, like Molecular. One supervisor with each user having his own CPU/memory. With today's MCUs integrated with memory on a single-chip, it looks to be very attractive.
My own experience starts with MP/M 1.0; I still have the MP/M II OEM distro kit, complete with pricelist, but have done nothing with it.
 
Keep in mind that your computer will need a "real" time clock that can provide time based interrupts.

In anticipation of MP/M, the eZ-Tiny already initializes Timer 1 values for 60 Hz during initialization but doesn't actually enable the timer or interrupts. The eZ80's RTC is also enabled for access to TOD values. MP/M is on my to-do list but no guarantee of when I'll get started on it.
 
Bear in mind what I and others have said--MP/M relies on interrupt processing of I/O--"blocking"/poll-type I/O operations will not make best use of the tasking capabilities. This can make the XIOS considerably more complex that a simple CP/M CBIOS, depending on the I/O servicing needs.
 
This thread has me curious.

What kind of timeslice does MPM use? And how many threads can it run (within practical limits) - And how much of a timeslice does each application get?

Is there any way for programs under MPM to hand over control when waiting for events?

is there a technical summary of MPM for dummies I can read?

Thanks
David
 
Thinking of it, the Amstrad PCW (or Schneider Joyce) may be an excellent candidate for MPM as it has 256 to 512 kByte of memory available in 16 kByte chunks which also can be mapped in 16 kByte offsets:

&F0O Select bank for &0000
&F1O Select bank for &4000
&F2O Select bank for &8000
&F3O Select bank for &C000. Usually &87.
&F4O b7-b4: when set, force memory reads to access the same bank as writes for &C000, &0000, &8000, and &4000 respectively

Maybe someone has already tried this?
 
From the PDF above:

Multi-terminal support. MP/M II supports up to 16 terminals. Also, a single process can access multiple
terminals.

• Multi-programming at each terminal. Any system console can initiate multiple programs or processes. In addition, a process can generate sub-processes.

• Support for bank-switched memory. MP/M II's memory
segments can either reside in common memory or be
distributed through separate memory banks, thereby
extending the system's effective memory capacity.

• Inter-process communication, synchronization, and mutual
exclusion. These functions are provided by queues.

• Logical interrupt mechanism using flags. This allows MP/M
II to interface with any physical interrupt structure.

• System timing functions. These functions enable processes
running under MP/M II to compute elapsed times, delay
execution for specified intervals, and to access and set
the current date and time. In addition, the user can
schedule programs to be run by date and time. The system
timing is also used to provide round-robin scheduling of
compute-bound processes executing at the same priority.

So, it seems you might not have virtual consoles/multiple virtual terminals available to one user, but, you can start multiple processes.
 
Ideally you want a 56K/8K split to get the best TPA sizes for MP/M, although 16/48K works for most stuff. Hard disk is also nice but not really needed more than in CP/M providing you are single user.

MP/M doesn't really care if you console is so it's perfectly possible to implement something like 4 virtual consoles on a TMS991A for example. Like CP/M it thinks it has serial type ports with input output and empty/full state. Unlike CP/M 2.2 you can easily bank all the console emulation though.
 
Back
Top