Chris Lattner
2b00dd86ae
don't make insanely large node numbers for no reason,
...
packing somewhat densely is better than not.
llvm-svn: 96213
2010-02-15 06:39:31 +00:00
Chris Lattner
ba70b52fe6
no need to add the instruction count anymore.
...
llvm-svn: 96212
2010-02-15 06:38:41 +00:00
Mikhail Glushenkov
47bcd93456
Revert r96130 ("Forward parameter options as '-option=param'").
...
This behaviour must be configurable.
llvm-svn: 96210
2010-02-15 03:17:06 +00:00
Chris Lattner
bd65f192f2
enhance raw_svector_ostream::write_impl to work with unbuffered streams,
...
which may call write_impl on things that are not the usual buffer.
llvm-svn: 96209
2010-02-15 02:18:26 +00:00
Chris Lattner
eeadc240f2
make PadToColumn return the stream so you can use:
...
OS.PadToColumn(42) << "foo";
llvm-svn: 96208
2010-02-15 02:17:50 +00:00
Dale Johannesen
c23d94e163
Ignore DBG_VALUE in a couple more places.
...
llvm-svn: 96207
2010-02-15 01:45:47 +00:00
Dan Gohman
6c0fdcea5e
When restoring a saved insert location, check to see if the saved
...
insert location has become an "inserted" instruction since the time
it was saved. If so, advance to the first non-"inserted" instruction.
llvm-svn: 96203
2010-02-15 00:21:43 +00:00
Chris Lattner
3d4086208b
constize
...
llvm-svn: 96199
2010-02-14 22:33:49 +00:00
Chris Lattner
4a7b56d74e
clean up a bunch of code, move some random predicates
...
on TreePatternNode to be methods on TreePatternNode.
llvm-svn: 96197
2010-02-14 22:22:58 +00:00
Chris Lattner
f036c806b3
mark "addr" as having type "iPTR", eliminating some type comparisons
...
in hte generated dag isel fil.
llvm-svn: 96193
2010-02-14 21:53:19 +00:00
Chris Lattner
8d7e9178d4
remove the DisablePatternForFastISel predicate, which is a check
...
that predated -fast-isel which attempted to speed up the dag pattern
matchers at -O0. Since fast-isel is around, this is basically
obsolete and removing it shrinks the generated dag isels.
llvm-svn: 96188
2010-02-14 21:11:53 +00:00
Chris Lattner
1a9a2e116d
add an insertion operator.
...
llvm-svn: 96187
2010-02-14 21:10:33 +00:00
Chris Lattner
216edab8dd
tidy up
...
llvm-svn: 96186
2010-02-14 21:10:15 +00:00
Dan Gohman
c954fc3333
Fix whitespace.
...
llvm-svn: 96179
2010-02-14 18:51:39 +00:00
Dan Gohman
900be69752
Fix a comment.
...
llvm-svn: 96178
2010-02-14 18:51:20 +00:00
Dan Gohman
de32b2fac0
When complicated expressions are broken down into subexpressions
...
with multiplication by constants distributed through, occasionally
those subexpressions can include both x and -x. For now, if this
condition is discovered within LSR, just prune such cases away,
as they won't be profitable. This fixes a "zero allocated in a
base register" assertion failure.
llvm-svn: 96177
2010-02-14 18:50:49 +00:00
Sanjiv Gupta
318fdf4e39
fixes to pagesel/banksel inserter.
...
1. restore these across direct/indirect calls.
2. restore pagesel for any macros with gotos.
llvm-svn: 96175
2010-02-14 18:27:42 +00:00
Anton Korobeynikov
3461f67cee
Forgot to commit the header
...
llvm-svn: 96174
2010-02-14 18:25:41 +00:00
Chris Lattner
42c8f96141
follow-on to PR6280
...
llvm-svn: 96172
2010-02-14 18:20:09 +00:00
Anton Korobeynikov
9436d20d76
Drop winmcasminfo and use normal AT&T COFF for all windows targets.
...
Otherwise AT&T asm printer is used with non-compatible MCAsmInfo and
there is no way to override this behaviour.
llvm-svn: 96165
2010-02-14 15:19:54 +00:00
Johnny Chen
475f273d63
Try to factorize the specification of saturating add/subtract operations a bit,
...
as suggested by Bob Wilson.
llvm-svn: 96153
2010-02-14 06:32:20 +00:00
Dan Gohman
dbffcb6c92
Actually, this code doesn't have to be quite so conservative in
...
the no-TLI case. But it should still default to declining the
transformation.
llvm-svn: 96152
2010-02-14 03:21:49 +00:00
Dan Gohman
4d5f3b74e4
In rememberInstruction, if the value being remembered is the
...
current insertion point, advance the current insertion point.
This avoids a use-before-def situation in a testcase extracted
from clang which is difficult to reduce to a reasonable-sized
regression test.
llvm-svn: 96151
2010-02-14 03:12:47 +00:00
Dan Gohman
47756a8549
Simplify this code; no need for a custom subclass if it doesn't need
...
to override anything from the parent class.
llvm-svn: 96150
2010-02-14 02:48:58 +00:00
Dan Gohman
8985140f3e
Remove a 'protected' keyword, now that SCEVExpander is no longer
...
intended to be subclassed.
llvm-svn: 96149
2010-02-14 02:47:26 +00:00
Dan Gohman
3b065f43af
Don't attempt aggressive post-inc uses if TargetLowering is not available,
...
because profitability can't be sufficiently approximated.
llvm-svn: 96148
2010-02-14 02:45:21 +00:00
Daniel Dunbar
59ecca73a9
2.7: Note that DataTypes.h moved.
...
llvm-svn: 96143
2010-02-14 01:47:19 +00:00
John McCall
5089836939
Make LSR not crash if invoked without target lowering info, e.g. if invoked
...
from opt.
llvm-svn: 96135
2010-02-13 23:40:16 +00:00
Eric Christopher
96f3c4222f
Fix a problem where we had bitcasted operands that gave us
...
odd offsets since the bitcasted pointer size and the offset pointer
size are going to be different types for the GEP vs base object.
llvm-svn: 96134
2010-02-13 23:38:01 +00:00
Mikhail Glushenkov
09bf7f44e8
Forward parameter options as '-option=parameter'.
...
Some tools do not like the '-option parameter' form. Should this be
configurable?
llvm-svn: 96130
2010-02-13 22:37:28 +00:00
Mikhail Glushenkov
d823a2e8ee
Support some more Darwin-only options.
...
We really need a conditional compilation mechanism...
llvm-svn: 96129
2010-02-13 22:37:13 +00:00
Mikhail Glushenkov
6de0557115
Support -mfix-and-continue properly.
...
llvm-svn: 96128
2010-02-13 22:37:00 +00:00
Mikhail Glushenkov
3b9bef0cfb
Revert r94752, turns out we don't need to touch these options.
...
llvm-svn: 96127
2010-02-13 22:36:43 +00:00
Daniel Dunbar
2b76a91c60
Trim trailing spaces (aka, trigger rebuild).
...
llvm-svn: 96126
2010-02-13 22:23:47 +00:00
Chris Lattner
d971210bd9
pull a bunch of huge inline methods in the PatternCodeEmitter
...
class out of line.
llvm-svn: 96113
2010-02-13 20:06:50 +00:00
Chris Lattner
b9c4a15ad5
teach the encoder to handle pseudo instructions like FP_REG_KILL,
...
encoding them into nothing.
llvm-svn: 96110
2010-02-13 19:16:53 +00:00
Chris Lattner
23368e55d7
remove dead code.
...
llvm-svn: 96109
2010-02-13 19:07:06 +00:00
Daniel Dunbar
e6679afaa7
MCAssembler: Fix pcrel relocations. Oh and,
...
--
ddunbar@ozzy:tmp$ clang -m32 -integrated-as hello.c && ./a.out
hello world!
--
llvm-svn: 96096
2010-02-13 09:45:59 +00:00
Daniel Dunbar
c05a38a3d3
MC/Mach-O: Start emitting fixups/relocations for instructions.
...
llvm-svn: 96095
2010-02-13 09:29:02 +00:00
Daniel Dunbar
7a1fd21459
MCAssembler: Switch MCAsmFixup to storing MCFixupKind instead of just a size.
...
llvm-svn: 96094
2010-02-13 09:28:54 +00:00
Daniel Dunbar
8e9044353a
MCAssembler: Sink fixup list into MCDataFragment.
...
llvm-svn: 96093
2010-02-13 09:28:43 +00:00
Daniel Dunbar
95ae012b0e
MCAssembler: Switch MCFillFragment to only taking constant values. Symbolic expressions can always be emitted as data + fixups.
...
llvm-svn: 96092
2010-02-13 09:28:32 +00:00
Daniel Dunbar
cc282ba52e
MC/Mach-O: Implement EmitValue using data fragments + fixups instead of fill fragment.
...
llvm-svn: 96091
2010-02-13 09:28:22 +00:00
Daniel Dunbar
481e926468
MCAssembler: Start applying fixups in the data section.
...
llvm-svn: 96090
2010-02-13 09:28:15 +00:00
Daniel Dunbar
a699e834fb
MCAssembler: Add assorted dump() methods.
...
llvm-svn: 96089
2010-02-13 09:28:03 +00:00
Daniel Dunbar
1581cae46f
X86: Move extended MCFixupKinds into X86FixupKinds.h
...
llvm-svn: 96088
2010-02-13 09:27:52 +00:00
Chris Lattner
0874dc6dab
Split some code out to a helper function (FindReusablePredBB)
...
and add a doxygen comment.
Cache the phi entry to avoid doing tons of
PHINode::getBasicBlockIndex calls in the common case.
On my insane testcase from re2c, this speeds up CGP from
617.4s to 7.9s (78x).
llvm-svn: 96083
2010-02-13 05:35:08 +00:00
Chris Lattner
9c797fdf1d
Speed up codegen prepare from 3.58s to 0.488s.
...
llvm-svn: 96081
2010-02-13 05:01:14 +00:00
Chris Lattner
975da20868
PHINode::getBasicBlockIndex is O(n) in the number of inputs
...
to a PHI, avoid it in the common case where the BB occurs
in the same index for multiple phis. This speeds up CGP on
an insane testcase from 8.35 to 3.58s.
llvm-svn: 96080
2010-02-13 04:24:19 +00:00
Chris Lattner
1a067d53b0
iterate over preds using PHI information when available instead of
...
using pred_begin/end. It is much faster.
llvm-svn: 96079
2010-02-13 04:15:26 +00:00