内存映射I / O端口VS映射I / O [英] Memory mapped I/O vs Port mapped I/O

查看:158
本文介绍了内存映射I / O端口VS映射I / O的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

内存映射I / O是一种技术,它允许使用中央存储器(RAM)的与外围设备进行通信。端口映射I / O使用端口(特殊安装说明),通过数字端口进行通信。

Memory mapped I/O is a technique which allows the use of central memory (RAM) to communicate with peripherals. Port mapped I/O uses ports (with special assembly instructions) to communicate over digital ports.

什么是一种方法的优势相对于其他?

What are the advantages of one method with respect to another?

推荐答案

至于邪神说,


  • 内存映射I / O允许读/写到I / O设备的端口一样的读/写正常的内存(使用同一台机器code / C ++)

但有一个缺点:


  • 您使用了物理内存地址空间,为您的内存映射I / O设备(32思考位Windows中不能够访问所有4G的内存在PC上)

因此​​,使用该端口的一个优点映射I / O的方法是,你有一个独立的地址空间,为您的I / O设备,您可以使用整个的内存寻址范围访问内存。

So an advantage of using the port mapped I/O method is that you have a separate address space for your I/O devices and you can use the whole memory addressing range to access memory.

编辑:下面是一个更完整的回答你的问题:<一href=\"http://stackoverflow.com/questions/4333849/what-real-platforms-map-hardware-ports-to-memory-addresses?rq=1\">hardware端口内存地址

Here is a more complete answer to your question: hardware ports to memory addresses

这篇关于内存映射I / O端口VS映射I / O的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆