Commit Graph

173738 Commits

Author SHA1 Message Date
Eric Christopher 0e6f41c659 Fix odd formatting that snuck into last patch.
llvm-svn: 208130
2014-05-06 21:04:27 +00:00
Joerg Sonnenberger 818e725158 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.

llvm-svn: 208129
2014-05-06 20:43:01 +00:00
Nico Weber bdc969839a Include translation unit filename in global ctor symbol names.
This makes it easier to see where a global ctor comes from, and it also makes
ASan's init order analyzer output easier to understand.  gcc does this too,
but only in -fPIC mode for some reason.  Don't do this for constructors with
explicit init priority.

Also prepend "sub_" before the 'I', that way regular constructors stay
lexicographically after symbols with init priority (because
ord('s') > ord('I')).  gold seems to ignore the name of constructor symbols,
and ld only looks at the symbol if it includes an init priority, which this
patch doesn't change.

Before: __GLOBAL_I_a
Now: __GLOBAL_sub_I_myfile.cc
llvm-svn: 208128
2014-05-06 20:32:45 +00:00
Eric Christopher dc5072d60e 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.

llvm-svn: 208127
2014-05-06 20:23:04 +00:00
Reid Kleckner 118e1bf862 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.

llvm-svn: 208126
2014-05-06 20:08:20 +00:00
Rui Ueyama 0d85dbfce0 Tests no longer uses getNextInputElement, so make it private.
llvm-svn: 208124
2014-05-06 19:32:54 +00:00
Rui Ueyama 2fa41d1817 Add a test for notifyProgress().
llvm-svn: 208123
2014-05-06 19:26:21 +00:00
Diego Novillo dd49157db1 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

llvm-svn: 208122
2014-05-06 19:14:00 +00:00
Rui Ueyama aa30ccffa8 Remove unused variable.
llvm-svn: 208121
2014-05-06 19:11:39 +00:00
Rui Ueyama b51711b356 Fix copypaste error.
llvm-svn: 208120
2014-05-06 19:05:14 +00:00
Rui Ueyama b12dcb6095 s/My/Test/ as these classes are for tests.
llvm-svn: 208119
2014-05-06 19:01:56 +00:00
Rui Ueyama fd5c70d0ec Make the test even more readable.
llvm-svn: 208118
2014-05-06 18:58:24 +00:00
Greg Clayton c62338e89d control-D on empty line to quit lldb stopped working in Release builds on MacOSX.
<rdar://problem/16822217>

llvm-svn: 208117
2014-05-06 18:54:53 +00:00
Rui Ueyama 48a1727e6f Simplify unit test code.
llvm-svn: 208116
2014-05-06 18:41:12 +00:00
Benjamin Kramer 1625bfccbe TTI: Estimate @llvm.fmuladd cost as fmul + fadd when FMA's aren't legal on the target.
llvm-svn: 208115
2014-05-06 18:36:23 +00:00
David Blaikie 483a9da598 Reapply: DebugInfo: Emit the definition of enums when the definition preceeds the declaration and initial use.
Reverting r208106 to reapply r208065 with a fix for the regression. The
issue was that the enum tried to be built even if the declaration hadn't
been constructed for debug info - presenting problems for enum templates
and typedefs of enums with names for linkage purposes.

Original commit message:

This regressed a little further 208055 though it was already a little
broken.

While the requiresCompleteType optimization should be implemented here.
Future (possibly near future) work.

llvm-svn: 208114
2014-05-06 18:35:21 +00:00
Rui Ueyama d976941704 Remove meaningless return value in test.
llvm-svn: 208112
2014-05-06 18:27:37 +00:00
Rui Ueyama 27169ce309 Replace copypasta with function calls to make tests intelligible.
llvm-svn: 208111
2014-05-06 18:24:27 +00:00
Nico Weber 7ce830bb67 Fix leak in ObjCSelfInitChecker, found by LSan.
BugReport doesn't take ownership of the bug type, so let the checker own the
the bug type.  (Requires making the bug type mutable, which is icky, but which
is also what other checkers do.)

llvm-svn: 208110
2014-05-06 17:33:42 +00:00
Rui Ueyama 1fe682cf37 Don't return value rather than always returning true.
addInputElement() never fails, and no one checks its return value
except tests. Let's simplify the signature.

llvm-svn: 208109
2014-05-06 17:33:14 +00:00
Nico Weber 5f8116ba46 Fix a leak found by LSan: ConsumedBlockInfo owns its StateMapsArray entries.
(I tried converting StateMapsArray to a vector<unique_ptr> and changing the
types of getInfo() and addInfo() to take unique_ptrs.  This mostly worked,
except for the three-argument form of addInfo() which I found confusing enough
that I went with this simpler fix for now.)

llvm-svn: 208108
2014-05-06 17:18:03 +00:00
Andrea Di Biagio c14ccc9184 [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.

llvm-svn: 208107
2014-05-06 17:09:03 +00:00
David Blaikie 29020cc571 Revert "DebugInfo: Emit the definition of enums when the definition preceeds the declaration and initial use."
This is breaking the compiler-rt build. Reverting while I
investigate/fix.

This reverts commit r208065.

llvm-svn: 208106
2014-05-06 17:02:15 +00:00
Tilmann Scheller e914bc8d46 Add driver support for AArch64 Fedora.
Reviewed by Eric Christopher.

llvm-svn: 208105
2014-05-06 16:58:14 +00:00
Renato Golin c7aea40ec6 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.

llvm-svn: 208104
2014-05-06 16:51:25 +00:00
Rafael Espindola 52dc5d828f 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.

llvm-svn: 208103
2014-05-06 16:48:58 +00:00
Eric Christopher a9f3a5cb37 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.

llvm-svn: 208102
2014-05-06 16:29:50 +00:00
Rui Ueyama b340f0117c Remove a method that no one is using.
llvm-svn: 208101
2014-05-06 16:22:04 +00:00
Jordan Rose b5d2dc2e89 Update comment for ObjCImplementationDecl's handling of instance variables.
No functionality change.

llvm-svn: 208099
2014-05-06 16:07:54 +00:00
Bob Wilson c16b7040e3 Add some details to the llvm-cov documentation. <rdar://problem/15819496>
llvm-svn: 208098
2014-05-06 15:58:06 +00:00
Marshall Clow 0fc6e981b0 Fix PR 19663. Some calls to find(vector<bool>) were returning iterators that were subtly invalid (didn't compare equal). Thanks to Erik Verbruggen for the report (and diagnosis)
llvm-svn: 208096
2014-05-06 15:33:23 +00:00
Rafael Espindola 8fbbfbbec3 Be more strict about not allowing setSection on aliases.
llvm-svn: 208095
2014-05-06 14:59:14 +00:00
Rafael Espindola a7d9c69cc8 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.

llvm-svn: 208094
2014-05-06 14:51:36 +00:00
Daniel Jasper 484033b188 clang-format: [JS] Keep space after closure style comments.
Before:
  var x = /** @type {foo} */ (bar);

After:
  var x = /** @type {foo} */(bar);

llvm-svn: 208093
2014-05-06 14:41:29 +00:00
Kostya Serebryany 7a733480c8 [asan] introduce interface function __sanitizer_verify_contiguous_container to verify annotations in vector-like containers
llvm-svn: 208092
2014-05-06 14:41:01 +00:00
Tim Northover 618850b6a5 AArch64/ARM64: implement diagnosis of unpredictable loads & stores
llvm-svn: 208091
2014-05-06 14:15:14 +00:00
Daniel Jasper 166c19bd37 clang-format: [JS] Keep space between 'return' and '['.
llvm-svn: 208090
2014-05-06 14:12:21 +00:00
Evgeniy Stepanov aa44aaee90 [sanitizer] Print addresses in hexadecimal.
llvm-svn: 208089
2014-05-06 14:01:13 +00:00
Daniel Jasper 4a39c84c91 clang-format: [JS] Don't indent in goog.scope blocks.
Before:
  goog.scope(function() {
    var x = a.b;
    var y = c.d;
  });  // goog.scope

After:
  goog.scope(function() {
  var x = a.b;
  var y = c.d;
  });  // goog.scope

llvm-svn: 208088
2014-05-06 13:54:10 +00:00
Alexey Bataev 0b397eaf93 [OPENMP] Another one fix for codegen test '#pragma omp parallel'
llvm-svn: 208087
2014-05-06 13:15:00 +00:00
Alexey Bataev 795b88b040 [OPENMP] Fixed test for '#pragma omp parallel' codegen
llvm-svn: 208086
2014-05-06 13:02:17 +00:00
Tim Northover 2ac82426f8 AArch64/ARM64: add two more MC tests to ARM64 set.
llvm-svn: 208085
2014-05-06 12:50:58 +00:00
Tim Northover d450746dc9 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.

llvm-svn: 208084
2014-05-06 12:50:55 +00:00
Tim Northover 15641cd4e1 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.

llvm-svn: 208083
2014-05-06 12:50:51 +00:00
Tim Northover 339ecf14ee AArch64/ARM64: add more specific diagnostic for floating imm 0.0.
llvm-svn: 208082
2014-05-06 12:50:47 +00:00
Tim Northover 05cbe7c80a AArch64/ARM64: add more specific diagnostic for invalid vector lanes
llvm-svn: 208081
2014-05-06 12:50:44 +00:00
Dinesh Dwivedi 2e92e66f66 Fixed one issue with casting
Before:
(void) SimplifyICmpOperands(Cond, LHS, RHS);

After:
(void)SimplifyICmpOperands(Cond, LHS, RHS);

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

llvm-svn: 208080
2014-05-06 11:46:49 +00:00
Tim Northover 0f54f309bb 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.

llvm-svn: 208079
2014-05-06 11:18:53 +00:00
Alexey Bataev e357df8eae [OPENMP] Temporary disable test for parallel codegen
llvm-svn: 208078
2014-05-06 10:51:53 +00:00
Alexey Bataev 9959db5fa9 [OPENMP] Initial codegen for '#pragma omp parallel'
llvm-svn: 208077
2014-05-06 10:08:46 +00:00