----- Original Message ----- From: Harold M Hallikainen To: Sent: Monday, August 19, 2002 6:37 PM Subject: Re: [EE]: More advanced system design.. > I really don't see any advantage to a separate I/O map over use of > memory mapped I/O. The Io/M pin on processor with a separate I/O could be > replaced with one more address line, doubling the size of the memory map. > The use of a separate I/O map requires the processor to have special I/O > instructions. These instructions are always limited when compared with > instructions that operate on memory. So, by using memory mapped I/O, we > get a simpler processor and more powerful instrucions for use on I/O. > It is true that more bits need to be decoded when using memory mapped > I/O. In simple systems, you might just take the most significant address > line and say that in one state it's talking to memory, in the other it's > talking to I/O. I've typically used a bipolar PROM or a PLD to decode the > address lines into chip selects. One device could generate chip selects > to the memory devices and an I/O chip select. A second device could > further decode the I/O area down to each device. > I first learned of memory mapped I/O when moving from the DEC PDP-8 to > the PDP-11. I thought memory mapped I/O was a very clever idea then. > Still do! > > Harold > Well that's one way to look at it. Another is that you can use the I/O line to tell the rest of the hardware that you are about to use the address bus in some special way. It can also help with slow periperal chip timings. Actually there is a very good reason to have special instructions for I/O which are distinct from normal memory accesses. They let the CPU know when the access is to a periperal chip. With a little extra hardware (in the CPU) you can distinquish between user and supervisor modes and trap a runaway user program that has crashed and is trying to execute data which happens to be a write to a periperal chip. And all without a complex MMU and sophisticated runtime executive. Regards Sergio Masci http://www.xcprod.com -- http://www.piclist.com hint: To leave the PICList mailto:piclist-unsubscribe-request@mitvma.mit.edu