Memory mapped IO
memory mapped IO: device registers get acessed by ordinary memory acess instructions.Another way of device acess is having extra instructions (e.g. IN OUT of 8080, 8086) that drive an extra processor pin to signal device acess.
Advantages of "IN/OUT": less decoding gear needed due to the extra IN/OUT pin (it can be determined by looking at one pin whether the addressbus bitpattern is directed at memory or device). No RAM addressspace is wasted (relevant on cpus with only 64 kilobyte or less address space).
Disadvantages of "IN/OUT": special instructions that do not work with all registers/addressing modi (it would be opcode space waste to provide IN/OUT with all addressing modi, not to mention all operations AND OR CLR...). Also the special instructions do not get generated by compilers, making it impossible e.g. in C to just say *device=value; .