[llvm-commits] [PATCH] Fix for some unpredictable instructions on ARM

Silviu Baranga silbar01 at arm.com
Wed Mar 21 03:47:22 PDT 2012


Hi,

 

The ARM instructions:

    STRD, STRH, LDRD, LDRH, LDRSH, LDRSB, LDRSBT, LDRHT, LDRSHT, MUL

have some corner cases in which are unpredictable. In these cases the
disassembler should 

still disassemble the instructions instead of rejecting them.

The attached standalone patches fix this.

  

 - addrmode3.diff - STRD, STRH, LDRD, LDRH, LDRSH and LDRSB instructions.
The patch

                  modifies the C++ ARM disassembler code to add the checking
conditions, which are 

                  too complex to introduce with tablegen files. 

 - ldr.diff - LDRSBT, LDRHT and LDRSHT  instructions. The patch introduces a
decoder 

                 method because of the Rn == Rt unpredictability condition
that is common to

                 all the instructions above. 

- mul.diff -  MUL instruction. The patch changes the TableGen description of
the MUL

                 Instruction in order to reflect the fact that the
instruction is unpredictable when

                either of the Rd, Rn or Rm register operands are the pc
register.

 

All patches add regression tests for the modifications.

 

Please review.

 

Thanks,

Silviu
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120321/daa6010c/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: addrmode3.diff
Type: application/octet-stream
Size: 6203 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120321/daa6010c/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ldr.diff
Type: application/octet-stream
Size: 4149 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120321/daa6010c/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mul.diff
Type: application/octet-stream
Size: 2251 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20120321/daa6010c/attachment-0002.obj>


More information about the llvm-commits mailing list