diff options
author | Chris Lattner <sabre@nondot.org> | 2006-01-30 06:14:02 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2006-01-30 06:14:02 +0000 |
commit | 9072c05cd8b1739244d8c669fb92c3415d01dccc (patch) | |
tree | bc8977ebc960696f8ceafb6da12f91f134c14fae /lib/CodeGen/MachineFunction.cpp | |
parent | d7e9f30a22059fb8ad4bacf2771c39ae9845afaf (diff) |
Compile:
uint %test(uint %X) {
%Y = call uint %llvm.ctpop.i32(uint %X)
ret uint %Y
}
to:
test:
save -96, %o6, %o6
sll %i0, 0, %l0
popc %l0, %i0
restore %g0, %g0, %g0
retl
nop
instead of to 40 logical ops. Note the shift-by-zero that clears the top
part of the 64-bit V9 register.
Testcase here: CodeGen/SparcV8/ctpop.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@25814 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/MachineFunction.cpp')
0 files changed, 0 insertions, 0 deletions