; Make sure this testcase does not use ctpop
; RUN: llvm-as < %s | llc -march=ppc32 | grep -i 'cntlzw'

declare int %llvm.cttz(int)

implementation   ; Functions:

int %bar(int %x) {
entry:
	%tmp.1 = call int %llvm.cttz( int %x ) 
	ret int %tmp.1
}

Add testcase for legalizing ISD::CTTZ efficiently. On PPC, ctlz(int) is now codegen'd as this:
Add testcase for legalizing ISD::CTTZ efficiently.  On PPC, ctlz(int) is
now codegen'd as this:

        addi r2, r3, -1
        andc r2, r2, r3
        cntlzw r2, r2
        subfic r3, r2, 32
        blr


git-svn-id: 0ff597fd157e6f4fc38580e8d64ab130330d2411@21881 91177308-0d34-0410-b5e6-96231b3b80d8
