Bill Wendling
9c5b7ff807
Refuse to inline two functions which use different personality functions.
...
llvm-svn: 136269
2011-07-27 21:44:28 +00:00
Bill Wendling
6c923bb8d9
Merge the contents from exception-handling-rewrite to the mainline.
...
This adds the new instructions 'landingpad' and 'resume'.
llvm-svn: 136253
2011-07-27 20:18:04 +00:00
Nick Lewycky
8ac9ecedfd
Teach the ConstantMerge pass about alignment. Fixes PR10514!
...
llvm-svn: 136250
2011-07-27 19:47:34 +00:00
Eli Friedman
89b694b096
Misc mid-level changes for new 'fence' instruction.
...
llvm-svn: 136205
2011-07-27 01:08:30 +00:00
Bill Wendling
3fe5d68563
Use the correct for for the version. It's little endian and my brain is
...
obviously big endian. :-)
PR10502
llvm-svn: 136111
2011-07-26 18:31:41 +00:00
Rafael Espindola
b84dc6bca8
Add LLVMAddAlwaysInlinerPass to the C API.
...
llvm-svn: 136083
2011-07-26 15:23:23 +00:00
Rafael Espindola
be2fe29f9c
LLVM 3.0 is here, remove old do nothing method.
...
llvm-svn: 136082
2011-07-26 15:17:32 +00:00
Nick Lewycky
15e2d90746
Finish adding support for lifetime intrinsics to SROA. Fixes PR10121!
...
llvm-svn: 136008
2011-07-25 23:14:22 +00:00
Andrew Trick
990f771a9a
Add clarifying comments for the new arguments to UnrollLoop.
...
llvm-svn: 135988
2011-07-25 22:17:47 +00:00
Nick Lewycky
77cb8e681f
Add missing space (this line is no longer pushing the 80-column limit).
...
llvm-svn: 135973
2011-07-25 21:16:04 +00:00
Rafael Espindola
7281395c8c
Add LLVMAddLowerExpectIntrinsicPass to the C API.
...
llvm-svn: 135966
2011-07-25 20:57:59 +00:00
Frits van Bommel
ede0dc6dda
Shorten some expressions by using ArrayRef::slice().
...
llvm-svn: 135910
2011-07-25 15:13:01 +00:00
Jay Foad
d1b7849d49
Convert GetElementPtrInst to use ArrayRef.
...
llvm-svn: 135904
2011-07-25 09:48:08 +00:00
Andrew Trick
1cabe54fab
Move trip count discovery outside of the generic LoopUnroll helper. This
...
removes its dependence on canonical induction variables.
llvm-svn: 135829
2011-07-23 00:33:05 +00:00
Andrew Trick
279e7a6c83
whitespace
...
llvm-svn: 135828
2011-07-23 00:29:16 +00:00
Dan Gohman
6320f52ff4
Move the last uses of RetainFunc etc. over to using getRetainCallee() etc.
...
so that a declaration for objc_retain is created when needed if it doesn't
already exist. rdar://9825114.
llvm-svn: 135821
2011-07-22 22:29:21 +00:00
Jay Foad
17bab44308
Fix more MSVC warnings caused by a cases I missed when converting
...
ConstantExpr::getGetElementPtr to use ArrayRef.
llvm-svn: 135762
2011-07-22 08:52:50 +00:00
Jay Foad
040dd82f44
Convert IRBuilder::CreateGEP and IRBuilder::CreateInBoundsGEP to use
...
ArrayRef.
llvm-svn: 135761
2011-07-22 08:16:57 +00:00
Jay Foad
71f19ac6af
Fix an MSVC warning, caused by a case I missed when converting
...
ConstantExpr::getGetElementPtr to use ArrayRef.
llvm-svn: 135758
2011-07-22 07:54:01 +00:00
Dan Gohman
e106aee6f5
Fix MergeInVectorType to check for vector types with the same alloc
...
size but different element types, so that it filters out the cases
that CreateShuffleVectorCast doesn't handle. This fixes rdar://9786827.
llvm-svn: 135721
2011-07-21 23:30:09 +00:00
Andrew Trick
cd3e8cb882
Cleanup: make std::pair usage slightly less indecipherable without actually naming variables!
...
llvm-svn: 135684
2011-07-21 17:37:39 +00:00
Jay Foad
2f5fc8c67d
Make better use of ConstantExpr::getGetElementPtr's InBounds parameter.
...
llvm-svn: 135676
2011-07-21 15:15:37 +00:00
Jay Foad
ed8db7d9df
Convert ConstantExpr::getGetElementPtr and
...
ConstantExpr::getInBoundsGetElementPtr to use ArrayRef.
llvm-svn: 135673
2011-07-21 14:31:17 +00:00
Chris Lattner
5cf753c95e
move tier out of an anonymous namespace, it doesn't make sense
...
to for it to be an an anon namespace and be in a header.
Eliminate some extraenous uses of tie.
llvm-svn: 135669
2011-07-21 06:21:31 +00:00
Andrew Trick
bd243d0dfe
LSR, correct fix for rdar://9786536. Silly casting bug.
...
llvm-svn: 135654
2011-07-21 01:45:54 +00:00
Andrew Trick
858e9f083d
LSR must sometimes sign-extend before generating double constants.
...
rdar://9786536
llvm-svn: 135650
2011-07-21 01:05:01 +00:00
Andrew Trick
8acb434402
LSR crashes on an empty IVUsers list.
...
rdar://9786536
llvm-svn: 135644
2011-07-21 00:40:04 +00:00
Eli Friedman
911e12f505
Clean up includes of llvm/Analysis/ConstantFolding.h so it's included where it's used and not included where it isn't.
...
llvm-svn: 135628
2011-07-20 21:57:23 +00:00
Eli Friedman
0cdc148ab8
Bring LICM into compliance with the new "Memory Model for Concurrent Operations" in LangRef.
...
llvm-svn: 135625
2011-07-20 21:37:47 +00:00
Jay Foad
50bfbab033
Fix a GCC warning.
...
llvm-svn: 135581
2011-07-20 08:15:21 +00:00
Andrew Trick
638b355a16
indvars: Added getInsertPointForUses to find a valid place to truncate the IV.
...
llvm-svn: 135568
2011-07-20 05:32:06 +00:00
Andrew Trick
2210448520
indvars -disable-iv-rewrite: Add NarrowIVDefUse to cache def-use
...
info. Holding Use* pointers is bad form even though it happened to
work in this case.
llvm-svn: 135566
2011-07-20 04:39:24 +00:00
Andrew Trick
c5dd3e976a
indvars -disable-iv-rewrite fix: derived GEP IVs
...
llvm-svn: 135558
2011-07-20 02:08:58 +00:00
Eli Friedman
55d6ccbb79
PR10386: Don't try to split an edge from an indirectbr.
...
llvm-svn: 135534
2011-07-19 22:59:41 +00:00
Devang Patel
a59b24b090
Distinguish between two copies of one inlined variable.
...
llvm-svn: 135528
2011-07-19 22:31:15 +00:00
Jay Foad
b992a635fb
Convert SimplifyGEPInst to use ArrayRef.
...
llvm-svn: 135482
2011-07-19 15:07:52 +00:00
Jay Foad
bf904773bb
Convert TargetData::getIndexedOffset to use ArrayRef.
...
llvm-svn: 135478
2011-07-19 14:01:37 +00:00
Jay Foad
f4b14a2b0d
Use ArrayRef in ConstantFoldInstOperands and ConstantFoldCall.
...
llvm-svn: 135477
2011-07-19 13:32:40 +00:00
Andrew Trick
c43b67644c
Compiler warning.
...
llvm-svn: 135426
2011-07-18 21:15:03 +00:00
Andrew Trick
7da2417c8a
indvars: LinearFunctionTestReplace for non-canonical IVs.
...
For -disable-iv-rewrite, perform LFTR without generating a new
"canonical" induction variable. Instead find the "best" existing
induction variable for use in the loop exit test and compute the final
value of that IV for use in the new loop exit test. In short,
convert to a simple eq/ne exit test as long as it's cheap to do so.
llvm-svn: 135420
2011-07-18 20:32:31 +00:00
Andrew Trick
494c549ebd
indvars: Added verification that LFTR and other indvars goodness does
...
not interfere with BackedgeTakenCount computation.
llvm-svn: 135412
2011-07-18 18:44:20 +00:00
Andrew Trick
a27d8b183a
indvars: Added isHighCostExpansion. Avoid generating extra ops in the
...
preheader for the sole purpose of LFTR, since LFTR itself is usually not
a clear optimization.
llvm-svn: 135409
2011-07-18 18:21:35 +00:00
Frits van Bommel
717d7edd3e
Migrate LLVM and Clang to use the new makeArrayRef(...) functions where previously explicit non-default constructors were used.
...
Mostly mechanical with some manual reformatting.
llvm-svn: 135390
2011-07-18 12:00:32 +00:00
Chris Lattner
229907cd11
land David Blaikie's patch to de-constify Type, with a few tweaks.
...
llvm-svn: 135375
2011-07-18 04:54:35 +00:00
Chris Lattner
7b70bef7c8
fix a warning in TinyPtrVector, adopt it in SSAUpdater, saving some
...
mallocs.
llvm-svn: 135366
2011-07-18 01:43:58 +00:00
Andrew Trick
c591f3afc3
indvars: fix a pass-sensitivity issue that would hit the SCEVExpander
...
assertion I added in r135333. Check for the existence of a preheader
before expanding a recurrence.
llvm-svn: 135335
2011-07-16 01:18:53 +00:00
Andrew Trick
9ea55dc2d6
indvars: remove ExprToIVMap because it won't be needed by LFTR.
...
llvm-svn: 135334
2011-07-16 01:06:48 +00:00
Chris Lattner
8b4cf5e8a2
fix rdar://9776316 - type remapping needed for inline asm blobs,
...
fixing some objc llvm-test crashes with LTO.
llvm-svn: 135324
2011-07-15 23:18:40 +00:00
Chad Rosier
a7ff54351a
Disable loop idiom recognition of memset/memcpy if the function being compiled
...
is named after a common idiom (i.e., memset/memcpy). Otherwise, we can run into
infinite recursion. Ideally, the user should use the correct -fno-builtin flag,
but in case they don't we should play nicely.
rdar://9763412
llvm-svn: 135286
2011-07-15 18:25:04 +00:00
Frits van Bommel
bbe46f28b1
No need to explicitly invoke the ArrayRef constructor here.
...
llvm-svn: 135281
2011-07-15 17:13:23 +00:00