Commit Graph

53201 Commits

Author SHA1 Message Date
Anton Korobeynikov
2bcf60a9cc Fix invalid for vector types fneg(bitconvert(x)) => bitconvert(x ^ sign)
transform.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84683 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 21:37:45 +00:00
Lang Hames
3fd7a68ba9 Oops. Backing out 84681 - needs to wait for the indexing patch.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84682 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 21:28:22 +00:00
Lang Hames
67f25669db Added some debugging output to pre-alloc splitting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84681 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 21:25:13 +00:00
Chris Lattner
d0d3cbb362 add a real testcase for PR4313
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84676 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 21:04:26 +00:00
Chris Lattner
82a39b3e14 add a test similar to that needed for PR4313, but that doesn't
fail without the patch.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84675 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 21:00:47 +00:00
Chris Lattner
b5b1e7738b the date on this testcase is wrong, it is unreduced, and it passes without the fix for PR4313.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84674 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:57:58 +00:00
Dan Gohman
eed9e5b833 Fix another place that calls Loop::contains a lot to construct a sorted
container of the blocks and do efficient lookups. This makes
isLoopSimplifyForm much faster on large loops, fixing a significant
compile-time issue in builds with assertions enabled.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84673 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:41:13 +00:00
Chris Lattner
f7d3570d8e merge and filecheckize
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84672 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:39:43 +00:00
Chris Lattner
7f2076023a merge two tests and convert to filecheck.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84671 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:33:46 +00:00
Jim Grosbach
3229b0bcf1 Disable by default while debugging
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84669 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:31:31 +00:00
Chris Lattner
88a8624f8e alternate fix for PR5258 which avoids worklist problems, with reduced testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84667 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:27:49 +00:00
Jim Grosbach
18ed9c9a2b add cmd line opt to disable frame index reuse for ARM and T2. debug aid.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84664 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:19:50 +00:00
Dan Gohman
cd53f64367 Restore LoopUnswitch's block-oriented threshold. LoopUnswitch now checks both
the estimated code size and the number of blocks when deciding whether to
do a non-trivial unswitch. This protects it from some very undesirable
worst-case behavior on large numbers of loop-unswitchable conditions, such
as in the testcase in PR5259.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84661 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 20:06:09 +00:00
David Goodwin
480c529e02 Checkpoint more aggressive anti-dependency breaking for post-ra scheduler.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84658 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 19:54:44 +00:00
Jim Grosbach
03d02d4faa Better handle instructions that re-def a scratch register
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84657 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 19:52:35 +00:00
Dan Gohman
bab42bdd87 Following r84485, add Defs = [EFLAGS] to the 32-bit lock instructions too.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84652 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 18:14:49 +00:00
Jeffrey Yasskin
1e86132122 Move the Function*->allocated blocks map from the JITMemoryManager to the
JITEmitter.

I'm gradually making Functions auto-remove themselves from the JIT when they're
destroyed. In this case, the Function needs to be removed from the JITEmitter,
but the map recording which Functions need to be removed lived behind the
JITMemoryManager interface, which made things difficult.

This patch replaces the deallocateMemForFunction(Function*) method with a pair
of methods deallocateFunctionBody(void *) and deallocateExceptionTable(void *)
corresponding to the two startFoo/endFoo pairs.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84651 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 18:13:21 +00:00
Jim Grosbach
f7a0c0de6d Register re-use for scavenged frame indices must check for re-deginition
of the register in the instruction which kills the scavenged value.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84641 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 16:33:57 +00:00
Dan Gohman
1a49295eae Make TranslateX86CC return COND_INVALID instead of aborting when it
encounters an OEQ or UNE comparison, and update its callers to check
for this return status and recover. This fixes a problem resulting from
the LowerOperation hooks being called from LegalizeVectorOps, because
LegalizeVectorOps only lowers vectors, so OEQ and UNE comparisons may
still be at large. This fixes PR5092.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84640 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 16:22:37 +00:00
Torok Edwin
f993327e71 Fix PR5258, jump-threading creating invalid PHIs.
When an incoming value for a PHI is updated, we must also updated all other
incoming values for the same BB to match, otherwise we create invalid PHIs.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84638 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 15:42:00 +00:00
Torok Edwin
2b6183d254 Fix PR4313: IPSCCP was not setting the lattice value for the invoke instruction
when the invoke had multiple return values: it set the lattice value only on the
extractvalue.
This caused the invoke's lattice value to remain the default (undefined), and
later propagated to extractvalue's operand, which incorrectly introduces
undefined behavior.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84637 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 15:15:09 +00:00
Benjamin Kramer
174101e13a Random #include pruning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84632 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 11:44:38 +00:00
Sanjiv Gupta
2edef7efdc This file is replaeced by PIC16Section.h.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84628 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 09:16:32 +00:00
Daniel Dunbar
80dd453b74 NNT: Implement "config mode", use -config path/to/llvm-config
- This runs the nightly test and does all the submission logic, but using the
   LLVM build specified by the llvm-config.

 - Useful for, among other things, testing NNT itself.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84620 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 07:30:54 +00:00
Daniel Dunbar
f27413866a NNT: Remove unused BUILDTYPE argument.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84619 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 07:30:46 +00:00
Chris Lattner
235e2f6a68 implement some more easy hooks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84614 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 06:22:33 +00:00
Chris Lattner
bf16faa16a Implement some hooks, make printOperand abort if unknown modifiers are
present.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84613 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 06:15:28 +00:00
Chris Lattner
c6b8a99207 t2MOVi32imm is currently always lowered by the Thumb2ITBlockPass.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84611 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 05:58:02 +00:00
Daniel Dunbar
b576beaaa8 PowerPC ifdef'ing considered more complicated than one might like.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84603 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 05:33:23 +00:00
Daniel Dunbar
2685a29a8d Wire up the ARM MCInst printer, for llvm-mc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84600 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 05:15:36 +00:00
Dan Gohman
07adb85cb7 Re-apply r84295, with fixes to how the loop "top" and "bottom" blocks are
tracked. Instead of trying to manually keep track of these locations
while doing complex modifications, just recompute them when they're needed.
This fixes a bug in which the TopMBB and BotMBB were not correctly updated,
leading to invalid transformations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84598 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 04:50:37 +00:00
Evan Cheng
5f4fb86d58 Trim unnecessary includes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84597 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 04:23:20 +00:00
Dan Gohman
81b16a3558 Add getTopBlock and getBottomBlock member functions to MachineLoopInfo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84596 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 04:16:37 +00:00
Nick Lewycky
13555eae17 Correct test for PowerPC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84595 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 04:09:50 +00:00
Daniel Dunbar
9a6d88d38b Revert "Tweak top-level Makefile to facilitate Apple-style build.", this is
breaking Clang's Apple-style build.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84592 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 02:23:13 +00:00
Daniel Dunbar
9fb0b7ef35 NNT: Remove duplicate verbose print.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84591 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 02:23:05 +00:00
Jim Grosbach
8fa4efeabf Now that all ARM subtargets use frame index scavenging, the Thumb1 requires*
functions are not needed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84587 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 01:32:47 +00:00
Evan Cheng
0222a8cfb8 If the physical register being spilled does not have an interval, spill its sub-registers instead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84586 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 01:31:09 +00:00
Jim Grosbach
7e831db1d4 Enable post-pass frame index register scavenging for ARM and Thumb2
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84585 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 01:26:58 +00:00
Chris Lattner
161dcbf799 lower ARM::MOVi32imm properly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84583 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 01:11:37 +00:00
Chris Lattner
292df8eb1f add support for external symbols. The mc instprinter can now handle
reasonable code like Codegen/ARM/2009-02-27-SpillerBug.ll, producing 
identical output except for superior formatting of constant pool entries.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84582 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:56:16 +00:00
Chris Lattner
96bc2173bb get fancy: support basic block operands. Yay for jumps.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84579 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:52:47 +00:00
Chris Lattner
233917c072 add supprort for the 'sbit' operand, MOVi apparently has one.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84577 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:46:11 +00:00
Chris Lattner
413ae25fb5 add support for instruction predicates.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84575 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:42:49 +00:00
Chris Lattner
017d9478d5 implement printSORegOperand, add lowering for the nasty and despicable MOVi2pieces :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84573 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:40:56 +00:00
Jim Grosbach
1fc1dc0682 Refs: A8-598.
Leave Inst{11-8}, which represents the starting byte index of the extracted
result in the concatenation of the operands and is left unspecified.

Patch by Johnny Chen.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84572 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:38:19 +00:00
Jim Grosbach
780d207d1c Add missing encoding bits to NLdSt class of instructions.
Patch by Johnny Chen.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84570 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-20 00:19:08 +00:00
Chris Lattner
af0df67d2b X86 should ignore implicit regs when lowering to MCInst also,
no functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84567 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-19 23:35:57 +00:00
Chris Lattner
306d14f9aa handle addmode4 modifiers, fix a fixme in printRegisterList
by ignoring all implicit regs when lowering.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84566 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-19 23:31:43 +00:00
Chris Lattner
84d8bf9d28 simplify by using the twine form of GetOrCreateSymbol
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@84565 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-19 23:05:23 +00:00