AArch64: correct CodeGen of MOVZ/MOVK combinations.
authorTim Northover <tnorthover@apple.com>
Mon, 1 Jul 2013 19:23:10 +0000 (19:23 +0000)
committerTim Northover <tnorthover@apple.com>
Mon, 1 Jul 2013 19:23:10 +0000 (19:23 +0000)
commit6711fc28a41c05e1c8398393c7794c41b2ee0202
treee1c42a6bd26aae3b40cf42926f328181c80278a9
parent1a84066b8c6e57d43309edc8cad2ca32acfbf836
AArch64: correct CodeGen of MOVZ/MOVK combinations.

According to the AArch64 ELF specification (4.6.8), it's the
assembler's responsibility to make sure the shift amount is correct in
relocated MOVZ/MOVK instructions.

This wasn't being obeyed by either the MCJIT CodeGen or RuntimeDyldELF
(which happened to work out well for JIT tests). This commit should
make us compliant in this area.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@185360 91177308-0d34-0410-b5e6-96231b3b80d8
lib/ExecutionEngine/RuntimeDyld/RuntimeDyldELF.cpp
lib/Target/AArch64/AArch64ISelDAGToDAG.cpp
lib/Target/AArch64/AArch64InstrInfo.td
test/CodeGen/AArch64/movw-shift-encoding.ll [new file with mode: 0644]