aboutsummaryrefslogtreecommitdiffstats
path: root/lib/Target/X86/README.txt
Commit message (Collapse)AuthorAgeFilesLines
* Add a natural stack alignment field to TargetData, and prevent InstCombine fromLang Hames2011-10-101-1/+1
| | | | | | | | | | | | | | | | promoting allocas to preferred alignments that exceed the natural alignment. This avoids some potentially expensive dynamic stack realignments. The natural stack alignment is set in target data strings via the "S<size>" option. Size is in bits and must be a multiple of 8. The natural stack alignment defaults to "unspecified" (represented by a zero value), and the "unspecified" value does not prevent any alignment promotions. Target maintainers that care about avoiding promotions should explicitly add the "S<size>" option to their target data strings. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141599 91177308-0d34-0410-b5e6-96231b3b80d8
* X86: Add patterns for the movbe instruction (mov + bswap, only available on ↵Benjamin Kramer2011-10-101-5/+0
| | | | | | atom) git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@141563 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a neat little two's complement hack for x86.Benjamin Kramer2011-07-261-25/+8
| | | | | | | | | | On x86 we can't encode an immediate LHS of a sub directly. If the RHS comes from a XOR with a constant we can fold the negation into the xor and add one to the immediate of the sub. Then we can turn the sub into an add, which can be commuted and encoded efficiently. This code is generated for __builtin_clz and friends. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136167 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a note about efficient codegen for binary log.Benjamin Kramer2011-07-251-0/+48
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@135996 91177308-0d34-0410-b5e6-96231b3b80d8
* add a noteChris Lattner2011-05-171-0/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@131455 91177308-0d34-0410-b5e6-96231b3b80d8
* This is done.Benjamin Kramer2011-04-291-20/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130499 91177308-0d34-0410-b5e6-96231b3b80d8
* move PR9803 to this readme.Chris Lattner2011-04-281-0/+28
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130385 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove working entry from README.Eli Friedman2011-04-171-8/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129654 91177308-0d34-0410-b5e6-96231b3b80d8
* Fix a ton of comment typos found by codespell. Patch byChris Lattner2011-04-151-1/+1
| | | | | | | | Luis Felipe Strano Moraes! git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129558 91177308-0d34-0410-b5e6-96231b3b80d8
* move PR9661 out to here.Chris Lattner2011-04-141-0/+24
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129527 91177308-0d34-0410-b5e6-96231b3b80d8
* Add another case we are not optimizing.Rafael Espindola2011-04-061-0/+30
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129012 91177308-0d34-0410-b5e6-96231b3b80d8
* The original issue has been fixed by not doing unnecessary sign extensions.Rafael Espindola2011-04-061-14/+17
| | | | | | Change the test to force a sign extension and expose the problem again. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@129011 91177308-0d34-0410-b5e6-96231b3b80d8
* A couple new README entries.Eli Friedman2011-03-171-0/+36
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@127786 91177308-0d34-0410-b5e6-96231b3b80d8
* a serious "compare CSE" issue that is nontrivial to get right,Chris Lattner2011-02-211-0/+69
| | | | | | | | but which is responsible for us doing really bad things to 256.bzip2. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126126 91177308-0d34-0410-b5e6-96231b3b80d8
* A lo/hi mul has higher latency than an imul r,ri, e.g. 5 cycles compared to 3Cameron Zwarich2011-02-211-35/+0
| | | | | | on Core 2 and Nehalem, so the code we generate is better than GCC's here. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126100 91177308-0d34-0410-b5e6-96231b3b80d8
* The signed version of our "magic number" computation for the integer ↵Cameron Zwarich2011-02-211-6/+4
| | | | | | | | | | | | | approximation of a constant had a minor typo introduced when copying it from the book, which caused it to favor negative approximations over positive approximations in many cases. Positive approximations require fewer operations beyond the multiplication. In the case of division by 3, we still generate code that is a single instruction larger than GCC's code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126097 91177308-0d34-0410-b5e6-96231b3b80d8
* Minor x86 README updates.Eli Friedman2011-02-191-20/+14
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@126054 91177308-0d34-0410-b5e6-96231b3b80d8
* add a poor division by constant case.Chris Lattner2011-02-181-0/+37
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@125832 91177308-0d34-0410-b5e6-96231b3b80d8
* update a bunch of entries.Chris Lattner2011-01-021-0/+37
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122700 91177308-0d34-0410-b5e6-96231b3b80d8
* fix some sort of weird pastoChris Lattner2010-12-261-60/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122560 91177308-0d34-0410-b5e6-96231b3b80d8
* add a noteChris Lattner2010-12-261-0/+91
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122559 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove some obsolete README items, add a new one off the top of my head.Benjamin Kramer2010-12-231-78/+26
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122495 91177308-0d34-0410-b5e6-96231b3b80d8
* X86: Lower a select directly to a setcc_carry if possible.Benjamin Kramer2010-12-221-52/+0
| | | | | | | | | | | | | | | | | | | int test(unsigned long a, unsigned long b) { return -(a < b); } compiles to _test: ## @test cmpq %rsi, %rdi ## encoding: [0x48,0x39,0xf7] sbbl %eax, %eax ## encoding: [0x19,0xc0] ret ## encoding: [0xc3] instead of _test: ## @test xorl %ecx, %ecx ## encoding: [0x31,0xc9] cmpq %rsi, %rdi ## encoding: [0x48,0x39,0xf7] movl $-1, %eax ## encoding: [0xb8,0xff,0xff,0xff,0xff] cmovael %ecx, %eax ## encoding: [0x0f,0x43,0xc1] ret ## encoding: [0xc3] git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@122451 91177308-0d34-0410-b5e6-96231b3b80d8
* Factor the (x & 2^n) ? 2^m : 0 instcombine into its own method and generalize itBenjamin Kramer2010-12-111-40/+0
| | | | | | | to catch cases where n != m with a shift. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@121608 91177308-0d34-0410-b5e6-96231b3b80d8
* Enable sibling call optimization of libcalls which are expanded duringEvan Cheng2010-11-301-18/+0
| | | | | | | | | | | | legalization time. Since at legalization time there is no mapping from SDNode back to the corresponding LLVM instruction and the return SDNode is target specific, this requires a target hook to check for eligibility. Only x86 and ARM support this form of sibcall optimization right now. rdar://8707777 git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@120501 91177308-0d34-0410-b5e6-96231b3b80d8
* apparently tailcalls are better on darwin/x86-64 than on linux?Chris Lattner2010-11-211-0/+18
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@119947 91177308-0d34-0410-b5e6-96231b3b80d8
* Don't narrow the load and store in a load+twiddle+store sequence unlessDan Gohman2010-09-021-0/+45
| | | | | | | | | | | there are clearly no stores between the load and the store. This fixes this miscompile reported as PR7833. This breaks the test/CodeGen/X86/narrow_op-2.ll optimization, which is safe, but awkward to prove safe. Move it to X86's README.txt. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112861 91177308-0d34-0410-b5e6-96231b3b80d8
* A couple of small missed optimizations.Eli Friedman2010-08-291-0/+52
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@112411 91177308-0d34-0410-b5e6-96231b3b80d8
* Custom lower the memory barrier instructions and add supportEric Christopher2010-07-221-7/+0
| | | | | | | | | for lowering without sse2. Add a couple of new testcases. Fixes a few libgomp tests and latent bugs. Remove a few todos. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@109078 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove a fixed item, update a couple partially-fixed items.Eli Friedman2010-06-031-81/+22
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@105375 91177308-0d34-0410-b5e6-96231b3b80d8
* This is now done.Dan Gohman2010-03-011-5/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@97450 91177308-0d34-0410-b5e6-96231b3b80d8
* A few missed optimizations; the last one could have a significant impact onEli Friedman2010-02-101-0/+66
| | | | | | | | code with lots of bitfields. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@95809 91177308-0d34-0410-b5e6-96231b3b80d8
* this is an SSE-specific issue.Chris Lattner2010-01-131-20/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93373 91177308-0d34-0410-b5e6-96231b3b80d8
* X86 if conversion + tail merging issues from PR6032.Chris Lattner2010-01-131-0/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@93372 91177308-0d34-0410-b5e6-96231b3b80d8
* Remove some README.txt entries which are now implemented.Dan Gohman2010-01-041-80/+3
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@92511 91177308-0d34-0410-b5e6-96231b3b80d8
* A couple minor README updates.Eli Friedman2009-12-211-14/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@91823 91177308-0d34-0410-b5e6-96231b3b80d8
* Move and clarify note.Bill Wendling2009-10-271-31/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85334 91177308-0d34-0410-b5e6-96231b3b80d8
* Note corrected.Bill Wendling2009-10-271-3/+5
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85332 91177308-0d34-0410-b5e6-96231b3b80d8
* Modify note.Bill Wendling2009-10-271-0/+8
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85331 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a note.Bill Wendling2009-10-271-0/+23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@85329 91177308-0d34-0410-b5e6-96231b3b80d8
* Add a note.Evan Cheng2009-07-301-0/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@77584 91177308-0d34-0410-b5e6-96231b3b80d8
* remove a bogus note.Chris Lattner2009-06-301-20/+0
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74509 91177308-0d34-0410-b5e6-96231b3b80d8
* add a noteChris Lattner2009-06-301-0/+20
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@74508 91177308-0d34-0410-b5e6-96231b3b80d8
* another xform that is target-independent (should be done in instcombine).Chris Lattner2009-06-161-3/+23
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73472 91177308-0d34-0410-b5e6-96231b3b80d8
* I think instcombine should unconditionally do this xform.Chris Lattner2009-06-161-2/+17
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73471 91177308-0d34-0410-b5e6-96231b3b80d8
* Misc x86 README updates: remove a couple of already-fixed issues, Eli Friedman2009-06-111-57/+57
| | | | | | | | add a few suggestions from looking at some assembly code. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@73210 91177308-0d34-0410-b5e6-96231b3b80d8
* add some late optimizations that GCC does. It thinks these are a winChris Lattner2009-05-251-0/+14
| | | | | | | even on Core2, not just AMD processors which was a surprise to me. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72396 91177308-0d34-0410-b5e6-96231b3b80d8
* we should eventually add -march=atom and the new atom movbe instruction.Chris Lattner2009-05-251-0/+2
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@72387 91177308-0d34-0410-b5e6-96231b3b80d8
* Move 3 "(add (select cc, 0, c), x) -> (select cc, x, (add, x, c))"Chris Lattner2009-03-121-22/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | related transformations out of target-specific dag combine into the ARM backend. These were added by Evan in r37685 with no testcases and only seems to help ARM (e.g. test/CodeGen/ARM/select_xform.ll). Add some simple X86-specific (for now) DAG combines that turn things like cond ? 8 : 0 -> (zext(cond) << 3). This happens frequently with the recently added cp constant select optimization, but is a very general xform. For example, we now compile the second example in const-select.ll to: _test: movsd LCPI2_0, %xmm0 ucomisd 8(%esp), %xmm0 seta %al movzbl %al, %eax movl 4(%esp), %ecx movsbl (%ecx,%eax,4), %eax ret instead of: _test: movl 4(%esp), %eax leal 4(%eax), %ecx movsd LCPI2_0, %xmm0 ucomisd 8(%esp), %xmm0 cmovbe %eax, %ecx movsbl (%ecx), %eax ret This passes multisource and dejagnu. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66779 91177308-0d34-0410-b5e6-96231b3b80d8
* Add more information to the EFLAGS note.Dan Gohman2009-03-101-4/+12
| | | | git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66515 91177308-0d34-0410-b5e6-96231b3b80d8