小尾数vs大尾数? [英] Little Endian vs Big Endian?

查看:132
本文介绍了小尾数vs大尾数?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在将两者缠绕在一起时遇到麻烦。我知道如何用大尾数表示。

I'm having troubles wrapping my head on the two. I understand how to represent something in big endian.

例如-12是1111 1111 1111 0100

For example -12 is 1111 1111 1111 0100

为什么小尾数表示为1111 0100 1111 1111而不是0100 1111 1111 1111?

But why is the little endian representation 1111 0100 1111 1111 instead of 0100 1111 1111 1111?

推荐答案

尾数大约是字节地址订购。小尾数表示低有效字节获得低地址。大尾数法则相反。因此,关于字节(8位块)而不是半字节(4位块)。我们使用的大多数计算机(有一些例外)都是在单个地址级别上的地址字节。

Endianness is about byte address order. Little endian means the lower significant bytes get the lower addresses. Big endian means the other way around. So it's about the bytes (8-bit chunks) not nibbles (4-bit chunks). Most computers we use (there are a few exceptions) address bytes at the individual address level.

使用 -12 示例:

内存中的小端将为:

000000: F4
000001: FF

内存中的大端字节为:

000000: FF
000001: F4

这篇关于小尾数vs大尾数?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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