[PATCH] D35209: [ARM] Unify handling of M-Class system registers

Javed Absar via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Jul 10 10:04:29 PDT 2017


javed.absar created this revision.
Herald added subscribers: kristof.beyls, aemerson.

This patch cleans up and fixes issues in the M-Class system register handling:

1. It defines the system registers and the encoding (SYSm values) in one place: ARMRegisterInfo.td, removing the hand-coded  values which existed duplicated in multiple places - ARMISelDAGToDAG.cpp, ARMAsmParser.cpp and ARMInstPrinter.cpp.

2. Some system registers e.g. BASEPRI_MAX_NS which do not exist (reference - ARMv6/7/8M architecture reference manual) were being allowed.

I have tried to solve those issues by clearly defining in one places which registers exist and in which mode.


https://reviews.llvm.org/D35209

Files:
  lib/Target/ARM/ARMISelDAGToDAG.cpp
  lib/Target/ARM/ARMRegisterInfo.td
  lib/Target/ARM/AsmParser/ARMAsmParser.cpp
  lib/Target/ARM/InstPrinter/ARMInstPrinter.cpp
  test/CodeGen/ARM/special-reg-v8m-main.ll
  test/MC/ARM/thumbv8m.s

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D35209.105873.patch
Type: text/x-patch
Size: 26130 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20170710/e0b0d3ca/attachment.bin>


More information about the llvm-commits mailing list