[ARM] Handling for coprocessor instructions that are undefined starting from ARMv8

Richard Barton richard.barton at arm.com
Fri Nov 8 06:18:14 PST 2013


Hi Artyom

 

LGTM. This brings disassembly into line with the new assembly functionality
after r194253. 

 

Ta

Rich

 

From: llvm-commits-bounces at cs.uiuc.edu
[mailto:llvm-commits-bounces at cs.uiuc.edu] On Behalf Of Artyom Skrobov
Sent: 06 November 2013 13:04
To: llvm-commits at cs.uiuc.edu
Subject: [ARM] Handling for coprocessor instructions that are undefined
starting from ARMv8

 

Hello,

 

v8 ARMARM has restricted the list of coprocessors supported in AArch32 to
the four required for the legacy code.

(Section E1.4 Coprocessor support: The only supported coprocessors in ARMv8
are CP15, CP14, CP10 and CP11.)

 

The coprocessor instructions operating on any coprocessors not in this list
are to be undefined, starting from ARMv8.

(e.g. Section F7.1.204: If no coprocessor can execute the instruction, an
Undefined Instruction exception is generated.)

 

CP10 and CP11, used for the FP/NEON operations, are already excluded from
the list of valid operands for the generic coprocessor instructions.

We're proposing a patchset to further restrict the valid ranges for
coprocessor operands, starting from ARMv8, as specified in Section G3.15.2:

 

* STC and LDC are only defined for CP14

* MCRR, MRRC, MRC, MCR are defined for CP14 and CP15

* CDP, CDP2, MCR2, MRC2, MCRR2, MRRC2, LDC2, STC2 are no longer defined for
any coprocessor

 

Our patchset consists of three patches. The first one exports
getSubtargetInfo() from MCDisassembler public interface, to allow
architecture-aware disassembly, which had not been required until now. The
two other patches implement the necessary changes for ARM and Thumb
encodings, correspondingly. The last patch also deletes 4KLOC from
test/MC/ARM/v8_IT_manual.s - these tested a bunch of encodings which are in
fact invalid.

 

OK to commit this?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20131108/44f7b1fe/attachment.html>


More information about the llvm-commits mailing list