Owen Anderson
b7970b2c6a
Try again at providing Thumb2 encodings for basic multiplication operators.
...
llvm-svn: 119601
2010-11-18 01:08:42 +00:00
Francois Pichet
598ba413b5
Appease MSVC 2008: you can't use keyword this inside EXPECT_EQ().
...
This is because of bug 331418 on Microsoft Connect.
llvm-svn: 119600
2010-11-18 00:59:50 +00:00
John Thompson
8c52bd2004
Fixed to use input redirection for source - to eliminate .s output.
...
llvm-svn: 119599
2010-11-18 00:50:20 +00:00
Jim Grosbach
42d103250b
Refactor a few ARM load instructions to better parameterize things and re-use
...
common encoding information.
llvm-svn: 119598
2010-11-18 00:46:58 +00:00
Owen Anderson
e8906ba112
Revert r119593 while I figure out my testing disagrees with the buildbot.
...
llvm-svn: 119597
2010-11-18 00:42:51 +00:00
Dan Gohman
3213622610
Introduce memoization for ScalarEvolution dominates and properlyDominates
...
queries, and SCEVExpander getRelevantLoop queries.
llvm-svn: 119595
2010-11-18 00:34:22 +00:00
Owen Anderson
47a64ab90c
Provide correct Thumb2 encodings for basic multiplication operators.
...
llvm-svn: 119593
2010-11-18 00:19:10 +00:00
Oscar Fuentes
8b8fa79ce0
Updated library dependencies.
...
llvm-svn: 119592
2010-11-18 00:12:27 +00:00
John Thompson
b33f935bc3
Bug 8621 fix - pointer cast stripped from inline asm constraint argument.
...
llvm-svn: 119590
2010-11-17 23:58:47 +00:00
Wesley Peck
849367836f
Make MCJIT work with CMake.
...
llvm-svn: 119589
2010-11-17 23:35:07 +00:00
Jim Grosbach
5d9d8356fa
Clean up LEApcrel instuction(s) a bit. It's not really a Pseudo, so don't mark
...
it as such. Add some encoding information.
llvm-svn: 119588
2010-11-17 23:33:14 +00:00
Dan Gohman
ecff21cc67
Factor out the code for purging a SCEV from all the various memoization maps.
...
Some of these maps may merge in the future, but for now it's convenient to have
a utility function for them.
llvm-svn: 119587
2010-11-17 23:28:48 +00:00
Dan Gohman
8e594dfe39
Merge the implementations of isLoopInvariant and hasComputableLoopEvolution, and
...
memoize the results. This improves compile time in code which highly complex
expressions which get queried many times.
llvm-svn: 119584
2010-11-17 23:21:44 +00:00
Wesley Peck
890a8357af
Now that the MBlaze backend is in its own directory, split the test cases into multiple files for different types of instructions.
...
llvm-svn: 119580
2010-11-17 22:54:43 +00:00
Dan Gohman
fb6ea18d0a
Make SCEV::getType() and SCEV::print non-virtual. Move SCEV::hasOperand
...
to ScalarEvolution. Delete SCEV::~SCEV. SCEV is no longer virtual.
llvm-svn: 119578
2010-11-17 22:27:42 +00:00
Owen Anderson
ea6ac4cdff
Second attempt at correct encodings for Thumb2 bitfield instructions.
...
llvm-svn: 119575
2010-11-17 22:16:31 +00:00
Jim Grosbach
16aeabf0d5
Fix comment typo.
...
llvm-svn: 119573
2010-11-17 21:57:51 +00:00
Dale Johannesen
a87210e350
These tests are looking for library function names that
...
appear to differ on Linux. Try to make them pass on Linux.
Would be good for a Linux person to review this.
llvm-svn: 119572
2010-11-17 21:57:32 +00:00
Dan Gohman
9bbb0fa515
Move SCEV::dominates and properlyDominates to ScalarEvolution.
...
llvm-svn: 119570
2010-11-17 21:41:58 +00:00
Bob Wilson
a217a6e40b
Change ARMGlobalMerge to keep BSS globals in separate pools.
...
This completes the fixes for Radar 8673120.
llvm-svn: 119566
2010-11-17 21:25:39 +00:00
Bob Wilson
819660b716
Fix ARMGlobalMerge pass to check if globals are entirely within range.
...
It is generally not sufficient to check if the starting offset is in range
of the maximum offset that can be efficiently used for the target.
llvm-svn: 119565
2010-11-17 21:25:36 +00:00
Bob Wilson
49bf8702f0
Change the symbol for merged globals from "merged" to "_MergedGlobals".
...
This makes it more clear that the symbol is an internal, compiler-generated
name and gives a little more description about its contents.
llvm-svn: 119564
2010-11-17 21:25:33 +00:00
Bob Wilson
fd7399b6a6
Fix the ARMGlobalMerge pass to look at variable sizes instead of pointer sizes.
...
It was mistakenly looking at the pointer type when checking for the size of
global variables. This is a partial fix for Radar 8673120.
llvm-svn: 119563
2010-11-17 21:25:27 +00:00
Dan Gohman
04df5af12b
Move SCEV::isLoopInvariant and hasComputableLoopEvolution to be member
...
functions of ScalarEvolution, in preparation for memoization and
other optimizations.
llvm-svn: 119562
2010-11-17 21:23:15 +00:00
Jim Grosbach
37233d0ea6
Make the ARM BR_JTadd instruction an explicit pseudo and lower it properly
...
in the MC lowering process.
llvm-svn: 119559
2010-11-17 21:05:55 +00:00
Evan Cheng
00c4672acc
Avoid isel movcc of large immediates when the large immediate is available in a register. These immediates aren't free.
...
llvm-svn: 119558
2010-11-17 20:56:30 +00:00
Dan Gohman
a29ddd0b21
Reference ScalarEvolution by name rather than directly in LICM,
...
to avoid an unneeded dependence.
llvm-svn: 119557
2010-11-17 20:50:07 +00:00
Duncan Sands
b5fd5f2124
Before replacing a phi node with a different value, it
...
needs to be checked that this won't break LCSSA form.
Change the existing checking method to a more direct one:
rather than seeing if all predecessors belong to the loop,
check that the replacing value is either not in any loop or
is in a loop that contains the phi node.
llvm-svn: 119556
2010-11-17 20:49:12 +00:00
Owen Anderson
2adebbb603
Revert r119551, which broke buildbots.
...
llvm-svn: 119555
2010-11-17 20:48:51 +00:00
Dan Gohman
4dc0a20aea
Verify SCEVAddRecExpr's invariant in ScalarEvolution::getAddRecExpr
...
instead of in SCEVAddRecExpr's constructor, in preparation for an
upcoming change.
llvm-svn: 119554
2010-11-17 20:48:38 +00:00
Owen Anderson
c7750780fc
Provide Thumb2 encodings for bitfield instructions.
...
llvm-svn: 119551
2010-11-17 20:35:29 +00:00
Dan Gohman
a585073323
Fix ScalarEvolution's range memoization to avoid using a
...
default ctor with ConstantRange.
llvm-svn: 119550
2010-11-17 20:23:08 +00:00
Evan Cheng
ce610bd6b3
Remove ARM isel hacks that fold large immediates into a pair of add, sub, and,
...
and xor. The 32-bit move immediates can be hoisted out of loops by machine
LICM but the isel hacks were preventing them.
Instead, let peephole optimization pass recognize registers that are defined by
immediates and the ARM target hook will fold the immediates in.
Other changes include 1) do not fold and / xor into cmp to isel TST / TEQ
instructions if there are multiple uses. This happens when the 'and' is live
out, machine sink would have sinked the computation and that ends up pessimizing
code. The peephole pass would recognize situations where the 'and' can be
toggled to define CPSR and eliminate the comparison anyway.
2) Move peephole pass to after machine LICM, sink, and CSE to avoid blocking
important optimizations.
rdar://8663787, rdar://8241368
llvm-svn: 119548
2010-11-17 20:13:28 +00:00
Rafael Espindola
7fc5cd0a58
make isVirtualSection a virtual method on MCSection. Chris' suggestion.
...
llvm-svn: 119547
2010-11-17 20:03:54 +00:00
Owen Anderson
d88cfe5453
More miscellaneous Thumb2 encodings.
...
llvm-svn: 119546
2010-11-17 19:57:38 +00:00
Chris Lattner
f808b37bae
add some justification for "using namespace llvm;"
...
llvm-svn: 119544
2010-11-17 19:47:20 +00:00
Jim Grosbach
122ce7f051
Fix typo.
...
llvm-svn: 119542
2010-11-17 19:30:11 +00:00
Bill Wendling
5c4f5ecff0
Add missing opcodes now that this function's used in more than one place.
...
llvm-svn: 119539
2010-11-17 19:16:20 +00:00
Benjamin Kramer
1b330efb46
InstCombine: Add a missing irem identity (X % X -> 0).
...
llvm-svn: 119538
2010-11-17 19:11:46 +00:00
Duncan Sands
2bd7e7c274
Move some those Xor simplifications which don't require creating new
...
instructions out of InstCombine and into InstructionSimplify. While
there, introduce an m_AllOnes pattern to simplify matching with integers
and vectors with all bits equal to one.
llvm-svn: 119536
2010-11-17 18:52:15 +00:00
Jim Grosbach
b640b6a7b4
More ARM encoding bits. LDRH now encodes properly.
...
llvm-svn: 119529
2010-11-17 18:11:11 +00:00
Chris Lattner
878ec25f02
various cleanups and other improvements, patch by Zhanyong Wan!
...
llvm-svn: 119515
2010-11-17 17:14:55 +00:00
Rafael Espindola
b6fcca35a2
Add support for .int.
...
llvm-svn: 119512
2010-11-17 16:24:40 +00:00
Rafael Espindola
9186952072
Add support for .2byte, .4byte and .8byte.
...
Fixes PR8631.
llvm-svn: 119511
2010-11-17 16:15:42 +00:00
Daniel Dunbar
1890e9a6b7
MC-JIT: Stub out "pure" streamer.
...
- No immediate use, but maybe someone feels like hacking on it.
llvm-svn: 119510
2010-11-17 16:06:47 +00:00
Daniel Dunbar
aff668a681
MCJIT: Stub out MCJIT implementation, still doesn't do anything useful.
...
llvm-svn: 119509
2010-11-17 16:06:43 +00:00
Daniel Dunbar
7817c0b45f
lli: Add stub -use-mcjit option, which doesn't currently do anything.
...
llvm-svn: 119508
2010-11-17 16:06:37 +00:00
Duncan Sands
c84443a206
Have InlineFunction use SimplifyInstruction rather than
...
hasConstantValue. I was leery of using SimplifyInstruction
while the IR was still in a half-baked state, which is the
reason for delaying the simplification until the IR is fully
cooked.
llvm-svn: 119494
2010-11-17 11:16:23 +00:00
Duncan Sands
a5bd3ff0e4
Now that hasConstantValue has been made simpler, it may return the
...
phi node itself if it occurs in an unreachable basic block. Protect
against this. Hopefully this will fix some more buildbots.
llvm-svn: 119493
2010-11-17 10:23:23 +00:00
Evan Cheng
907a7149d6
Revert r119109 for now. It's breaking 176.gcc.
...
llvm-svn: 119492
2010-11-17 09:31:04 +00:00