Benjamin Kramer
96956ed0ff
Reduce string trashing.
...
llvm-svn: 100038
2010-03-31 20:15:45 +00:00
Benjamin Kramer
74729ae094
DwarfDebug: Allocate DIEValues with a BumpPtrAllocator. Most of them are
...
POD-like anyway, so we don't even care about calling their d'tors (DIEBlock
being the exception).
~6% less mallocs and ~1% compile time improvement on clang -O0 -g oggenc.c
llvm-svn: 100035
2010-03-31 19:34:01 +00:00
Chris Lattner
17d38594fe
reduce indentation
...
llvm-svn: 99999
2010-03-31 06:09:04 +00:00
Chris Lattner
71696ef1ad
tidy up
...
llvm-svn: 99998
2010-03-31 06:06:37 +00:00
Chris Lattner
03e1b5ab5c
MI != 0 is checked in the assert right above this.
...
llvm-svn: 99995
2010-03-31 05:42:48 +00:00
Chris Lattner
848c7d2e49
use the isDebugValue() predicate and pop_back_val()
...
llvm-svn: 99993
2010-03-31 05:39:57 +00:00
Chris Lattner
8d2fe28910
assert is a function-like macro, not a control flow operator.
...
llvm-svn: 99992
2010-03-31 05:36:29 +00:00
Chris Lattner
a5ab82a613
reduce indentation, fit in 80 cols and various other cosmetic cleanups.
...
llvm-svn: 99989
2010-03-31 05:15:22 +00:00
Chris Lattner
3131ae86d8
use the optimized debug info apis in sdisel.
...
llvm-svn: 99986
2010-03-31 04:24:50 +00:00
Chris Lattner
009de335ac
add new apis for getting/setting !dbg metadata on
...
instructions. In addition to being a convenience,
they are faster than the old apis, particularly when
not going from an MDKindID like people should be
doing.
llvm-svn: 99982
2010-03-31 03:34:40 +00:00
Bob Wilson
6f7fd28824
Revert Mon Ping's change 99928, since it broke all the llvm-gcc buildbots.
...
llvm-svn: 99948
2010-03-30 22:27:04 +00:00
Devang Patel
57c644f926
Ignore invalid metadata.
...
llvm-svn: 99938
2010-03-30 22:09:52 +00:00
Mon P Wang
7460571381
Added support for address spaces and added a isVolatile field to memcpy, memmove, and memset,
...
e.g., llvm.memcpy.i32(i8*, i8*, i32, i32) -> llvm.memcpy.p0i8.p0i8.i32(i8*, i8*, i32, i32, i1)
A update of langref will occur in a subsequent checkin.
llvm-svn: 99928
2010-03-30 20:55:56 +00:00
Benjamin Kramer
04c713dd45
Introduce SpecificBumpPtrAllocator, a wrapper for BumpPtrAllocator which allows
...
only a single type of object to be allocated. Use it to make VNInfo destruction
typesafe.
llvm-svn: 99919
2010-03-30 20:16:45 +00:00
Chris Lattner
9897043928
Rip out the 'is temporary' nonsense from the MCContext interface to
...
create symbols. It is extremely error prone and a source of a lot
of the remaining integrated assembler bugs on x86-64.
This fixes rdar://7807601.
llvm-svn: 99902
2010-03-30 18:10:53 +00:00
Evan Cheng
85eea4e031
Funky indentation.
...
llvm-svn: 99901
2010-03-30 18:08:53 +00:00
Devang Patel
67d94ab0f8
There is no need to fall through after processing DBG_VALUE machine instruction.
...
llvm-svn: 99899
2010-03-30 18:07:00 +00:00
Daniel Dunbar
692d165c3b
Fix -Asserts warning.
...
llvm-svn: 99895
2010-03-30 17:57:42 +00:00
Torok Edwin
8061bb141e
Reapply r99881 with some fixes: only call destructor in releaseMemory!
...
llvm-svn: 99883
2010-03-30 11:17:48 +00:00
Torok Edwin
a2d1dc42e1
Revert 99881, it brooke smooshlab's llvm-gcc-i386-darwin9.
...
llvm-svn: 99882
2010-03-30 10:25:08 +00:00
Torok Edwin
ba6d13c0ea
Introduce another Reset() method in BumpPtrAllocator that calls a destructor
...
on all objects it has allocated, if they are all of the same size and alignment.
Use this to destruct all VNInfos allocated in LiveIntervalAnalysis (PR6653).
valnos is not reliable for this purpose, as seen in r99400
(which still leaked, and sometimes caused double frees).
llvm-svn: 99881
2010-03-30 10:08:26 +00:00
Evan Cheng
cbcccce420
Avoid being influenced by the presence of dbg_value instructions.
...
llvm-svn: 99879
2010-03-30 05:49:07 +00:00
Bill Wendling
b2799edaf6
Re-add back in the slow way of determining of a clean-up should become a
...
catch-all. The "dominates" way won't catch all of the selectors which must be
changed.
llvm-svn: 99850
2010-03-29 23:37:07 +00:00
Bill Wendling
decbb74d68
A more general (and simpler!) implementation of r99671. It performs a similar
...
transform. I.e., if a clean-up eh.selector call dominates the invoke of an
_Unwind_Resume_or_Rethrow, then we convert the eh.selector into a
catch-all. This patch, however, uses the DominatorTree information, and doesn't
go through the whole rigmarole of starting at the eh.exception call, finding the
corresponding URoR and eh.selector calls, and trying to trace through any number
of instruction types to get to them.
llvm-svn: 99846
2010-03-29 23:02:46 +00:00
Devang Patel
23b2ae621c
Encode start location of debug value, communicated through DBG_VALUE machine instruction, in a variable's DIE.
...
llvm-svn: 99845
2010-03-29 22:59:58 +00:00
Evan Cheng
742db6874a
Fix PR4975. Avoid referencing empty vector.
...
llvm-svn: 99840
2010-03-29 21:27:30 +00:00
Evan Cheng
4d1aa2a1c6
Pool allocate SDDbgValue nodes.
...
llvm-svn: 99836
2010-03-29 20:48:30 +00:00
Chris Lattner
6efa201f7f
use RAII for ExceptionTimer too
...
llvm-svn: 99833
2010-03-29 20:39:38 +00:00
Chris Lattner
4787975994
fix a variety of issues were we'd start DebugTimer but
...
not stop it by using RAII.
llvm-svn: 99832
2010-03-29 20:38:20 +00:00
Devang Patel
bd477bef25
Refactor code to push DILocation prcessing into DwarfDebug.cpp from AsmPrinter.cpp.
...
This is same as r99772 (which was reverted) with just one meaningful difference where two source lines exchanged their positions.
llvm-svn: 99816
2010-03-29 17:20:31 +00:00
Devang Patel
1e8ccb5f8b
Revert 99772.
...
llvm-svn: 99778
2010-03-28 21:23:37 +00:00
Chris Lattner
03719af41d
add a statistic for the # times isel has to backtrack.
...
llvm-svn: 99774
2010-03-28 19:46:56 +00:00
Devang Patel
32bdaef3fe
Refactoring. Push DILocation processing in to DwarfDebug from AsmPrinter.
...
llvm-svn: 99772
2010-03-28 18:57:09 +00:00
Chris Lattner
6642118e83
finally remove the immAllOnesV_bc/immAllZerosV_bc patterns
...
and those derived from them. These are obnoxious because
they were written as: PatLeaf<(bitconvert). Not having an
argument was foiling adding better type checking for operand
count matching up with what was required (in this case,
bitconvert always requires an operand!)
llvm-svn: 99759
2010-03-28 08:43:23 +00:00
Chris Lattner
89ad2f1d60
comply with the wishes of a fixme.
...
llvm-svn: 99742
2010-03-28 05:55:17 +00:00
Chris Lattner
4d8786b5cc
now that (parallel) is gone and a variety of bugs in targets
...
are cleaned up, we can remove an old fixme.
llvm-svn: 99741
2010-03-28 05:54:03 +00:00
Chris Lattner
49e2773dd8
add an optimized form of OPC_EmitMergeInputChains for the 1, 0 and
...
1, 1 cases which are by-far the most frequent. This shrinks the X86
isel table from 77014 -> 74657 bytes.
llvm-svn: 99740
2010-03-28 05:50:16 +00:00
Chris Lattner
e01f7e33ac
don't add nodes to the now-dead nodes list multiple times, this
...
can cause a crash on crazy situations in msp430 when morph-node-to
is disabled.
llvm-svn: 99739
2010-03-28 05:28:31 +00:00
Chris Lattner
7aed1fb69d
don't add flag nodes with chain results to the NowDeadNodes
...
list multiple times when MorphNodeTo can't be applied.
llvm-svn: 99735
2010-03-28 04:54:33 +00:00
Chris Lattner
decc73d4bc
improve -debug-only=isel comments for cases when we don't enter a
...
scope due to obviously false predicate.
llvm-svn: 99723
2010-03-27 18:54:50 +00:00
Bill Wendling
6888e798d3
Forgot the part where we handle the ".llvm.eh.catch.all.value".
...
llvm-svn: 99697
2010-03-27 01:24:30 +00:00
Bill Wendling
ec8b44adeb
Return if we changed anything or not.
...
llvm-svn: 99695
2010-03-27 01:22:38 +00:00
Bill Wendling
f2c1f40e95
If a selector has a call to ".llvm.eh.catch.all.value" that we haven't
...
converted, then use the initializer, since using the name itself won't work.
llvm-svn: 99692
2010-03-27 01:19:12 +00:00
Bill Wendling
d1aa77c37d
If we mark clean-ups as clean-ups, then it could break when inlining through an
...
'invoke' instruction. You will get a situation like this:
bb:
%ehptr = eh.exception()
%sel = eh.selector(%ehptr, @per, 0);
...
bb2:
invoke _Unwind_Resume_or_Rethrow(%ehptr) %normal unwind to %lpad
lpad:
...
The unwinder will see the %sel call as a clean-up and, if it doesn't have a
catch further up the call stack, it will skip running it. But there *is* another
catch up the stack -- the catch for the %lpad. However, we can't see that. This
is fixed in code-gen, where we detect this situation, and convert the "clean-up"
selector call into a "catch-all" selector call. This gives us the correct
semantics.
llvm-svn: 99671
2010-03-26 23:41:30 +00:00
Anton Korobeynikov
2f072e95e6
Add few missed libcalls and correct names for others.
...
llvm-svn: 99656
2010-03-26 21:32:14 +00:00
Dale Johannesen
6096d5a279
Debug info shouldn't affect kills.
...
llvm-svn: 99637
2010-03-26 19:21:26 +00:00
Evan Cheng
eb50ac5ccc
LiveVariables should clear kill / dead markers first. This allows us to remove a hack in the scheduler.
...
llvm-svn: 99597
2010-03-26 02:12:24 +00:00
Evan Cheng
7b4a1a221b
Try trivial remat before the coalescer gives up on a vr / physreg coalescing for fear of tying up a physical register.
...
llvm-svn: 99575
2010-03-26 00:07:25 +00:00
Dale Johannesen
5d99d7fe79
Handle DEBUG_VALUE in this pass.
...
llvm-svn: 99573
2010-03-26 00:02:44 +00:00
Evan Cheng
510bda2064
Code clean up.
...
llvm-svn: 99544
2010-03-25 19:46:11 +00:00