[PATCH] [AArch64] Add add/sub/cmp/cmn aliases to MC AsmParser

Arnaud A. de Grandmaison arnaud.degrandmaison at arm.com
Fri Jul 11 05:28:02 PDT 2014


Well, the title says it all.

 

This patch teaches the AsmParser to accept some add/sub/cmp/cmn with

negative immediate operand and convert them as shown:

 

  add  Rd, Rn, -imm -> sub  Rd, Rn, imm

  sub  Rd, Rn, -imm -> add  Rd, Rn, imm

  adds Rd, Rn, -imm -> subs Rd, Rn, imm

  subs Rd, Rn, -imm -> adds Rd, Rn, imm

  cmp  Rn, -imm     -> cmn  Rn, imm

  cmn  Rn, -imm     -> cmp  Rn, imm

 

Those instructions are an alternate syntax available to assembly coders,

and are needed in order to support code already compiling with some other

assemblers.

 

OK to commit ?

 

Cheers,

--

Arnaud A. de Grandmaison
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140711/a69ea7e9/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-AArch64-Add-add-sub-cmp-cmn-aliases-to-MC-AsmParser.patch
Type: application/octet-stream
Size: 13345 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20140711/a69ea7e9/attachment.obj>


More information about the llvm-commits mailing list