Skip to content

Latest commit

 

History

History
10 lines (6 loc) · 1.42 KB

8.Instruction_Set.adoc

File metadata and controls

10 lines (6 loc) · 1.42 KB

CHAPTER 8. Instruction Set

The LoongArch architecture is divided into two versions: the 32-bit LA32 architecture and the 64-bit LA64 architecture. The LA64 architecture is application-level downward binary compatible with the LA32 architecture. This means that binaries of application software built for LA32 can run directly run on machines compatible with the LA64 architecture and produce the same running results. On the other hand, it refers to the fact that this downward binary compatibility is limited to application software. The architecture specification does not guarantee that binaries of system software (such as the operating system kernel) running on machines compatible with LA32 architecture always yields the same running result when running directly on machines compatible with LA64 architecture.

The hexadecimal representation of the integer ranges involved in this book must include a sign. For example, [-0x800, 0x7ff] indicates the the range [-2048, 2047], where the minus sign for -0x800 must exist. Otherwise, the assembler overflow error will occur. If you need to represent this range without a sign, 0x800 and 0x7ff should be sign-extended to GRLEN, resulting in [0xfffffff800, 0x0000007ff] for LA32 and [0xfffffffffff800, 0x00000000007ff] for LA64.