Commit Graph

52755 Commits

Author SHA1 Message Date
Chris Lattner
0bef562ea2 add a simple helper method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83745 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 23:41:48 +00:00
Chris Lattner
f5a1fb6b24 add ability for clients of SSAUpdater to find out about the
PHI nodes inserted.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83744 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 23:15:24 +00:00
Chris Lattner
aa6aeb91b4 clarify
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83743 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 23:05:42 +00:00
Chris Lattner
813dbd5912 remove dead code
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83742 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 23:04:12 +00:00
Chris Lattner
1a8d4de397 add the ability to get a rewritten value from the middle of a block,
not just at the end.  Add a big comment explaining when this could
be useful (which never happens for jump threading).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83741 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 23:00:11 +00:00
Chris Lattner
5fb107287f rename GetValueInBlock -> GetValueAtEndOfBlock to better reflect
what it does.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83740 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 22:41:58 +00:00
Anton Korobeynikov
8f8e9f0830 It seems that OR operation does not affect status reg at all.
Remove impdef of SRW. This fixes PR4779


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83739 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 22:17:47 +00:00
Chris Lattner
558c36729f fix broken link
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83738 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 22:15:25 +00:00
Chris Lattner
f0390dfbc4 final changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83737 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 22:13:38 +00:00
Chris Lattner
220b9eecf5 down to 'major changes'
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83736 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 22:02:58 +00:00
Chris Lattner
85c70786f2 more updates
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83735 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 21:40:13 +00:00
Chris Lattner
9b96e80da4 add a link to the GSG for info on how to check out svn trunk
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83734 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 21:37:16 +00:00
Chris Lattner
b91227dc6c x86 uses 5 operands for most memory refs now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83733 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 21:30:55 +00:00
Duncan Sands
2eff6e74be More spelling and grammar tweaks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83728 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 20:06:04 +00:00
Benjamin Kramer
9ddfb948e8 More spelling fixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83724 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 19:45:13 +00:00
Duncan Sands
65b0e39acf Spelling fixes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83722 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 19:30:16 +00:00
Chris Lattner
f435c4139e more tweaks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83721 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 19:26:21 +00:00
Duncan Sands
a637737e49 Remove an inappropriate line in the description of the
clang static analyser.  Decrease duplication in the text.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83720 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 19:16:25 +00:00
Chris Lattner
cfb92fe54e continue decoding chris scribble.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83719 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 19:00:55 +00:00
Chris Lattner
60f034097e remove some dead passes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83717 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 18:40:48 +00:00
Chris Lattner
39c0e67a89 checkpoint.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83716 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 18:33:13 +00:00
Chris Lattner
5a2d87541f fix broken anchors.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83715 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 18:26:06 +00:00
Chris Lattner
f9920fabac use a typedef instead of spelling out an insane type. Yay for auto someday.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83707 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 09:09:20 +00:00
Chris Lattner
433a0dbb26 Change jump threading to use the new SSAUpdater class instead of
DemoteRegToStack.  This makes it more efficient (because it isn't
creating a ton of load/stores that are eventually removed by a later
mem2reg), and more slightly more effective (because those load/stores
don't get in the way of threading).



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83706 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 09:05:58 +00:00
Chris Lattner
93f3bcf7f3 Implement an efficient and fully general SSA update mechanism that
works on unstructured CFGs.  This implements PR217, our oldest open PR.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83705 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 09:04:27 +00:00
Chris Lattner
f6811274e1 add some WeakVH::operator='s. Without these, assigning
a Value* to a WeakVH was constructing a temporary WeakVH
(due to the implicit assignment operator).  This avoids
that cost.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83704 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 08:27:29 +00:00
Chris Lattner
fc61aeff2c change some static_cast into cast, pointed out by Gabor.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83703 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 08:01:27 +00:00
Chris Lattner
ceaa457a9d add a version of PHINode::getIncomingBlock that takes a raw
Use, to complement the version that takes a use_iterator.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83702 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 07:42:42 +00:00
Chris Lattner
2d7f1d24bf random tidying
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83701 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 06:22:45 +00:00
Dan Gohman
bcea859fc1 Create a new InstrEmitter class for translating SelectionDAG nodes
into MachineInstrs. This is mostly just moving the code from
ScheduleDAGSDNodesEmit.cpp into a new class. This decouples MachineInstr
emitting from scheduling.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83699 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 01:32:21 +00:00
Dan Gohman
c81b783e27 Make getMachineNode return a MachineSDNode* instead of a generic SDNode*
since it won't do any folding. This will help avoid some inconvenient
casting.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83698 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 01:29:16 +00:00
Dan Gohman
4e6f7a0179 Remove a no-longer-necessary #include.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83697 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 00:36:09 +00:00
Dan Gohman
3731bc026c Replace X86's CanRematLoadWithDispOperand by calling the target-independent
MachineInstr::isInvariantLoad instead, which has the benefit of being
more complete.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83696 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 00:34:18 +00:00
Dan Gohman
5bf7c2a346 Fix a missing initialization of PostRAScheduler's AA member.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83695 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-10 00:15:38 +00:00
Dan Gohman
98976e4dcd The ScheduleDAG framework now requires an AliasAnalysis argument, though
it isn't needed in the ScheduleDAGSDNodes schedulers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83691 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 23:33:48 +00:00
Dan Gohman
cda49a0b29 Update this test; the code is the same but it gets counted as one
fewer remat.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83690 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 23:31:04 +00:00
Dan Gohman
59ac57153b Mark the LDR instruction with isReMaterializable, as it is rematerializable
when loading from an invariant memory location.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83688 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 23:28:27 +00:00
Dan Gohman
a70dca156f Factor out LiveIntervalAnalysis' code to determine whether an instruction
is trivially rematerializable and integrate it into
TargetInstrInfo::isTriviallyReMaterializable. This way, all places that
need to know whether an instruction is rematerializable will get the
same answer.

This enables the useful parts of the aggressive-remat option by
default -- using AliasAnalysis to determine whether a memory location
is invariant, and removes the questionable parts -- rematting operations
with virtual register inputs that may not be live everywhere.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83687 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 23:27:56 +00:00
Devang Patel
ac1ceb3dd3 Extract scope information from the variable itself, instead of relying on alloca or llvm.dbg.declare location.
While recording beginning of a function, use scope info from the first location entry instead of just relying on first location entry itself.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83684 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 22:42:28 +00:00
Jeffrey Yasskin
c89d27a440 ExecutionEngine::clearGlobalMappingsFromModule failed to remove reverse
mappings, which could cause errors and assert-failures.  This patch fixes that,
adds a test, and refactors the global-mapping-removal code into a single place.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83678 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 22:10:27 +00:00
Dan Gohman
769b7f8953 Add a const qualifier.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83677 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 22:09:05 +00:00
Dale Johannesen
bdb984bc27 Use names instead of numbers for some of the magic
constants used in inlining heuristics (especially
those used in more than one file).  No functional change.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83675 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 21:42:02 +00:00
Kevin Enderby
d7894f105a Added another bit of the ARM target assembler to llvm-mc to parse register
lists.  Changed ARMAsmParser::MatchRegisterName to return -1 instead of 0 on
errors so 0-15 values could be returned as register numbers.  Also added the
rest of the arm register names to the currently hacked up version to allow more
testing.  Some changes to ARMAsmParser::ParseOperand to give different errors
for things not yet supported and some additions to the hacked
ARMAsmParser::MatchInstruction to allow more testing for now.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83673 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 21:12:28 +00:00
Dan Gohman
599a87aca0 isTriviallyReMaterializable checks the
TargetInstrDesc::isRematerializable flag, so it isn't necessary to do
this check in its callers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83671 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 21:02:10 +00:00
Dan Gohman
11596ed43c Fix the x86 test-shrink optimization so that it doesn't shrink comparisons
when one of the bits being tested would end up being the sign bit in the
narrower type, and a signed comparison is being performed, since this would
change the result of the signed comparison. This fixes PR5132.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83670 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 20:35:19 +00:00
Bob Wilson
83815aeb29 Merge a bunch of NEON tests into larger files so they run faster.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83667 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 20:20:54 +00:00
Dan Gohman
91e69c3715 Add basic infrastructure and x86 support for preserving MachineMemOperand
information when unfolding memory references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83656 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 18:10:05 +00:00
Devang Patel
c525472828 Check invalid debug info for enums. This may happen when underlyng enum is optimized away. Eventually DwarfChecker will clean this up during llvm verification stage.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83655 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 17:51:49 +00:00
Jim Grosbach
71c8dc9b20 when previous scratch register is killed, flag the value as no longer tracking
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83653 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 17:33:33 +00:00
Bob Wilson
e8e72be33a Convert some ARM tests with lots of greps to use FileCheck.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@83651 91177308-0d34-0410-b5e6-96231b3b80d8
2009-10-09 17:20:46 +00:00