tech-embed archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Quick and dirty embedded OS



-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi,

the issue with not having (1), i.e. page tables via MMU, is threefold. First, one obviously loses memory protection. With well-written and reviewed code, this should not be impossible to overcome (to sufficient degree, depending on your application).

Second, all application code you run must be (statically linked, which I'll ignore as impractical for most purposes, or) relocatable - because the different instances cannot obviously see the same start address when memory is not mappable. Regular unix binaries by default aren't relocatable, but .so's are. Theoretically a single address space solution could be devised with proper compilation flags, and potentially modifications to the program loader. You can simulate this by writing a process which loads executable code dynamically from shared object files - into a single shared address space.

The third, and a much more complex issue, is the in-kernel memory management, such as allocating (and managing) the buffer cache memory. All such code relying on page mapping capabilities will need to be reimplemented for an MMU-less environment.

Cheers,
Jussi

On Oct 19, 2004, at 20:50, Brian Rose wrote:

My understanding is that the MMU serves two functions.
(1) To provide the system processes with their own view of memory, such that each process feels that it has access to the entire address space.

(2) To provide an apparant memory greater than the installed physical RAM.

For embedded devices, (2) could be solved by not making a swap partition and essentially setting it to 0 (like a boot floppy image), correct? As for (1), is there any way to work around this? My guess is that emulating an MMU in software would eat up so much of the processor's time, that performance would be killed (if it is possible at all).

If (1) is discarded is it possible to still have multiple threads in the single process address space?
- --
Juha-Matti Liukkonen - Systems Architect, Cubical Solutions Ltd
tel: +358-40-5280142
e-mail: jml%cubical.fi@localhost

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (Darwin)

iD8DBQFBdXFCKDUn3bh7M9gRAnoJAJ43cdkcI4c1H6PA95lU9EufBEWEoQCgxnII
NgKuj6IOuZhDyEsvV5WO2rk=
=TIXU
-----END PGP SIGNATURE-----




Home | Main Index | Thread Index | Old Index