[PowerPC] Replace cntlz[.] with cntlzw[.]
authorHal Finkel <hfinkel@anl.gov>
Wed, 28 Oct 2015 03:26:45 +0000 (03:26 +0000)
committerHal Finkel <hfinkel@anl.gov>
Wed, 28 Oct 2015 03:26:45 +0000 (03:26 +0000)
commite60bc4e8b82e5ab94eb70bb21d94c431be9f257d
treefce496edef3a9ba30441a1ca0b29c2041869391c
parent3386f43f2a50c67f9d22351b4e1ab6fa0980e99b
[PowerPC] Replace cntlz[.] with cntlzw[.]

cntlz is the old POWER mnemonic. cntlzw is the PowerPC mnemonic.

This change fixes an issue when -no-integrated-as: The opcode cntlz is
unrecognized by gas

Alias the POWER mnemonic cntlz[.] to the PowerPC mnemonic cntlzw[.]
This is done for because the POWER cntlz mnemonic has be used by LLVM for
a very long time. We need to make sure that assembly programs
that are using the cntlz[.] do not break with this change.

Change PowerPC tests to reflect the insn change from cntlz to cntlzw.
Add assembly test to verify cntlz[.] is encoded correctly.

Patch by Tom Rix!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@251489 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Target/PowerPC/PPCInstrInfo.td
test/CodeGen/PowerPC/cttz.ll
test/CodeGen/PowerPC/long-compare.ll
test/CodeGen/PowerPC/seteq-0.ll
test/MC/Disassembler/PowerPC/ppc64-encoding.txt
test/MC/Disassembler/PowerPC/ppc64le-encoding.txt
test/MC/PowerPC/ppc64-encoding.s