对 32 MB 字节可寻址存储器进行寻址需要多少个地址位?

发布于 2024-12-22 19:24:39 字数 95 浏览 3 评论 0原文

我在之前的一份试卷中发现了这个问题,我不确定我是否得到了正确的答案。据我所知,2^15 是 32768,即 32 MB,所以答案可能是 15 位。但我想我在这里遗漏了一些东西?

I found this question in one of my previous exam papers and I am not really sure if I got the right answer to it. As far as I see 2^15 is 32768 which is 32 MB so the answer could be 15 bits. But I think I'm missing something here?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

海的爱人是光 2024-12-29 19:24:40

32768 字节不是 32 Mb。

32 Mb = 32 * 1024Kb = 32 * 1024 * 1024 字节 = 2^5 * 2^10 * 2^10 = 2^25

也就是说,33.554.432 字节 = 32 Mb。

因此,您将需要至少 25 位来寻址该内存方案中的单个字节。

32768 bytes is not 32 Mb.

32 Mb = 32 * 1024Kb = 32 * 1024 * 1024 bytes = 2^5 * 2^10 * 2^10 = 2^25

That is, 33.554.432 bytes = 32 Mb.

So you will need, at least 25 bits to address a single byte in that memory scheme.

心头的小情儿 2024-12-29 19:24:40

由于 1MB = 10^6 字节,即 32 MB 需要 2^20 字节,我们有:

32 = 2^5 字节
1MB = 2^20 字节,因此,

32MB = 2^5 * 2^20 = 2^25 字节,

但问题是问“有多少地址位...”而不是字节,因此我们乘以 8 = 2^3 (因为1byte = 8bits),即
32 MB = 2^5 * 2^20 *2^3 = 2^28

因此,需要 28 位。

Since 1MB = 10^6 bytes i.e. 2^20 bytes for 32 MB we have:

32 = 2^5 bytes
1MB = 2^20 bytes so,

32MB = 2^5 * 2^20 = 2^25 bytes,

BUT the question asks "How many address bits..." not bytes, therefore we multiply by 8 = 2^3 (because 1byte = 8bits), that is
32 Mbytes = 2^5 * 2^20 *2^3 = 2^28

Thus, 28 bits are needed.

萌︼了一个春 2024-12-29 19:24:40

是的,10的一些次方。32768<>32MB

1M是2^20,32是2^5,所以你需要25位。

Yes, some powers of 10. 32768<>32MB

1M is 2^20, 32 is 2^5, so you need 25 bits.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文