Duncan Sands [Wed, 11 Mar 2009 09:04:34 +0000 (09:04 +0000)]
Add parentheses to pacify gcc-4.3.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66653
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Wed, 11 Mar 2009 08:08:06 +0000 (08:08 +0000)]
Remove the one-definition-rule version of extern_weak
linkage: this linkage type only applies to declarations,
but ODR is only relevant to globals with definitions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66650
91177308-0d34-0410-b5e6-
96231b3b80d8
Nate Begeman [Wed, 11 Mar 2009 07:03:43 +0000 (07:03 +0000)]
Allow cross-process JIT to handle MachineRelocations of the ExternalSymbol
variety. For example, an i64 div might turn into a call to __divdi3 during
legalization.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66646
91177308-0d34-0410-b5e6-
96231b3b80d8
Mon P Wang [Wed, 11 Mar 2009 06:35:11 +0000 (06:35 +0000)]
Fixed a v8i16 shuffle case that should generate a pshufb instead of a pshuflw/hw.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66645
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 11 Mar 2009 05:48:52 +0000 (05:48 +0000)]
formatting change, reduce indentation. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66642
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Wed, 11 Mar 2009 05:08:08 +0000 (05:08 +0000)]
reapply my previous patch (r66358) with a tweak to set the
alignment of the generated constant pool entry to the
desired alignment of a type. If we don't do this, we end up
trying to do movsd from 4-byte alignment memory. This fixes
450.soplex and 456.hmmer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66641
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Wed, 11 Mar 2009 00:03:50 +0000 (00:03 +0000)]
Put the assignment back at the top of this method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66611
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Wed, 11 Mar 2009 00:03:21 +0000 (00:03 +0000)]
Two coalescer fixes in one.
1. Use the same value# to represent unknown values being merged into sub-registers.
2. When coalescer commute an instruction and the destination is a physical register, update its sub-registers by merging in the extended ranges.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66610
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 23:57:09 +0000 (23:57 +0000)]
Make ivars private. Other cleanup. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66607
91177308-0d34-0410-b5e6-
96231b3b80d8
Mon P Wang [Tue, 10 Mar 2009 23:48:49 +0000 (23:48 +0000)]
Changed Allocate to use size_t instead of unsigned.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66602
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 10 Mar 2009 23:10:46 +0000 (23:10 +0000)]
Add an explicit keyword.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66595
91177308-0d34-0410-b5e6-
96231b3b80d8
Mon P Wang [Tue, 10 Mar 2009 23:04:40 +0000 (23:04 +0000)]
Fixed rounding up EltSize
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66594
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Tue, 10 Mar 2009 23:02:13 +0000 (23:02 +0000)]
Give Op<N>() AppleScript-like semantics, i.e. for negative N it indexes relative to op_end.
This is a preliminary to changes to come. No intended functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66593
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 22:58:53 +0000 (22:58 +0000)]
Just make the Dwarf timer group static inside of the getter function. No need to alloc/dealloc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66591
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 22:36:31 +0000 (22:36 +0000)]
Don't put static functions in anonymous namespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66589
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Tue, 10 Mar 2009 22:20:02 +0000 (22:20 +0000)]
Don't consider debug intrinsics when checking
whether a callee to be inlined is a leaf.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66588
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 22:02:13 +0000 (22:02 +0000)]
These should *stop* the timer, not start it again.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66586
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 21:59:25 +0000 (21:59 +0000)]
- Fix misspelled method name.
- Remove unused method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66585
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 21:47:45 +0000 (21:47 +0000)]
- Create GetOrCreateSourceID from getOrCreateSourceID. GetOrCreateSourceID is
the untimed version of getOrCreateSourceID. getOrCreateSourceID calls
GetOrCreateSourceID, of course.
- Move some methods into the "private" section. Constify at least one method.
- General clean-ups.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66582
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 21:31:00 +0000 (21:31 +0000)]
Readd test, but XFAIL it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66581
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 21:23:25 +0000 (21:23 +0000)]
Refine the Dwarf writer timers so that they measure exception writing and debug
writing individually.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66577
91177308-0d34-0410-b5e6-
96231b3b80d8
Dale Johannesen [Tue, 10 Mar 2009 21:19:49 +0000 (21:19 +0000)]
Removing a dead debug intrinsic shouldn't trigger
another instcombine pass if we weren't going to make
one without debug info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66576
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Tue, 10 Mar 2009 20:47:18 +0000 (20:47 +0000)]
Revert 66358 for now. It's breaking povray, 450.soplex, and 456.hmmer on x86 / Darwin.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66574
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 20:41:52 +0000 (20:41 +0000)]
Add a timer to the DwarfWriter pass that measures the total time it takes to
emit exception and debug Dwarf info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66571
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 10 Mar 2009 19:33:13 +0000 (19:33 +0000)]
Add -disable-bindings for utils/NewNightlyTest.pl
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66566
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 10 Mar 2009 19:01:23 +0000 (19:01 +0000)]
Change these sed lines to behave correctly when the input string
contains commas. This fixes PR3727.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66565
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 10 Mar 2009 18:47:59 +0000 (18:47 +0000)]
Use WriteAsOperand instead of manually decorating the name for this
debug output. This improves the printing of anonymous values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66561
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 10 Mar 2009 18:10:43 +0000 (18:10 +0000)]
Fix a post-RA scheduling liveness bug. When a basic block is being
scheduled in multiple regions, liveness data used by the
anti-dependence breaker is carried from one region to the next, however
the information reflects the state of the instructions before scheduling.
After scheduling, there may be new live range overlaps. Handle this by
pessimizing the liveness data carried between regions to the point where
it will be conservatively correct now matter how the earlier region is
scheduled. This fixes a miscompilation in 176.gcc with the post-RA
scheduler enabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66558
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Tue, 10 Mar 2009 18:00:05 +0000 (18:00 +0000)]
Ignore dbg info, while estimating size of jump through block.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66554
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Tue, 10 Mar 2009 17:58:54 +0000 (17:58 +0000)]
Fix rebuilding after a .td file is modified. This was broken since revision
65834.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66553
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 10 Mar 2009 17:15:56 +0000 (17:15 +0000)]
don't pass -Wl,-exported_symbol -Wl,_main to the linker when building on
Tiger. PR3743
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66550
91177308-0d34-0410-b5e6-
96231b3b80d8
Stuart Hastings [Tue, 10 Mar 2009 16:44:45 +0000 (16:44 +0000)]
Tweak the DejaGNU voodoo to match Bill's advice.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66547
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 10 Mar 2009 16:21:55 +0000 (16:21 +0000)]
PR3478: raw_ostream should not buffer stderr
- Add unbuffered flag to raw_ostream, forwarded by raw_fd_ostream and
used by raw_stderr_ostream.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66545
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Dunbar [Tue, 10 Mar 2009 15:56:48 +0000 (15:56 +0000)]
Add C++ marker.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66543
91177308-0d34-0410-b5e6-
96231b3b80d8
John Criswell [Tue, 10 Mar 2009 15:04:53 +0000 (15:04 +0000)]
Do not attempt to do parial redundancy elimination on void values.
Also fixed a punctuation error in the header comment.
This fixes PR3775.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66542
91177308-0d34-0410-b5e6-
96231b3b80d8
Torok Edwin [Tue, 10 Mar 2009 13:41:26 +0000 (13:41 +0000)]
Global variables don't have a corresponding llvm.dbg.declare, yet it is possible
to obtain debug info about them.
Introduce helpers to access debug info for global variables. Also introduce a
helper that works for both local and global variables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66541
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjiv Gupta [Tue, 10 Mar 2009 10:35:34 +0000 (10:35 +0000)]
Mark the Defs and Uses of STATUS register correctly, plus some reformatting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66540
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Tue, 10 Mar 2009 07:57:50 +0000 (07:57 +0000)]
If a function is marked alwaysinline, it must be inlined (possibly for correctness). Do so even if the callee has dynamic alloca and the caller doesn't.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66539
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Tue, 10 Mar 2009 06:53:54 +0000 (06:53 +0000)]
Add radar number.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66534
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Tue, 10 Mar 2009 05:37:13 +0000 (05:37 +0000)]
wire up support for emitting "special" values from inline asm
format strings with the standard ${:foo} syntax.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66527
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Tue, 10 Mar 2009 00:26:23 +0000 (00:26 +0000)]
Add more information to the EFLAGS note.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66515
91177308-0d34-0410-b5e6-
96231b3b80d8
Stuart Hastings [Tue, 10 Mar 2009 00:17:39 +0000 (00:17 +0000)]
Check for warnings about inappropriate weak_imports.
Darwin-specific; marked XFAIL for others.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66514
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 23:47:02 +0000 (23:47 +0000)]
Add a note about EFLAGS optimization.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66508
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Mon, 9 Mar 2009 23:04:12 +0000 (23:04 +0000)]
Ignore debug info while evaluating function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66490
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 22:04:01 +0000 (22:04 +0000)]
Don't record the increment instruction; just recompute it from the Phi
if needed. This simplifies the code a little, and is needed for an
upcoming refactoring.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66479
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 21:34:10 +0000 (21:34 +0000)]
Fix PR3724 by searching for the largest free block when
allocating memory in the JIT. This is insanely inefficient, but
hey, most people implement their own memory managers anyway.
Patch by Eric Yew!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66472
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Mon, 9 Mar 2009 21:32:28 +0000 (21:32 +0000)]
Remove llvm.dbg.global_variables also.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66471
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 21:22:12 +0000 (21:22 +0000)]
Fix a few more places where induction variable types were used
where memory access types are needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66470
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 21:19:58 +0000 (21:19 +0000)]
Use ReplacedTy instead of recomputing the same value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66469
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 21:14:16 +0000 (21:14 +0000)]
Use LoopInfo's getLoopLatch() instead of doing what it does manualy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66467
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 21:04:19 +0000 (21:04 +0000)]
Don't use an induction variable type as a memory access type.
Use VoidTy instead, to be properly conservative.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66463
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 21:01:17 +0000 (21:01 +0000)]
Factor out the code that determines the memory access type
of an instruction into a helper function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66460
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 20:55:18 +0000 (20:55 +0000)]
Clarify wording, patch by Stefanus Du Toit!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66458
91177308-0d34-0410-b5e6-
96231b3b80d8
Devang Patel [Mon, 9 Mar 2009 20:49:37 +0000 (20:49 +0000)]
Add helper pass to remove llvm.dbg.declare intrinsics.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66454
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 20:46:50 +0000 (20:46 +0000)]
Move the sorting of the StrideOrder array earlier so that it doesn't
have to be done twice.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66449
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 20:41:15 +0000 (20:41 +0000)]
Delete the isOnlyStride argument, which is unused.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66446
91177308-0d34-0410-b5e6-
96231b3b80d8
Dan Gohman [Mon, 9 Mar 2009 20:34:59 +0000 (20:34 +0000)]
Tidy some LSR debug output: announce the loop it's about to process
before it does any processing.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66443
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 9 Mar 2009 20:25:39 +0000 (20:25 +0000)]
ARM target now also recognize triplets like thumbv6-apple-darwin and set thumb mode and arch subversion. Eventually thumb triplets will go way and replaced with function notes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66435
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 20:22:18 +0000 (20:22 +0000)]
Fix PR3763 by using proper APInt methods instead of uint64_t's.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66434
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Mon, 9 Mar 2009 19:57:49 +0000 (19:57 +0000)]
make the Op<N> methods protected, how it was intended to be
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66430
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 9 Mar 2009 19:15:00 +0000 (19:15 +0000)]
ARM isLegalAddressImmediate should check if type is a simple type now that optimizer can create values of funky scalar types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66429
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 9 Mar 2009 19:00:05 +0000 (19:00 +0000)]
Yet another case where the spiller marked two uses of the same register on the same instruction as kill. This fixes PR3706.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66428
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Mon, 9 Mar 2009 18:28:37 +0000 (18:28 +0000)]
Re-apply 66315, but restrict it to Darwin only.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66427
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 9 Mar 2009 18:01:33 +0000 (18:01 +0000)]
Revert r66415. It's causing failures during bootstrap builds:
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://developer.apple.com/bugreporter> for instructions.
/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmgcc42.roots/llvmgcc42~obj/src/gcc/libgcc2.c: In function '__muldi3':
/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmgcc42.roots/llvmgcc42~obj/src/gcc/libgcc2.c:567: internal compiler error: Bus error
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://developer.apple.com/bugreporter> for instructions.
/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmgcc42.roots/llvmgcc42~obj/src/gcc/libgcc2.c: In function '__lshrdi3':
/Volumes/Sandbox/Buildbot/llvm/full-llvm/build/llvmgcc42.roots/llvmgcc42~obj/src/gcc/libgcc2.c:421: internal compiler error: Bus error
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://developer.apple.com/bugreporter> for instructions.
make[5]: *** [libgcc/./_lshrdi3.o] Error 1
make[5]: *** Waiting for unfinished jobs....
make[5]: *** [libgcc/./_muldi3.o] Error 1
make[5]: *** [libgcc/./_negdi2.o] Error 1
--- Reverse-merging (from foreign repository) r66415 into '.':
U include/llvm/BasicBlock.h
U include/llvm/ADT/ilist_node.h
U include/llvm/CodeGen/SelectionDAG.h
U include/llvm/CodeGen/MachineFunction.h
U include/llvm/CodeGen/MachineBasicBlock.h
U include/llvm/Function.h
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66426
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Wilson [Mon, 9 Mar 2009 17:07:15 +0000 (17:07 +0000)]
Add a constructor for BuildVectorSDNode and revert the temporary workaround
from 66280. I was unable to verify this with gcc-3.4.6, but with gcc-3.3 it
avoids the "base class with only non-default constructor in class without
a constructor" warning. Apparently that warning was promoted to an error
in gcc-3.4.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66424
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Mon, 9 Mar 2009 11:57:08 +0000 (11:57 +0000)]
This debug info special case should no longer
be needed now that these intrinsics are marked
as not accessing memory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66420
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 08:18:48 +0000 (08:18 +0000)]
just remove the use_empty() check entirely, the only reason it
existed was for llvm-gcc 3.4 (which used the __main hack) which
is really really long dead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66417
91177308-0d34-0410-b5e6-
96231b3b80d8
Gabor Greif [Mon, 9 Mar 2009 07:09:01 +0000 (07:09 +0000)]
in builds without asserts we do not need to allocate the Next pointer in "ghostly" sentinels
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66415
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Mon, 9 Mar 2009 06:16:46 +0000 (06:16 +0000)]
Regenerate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66407
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Mon, 9 Mar 2009 06:16:26 +0000 (06:16 +0000)]
Remove configurey-fu to autodetect hash_map and hash_set now that they are
no longer used in LLVM.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66406
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 05:52:15 +0000 (05:52 +0000)]
Make the code generator rip of dead constant expr uses before deciding
whether a global is dead or not. This should fix PR3749 - linker adds
spurious use to appending globals. I can't reasonably add a testcase
for this, because the bc writer/reader strip dead constant users.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66404
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 05:50:45 +0000 (05:50 +0000)]
make GlobalValue::removeDeadConstantUsers() const.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66403
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 05:44:59 +0000 (05:44 +0000)]
testcase for PR3744
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66401
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 05:20:45 +0000 (05:20 +0000)]
don't allow hash_map or hash_set.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66400
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Mon, 9 Mar 2009 05:12:38 +0000 (05:12 +0000)]
Ignore debug intrinsics when computing dependences.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66399
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 05:11:09 +0000 (05:11 +0000)]
reimplement AliasSetTracker in terms of DenseMap instead of hash_map,
hopefully no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66398
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 05:10:08 +0000 (05:10 +0000)]
add a #include to improve portability to windows, as requested by
someone on llvmdev.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66397
91177308-0d34-0410-b5e6-
96231b3b80d8
Bill Wendling [Mon, 9 Mar 2009 05:04:40 +0000 (05:04 +0000)]
Pass in a std::string when getting the names of debugging things. This cuts down
on the number of times a std::string is created and copied.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66396
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 04:56:22 +0000 (04:56 +0000)]
fix Analysis/BasicAA/2004-12-08-BasicAACrash.ll by allowing opaque types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66395
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 04:49:14 +0000 (04:49 +0000)]
Fix two classes of bugs. First:
validate an invariant so that the asmparser rejects a bad construct
instead of the verifier. Before:
llvm-as: assembly parsed, but does not verify as correct!
Invalid struct return type!
i64 (%struct.Type*, %struct.Type*)* @foo
after:
llvm-as: t.ll:5:8: functions with 'sret' argument must return void
define i64 @foo(%struct.Type* noalias nocapture sret %agg.result, %struct.Type* nocapture byval %t) nounwind {
^
Second, check that void is only used where allowed (in function return types) not in
arbitrary places, fixing PR3747 - Crash in llvm-as with void field in struct. We
now reject that example with:
$ llvm-as t.ll
llvm-as: t.ll:1:12: struct element can not have void type
%x = type {void}
^
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66394
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 04:46:40 +0000 (04:46 +0000)]
Fix PR3746 - Crash in isel with GEP of function pointer
by checking that the top-level type of a gep is sized. This
causes us to reject the example with:
llvm-as: t2.ll:2:16: invalid getelementptr indices
getelementptr i32()* null, i32 1
^
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66393
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Mon, 9 Mar 2009 04:45:03 +0000 (04:45 +0000)]
Fix PR3743 - -mmacosx-version-min inappropriate for Mac OS X 10.4.11,
by stripping off any versions past the "10.4".
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66392
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 19:13:45 +0000 (19:13 +0000)]
add some explicit llvm:: qualifiers to the unix side, fix problems on the windows side.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66386
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 8 Mar 2009 19:02:17 +0000 (19:02 +0000)]
Keep calling-convention and tail-call bit when creating new invoke or call.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66384
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 18:44:31 +0000 (18:44 +0000)]
do not export all the X86FastISel symbols, ever.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66382
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 8 Mar 2009 17:08:09 +0000 (17:08 +0000)]
Fix comments, pointed out by Duncan Sands.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66381
91177308-0d34-0410-b5e6-
96231b3b80d8
Duncan Sands [Sun, 8 Mar 2009 13:35:23 +0000 (13:35 +0000)]
Apply ODR linkage changes accidentally dropped during
final cleaning. This fixes a bunch of testsuite failures.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66380
91177308-0d34-0410-b5e6-
96231b3b80d8
Sebastian Redl [Sun, 8 Mar 2009 11:43:20 +0000 (11:43 +0000)]
Test commit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66378
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sun, 8 Mar 2009 06:20:47 +0000 (06:20 +0000)]
Mark function returns as noalias.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66369
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 04:17:04 +0000 (04:17 +0000)]
teach SROA to handle promoting vector allocas with a memset into them into
a vector type instead of into an integer type.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66368
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 04:06:26 +0000 (04:06 +0000)]
fix typo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66367
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 04:04:21 +0000 (04:04 +0000)]
Enhance SROA to "promote to scalar" allocas which are
memcpy/memmove'd into or out of. This fixes a serious
perf issue that Nate ran into.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66366
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Sun, 8 Mar 2009 04:02:49 +0000 (04:02 +0000)]
Recognize triplets starting with armv5-, armv6- etc. And set the ARM arch version accordingly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66365
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 03:59:00 +0000 (03:59 +0000)]
change the MemIntrinsic get/setAlignment method to take an unsigned
instead of a Constant*, which is what the clients of it really want.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66364
91177308-0d34-0410-b5e6-
96231b3b80d8
Evan Cheng [Sun, 8 Mar 2009 03:58:35 +0000 (03:58 +0000)]
If a MI uses the same register more than once, only mark one of them as 'kill'.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66363
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 03:37:35 +0000 (03:37 +0000)]
use MemTransferInst.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66362
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 03:37:16 +0000 (03:37 +0000)]
Introduce a new MemTransferInst pseudo class, which is a common
parent between MemCpyInst and MemMoveInst, simplify some code to
use it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66361
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 03:04:26 +0000 (03:04 +0000)]
add a note.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66360
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 01:54:43 +0000 (01:54 +0000)]
add a note.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66359
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Lattner [Sun, 8 Mar 2009 01:51:30 +0000 (01:51 +0000)]
implement an optimization to codegen c ? 1.0 : 2.0 as load { 2.0, 1.0 } + c*4.
For 2009-03-07-FPConstSelect.ll we now produce:
_f:
xorl %eax, %eax
testl %edi, %edi
movl $4, %ecx
cmovne %rax, %rcx
leaq LCPI1_0(%rip), %rax
movss (%rcx,%rax), %xmm0
ret
previously we produced:
_f:
subl $4, %esp
cmpl $0, 8(%esp)
movss LCPI1_0, %xmm0
je LBB1_2 ## entry
LBB1_1: ## entry
movss LCPI1_1, %xmm0
LBB1_2: ## entry
movss %xmm0, (%esp)
flds (%esp)
addl $4, %esp
ret
on PPC the code also improves to:
_f:
cntlzw r2, r3
srwi r2, r2, 5
li r3, lo16(LCPI1_0)
slwi r2, r2, 2
addis r3, r3, ha16(LCPI1_0)
lfsx f1, r3, r2
blr
from:
_f:
li r2, lo16(LCPI1_1)
cmplwi cr0, r3, 0
addis r2, r2, ha16(LCPI1_1)
beq cr0, LBB1_2 ; entry
LBB1_1: ; entry
li r2, lo16(LCPI1_0)
addis r2, r2, ha16(LCPI1_0)
LBB1_2: ; entry
lfs f1, 0(r2)
blr
This also improves the existing pic-cpool case from:
foo:
subl $12, %esp
call .Lllvm$1.$piclabel
.Lllvm$1.$piclabel:
popl %eax
addl $_GLOBAL_OFFSET_TABLE_ + [.-.Lllvm$1.$piclabel], %eax
cmpl $0, 16(%esp)
movsd .LCPI1_0@GOTOFF(%eax), %xmm0
je .LBB1_2 # entry
.LBB1_1: # entry
movsd .LCPI1_1@GOTOFF(%eax), %xmm0
.LBB1_2: # entry
movsd %xmm0, (%esp)
fldl (%esp)
addl $12, %esp
ret
to:
foo:
call .Lllvm$1.$piclabel
.Lllvm$1.$piclabel:
popl %eax
addl $_GLOBAL_OFFSET_TABLE_ + [.-.Lllvm$1.$piclabel], %eax
xorl %ecx, %ecx
cmpl $0, 4(%esp)
movl $8, %edx
cmovne %ecx, %edx
fldl .LCPI1_0@GOTOFF(%eax,%edx)
ret
This triggers a few dozen times in spec FP 2000.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@66358
91177308-0d34-0410-b5e6-
96231b3b80d8