Daniel Dunbar
06a1d9ddcf
Fix a -Wreorder warning.
...
llvm-svn: 110022
2010-08-02 05:43:46 +00:00
Nick Lewycky
747b2ba2b9
Work in progress.
...
Start cleaning up MergeFunctions to look more like the rest of LLVM. The
primary change here is to move the methods responsible for comparison into the
new FunctionComparator object. Some comments added. There's more to do.
llvm-svn: 110021
2010-08-02 05:23:03 +00:00
Eli Friedman
081daa15e1
PR7586: Make sure we don't claim that unknown bits are actually known in the
...
ISD::AND case of TargetLowering::SimplifyDemandedBits.
llvm-svn: 110019
2010-08-02 04:42:25 +00:00
Eli Friedman
40cb7d9994
PR7781: Fix incorrect shifting in PPCTargetLowering::LowerBUILD_VECTOR.
...
llvm-svn: 109998
2010-08-02 00:18:19 +00:00
Eli Friedman
3c5289c381
PR7774: Fix undefined shifts in Alpha backend. As a bonus, this actually
...
improves the generated code in some cases.
llvm-svn: 109985
2010-08-01 21:13:28 +00:00
Benjamin Kramer
1f47ed839d
Preallocate vector, avoid unnecessary vector growth.
...
llvm-svn: 109971
2010-08-01 11:43:26 +00:00
Bill Wendling
36376df573
Reference the personalities. Don't copy them into a new vector.
...
llvm-svn: 109966
2010-08-01 01:34:21 +00:00
Daniel Dunbar
e0737ebae3
Silence some -Asserts uninitialized variable warnings.
...
llvm-svn: 109956
2010-07-31 21:08:54 +00:00
Daniel Dunbar
f2be238c99
Speculatively revert r108614, "Another attempt at getting the clang self-host to
...
like my instcombine patch.", in an attempt to fix Clang i386 bootstrap.
- Also PR7719.
llvm-svn: 109953
2010-07-31 19:51:11 +00:00
Michael J. Spencer
1f89cc1fe5
MC: Remove HasAbsolutizedSet from WindowsX86AsmBackend.
...
llvm-svn: 109949
2010-07-31 07:21:44 +00:00
Bob Wilson
58c8a5da9e
Move newlines before inline jumptables from the asm strings in .td files to
...
the jtblock_operand print methods. This avoids extra newlines in the
disassembler's output. PR7757.
llvm-svn: 109948
2010-07-31 06:28:10 +00:00
Michael J. Spencer
b52ff1ba41
Add relax all support to the COFF object streamer.
...
llvm-svn: 109947
2010-07-31 06:22:29 +00:00
Bob Wilson
439e7b1d73
Add support for disassembling VMVN (immediate) instructions. PR7747.
...
llvm-svn: 109946
2010-07-31 05:57:44 +00:00
Rafael Espindola
75734bc143
The BlockExtractorPass() constructor was not reading the BlockFile and that was
...
exactly what bugpoint expected it to do.
There was also only one user of
BlockExtractorPass(const std::vector<BasicBlock*> &B), so just remove it and
make BlockExtractorPass read BlockFile.
This fixes bugpoint's block extraction.
Nick, please review.
llvm-svn: 109936
2010-07-31 00:32:17 +00:00
Owen Anderson
e1aed29cca
Add an initial implementation of PHI translation for LazyValueInfo. This involves rolling back some
...
of my earlier data structure improvements until I can ensure that there are no iterator invalidation problems.
llvm-svn: 109935
2010-07-30 23:59:40 +00:00
Evan Cheng
ee59acf6dd
Add -disable-shifter-op to disable isel of shifter ops. On Cortex-a9 the shifts cost extra instructions so it might be better to emit them separately to take advantage of dual-issues.
...
llvm-svn: 109934
2010-07-30 23:33:54 +00:00
Bob Wilson
6ce71251cc
Add a check in the ARM disassembler for NEON instructions that would
...
reference registers past the end of the NEON register file, and report them
as invalid instead of asserting when trying to print them. PR7746.
llvm-svn: 109933
2010-07-30 23:27:59 +00:00
Dale Johannesen
eb251be031
PPC doesn't supported VLA with large alignment. This was
...
formerly rejected by the FE, so asserted in the BE; now the FE only
warns, so we treat it as a legitimate fatal error in PPC BE.
This means the test for the feature won't pass, so it's xfail'd.
llvm-svn: 109892
2010-07-30 21:09:48 +00:00
Dan Gohman
230d92b375
Move MaximumAlignment to be a member of the Value class.
...
llvm-svn: 109891
2010-07-30 21:07:05 +00:00
Owen Anderson
4e6f48d705
Revert my last two patches to LVI, which recent changes have exposed a miscompilation in.
...
llvm-svn: 109889
2010-07-30 20:56:07 +00:00
Nick Lewycky
b6db4aaeaa
Add missing newline to debug statement.
...
llvm-svn: 109886
2010-07-30 20:27:01 +00:00
Bob Wilson
bd1dc153a5
Add the __TEXT,__StaticInit section to the list of sections emitted at the
...
beginning on ARM Darwin assembly files so that it won't be placed after
debug sections. Radar 8252813.
llvm-svn: 109879
2010-07-30 19:55:47 +00:00
Bruno Cardoso Lopes
0c0dd2173c
Support all 128-bit AVX vector intrinsics. Most part of them I already
...
declared during the addition of the assembler support, the additional
changes are:
- Add missing intrinsics
- Move all SSE conversion instructions in X86InstInfo64.td to the SSE.td file.
- Duplicate some patterns to AVX mode.
- Step into PCMPEST/PCMPIST custom inserter and add AVX versions.
llvm-svn: 109878
2010-07-30 19:54:33 +00:00
Bruno Cardoso Lopes
5d4afd0cb9
Fix typo!
...
llvm-svn: 109877
2010-07-30 19:41:24 +00:00
Daniel Dunbar
19ee08da53
MC: Initialize MCFragment::Offset, noticed by Cameron Esfahani.
...
llvm-svn: 109875
2010-07-30 18:32:09 +00:00
Daniel Dunbar
c97e760282
Fix -Wmissing-field-initializers warnings.
...
llvm-svn: 109872
2010-07-30 17:49:04 +00:00
Eli Friedman
bea7c851cf
Fix for bug reported by Evzen Muller on llvm-commits: make sure to correctly
...
check the range of the constant when optimizing a comparison between a
constant and a sign_extend_inreg node.
llvm-svn: 109854
2010-07-30 06:44:31 +00:00
Jim Grosbach
1718345a30
Many Thumb2 instructions can reference the full ARM register set (i.e.,
...
have 4 bits per register in the operand encoding), but have undefined
behavior when the operand value is 13 or 15 (SP and PC, respectively).
The trivial coalescer in linear scan sometimes will merge a copy from
SP into a subsequent instruction which uses the copy, and if that
instruction cannot legally reference SP, we get bad code such as:
mls r0,r9,r0,sp
instead of:
mov r2, sp
mls r0, r9, r0, r2
This patch adds a new register class for use by Thumb2 that excludes
the problematic registers (SP and PC) and is used instead of GPR
for those operands which cannot legally reference PC or SP. The
trivial coalescer explicitly requires that the register class
of the destination for the COPY instruction contain the source
register for the COPY to be considered for coalescing. This prevents
errant instructions like that above.
PR7499
llvm-svn: 109842
2010-07-30 02:41:01 +00:00
Nate Begeman
0b0f838c32
Add builtins for ssat/usat, similar to RealView's __ssat and __usat intrinsics.
...
llvm-svn: 109813
2010-07-29 22:48:09 +00:00
Bob Wilson
d70ec880ea
Refactor ARM-specific DAG combining in preparation for adding some more
...
transformations.
llvm-svn: 109800
2010-07-29 20:34:14 +00:00
Dale Johannesen
717fbb2b32
Implement vector constants which are splat of
...
integers with mov + vdup. 8003375. This is
currently disabled by default because LICM will
not hoist a VDUP, so it pessimizes the code if
the construct occurs inside a loop (8248029).
llvm-svn: 109799
2010-07-29 20:10:08 +00:00
Bob Wilson
823182c3e5
Don't assert on an unrecognized BrMiscFrm instruction.
...
PR7745.
llvm-svn: 109788
2010-07-29 18:29:28 +00:00
Eli Friedman
642f4c66c3
PR7750: !CExpr->isNullValue() only properly computes whether CExpr is nonnull
...
if CExpr is a ConstantInt.
llvm-svn: 109773
2010-07-29 18:03:33 +00:00
Nate Begeman
b24fa8b8ae
Add intrinsics __builtin_arm_qadd & __builtin_arm_qsub to allow access to the QADD & QSUB instructions.
...
Behave identically to __qadd & __qsub RealView instruction intrinsics.
llvm-svn: 109770
2010-07-29 17:56:55 +00:00
Benjamin Kramer
d1340209a1
Plug the remaining MC leaks by giving MCObjectStreamer/MCAsmStreamer ownership of the TargetAsmBackend and the MCCodeEmitter.
...
llvm-svn: 109767
2010-07-29 17:48:06 +00:00
Dale Johannesen
71204e008b
Comment typo.
...
llvm-svn: 109765
2010-07-29 17:45:24 +00:00
Jakob Stoklund Olesen
1dee3913d6
Revert r109652, and remove the offending assert in loadRegFromStackSlot instead.
...
We do sometimes load from a too small stack slot when dealing with x86 arguments
(varargs and smaller-than-32-bit args). It looks like we know what we are doing
in those cases, so I am going to remove the assert instead of artifically
enlarging stack slot sizes.
The assert in storeRegToStackSlot stays in. We don't want to write beyond the
bounds of a stack slot.
llvm-svn: 109764
2010-07-29 17:42:27 +00:00
Daniel Dunbar
d516b0a1bd
CrashRecovery: Use ThreadLocal::erase() instead of set(0).
...
llvm-svn: 109752
2010-07-29 15:24:21 +00:00
Benjamin Kramer
85d8649a9c
Stop leaking std::strings in GetDwarfFile.
...
llvm-svn: 109746
2010-07-29 13:53:19 +00:00
Benjamin Kramer
20e27bc59b
COFFObjectWriter: Don't leak COFFSymbols and COFFSections.
...
llvm-svn: 109745
2010-07-29 11:57:59 +00:00
Daniel Dunbar
d62252d9f8
Make sure to include config.h, to pickup LLVM_ON_WIN32.
...
llvm-svn: 109721
2010-07-29 01:52:04 +00:00
Daniel Dunbar
7972ac4c88
MC: Destroy Macro instances.
...
llvm-svn: 109720
2010-07-29 01:51:55 +00:00
Eric Christopher
6a1da7b4a5
Speculatively revert r109705 since it seems to be causing some build bot
...
angst.
llvm-svn: 109718
2010-07-29 01:25:38 +00:00
Daniel Dunbar
a5b23b4df1
CrashRecoveryContext: Add a simple POSIX implementation.
...
- This works, but won't handle crashes on stack overflow, or signals delivered
to a thread other than the one that crashed. The latter is particular annoying
on Darwin, because SIGABRT tends to go to the main thread.
llvm-svn: 109717
2010-07-29 01:21:47 +00:00
Jakob Stoklund Olesen
7f337a8e64
Fix a bug in the -regalloc=fast handling of exotic two-address instruction with
...
multiple defs, like t2LDRSB_POST.
The first def could accidentally steal the physreg that the second, tied def was
required to be allocated to.
Now, the tied use-def is treated more like an early clobber, and the physreg is
reserved before allocating the other defs.
This would never be a problem when the tied def was the only def which is the
usual case.
This fixes MallocBench/gs for thumb2 -O0.
llvm-svn: 109715
2010-07-29 00:52:19 +00:00
Dan Gohman
ea1486b53c
Factor out some of the code for updating old SCEVUnknown values, and
...
extend it to handle the case where multiple RAUWs affect a single
SCEVUnknown.
Add a ScalarEvolution unittest to test for this situation.
llvm-svn: 109705
2010-07-29 00:17:55 +00:00
Owen Anderson
712152a68e
Pass the queried value by argument rather than in a member, in preparation for supporting PHI translation.
...
llvm-svn: 109701
2010-07-28 23:50:08 +00:00
Jim Grosbach
8764c0127d
ARM mode version of r109693. Remove incorrect substitution pattern for UXTB16. It wrongly assumed the input shift was actually a rotate. rdar://8240138
...
llvm-svn: 109696
2010-07-28 23:25:44 +00:00
Jim Grosbach
17bec0f609
Remove incorrect substitution pattern for UXTB16. It wrongly assumed the input shift was actually a rotate. rdar://8240138
...
llvm-svn: 109693
2010-07-28 23:17:45 +00:00
Jim Grosbach
03b130774b
Remove dead prototype
...
llvm-svn: 109691
2010-07-28 23:16:12 +00:00
Gabor Greif
0899f01287
simplify by using CallSite constructors; virtually eliminates CallSite::get from the tree
...
llvm-svn: 109687
2010-07-28 22:50:26 +00:00
Owen Anderson
8769f9a8dd
Add an erase() method to llvm::ThreadLocal.
...
llvm-svn: 109686
2010-07-28 22:49:43 +00:00
Owen Anderson
670fd343a5
Get rid of LVIQuery as a distinct data structure, so that we don't have to initialize a new set of maps on every query.
...
llvm-svn: 109679
2010-07-28 22:07:25 +00:00
Dan Gohman
343e4fb4ea
Make GlobalValue alignment consistent with load, store, and alloca
...
alignment, fixing silent truncation of alignment values.
llvm-svn: 109653
2010-07-28 20:56:48 +00:00
Jakob Stoklund Olesen
d4c60eed5e
Create a fixed stack object for varargs that is as large as any register.
...
The size of this object isn't used for anything - technically it is of variable
size.
This avoids a false positive from the assert in
X86InstrInfo::loadRegFromStackSlot, and fixes PR7735.
llvm-svn: 109652
2010-07-28 20:55:38 +00:00
Kevin Enderby
3f202e65e8
Added first bit of support for the dwarf .file directive. This patch collects
...
the info from the .file directive and makes file and directory tables that
will eventually be put out as part of the dwarf info in the output file.
llvm-svn: 109651
2010-07-28 20:55:35 +00:00
Daniel Dunbar
111cf008aa
RegionInfo: Make sure to free cached nodes; Tobias, please check!
...
llvm-svn: 109650
2010-07-28 20:28:50 +00:00
Daniel Dunbar
1c35389c03
MC: Put back the MCFragment vtable, so subclasses are destroyed properly (duh).
...
llvm-svn: 109649
2010-07-28 20:28:45 +00:00
Dan Gohman
939744be5f
Define a maximum supported alignment value for load, store, and
...
alloca instructions (constrained by their internal encoding),
and add error checking for it. Fix an instcombine bug which
generated huge alignment values (null is infinitely aligned).
This fixes undefined behavior noticed by John Regehr.
llvm-svn: 109643
2010-07-28 20:12:04 +00:00
Jakob Stoklund Olesen
7ac201b2e3
Print out the regclass of any virtual registers used by a machine instruction.
...
llvm-svn: 109608
2010-07-28 18:35:46 +00:00
Douglas Gregor
4e0ad2b35b
Unbreak my CMake build, say you'll compile for me again...
...
llvm-svn: 109598
2010-07-28 17:17:46 +00:00
Dan Gohman
a4186ab5f0
Fix this code to avoid decrementing an iterator past the beginning
...
of a std::vector.
llvm-svn: 109597
2010-07-28 17:15:36 +00:00
Dan Gohman
5295c21189
When user code intentionally dereferences null, the alignment of the
...
dereference is theoretically infinite. Put a cap on the computed
alignment to avoid overflow, noticed by John Regehr.
llvm-svn: 109596
2010-07-28 17:14:23 +00:00
Dan Gohman
041bd99662
Do GEP offset calculations with unsigned math rather than signed math
...
to avoid undefined behavior on overflow, noticed by John Regehr.
llvm-svn: 109594
2010-07-28 17:11:36 +00:00
Gabor Greif
ecd9b45b05
simplify
...
llvm-svn: 109589
2010-07-28 15:52:43 +00:00
Daniel Dunbar
4cf25fa76a
Support: Add CrashRecoveryContext helper object.
...
- Designed as a simple wrapper to allow clients to attempt to catch crashes
(memory errors, assertion violations, etc.) and do some kind of recovery.
- Currently doesn't actually attempt to catch crashes.
llvm-svn: 109586
2010-07-28 15:40:20 +00:00
Gabor Greif
4909c0a1f1
simplify
...
llvm-svn: 109585
2010-07-28 15:31:37 +00:00
Gabor Greif
16a98fddef
use Value* constructor of CallSite to create potentially improper site, and test that
...
llvm-svn: 109581
2010-07-28 14:28:18 +00:00
Gabor Greif
9bb43864b1
use Value* constructor of CallSite to create potentially improper site, and test that
...
llvm-svn: 109580
2010-07-28 12:35:54 +00:00
Gabor Greif
f6966fafe3
use Value* constructor of CallSite to create potentially improper site
...
llvm-svn: 109579
2010-07-28 12:19:46 +00:00
Gabor Greif
e27a194ce5
simplify
...
llvm-svn: 109578
2010-07-28 10:57:28 +00:00
Gabor Greif
6dc7dec8c1
simplify
...
llvm-svn: 109577
2010-07-28 10:46:09 +00:00
Dan Gohman
2bea1e1572
Make SCEVCallbackVH::allUsesReplacedWith update the old SCEVUnknown
...
object, as it may still be referenced by SCEVs not cleaned up by the
use list traversal.
Also, in ScalarEvolution::forgetValue, only check for a SCEVUnknown
object for the original value, not for any value in the use list,
because other SCEVUnknown values aren't necessary obsolete at that
point.
llvm-svn: 109570
2010-07-28 01:09:07 +00:00
Dan Gohman
9a6ea54d94
Make SCEVCallbackVH::allUsesReplacedWith unconditionally delete
...
the old value.
llvm-svn: 109567
2010-07-28 00:28:25 +00:00
Nate Begeman
133820e806
Implement a vectorized algorithm for <16 x i8> << <16 x i8>
...
This is about 4x faster and smaller than the existing scalarization.
llvm-svn: 109566
2010-07-28 00:21:48 +00:00
Owen Anderson
2d39891e91
Rearrange several datastructures in LazyValueInfo to improve compile time.
...
This is still not perfect, but better than it was before.
llvm-svn: 109563
2010-07-27 23:58:11 +00:00
Gabor Greif
ec0c7b2427
reintroduce original (asserting) semantics of CallSite(Instruction *II)
...
add instead a CallSite(Value* V) constructor that is consistent with ImmutableCallSize
and use that one in client code
llvm-svn: 109553
2010-07-27 22:53:28 +00:00
Nate Begeman
068e932975
~40% faster vector shl <4 x i32> on SSE 4.1 Larger improvements for smaller types coming in future patches.
...
For:
define <2 x i64> @shl(<4 x i32> %r, <4 x i32> %a) nounwind readnone ssp {
entry:
%shl = shl <4 x i32> %r, %a ; <<4 x i32>> [#uses=1]
%tmp2 = bitcast <4 x i32> %shl to <2 x i64> ; <<2 x i64>> [#uses=1]
ret <2 x i64> %tmp2
}
We get:
_shl: ## @shl
pslld $23, %xmm1
paddd LCPI0_0, %xmm1
cvttps2dq %xmm1, %xmm1
pmulld %xmm1, %xmm0
ret
Instead of:
_shl: ## @shl
pshufd $3, %xmm0, %xmm2
movd %xmm2, %eax
pshufd $3, %xmm1, %xmm2
movd %xmm2, %ecx
shll %cl, %eax
movd %eax, %xmm2
pshufd $1, %xmm0, %xmm3
movd %xmm3, %eax
pshufd $1, %xmm1, %xmm3
movd %xmm3, %ecx
shll %cl, %eax
movd %eax, %xmm3
punpckldq %xmm2, %xmm3
movd %xmm0, %eax
movd %xmm1, %ecx
shll %cl, %eax
movd %eax, %xmm2
movhlps %xmm0, %xmm0
movd %xmm0, %eax
movhlps %xmm1, %xmm1
movd %xmm1, %ecx
shll %cl, %eax
movd %eax, %xmm0
punpckldq %xmm0, %xmm2
movdqa %xmm2, %xmm0
punpckldq %xmm3, %xmm0
ret
llvm-svn: 109549
2010-07-27 22:37:06 +00:00
Gabor Greif
8c197e5dbb
recommit simplification (originally r109504, backed out in r109508) now that problem in CallSiteBase is fixed
...
llvm-svn: 109547
2010-07-27 22:02:00 +00:00
Devang Patel
38a7221118
It is FE's responsibility to emit proper directory name.
...
llvm-svn: 109538
2010-07-27 20:51:15 +00:00
Jim Grosbach
2f4adcee5f
Grammar
...
llvm-svn: 109525
2010-07-27 18:36:27 +00:00
Nate Begeman
15fe179ecb
Fix a crash in the dag combiner caused by ConstantFoldBIT_CONVERTofBUILD_VECTOR calling itself
...
recursively and returning a SCALAR_TO_VECTOR node, but assuming the input was always a BUILD_VECTOR.
llvm-svn: 109519
2010-07-27 18:02:18 +00:00
Jim Grosbach
4d81e796cb
80 column
...
llvm-svn: 109513
2010-07-27 17:38:47 +00:00
Jim Grosbach
7e561eb81c
fix typo
...
llvm-svn: 109511
2010-07-27 17:14:29 +00:00
Gabor Greif
2778a21978
recommit simplification (r109502, backed out r109509); seems to innocent
...
llvm-svn: 109510
2010-07-27 16:44:23 +00:00
Gabor Greif
c95e84ab61
back out this too to restore the bots
...
llvm-svn: 109509
2010-07-27 15:56:07 +00:00
Gabor Greif
981f3d3a31
back out r109504, breaks the bots
...
llvm-svn: 109508
2010-07-27 15:18:11 +00:00
Gabor Greif
394841cea8
simplify: CallSite::get --> CallSite constructor
...
llvm-svn: 109506
2010-07-27 15:02:37 +00:00
Gabor Greif
90a627cfaa
simplify
...
llvm-svn: 109504
2010-07-27 14:38:38 +00:00
Gabor Greif
aaf68e2e5a
use ImmutableCallSite for const-corrgoodness
...
llvm-svn: 109503
2010-07-27 14:15:29 +00:00
Gabor Greif
ee90e05139
simplify
...
llvm-svn: 109502
2010-07-27 13:31:22 +00:00
Mikhail Glushenkov
61338a536b
Fix silent failure with no input files.
...
llvm-svn: 109500
2010-07-27 11:19:40 +00:00
Mikhail Glushenkov
33c561c22c
Return -1 only on failure to execute a program.
...
Also fix some comments.
llvm-svn: 109499
2010-07-27 11:19:36 +00:00
Tobias Grosser
ebc6c0cf50
RegionInfo: Add getMaxRegionExit()
...
getMaxRegionExit returns the exit of the maximal refined region starting
at a specific basic block.
llvm-svn: 109496
2010-07-27 08:39:43 +00:00
Duncan Sands
816457c7f3
After updating value handles for RAUW, check that no weak or tracking handles
...
are still on the list. This might happen if a CallbackVH created some new value
handles for the old value when doing RAUW. Barf if it occurs, since it is almost
certainly a mistake.
llvm-svn: 109495
2010-07-27 06:53:14 +00:00
Michael J. Spencer
33ac353ce4
Make MC use Windows COFF on Windows and add tests.
...
llvm-svn: 109494
2010-07-27 06:46:15 +00:00
Tobias Grosser
16789d79fe
Add function to query RegionInfo about loops.
...
* contains(Loop), * getOutermostLoop()
* Improve getNameStr() to return a sensible name, if basic blocks are not named.
llvm-svn: 109490
2010-07-27 04:17:13 +00:00
Jakob Stoklund Olesen
b056152ccf
The isLoadFromStackSlot and isStoreToStackSlot have no way of reporting
...
subregister operands like this:
%reg1040:sub_32bit<def> = MOV32rm <fi#-2>, 1, %reg0, 0, %reg0, %reg1040<imp-def>; mem:LD4[FixedStack-2](align=8)
Make them return false when subreg operands are present. VirtRegRewriter is
making bad assumptions otherwise.
This fixes PR7713.
llvm-svn: 109489
2010-07-27 04:17:01 +00:00
Jakob Stoklund Olesen
fa4bcde9d9
Add assertions that expose the PR7713 miscompilation: Accessing a stack slot
...
with a too-big register class.
llvm-svn: 109488
2010-07-27 04:16:58 +00:00
Bill Wendling
bb2398331b
It's better to have the arrays, which would trigger the creation of stack
...
protectors, to be near the stack protectors on the stack. Accomplish this by
tagging the stack object with a predicate that indicates that it would trigger
this. In the prolog-epilog inserter, assign these objects to the stack after the
stack protector but before the other objects.
llvm-svn: 109481
2010-07-27 01:55:19 +00:00
Jakob Stoklund Olesen
2b379c4339
Add SplitEditor to SplitKit. This class will be used to edit live intervals and
...
rewrite instructions for live range splitting.
Still work in progress.
llvm-svn: 109469
2010-07-26 23:44:11 +00:00
Dan Gohman
64157c1919
Fix a use-after-free.
...
llvm-svn: 109468
2010-07-26 23:40:24 +00:00
Bill Wendling
efed27734e
Using llvm.eh.catch.all.value instead of .llvm.eh.catch.all.value.
...
llvm-svn: 109462
2010-07-26 22:36:52 +00:00
Eli Friedman
94c9f00dd6
And a bit more non-ASCII stuff.
...
llvm-svn: 109458
2010-07-26 22:28:18 +00:00
Anton Korobeynikov
b71ee4ebbb
Drop some non-ascii stuff
...
llvm-svn: 109456
2010-07-26 22:23:07 +00:00
Bob Wilson
73936af25b
Don't call __register_frame from the JIT on systems that use setjmp/longjmp
...
exception handling. Also fix an extra underscore typo in one instance of
"__ARM_EABI__". Radar 8236264.
llvm-svn: 109451
2010-07-26 21:58:00 +00:00
Evan Cheng
4cee8136a7
On x86, f32 / f64 nodes share the same registers as 128-bit vector values.
...
llvm-svn: 109450
2010-07-26 21:50:05 +00:00
Evan Cheng
e5f7eaf10c
The "excess register pressure" returned by HighRegPressure() is not accurate enough to factor into scheduling priority. Eliminate it and add early exits to speed up scheduling.
...
llvm-svn: 109449
2010-07-26 21:49:07 +00:00
Anton Korobeynikov
5e1e95aed9
Add a note
...
llvm-svn: 109448
2010-07-26 21:48:35 +00:00
Bruno Cardoso Lopes
cb0f921ca4
Temporary hack to let codegen assert or generate poor code in case
...
we are using AVX and no AVX version of the desired intruction is present,
this is better for incremental dev (without fallbacks it's easier to spot
what's missing). Not sure this is the best hack thought (we can also disable
all HasSSE* predicates by dinamically marking them 'false' if AVX is present)
llvm-svn: 109434
2010-07-26 21:01:18 +00:00
Owen Anderson
12ab6162bf
Add an initial implementation of LazyValueInfo updating for JumpThreading. Disabled for now.
...
llvm-svn: 109424
2010-07-26 18:48:03 +00:00
Anton Korobeynikov
5e3d50ec58
Currently EH lowering code expects typeinfo to be global only.
...
This assumption is not satisfied due to global mergeing.
Workaround the issue by temporary disablinge mergeing of const globals.
Also, ignore LLVM "special" globals. This fixes PR7716
llvm-svn: 109423
2010-07-26 18:45:39 +00:00
Evan Cheng
1566171daa
ARM fastisel isn't ready.
...
llvm-svn: 109421
2010-07-26 18:32:55 +00:00
Dan Gohman
9e0ae022d2
Fix SCEVExpander::visitAddRecExpr so that it remembers the induction variable
...
it inserted rather than using LoopInfo::getCanonicalInductionVariable to
rediscover it, since that doesn't work on non-canonical loops. This fixes
infinite recurrsion on such loops; PR7562.
llvm-svn: 109419
2010-07-26 18:28:14 +00:00
Dan Gohman
52e662a7f7
Handle Values with no value in getCopyFromRegs.
...
llvm-svn: 109415
2010-07-26 18:15:41 +00:00
Dan Gohman
23a6a1bdc5
Remove LCSSA's bogus dependence on LoopSimplify and LoopSimplify's bogus
...
dependence on DominanceFrontier. Instead, add an explicit DominanceFrontier
pass in StandardPasses.h to ensure that it gets scheduled at the right
time.
Declare that loop unrolling preserves ScalarEvolution, and shuffle some
getAnalysisUsages.
This eliminates one LoopSimplify and one LCCSA run in the standard
compile opts sequence.
llvm-svn: 109413
2010-07-26 18:11:16 +00:00
Dan Gohman
7d588b7dec
Preserve ScalarEvolution in the loop unroller.
...
llvm-svn: 109412
2010-07-26 18:02:06 +00:00
Dan Gohman
e191a19b69
Fix (at least) quadratic worst-case complexity in DominanceFrontier::splitBlock:
...
don't visit all blocks in the function, and don't iterate over the split blocks'
predecessor lists for each block visited.
Also, remove the special-case test for the entry block. Splitting the entry
block isn't common enough to make this worthwhile.
This fixes a major compile-time bottleneck which is exposed now that
LoopSimplify isn't being redundantly run both before and after
DominanceFrontier.
llvm-svn: 109408
2010-07-26 17:55:15 +00:00
Dan Gohman
c90f474e23
Avoid copying and recopying a std::set.
...
llvm-svn: 109405
2010-07-26 17:45:33 +00:00
Dan Gohman
8babd895c7
Exit a search loop when the search goal is found.
...
llvm-svn: 109404
2010-07-26 17:41:45 +00:00
Dan Gohman
014eec6389
Fix formatting.
...
llvm-svn: 109403
2010-07-26 17:39:33 +00:00
Dan Gohman
8f7e88352a
A block dominates itself, by definition.
...
llvm-svn: 109402
2010-07-26 17:38:15 +00:00
Dan Gohman
32010a6c96
Use DominatorTree::properlyDominates instead of dominates with an
...
explicit inequality check.
llvm-svn: 109401
2010-07-26 17:37:36 +00:00
Dan Gohman
bed2730c5b
A block dominates itself, by definition.
...
llvm-svn: 109400
2010-07-26 17:35:32 +00:00
Dan Gohman
0627594a67
Use DominatorTree::properlyDominates instead of dominates with an
...
explicit inequality check.
llvm-svn: 109398
2010-07-26 17:34:05 +00:00
Duncan Sands
0f0329ea35
Pacify gcc-4.5 which wrongly thinks that RExcess (passed as the Excess parameter)
...
may be used uninitialized in the callers of HighRegPressure.
llvm-svn: 109393
2010-07-26 07:54:17 +00:00
Douglas Gregor
8f3e666150
Fix format-specifier warning
...
llvm-svn: 109391
2010-07-26 03:55:44 +00:00
Michael J. Spencer
d061ee82ad
MC: Fix whitespace error from last commit.
...
A Visual C++ extension that removes trailing new lines? Seriously?
llvm-svn: 109390
2010-07-26 03:01:28 +00:00
Michael J. Spencer
9d96c92bde
MC: Add WinCOFFObjectWriter implementation.
...
Origonal Windows COFF implementation by Nathan Jedffords.
llvm-svn: 109389
2010-07-26 02:17:32 +00:00
Lang Hames
998b522009
Factored out a bit of common code to mark VNInfos for deletion.
...
llvm-svn: 109388
2010-07-26 01:49:41 +00:00
Benjamin Kramer
0f8f1bd5a1
Reduce string trashing.
...
llvm-svn: 109386
2010-07-25 23:18:32 +00:00
Evan Cheng
94e820829a
Add comments.
...
llvm-svn: 109383
2010-07-25 18:59:43 +00:00
Douglas Gregor
caa8768635
Remove extraneous semicolon
...
llvm-svn: 109373
2010-07-25 17:34:42 +00:00
Douglas Gregor
dc72ace097
Unbreak CMake build
...
llvm-svn: 109372
2010-07-25 17:10:14 +00:00
Bob Wilson
4f9b0d9fad
Fix crashes when scheduling a CopyToReg node -- getMachineOpcode asserts on
...
those. Radar 8231572.
llvm-svn: 109367
2010-07-25 05:34:27 +00:00
Eli Friedman
07a7e448b3
Revert r109361; it's impossible to write a call with an argument with an
...
invalid type.
llvm-svn: 109365
2010-07-24 23:06:59 +00:00
Eli Friedman
cd361b852b
Minor simplification.
...
llvm-svn: 109362
2010-07-24 23:00:59 +00:00
Eli Friedman
124f0f9120
Make the ll parser check that arguments have valid types.
...
llvm-svn: 109361
2010-07-24 23:00:26 +00:00
Eli Friedman
6769a5186d
PR7704: A function is not allowed to return a function; make sure to enforce
...
this consistently.
llvm-svn: 109360
2010-07-24 22:58:04 +00:00
Anton Korobeynikov
7ae895e007
Hook in GlobalMerge pass
...
llvm-svn: 109359
2010-07-24 21:52:08 +00:00
Nick Lewycky
8cbc57da86
Revert this because we can't clone cyclic MDNodes which are creating during a
...
build of llvm-gcc.
llvm-svn: 109355
2010-07-24 20:54:02 +00:00
Anton Korobeynikov
2a0715eb1b
Add hook to insert late LLVM=>LLVM passes just before isel
...
llvm-svn: 109354
2010-07-24 20:48:54 +00:00
Nick Lewycky
7094bd27bc
Whether function-local or not, a MDNode may reference a Function in which case
...
it needs to be mapped to refer to the function in the new module, not the old
one. Fixes PR7700.
llvm-svn: 109353
2010-07-24 19:43:25 +00:00
Duncan Sands
5128cb3743
Clarify that if a new value handle is added while dropping value handles
...
hanging off a value, then the dropping code will intentionally not drop
it too (since this is almost certainly a bug).
llvm-svn: 109337
2010-07-24 12:09:22 +00:00
Bob Wilson
59114a12b8
Change ScheduleDAGInstrs::Defs and ::Uses to be variable-size vectors
...
instead of fixed size arrays, so that increasing FirstVirtualRegister to 16K
won't cause a compile time performance regression.
llvm-svn: 109330
2010-07-24 06:01:53 +00:00
Devang Patel
df9f5bf991
Use current working directory when Dirname is empty. This only happens when absolute source file path is used on compiler command line.
...
llvm-svn: 109302
2010-07-24 00:53:22 +00:00
Evan Cheng
a0b74d8804
Add an ILP scheduler. This is a register pressure aware scheduler that's
...
appropriate for targets without detailed instruction iterineries.
The scheduler schedules for increased instruction level parallelism in
low register pressure situation; it schedules to reduce register pressure
when the register pressure becomes high.
On x86_64, this is a win for all tests in CFP2000. It also sped up 256.bzip2
by 16%.
llvm-svn: 109300
2010-07-24 00:39:05 +00:00
Bruno Cardoso Lopes
632295a03c
Support x86 "eiz" and "riz" pseudo index registers in the assembler.
...
llvm-svn: 109295
2010-07-24 00:06:39 +00:00
Jim Grosbach
4b7545413d
Use the appropriate register class for an i32 when adding ARM::LR to the
...
function live in set. This will give us tGPR for Thumb1 and GPR otherwise,
so the copy will be spillable. rdar://8224931
llvm-svn: 109293
2010-07-23 23:50:35 +00:00
Jim Grosbach
30d0fca117
Remove too-strict assertion. We may want the vreg copy of the physical register
...
to be of a different register class. For example, in Thumb1 if the live-in is
a high register, we want the vreg to be a low register. rdar://8224931
llvm-svn: 109291
2010-07-23 23:48:02 +00:00
Devang Patel
7049c83125
Revert r109262.
...
llvm-svn: 109285
2010-07-23 23:04:41 +00:00
Dale Johannesen
50d2bc2942
Revert 109076. It is wrong and was causing regressions. Add some
...
comments explaining why it was wrong. 8225024.
Fix the real problem in 8213383: the code that splits very large
blocks when no other place to put constants can be found was not
considering the case that the block contained a Thumb tablejump.
llvm-svn: 109282
2010-07-23 22:50:23 +00:00
Evan Cheng
f215e55d5f
- Allow target to specify when is register pressure "too high". In most cases,
...
it's too late to start backing off aggressive latency scheduling when most
of the registers are in use so the threshold should be a bit tighter.
- Correctly handle live out's and extract_subreg etc.
- Enable register pressure aware scheduling by default for hybrid scheduler.
For ARM, this is almost always a win on # of instructions. It's runtime
neutral for most of the tests. But for some kernels with high register
pressure it can be a huge win. e.g. 464.h264ref reduced number of spills by
54 and sped up by 20%.
llvm-svn: 109279
2010-07-23 22:39:59 +00:00
Bruno Cardoso Lopes
06fcdd6563
Remove trailing whitespace
...
llvm-svn: 109276
2010-07-23 22:15:26 +00:00
Dan Gohman
e6e38c1685
Eliminate getCanonicalInductionVariableIncrement's last user and
...
eliminate it.
llvm-svn: 109270
2010-07-23 21:34:51 +00:00
Dan Gohman
1d19d69faf
Simplify this code; it can use the regular CFG utlities rather than
...
the BlockTraits abstractions.
llvm-svn: 109268
2010-07-23 21:25:16 +00:00
Dan Gohman
188a4d7d53
Micro-optimize SCEVComplexityCompare.
...
llvm-svn: 109267
2010-07-23 21:20:52 +00:00
Dan Gohman
2de2b0713e
Add a const qualifier.
...
llvm-svn: 109266
2010-07-23 21:18:55 +00:00
Dan Gohman
1694c4352a
Use the proper type for shift counts. This fixes a bootstrap error.
...
llvm-svn: 109265
2010-07-23 21:08:12 +00:00
Devang Patel
01d5937192
IF directory name is empty then try to extract one using absolute file name.
...
llvm-svn: 109262
2010-07-23 20:36:13 +00:00
Bruno Cardoso Lopes
a80b57e5fc
Add AVX version of CLMUL instructions
...
llvm-svn: 109248
2010-07-23 18:41:12 +00:00
Dan Gohman
8859ab786b
DAGCombine (shl (anyext x, c)) to (anyext (shl x, c)) if the high bits
...
are not demanded. This often allows the anyext to be folded away.
llvm-svn: 109242
2010-07-23 18:03:30 +00:00
Dan Gohman
b5a26419b8
Make SDNode::dump() print a newline at the end.
...
llvm-svn: 109234
2010-07-23 16:37:47 +00:00
Gabor Greif
30f8e2112c
fix constness warnings
...
llvm-svn: 109224
2010-07-23 13:28:47 +00:00
Gabor Greif
a04ffe0391
do not (implicitly) dereference iterator many times, cache it instead
...
llvm-svn: 109222
2010-07-23 10:23:01 +00:00
Mikhail Glushenkov
bbe02846de
Formatting.
...
llvm-svn: 109216
2010-07-23 04:19:34 +00:00
Mikhail Glushenkov
bbeb485c74
Get rid of exceptions in llvmc.
...
llvmc can be now compiled with llvm-gcc on Windows.
llvm-svn: 109215
2010-07-23 03:42:55 +00:00
Bruno Cardoso Lopes
b5374c4b69
Declare CLMUL as a subtarget feature
...
llvm-svn: 109207
2010-07-23 01:22:45 +00:00
Bruno Cardoso Lopes
b034ffa291
Add x86 CLMUL (Carry-less multiplication) cpu feature
...
llvm-svn: 109206
2010-07-23 01:17:51 +00:00
Eric Christopher
308237108d
80-col.
...
llvm-svn: 109205
2010-07-23 01:05:59 +00:00
Bruno Cardoso Lopes
b9182e3051
Add complete assembler support for FMA3 instructions, with descriptions and encodings taken from the AVX manual
...
llvm-svn: 109204
2010-07-23 00:54:35 +00:00
Dale Johannesen
1ee436f417
The only supported calling convention for X86-64 uses
...
SSE, so we can't return floating point values if this
is disabled. Detect this error for clang.
With SSE1 only, f64 is a problem; it can be done, but
neither llvm-gcc nor clang has ever generated correct
code for it. Since nobody noticed this I think it's
OK to treat it as an error for now.
This also handles SSE-sized vectors of floating point.
8207686, 8204109.
llvm-svn: 109201
2010-07-23 00:30:35 +00:00
Bruno Cardoso Lopes
93fd8bdf6a
Fix some AVX instructions which didnt had HasAVX prefix. And also a problem with PINSRW, which was totally wrong because of a typo I introduced previously
...
llvm-svn: 109198
2010-07-23 00:14:54 +00:00
Chris Lattner
a1dcdf0bd4
eliminate the TargetInstrInfo::GetInstSizeInBytes hook.
...
ARM/PPC/MSP430-specific code (which are the only targets that
implement the hook) can directly reference their target-specific
instrinfo classes.
llvm-svn: 109171
2010-07-22 21:27:00 +00:00
Chris Lattner
7c16f1a16e
remove the dwarf sizing stuff which is now dead, it was
...
"yet another" copy of the dwarf EH emission code that was
copied, pasted and slightly hacked up.
llvm-svn: 109169
2010-07-22 21:20:39 +00:00
Bruno Cardoso Lopes
7722724eee
Add remaining AVX instructions (most of them dealing with GR64 destinations. This complete the assembler support for the general AVX ISA. But we still miss instructions from FMA3 and CLMUL specific feature flags, which are now the next step
...
llvm-svn: 109168
2010-07-22 21:18:49 +00:00
Chris Lattner
65ad913bec
remove the JIT "NeedsExactSize" feature and supporting logic.
...
llvm-svn: 109167
2010-07-22 21:17:55 +00:00
Chris Lattner
9c30949ae1
switch a private implementation of GetFunctionSizeInBytes.
...
This is probably not the best way to implement "Force LR to
be spilled if the Thumb function size is > 2048." do this,
it should use the branch shortening infrastructure, but I'm
just preserving functionality here.
llvm-svn: 109165
2010-07-22 21:14:33 +00:00
Chris Lattner
7704d56b21
X86MCInstLower now depends on AsmPrinter being around.
...
llvm-svn: 109154
2010-07-22 21:10:04 +00:00
Chris Lattner
367aa754b1
instead of migrating it to the MC instruction encoder, just
...
rip out the implementation of X86InstrInfo::GetInstSizeInBytes.
The code being ripped out just implemented a copy and hacked up
version of the (old) instruction encoder, and is buggy and
terrible in other ways. Since "GetInstSizeInBytes" is really
only there to support the JIT's "NeedsExactSize" hook (which
noone is using), just rip out the code. I will rip out the
NeedsExactSize hook next.
This resolves rdar://7617809 - switch X86InstrInfo::GetInstSizeInBytes to use X86MCCodeEmitter
llvm-svn: 109149
2010-07-22 21:05:13 +00:00
Devang Patel
f53de95e64
Speculatively revert 109117
...
llvm-svn: 109132
2010-07-22 18:44:00 +00:00
Xerxes Ranby
c7a04bcaa5
ARMv4 JIT forgets to set the lr register when making a indirect function call. Fixes PR7608
...
llvm-svn: 109125
2010-07-22 17:28:34 +00:00
Gabor Greif
feb96f2df2
keep in 80 cols
...
llvm-svn: 109122
2010-07-22 17:18:03 +00:00
Devang Patel
58b7143697
Map MDNode correctly.
...
A non function local MDNode can have an operand which is cloned by MapValue().
llvm-svn: 109117
2010-07-22 16:35:00 +00:00
Gabor Greif
346b13120a
use cascading operator-> feature
...
llvm-svn: 109104
2010-07-22 13:49:27 +00:00
Gabor Greif
96a9f8c7c6
mass elimination of reliance on automatic iterator dereferencing
...
llvm-svn: 109103
2010-07-22 13:36:47 +00:00
Gabor Greif
225d763b90
simplify
...
llvm-svn: 109101
2010-07-22 13:07:39 +00:00
Gabor Greif
40e372be7e
do not access arguments via low-level interface, do not multiply dereference use_iterators
...
llvm-svn: 109100
2010-07-22 13:04:32 +00:00
Gabor Greif
582eb39c11
pass dereferenced iterator to dyn_cast
...
llvm-svn: 109099
2010-07-22 11:48:35 +00:00
Gabor Greif
87ef691878
pass dereferenced iterator to dyn_cast
...
llvm-svn: 109098
2010-07-22 11:43:44 +00:00
Gabor Greif
197322c365
use -> instead of (*).
...
llvm-svn: 109094
2010-07-22 11:12:32 +00:00
Gabor Greif
e826ece8c2
cache dereferenced iterator
...
llvm-svn: 109093
2010-07-22 11:07:46 +00:00
Gabor Greif
a7509fca78
undo 80 column trespassing I caused
...
llvm-svn: 109092
2010-07-22 10:37:47 +00:00
Chandler Carruth
e10953d673
Mark an assert-only variable as used.
...
llvm-svn: 109091
2010-07-22 08:02:25 +00:00
Chandler Carruth
4810e179e9
Fix the generated file name for CMake.
...
llvm-svn: 109090
2010-07-22 08:00:52 +00:00
Tobias Grosser
604a50cd71
Add new RegionInfo pass.
...
The RegionInfo pass detects single entry single exit regions in a function,
where a region is defined as any subgraph that is connected to the remaining
graph at only two spots.
Furthermore an hierarchical region tree is built.
Use it by calling "opt -regions analyze" or "opt -view-regions".
llvm-svn: 109089
2010-07-22 07:46:31 +00:00
Chandler Carruth
66edf31b8e
Attempt to fix linking issues with CMake. Please review other CMake users,
...
especially on other platforms. Is there a better way to fix this.
llvm-svn: 109084
2010-07-22 06:27:45 +00:00
Evan Cheng
c47b23ef06
Re-apply r109079 with fix.
...
llvm-svn: 109083
2010-07-22 06:24:48 +00:00
Owen Anderson
2553a4be1a
Revert r109079, which broke a lot of CodeGen tests.
...
llvm-svn: 109082
2010-07-22 06:01:28 +00:00
Owen Anderson
01e73ac583
Update CMake files.
...
llvm-svn: 109081
2010-07-22 06:00:01 +00:00
Reid Kleckner
3a876ca187
Initial modifications to MCAssembler and TargetMachine for the MCJIT.
...
Patch by Olivier Meurant!
llvm-svn: 109080
2010-07-22 05:58:53 +00:00
Evan Cheng
f1ca10c69f
Initialize RegLimit only when register pressure is being tracked.
...
llvm-svn: 109079
2010-07-22 05:18:41 +00:00
Eric Christopher
4924d5fb93
Custom lower the memory barrier instructions and add support
...
for lowering without sse2. Add a couple of new testcases.
Fixes a few libgomp tests and latent bugs. Remove a few todos.
llvm-svn: 109078
2010-07-22 02:48:34 +00:00
Evan Cheng
32f6aba7d8
Fix constant island pass's handling of tBR_JTr. The offset of the instruction does not have to be 4-byte aligned. Rather, it's the offset + 2 that must be aligned since the instruction expands into:
...
mov pc, r1
.align 2
LJTI0_0_0:
.long LBB0_14
This fixes rdar://8213383. No test case since it's not possible to come up with a suitable small one.
llvm-svn: 109076
2010-07-22 02:09:47 +00:00
Eric Christopher
5901214b6a
80-columns.
...
llvm-svn: 109070
2010-07-22 00:26:08 +00:00
Nate Begeman
c50bef0df7
Make fast isel win64-aware w.r.t. call-clobbered regs
...
llvm-svn: 109069
2010-07-22 00:09:39 +00:00
Evan Cheng
5aa6a25102
More register pressure aware scheduling work.
...
llvm-svn: 109064
2010-07-21 23:53:58 +00:00
Bruno Cardoso Lopes
5920e38cd2
Add more 256-bit forms for a bunch of regular AVX instructions
...
Add 64-bit (GR64) versions of some instructions (which are not
described in their SSE forms, but are described in AVX)
llvm-svn: 109063
2010-07-21 23:53:50 +00:00
Dan Gohman
859ffd353e
Make NamedMDNode not be a subclass of Value, and simplify the interface
...
for creating and populating NamedMDNodes.
llvm-svn: 109061
2010-07-21 23:38:33 +00:00
Rafael Espindola
c8342b43c4
Fixes win64. It was broken by a previous patch where I missed the !isWin64
...
and then forced every register to be a vr128 on win64.
llvm-svn: 109060
2010-07-21 23:19:57 +00:00
Owen Anderson
b36d01c1b6
Add INSTANTIATE_AG_PASS, which combines RegisterPass<> with RegisterAnalysisGroup<> for pass registration.
...
llvm-svn: 109058
2010-07-21 23:07:00 +00:00
Jim Grosbach
489d758ea8
For ARM/Darwin, add a dwarf entry indicating whether a function is arm or thumb
...
rdar://8202967
llvm-svn: 109057
2010-07-21 23:03:52 +00:00
Chris Lattner
418c190d93
add some rough support for making mcinst lowering work without an
...
asmprinter or mangler around. This is option #B for killing off
X86InstrInfo::GetInstSizeInBytes. Option #A (killing
"needsexactsize") was sent for consideration to llvmdev.
llvm-svn: 109056
2010-07-21 23:03:35 +00:00
Eric Christopher
3d118d5e8a
Baby steps towards ARM fast-isel.
...
llvm-svn: 109047
2010-07-21 22:26:11 +00:00
Owen Anderson
f8addbb0a1
Fix batch of converting RegisterPass<> to INTIALIZE_PASS().
...
llvm-svn: 109045
2010-07-21 22:09:45 +00:00
Bruno Cardoso Lopes
eea3b7ed83
Add missing AVX convert instructions. Those instructions are not described in their SSE forms (although they exist), but add the AVX forms anyway, so the assembler can benefit from it
...
llvm-svn: 109039
2010-07-21 21:37:59 +00:00
Jim Grosbach
4d3c808fd9
tidy up.
...
llvm-svn: 109038
2010-07-21 21:36:25 +00:00
Jim Grosbach
6b4f9f4c14
80 column and trailing whitespace cleanup
...
llvm-svn: 109037
2010-07-21 21:21:52 +00:00
Dan Gohman
bb800aa2f7
Add some debug output to help diagnose PR7689.
...
llvm-svn: 109036
2010-07-21 21:18:37 +00:00
Nate Begeman
e7ca21ab3b
Fix a couple issues with Win64 ABI
...
1) all registers were spilled as xmm, regardless of actual size
2) win64 abi doesn't do the varargs-size-in-%al thing
Still to look into:
xmm6-15 are marked as clobbered by call instructions on win64 even though they aren't.
llvm-svn: 109035
2010-07-21 20:49:52 +00:00
Bruno Cardoso Lopes
1284fdc932
Avoid AVX instructions to be selected instead of its SSE form
...
llvm-svn: 109032
2010-07-21 20:38:42 +00:00
Dan Gohman
f4c6f5cc46
NamedMDNode is never an operand.
...
llvm-svn: 109031
2010-07-21 20:25:43 +00:00
Dan Gohman
fc3ee085a0
Disallow null as a named metadata operand.
...
Make MDNode::destroy private.
Fix the one thing that used MDNode::destroy, outside of MDNode itself.
One should never delete or destroy an MDNode explicitly. MDNodes
implicitly go away when there are no references to them (implementation
details aside).
llvm-svn: 109028
2010-07-21 18:54:18 +00:00
Dan Gohman
b0db34a612
Use TrackingVH instead of WeakVH for NamedMDNode's operands, since nodes
...
referenced by NamedMDNodes shouldn't be deleted.
llvm-svn: 109021
2010-07-21 18:01:42 +00:00
Dan Gohman
328a6ebeae
Tidy.
...
llvm-svn: 109020
2010-07-21 17:53:53 +00:00
Owen Anderson
f26c7a852f
Move the smarts of AnalysisGroup registration into PassRegistry.
...
llvm-svn: 109019
2010-07-21 17:52:45 +00:00
Rafael Espindola
9aab8413b8
Fix calling convention on ARM if vfp2+ is enabled.
...
llvm-svn: 109009
2010-07-21 11:38:30 +00:00
Eric Christopher
959481ec87
Pulling out previous patch, must've run the tests in
...
the wrong directory.
llvm-svn: 109005
2010-07-21 09:23:56 +00:00
Eric Christopher
5c12ad2a4b
Lower MEMBARRIER on x86 and support processors without SSE2.
...
Fixes a pile of libgomp failures in the llvm-gcc testsuite due
to the libcall not existing.
llvm-svn: 109004
2010-07-21 09:05:23 +00:00
Lang Hames
26319a802c
Changed OStream templates to functions on raw_ostream, removed the unused "renderWarnings" function.
...
llvm-svn: 109003
2010-07-21 09:02:06 +00:00
Bruno Cardoso Lopes
d13d8c2562
Add AVX only vzeroall and vzeroupper instructions
...
llvm-svn: 109002
2010-07-21 08:56:24 +00:00
Evan Cheng
df725c25dd
Teach bottom up pre-ra scheduler to track register pressure. Work in progress.
...
llvm-svn: 108991
2010-07-21 06:09:07 +00:00
Bruno Cardoso Lopes
c4d93a5a34
Add new AVX vpermilps, vpermilpd and vperm2f128 instructions
...
llvm-svn: 108984
2010-07-21 03:07:42 +00:00
Bruno Cardoso Lopes
a7efb29695
Add new AVX vmaskmov instructions, and also fix the VEX encoding bits to support it
...
llvm-svn: 108983
2010-07-21 02:46:58 +00:00
Dan Gohman
09326457a8
Give MDNode printing has access to the current Module in more
...
cases. This will be needed when function-local metadata can
appear in places that aren't intrinsic function arguments.
llvm-svn: 108971
2010-07-20 23:55:01 +00:00
Jakob Stoklund Olesen
2e78d6ed2e
Change the createSpiller interface to take a MachineFunctionPass argument.
...
The spillers can pluck the analyses they need from the pass reference.
Switch some never-null pointers to references.
llvm-svn: 108969
2010-07-20 23:50:15 +00:00
Dan Gohman
a07df2e2bf
Make this code a little more readable.
...
llvm-svn: 108968
2010-07-20 23:49:44 +00:00
Dan Gohman
6f009c4a42
Use DebugLocs instead of MDNodes.
...
llvm-svn: 108967
2010-07-20 23:49:05 +00:00
Owen Anderson
6265d52037
Move the handling of PassRegistrationListener's to PassRegistry.
...
llvm-svn: 108966
2010-07-20 23:41:56 +00:00
Bruno Cardoso Lopes
e0dce1c741
Add new AVX vextractf128 instructions
...
llvm-svn: 108964
2010-07-20 23:19:02 +00:00
Dan Gohman
c813346166
Fix a typo.
...
llvm-svn: 108962
2010-07-20 23:10:36 +00:00
Dan Gohman
66ae369e76
Don't look up the "dbg" metadata kind by name.
...
llvm-svn: 108961
2010-07-20 23:09:34 +00:00
Chris Lattner
fa1479a813
make asmprinter optional, even though passing in null will cause things to explode right now.
...
llvm-svn: 108955
2010-07-20 22:45:33 +00:00
Chris Lattner
535d070a96
continue pushing dependencies around.
...
llvm-svn: 108952
2010-07-20 22:35:40 +00:00
Chris Lattner
607e343ee1
reduce X86MCInstLower dependencies on asmprinter.
...
llvm-svn: 108950
2010-07-20 22:30:53 +00:00
Chris Lattner
2c7b47d3bf
pass around MF, not MMI.
...
llvm-svn: 108949
2010-07-20 22:26:07 +00:00
Dan Gohman
71724e8c7a
Rename removeAllMetadata to clearMetadataHashEntries and simplify
...
it to just do the things that need to be done when an instruction
is deleted.
llvm-svn: 108948
2010-07-20 22:25:04 +00:00
Chris Lattner
5834a54ac3
cleanups.
...
llvm-svn: 108947
2010-07-20 22:23:57 +00:00
Chris Lattner
cbca96b513
move two asmprinter methods into the asmprinter .cpp file.
...
llvm-svn: 108945
2010-07-20 22:18:19 +00:00
Jakob Stoklund Olesen
dcf78c06f8
Implement loop splitting analysis.
...
Determine which loop exit blocks need a 'pre-exit' block inserted.
Recognize when this would be impossible.
llvm-svn: 108941
2010-07-20 21:46:58 +00:00