llvm-6502/test/CodeGen
Chandler Carruth 7782102c70 Use standard promotion for i8 CTTZ nodes and i8 CTLZ nodes when the
LZCNT instructions are available. Force promotion to i32 to get
a smaller encoding since the fix-ups necessary are just as complex for
either promoted type

We can't do standard promotion for CTLZ when lowering through BSR
because it results in poor code surrounding the 'xor' at the end of this
instruction. Essentially, if we promote the entire CTLZ node to i32, we
end up doing the xor on a 32-bit CTLZ implementation, and then
subtracting appropriately to get back to an i8 value. Instead, our
custom logic just uses the knowledge of the incoming size to compute
a perfect xor. I'd love to know of a way to fix this, but so far I'm
drawing a blank. I suspect the legalizer could be more clever and/or it
could collude with the DAG combiner, but how... ;]

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@147251 91177308-0d34-0410-b5e6-96231b3b80d8
2011-12-24 12:12:34 +00:00
..
ARM Fix a couple of copy-n-paste bugs. Noticed by George Russell! 2011-12-21 18:56:22 +00:00
CBackend
CellSPU
CPP
Generic Manually upgrade the test suite to specify the flag to cttz and ctlz. 2011-12-12 11:59:10 +00:00
Hexagon Hexagon: Fix a nasty order-of-initialization bug. 2011-12-16 19:08:59 +00:00
MBlaze
Mips Test case for r147232. 2011-12-24 03:05:43 +00:00
MSP430
PowerPC Add a test case to make sure that the nop really does follow the bl on ppc64 elf 2011-12-15 17:59:23 +00:00
PTX PTX: Continue to fix up the register mess. 2011-12-06 17:39:48 +00:00
SPARC Sparc CodeGen: Fix AnalyzeBranch for PR 10282. Removing addSuccessor() since 2011-12-03 21:24:48 +00:00
Thumb
Thumb2 Experimental support for aligned NEON spills. 2011-12-23 00:36:18 +00:00
X86 Use standard promotion for i8 CTTZ nodes and i8 CTLZ nodes when the 2011-12-24 12:12:34 +00:00
XCore