ARM: fix literal load with positive offset encoding
authorAmaury de la Vieuville <amaury.dlv@gmail.com>
Tue, 18 Jun 2013 08:13:05 +0000 (08:13 +0000)
committerAmaury de la Vieuville <amaury.dlv@gmail.com>
Tue, 18 Jun 2013 08:13:05 +0000 (08:13 +0000)
commitbeb920fce6ccc89b4735f280f94cb8c227f4ef5e
treeb05f8b29168dcdff8045ea3d5b0f859beab8b8a0
parentf8b60d6f30a8f25c84a71d36ff3a86fe1f52f671
ARM: fix literal load with positive offset encoding

When using a positive offset, literal loads where encoded
as if it was negative, because:
- The sign bit was not assigned to an operand
- The addrmode_imm12 operand was not encoding the sign bit correctly

This patch also makes the assembler look at the .w/.n specifier for
loads.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@184182 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/ARM/ARMInstrThumb2.td
lib/Target/ARM/AsmParser/ARMAsmParser.cpp
lib/Target/ARM/MCTargetDesc/ARMMCCodeEmitter.cpp
test/MC/ARM/basic-thumb2-instructions.s