Commit Graph

103755 Commits

Author SHA1 Message Date
David Blaikie
8a25ee1440 PR19562: DebugInfo temporary MDNode leak: Don't include a temporary node to replace with a variable list for methods, since they're always declarations and thus never include variables
This field is used for a list of variables to ensure they are not lost
during optimization (they're only included when optimizations are
enabled).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208159 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 06:08:28 +00:00
Tobias Grosser
a1f8bd6753 [C++11] Add NArySCEV->Operands iterator range
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208158 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 06:07:47 +00:00
Simon Atanasyan
111454f4e9 [obj2yaml] Recognize input file format using llvm::object::ObjectFile
interface methods isCOFF().

The '-coff' command line option has been removed. It was not used in any
test cases.

The patch reviewed by Michael Spencer.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208157 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 05:18:51 +00:00
Saleem Abdulrasool
3fe09b705c ARM: mark additional instructions as MachineFrameSetup
Mark up additional instructions which are part of the function prologue as
MachineFrameSetup.  These instructions are part of the function prologue,
emitted by the PEI pass to setup the stack for use in the activating frame.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208153 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 03:03:31 +00:00
Saleem Abdulrasool
0029e2d665 ARM: fix WoA PEI instruction selection
The ARM::BLX instruction is an ARM mode instruction.  The Windows on ARM target
is limited to Thumb instructions.  Correctly use the thumb mode tBLXr
instruction.  This would manifest as an errant write into the object file as the
instruction is 4-bytes in length rather than 2.  The result would be a corrupted
object file that would eventually result in an executable that would crash at
runtime.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208152 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 03:03:27 +00:00
Justin Bogner
ffb8718ee5 llvm-cov: Document --no-output in the command guide
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208151 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 02:33:58 +00:00
Justin Bogner
c92330c18c llvm-cov: Handle missing source files as GCOV does
If the source files referenced by a gcno file are missing, gcov
outputs a coverage file where every line is simply /*EOF*/.  This also
occurs for lines in the coverage that are past the end of a file that
is found.

This change mimics gcov.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208149 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 02:11:23 +00:00
Justin Bogner
56d05e468c llvm-cov: Implement --no-output
In gcov, there's a -n/--no-output option, which disables the writing
of any .gcov files, so that it emits only the summary info on stdout.
This implements the same behaviour in llvm-cov.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208148 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-07 02:11:18 +00:00
Argyrios Kyrtzidis
6d46f2d394 [Support/MemoryBuffer] Remove the assertion that the file size did not shrink.
This can happen in practice with the user changing files and we can recover from it.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208143 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 23:30:56 +00:00
Nico Weber
9e9ec9b69c Fix ASan init function detection after clang r208128.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208141 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 23:17:26 +00:00
Rafael Espindola
26668d093e Special case aliases in GlobalValue::getSection.
This is similar to the getAlignment patch, but is done just for
completeness. It looks like we never call getSection on an alias. All the
tests still pass if the if is replaced with an assert.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208139 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 22:44:30 +00:00
Andrew Trick
8abb75bc61 Update an embarassing out-of-date comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208137 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 22:18:43 +00:00
Eric Christopher
887ab99a6e Use a range based for loop for the SubtargetFeatures print function.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208132 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 21:20:29 +00:00
David Blaikie
ccad744d4a Revert "Try simplifying LexicalScopes ownership again."
Speculatively reverting due to a suspicious failure on a Windows
buildbot.

This reverts commit 10c37a012e.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208131 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 21:07:17 +00:00
Eric Christopher
d2ba53bdaa Fix odd formatting that snuck into last patch.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208130 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 21:04:27 +00:00
Joerg Sonnenberger
b84f890bc3 If a function needs a frame pointer, but r11 (aka fp) has not been used,
remove it from the list of unspilled registers. Otherwise the following
attempt to keep the stack aligned by picking an extra GPR register to
spill will not work as it picks up r11.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208129 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 20:43:01 +00:00
Eric Christopher
d474181920 ArrayRef-ize the Feature and Processor tables for SubtargetFeatures.
This removes arguments passed everywhere and allows the use of
standard iteration over lists.
Should be no functional change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208127 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 20:23:04 +00:00
Reid Kleckner
3949749701 Copy the full TailCallKind in CallInst::clone_impl
Split from the musttail inliner change.  This will be covered by an opt
test when the inliner change lands.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208126 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 20:08:20 +00:00
Diego Novillo
e3e870face Do not make -pass-remarks additive.
Summary:
When I initially introduced -pass-remarks, I thought it would be a
neat idea to make it additive. So, if one used it as:

$ llc -pass-remarks=inliner --pass-remarks=loop.*

the compiler would build the regular expression '(inliner)|(loop.*)'.

The more I think about it, the more I regret it. This is not how
other flags work. The standard semantics are right-to-left overrides.

This is how clang interprets -Rpass. And I think the two should be
compatible in this respect.

Reviewers: qcolombet

Subscribers: llvm-commits

Differential Revision: http://reviews.llvm.org/D3614

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208122 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 19:14:00 +00:00
Benjamin Kramer
2c06cd8612 TTI: Estimate @llvm.fmuladd cost as fmul + fadd when FMA's aren't legal on the target.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208115 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 18:36:23 +00:00
Andrea Di Biagio
8a712ba229 [X86] Improve the lowering of BITCAST dag nodes from type f64 to type v2i32 (and vice versa).
Before this patch, the backend always emitted a store+load sequence to
bitconvert from f64 to i64 the input operand of a ISD::BITCAST dag node that
performed a bitconvert from type MVT::f64 to type MVT::v2i32. The resulting
i64 node was then used to build a v2i32 vector.

With this patch, the backend now produces a cheaper SCALAR_TO_VECTOR from
MVT::f64 to MVT::v2f64. That SCALAR_TO_VECTOR is then followed by a "free"
bitcast to type MVT::v4i32. The elements of the resulting
v4i32 are then extracted to build a v2i32 vector (which is illegal and
therefore promoted to MVT::v2i64).

This is in general cheaper than emitting a stack store+load sequence
to bitconvert the operand from type f64 to type i64.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208107 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 17:09:03 +00:00
Renato Golin
22f779d1fd Implememting named register intrinsics
This patch implements the infrastructure to use named register constructs in
programs that need access to specific registers (bare metal, kernels, etc).

So far, only the stack pointer is supported as a technology preview, but as it
is, the intrinsic can already support all non-allocatable registers from any
architecture.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208104 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 16:51:25 +00:00
Rafael Espindola
b889448841 Special case aliases in GlobalValue::getAlignment.
An alias has the address of what it points to, so it also has the same
alignment.

This allows a few optimizations to see past aliases for free.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208103 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 16:48:58 +00:00
Eric Christopher
bfc3f301b6 Have the SubtargetFeature help routine just not return a number and
fall back to the normal path without a cpu. While doing this fix
llc to just exit when we don't have a module to process instead of
asserting.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208102 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 16:29:50 +00:00
Bob Wilson
534ec26d07 Add some details to the llvm-cov documentation. <rdar://problem/15819496>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208098 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 15:58:06 +00:00
Rafael Espindola
4f1723522e Be more strict about not allowing setSection on aliases.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208095 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 14:59:14 +00:00
Rafael Espindola
55ba6a126f Be more strict about not calling setAlignment on global aliases.
The fact that GlobalAlias::setAlignment exists at all is a side effect of
how the classes are organized, it should never be used.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208094 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 14:51:36 +00:00
Tim Northover
3524723195 AArch64/ARM64: implement diagnosis of unpredictable loads & stores
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208091 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 14:15:14 +00:00
Tim Northover
4d28f030f7 AArch64/ARM64: add two more MC tests to ARM64 set.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208085 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 12:50:58 +00:00
Tim Northover
c08733f867 AArch64/ARM64: enable MC-level diagnostic tests for NEON insts.
Obviously we can't expect the two backends to produce identical diagnostics,
since what's possible depends quite a bit on how the .td files are structured.
I think the ARM64 diagnostics are basically of the same quality in all the
changed cases, so I've split the CHECK lines.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208084 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 12:50:55 +00:00
Tim Northover
09b3bd8ca3 AArch64/ARM64: make NEON vector list parsing a bit more robust
It doesn't change the results, but it seems silly not to diagnose obvious
problems early on.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208083 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 12:50:51 +00:00
Tim Northover
d58350d789 AArch64/ARM64: add more specific diagnostic for floating imm 0.0.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208082 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 12:50:47 +00:00
Tim Northover
c5f9aff43e AArch64/ARM64: add more specific diagnostic for invalid vector lanes
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208081 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 12:50:44 +00:00
Tim Northover
6e64f90dc5 AArch64/ARM64: produce more informative diagnostic assembling some immediates
No tests here, they'll be added when the entire neon-diagnostics.s test from
AArch64 is enabled.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208079 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 11:18:53 +00:00
Christian Pirker
80fd09110d ARM: For thumb fixups store halfwords high first and low second
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208076 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 10:05:11 +00:00
Kevin Qin
03145ebd88 [ARM64] Enable alignment control option in front-end for ARM64.
This is the modification in llvm part.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208074 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 09:48:52 +00:00
Evgeniy Stepanov
0e8c40d643 Disable -Wcomment when building with GCC.
GCC version of -Wcomment is not compatible with ascii art graph diagrams.

Reverts r207629.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208073 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 09:46:06 +00:00
Richard Smith
64cd55a126 Update programmers manual to cover llvm::function_ref, and add a note to the
coding standard suggesting using it instead of the (unavailable) std::function.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208067 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 07:45:39 +00:00
Craig Topper
b0eeb124b2 Use X86 memory operand enums instead of hardcoding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208064 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 07:04:32 +00:00
Owen Anderson
b184a37074 Fix some obvious Doxygen comment bugs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208059 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 05:05:59 +00:00
David Blaikie
3e889f7041 Update comment from a recent commit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208057 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 03:53:10 +00:00
Adam Nemet
f0e7f76933 [Build] Add rule to generate fully-expanded .td file
I found it useful in the past and now again to have a version of the .td file
where all the records are expanded.  This adds a makefile rule to generate
this on demand.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208056 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 03:49:45 +00:00
David Blaikie
40a1b74db6 PR19598: Provide the ability to RAUW a declaration with itself, creating a non-temporary copy and using that to RAUW.
Also, provide the ability to create temporary and non-temporary
declarations, as not all declarations may be replaced by definitions
later on.

This provides the necessary infrastructure for Clang to fix PR19598,
leaking temporary MDNodes in Clang's debug info generation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208054 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 03:41:57 +00:00
Eric Christopher
5c34f99911 Revert "Walk back commits for unused function parameters - they're still being"
this reapplies 208012 and 208002.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208037 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 02:37:26 +00:00
Duncan P. N. Exon Smith
cca77fc0d6 blockfreq: Move include to .cpp
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208035 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 01:57:42 +00:00
Richard Smith
2efa833c4e Revert accidentally-committed files.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208034 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 01:46:26 +00:00
Richard Smith
36ecb2ee9d Re-commit r208025, reverted in r208030, with a fix for a conformance issue
which GCC detects and Clang does not!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208033 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 01:44:26 +00:00
Richard Smith
f3a199b2ae Revert r208025, which made buildbots unhappy for unknown reasons.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208030 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 01:26:00 +00:00
Reid Kleckner
9ad48c11b1 Fix i128 div/mod on mingw64
The Win64 docs are very clear that anything larger than 8 bytes is
passed by reference, and GCC MinGW64 honors that for __modti3 and
friends.

Patch by Jameson Nash!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208029 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 01:20:42 +00:00
Argyrios Kyrtzidis
10222d2959 [Support/MemoryBuffer] Rename IsVolatile -> IsVolatileSize and add a comment about the use case for the new parameter.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@208026 91177308-0d34-0410-b5e6-96231b3b80d8
2014-05-06 01:03:52 +00:00