09.12.2012 Views

Cortex-A8 Technical Reference Manual - ARM Information Center

Cortex-A8 Technical Reference Manual - ARM Information Center

Cortex-A8 Technical Reference Manual - ARM Information Center

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

2.3 ThumbEE instruction set<br />

2.3.1 Instructions<br />

2.3.2 Configuration<br />

Programmers Model<br />

ThumbEE is a variant of the Thumb-2 instruction set. It is designed as a target for dynamically<br />

generated code. This is code compiled on the device either shortly before or during execution<br />

from a portable bytecode or other intermediate or native representation. It is particularly suited<br />

to languages that employ managed pointers or array types. ThumbEE provides increased code<br />

density for the compiled binary compared with the compiled code for the <strong>ARM</strong> or Thumb-2<br />

instruction set. ThumbEE introduces a new processor state, the ThumbEE state, indicated by<br />

both the T bit and the J bit in the CPSR Register being set to 1.<br />

See the <strong>ARM</strong> Architecture <strong>Reference</strong> <strong>Manual</strong> for information on the <strong>ARM</strong>, Thumb, and<br />

ThumbEE instruction sets.<br />

In ThumbEE state, the processor uses almost the same instruction set as Thumb-2 although<br />

some instructions behave differently, and a few are removed, or added.<br />

The key differences are:<br />

• additional state changing instructions in both Thumb state and ThumbEE state<br />

• new instructions to branch to handlers<br />

• null pointer checking on loads and stores<br />

• an additional instruction in ThumbEE state to check array bounds<br />

• some other modifications to the load, store, and branch instructions.<br />

ThumbEE instructions are accessible when the processor is in ThumbEE state.<br />

Two registers provide ThumbEE configuration:<br />

• ThumbEE Configuration Register. This contains a single bit, the ThumbEE configuration<br />

control bit, XED.<br />

• ThumbEE HandlerBase Register. This contains the base address for ThumbEE handlers.<br />

A handler is a short, commonly executed, sequence of instructions. It is typically, but not<br />

always, associated directly with one or more bytecodes or other intermediate language<br />

elements.<br />

ThumbEE Configuration Register<br />

The purpose of the ThumbEE Configuration Register is to control access to the ThumbEE<br />

HandlerBase Register.<br />

The ThumbEE Configuration Register is:<br />

• in CP14 register c0<br />

• a 32-bit register, with access rights that depend on the current privilege:<br />

— the result of an unprivileged write to the register is Undefined<br />

— unprivileged reads, and privileged reads and writes, are permitted.<br />

Figure 2-2 on page 2-5 shows the bit arrangement of the ThumbEE Configuration Register.<br />

<strong>ARM</strong> DDI 0344K Copyright © 2006-2010 <strong>ARM</strong> Limited. All rights reserved. 2-4<br />

ID060510 Non-Confidential

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!