platform/upstream/llvm.git
10 years ago[Mips] Remove duplicated relocation calculation routines
Simon Atanasyan [Thu, 20 Nov 2014 22:29:49 +0000 (22:29 +0000)]
[Mips] Remove duplicated relocation calculation routines

No functional changes.

llvm-svn: 222469

10 years ago[Mips] Remove unused function argument
Simon Atanasyan [Thu, 20 Nov 2014 22:29:43 +0000 (22:29 +0000)]
[Mips] Remove unused function argument

No functional changes.

llvm-svn: 222468

10 years ago[Mips] Use endian::read/write function to load/save MIPS32 instructions
Simon Atanasyan [Thu, 20 Nov 2014 22:29:37 +0000 (22:29 +0000)]
[Mips] Use endian::read/write function to load/save MIPS32 instructions

No functional changes.

llvm-svn: 222467

10 years ago[Hexagon] [NFC] Deleting empty directory.
Colin LeMahieu [Thu, 20 Nov 2014 22:20:40 +0000 (22:20 +0000)]
[Hexagon] [NFC] Deleting empty directory.

llvm-svn: 222466

10 years agoEnsure all TypoExprs are diagnosed by the tree transform.
Kaelyn Takata [Thu, 20 Nov 2014 22:06:44 +0000 (22:06 +0000)]
Ensure all TypoExprs are diagnosed by the tree transform.

If there is more than one TypoExpr within the expr being transformed and
any but the last TypoExpr seen don't have any viable candidates, the
tree transform will be aborted early and the remaining TypoExprs are
never seen and hence never diagnosed. This adds a simple
RecursiveASTVisitor to find all of the TypoExprs to be diagnosed in the
case where typo correction of the entire expr fails (and the result of
the tree transform is an ExprError).

llvm-svn: 222465

10 years agoWire up delayed typo correction to DiagnoseEmptyLookup and set up
Kaelyn Takata [Thu, 20 Nov 2014 22:06:40 +0000 (22:06 +0000)]
Wire up delayed typo correction to DiagnoseEmptyLookup and set up
Sema::ActOnIdExpression to use the new functionality.

Among other things, this allows recovery in several cases where it
wasn't possible before (e.g. correcting a mistyped static_cast<>).

llvm-svn: 222464

10 years agoAdd a flag to BuildDeclarationNameExpr to not reject invalid decls.
Kaelyn Takata [Thu, 20 Nov 2014 22:06:33 +0000 (22:06 +0000)]
Add a flag to BuildDeclarationNameExpr to not reject invalid decls.

llvm-svn: 222463

10 years agoFactor out the default recovery handling.
Kaelyn Takata [Thu, 20 Nov 2014 22:06:30 +0000 (22:06 +0000)]
Factor out the default recovery handling.

The default handling is extended to properly create member expressions
and Objective-C ivar references.

Also detect and reject cases where multiple corrections have identical
correction distances and are valid, instead of suggesting the first one
that is found.

llvm-svn: 222462

10 years agoAdd a few small helper methods to the TypoCorrectionConsumer.
Kaelyn Takata [Thu, 20 Nov 2014 22:06:29 +0000 (22:06 +0000)]
Add a few small helper methods to the TypoCorrectionConsumer.

llvm-svn: 222461

10 years agoCorrectly set the SourceRange a TypoCorrection will replace.
Kaelyn Takata [Thu, 20 Nov 2014 22:06:26 +0000 (22:06 +0000)]
Correctly set the SourceRange a TypoCorrection will replace.

Also clean up TypoCorrection::setCorrectionRange while we're at it.

llvm-svn: 222460

10 years ago"nexti" should not step over inlined functions.
Jim Ingham [Thu, 20 Nov 2014 22:04:45 +0000 (22:04 +0000)]
"nexti" should not step over inlined functions.

<rdar://problem/16705325>

llvm-svn: 222459

10 years ago[Hexagon] [NFC] Merging InstPrinter directory in to MCTargetDesc since they have...
Colin LeMahieu [Thu, 20 Nov 2014 21:56:35 +0000 (21:56 +0000)]
[Hexagon] [NFC] Merging InstPrinter directory in to MCTargetDesc since they have a circular dependency.

llvm-svn: 222458

10 years ago[mach-o] fix whitespace
Nick Kledzik [Thu, 20 Nov 2014 21:41:53 +0000 (21:41 +0000)]
[mach-o] fix whitespace

llvm-svn: 222457

10 years agoThe Syntax enumeration requires at least three bits to store all of its values. Incre...
Aaron Ballman [Thu, 20 Nov 2014 21:34:56 +0000 (21:34 +0000)]
The Syntax enumeration requires at least three bits to store all of its values. Increase the number of bits for SyntaxUsed. Decrease the number of expression arguments allowed by a single bit so that the bit fields continue to add up to 32-bits evenly.

There is no test for this fix because I could find no reasonable way to trigger a visible failure from it.

Thanks to Doug Gregor for spotting this!

llvm-svn: 222456

10 years ago[mach-o] use reference with "auto" to prevent copies
Nick Kledzik [Thu, 20 Nov 2014 21:19:58 +0000 (21:19 +0000)]
[mach-o] use reference with "auto" to prevent copies

Patch by Jean-Daniel Dupas

llvm-svn: 222455

10 years ago[MCJIT] Remove JITEventListener::NotifyFunctionEmitted - this method is dead
Lang Hames [Thu, 20 Nov 2014 21:16:16 +0000 (21:16 +0000)]
[MCJIT] Remove JITEventListener::NotifyFunctionEmitted - this method is dead
now that the legacy JIT has been removed.

llvm-svn: 222453

10 years ago[PECOFF] Sort export table properly.
Rui Ueyama [Thu, 20 Nov 2014 21:05:05 +0000 (21:05 +0000)]
[PECOFF] Sort export table properly.

Export table entries need to be sorted in ASCII-betical order,
so that the loader can find an entry for a function by binary search.

We sorted the entries by its mangled names. That can be different
from their exported names. As a result, LLD produces incorrect export
table, from which the loader complains that a function that actually
exists in a DLL cannot be found.

This patch fixes that issue.

llvm-svn: 222452

10 years agoFix a trip-count overflow issue in LoopUnroll.
Michael Zolotukhin [Thu, 20 Nov 2014 20:19:55 +0000 (20:19 +0000)]
Fix a trip-count overflow issue in LoopUnroll.

Currently LoopUnroll generates a prologue loop before the main loop
body to execute first N%UnrollFactor iterations. Also, this loop is
used if trip-count can overflow - it's determined by a runtime check.

However, we've been mistakenly optimizing this loop to a linear code for
UnrollFactor = 2, not taking into account that it also serves as a safe
version of the loop if its trip-count overflows.

llvm-svn: 222451

10 years agoRemove decorator for FreeBSD test that now passes
Ed Maste [Thu, 20 Nov 2014 19:43:33 +0000 (19:43 +0000)]
Remove decorator for FreeBSD test that now passes

llvm-svn: 222449

10 years agoCompilation test for PostOrderIterator.
Michael Ilseman [Thu, 20 Nov 2014 19:33:33 +0000 (19:33 +0000)]
Compilation test for PostOrderIterator.

If the template specialization for externally managed sets in
PostOrderIterator call too far out of sync with each other, this unit
test will fail to build. This is especially useful for developers who
may not build Clang (the only in-tree user) every time.

llvm-svn: 222447

10 years agoUpdate template specialization to reflect API changes.
Michael Ilseman [Thu, 20 Nov 2014 19:33:30 +0000 (19:33 +0000)]
Update template specialization to reflect API changes.

po_iterator_storage's insertEdge was updated to reflect the API
changes from many of our insert methods in r222334, however the
template specialization for external storage was not updated. This
updates the specialization.

llvm-svn: 222446

10 years agoBring PostOrderCFGView's insert API up to date with other API changes.
Michael Ilseman [Thu, 20 Nov 2014 19:32:48 +0000 (19:32 +0000)]
Bring PostOrderCFGView's insert API up to date with other API changes.

r222334 updates LLVM data structure's insert API to return a
pair. This change updates PostOrderCFGView accordingly, so that it can
be used interchangably with other sets.

llvm-svn: 222445

10 years agoExtended list of valid frontend options with '-cl-std=CL2.0'.
Anastasia Stulova [Thu, 20 Nov 2014 19:25:00 +0000 (19:25 +0000)]
Extended list of valid frontend options with '-cl-std=CL2.0'.

This option sets language mode for the compilation of a source file to be OpenCL v2.0.

Example: clang -cc1 -cl-std=CL2.0 myfile.cl
llvm-svn: 222444

10 years agoAdd decorator for FreeBSD failure
Ed Maste [Thu, 20 Nov 2014 18:56:11 +0000 (18:56 +0000)]
Add decorator for FreeBSD failure

llvm.org/pr21620

llvm-svn: 222442

10 years agoProperly specify a few checksum values for llgs tests.
Stephane Sezer [Thu, 20 Nov 2014 18:50:46 +0000 (18:50 +0000)]
Properly specify a few checksum values for llgs tests.

Summary: In noack mode, these checksums are ignored by llgs, but some implementations need them still. Specify these checksums to ease integration.

Test Plan: Run the tests before and after the change and make sure nothing breaks.

Reviewers: clayborg, tfiala

Subscribers: lldb-commits

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

llvm-svn: 222441

10 years agoFix a typo in lldb-gdb-remote.txt.
Stephane Sezer [Thu, 20 Nov 2014 18:50:16 +0000 (18:50 +0000)]
Fix a typo in lldb-gdb-remote.txt.

Test Plan: None.

Reviewers: clayborg

Subscribers: lldb-commits

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

llvm-svn: 222440

10 years agoX86: use the correct alloca symbol for Windows Itanium
Saleem Abdulrasool [Thu, 20 Nov 2014 18:01:26 +0000 (18:01 +0000)]
X86: use the correct alloca symbol for Windows Itanium

Windows itanium targets the MSVCRT, and the stack probe symbol is provided by
MSVCRT.  This corrects the emission of stack probes on i686-windows-itanium.

llvm-svn: 222439

10 years agoTesting commit access.
Anastasia Stulova [Thu, 20 Nov 2014 17:57:27 +0000 (17:57 +0000)]
Testing commit access.

llvm-svn: 222438

10 years agoRemove now dead code.
Frederic Riss [Thu, 20 Nov 2014 16:24:29 +0000 (16:24 +0000)]
Remove now dead code.

After LLVM r222434, the Variables field of DISubprograms for forward
declarations will always be null. No need to keep code around to
delete them.

llvm-svn: 222437

10 years agoMake DWARFAcceleratorTable::dump() const.
Frederic Riss [Thu, 20 Nov 2014 16:21:11 +0000 (16:21 +0000)]
Make DWARFAcceleratorTable::dump() const.

As dump() methods  should be. To allow that, do not store the DWARFFormValue
objects used for the dump in the header data.

Per Alexey's suggestion!

llvm-svn: 222436

10 years agoAdd missing copyright headers.
Frederic Riss [Thu, 20 Nov 2014 16:21:06 +0000 (16:21 +0000)]
Add missing copyright headers.

llvm-svn: 222435

10 years agoDo not create a replaceable Variables MDNode for function forward decls.
Frederic Riss [Thu, 20 Nov 2014 15:52:34 +0000 (15:52 +0000)]
Do not create a replaceable Variables MDNode for function forward decls.

These fields would need to be explicitly deleted before we RAUW the temporary
node anyway (this was done in cfe commit r222373). Instead, do not create
these useless nodes in the first place.

llvm-svn: 222434

10 years agoPrepare for the DIBuilder populating DISubprogram's Variables with null.
Frederic Riss [Thu, 20 Nov 2014 15:46:59 +0000 (15:46 +0000)]
Prepare for the DIBuilder populating DISubprogram's Variables with null.

This is a followup to r222373. A better solution to the problem solved
there is to not create the leaked nodes at all (we know that they will
never be used for forward declared functions anyway). To avoid bot
breakage in the interval between the cfe and llvm commits, add a check
that the nMDNode is not null before deleting it. This code can completely
go away after the LLVM part is in.

llvm-svn: 222433

10 years agoReplace variadic operator function pointer with an enum value.
Samuel Benzaquen [Thu, 20 Nov 2014 15:45:53 +0000 (15:45 +0000)]
Replace variadic operator function pointer with an enum value.

Summary:
Replace variadic operator function pointer with an enum value.
Hiding the implementation of the variadic matcher will allow to specialize them for the operation performed.
In particular, it will allow for a more efficient allOf() matcher.

Reviewers: klimek

Subscribers: klimek, cfe-commits

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

llvm-svn: 222432

10 years ago[clang-tidy] Set google-readability-namespace-comments.ShortNamespaceLines to 10
Alexander Kornienko [Thu, 20 Nov 2014 15:05:32 +0000 (15:05 +0000)]
[clang-tidy] Set google-readability-namespace-comments.ShortNamespaceLines to 10

This value is used in cpplint, so we'd better be consistent.

llvm-svn: 222431

10 years agoMCJIT tests passing on ARM after r222414 fixed the relocation
Renato Golin [Thu, 20 Nov 2014 13:32:16 +0000 (13:32 +0000)]
MCJIT tests passing on ARM after r222414 fixed the relocation

llvm-svn: 222430

10 years agoConvert CR+LF -> LF in a test file
Timur Iskhodzhanov [Thu, 20 Nov 2014 12:59:14 +0000 (12:59 +0000)]
Convert CR+LF -> LF in a test file

llvm-svn: 222429

10 years agoRevert r222416, r222422, r222426: the former revision had problems and fixing them...
Timur Iskhodzhanov [Thu, 20 Nov 2014 12:36:43 +0000 (12:36 +0000)]
Revert r222416, r222422, r222426: the former revision had problems and fixing them introduced bugs

llvm-svn: 222428

10 years ago[clang-tidy] Count errors in ClangTidyDiagnosticConsumer
Alexander Kornienko [Thu, 20 Nov 2014 12:05:51 +0000 (12:05 +0000)]
[clang-tidy] Count errors in ClangTidyDiagnosticConsumer

This re-applies r222363 reverted in r222390 after compilation errors in our
out-of-tree clang-tidy tests were fixed.

llvm-svn: 222427

10 years agoFix a typo
Timur Iskhodzhanov [Thu, 20 Nov 2014 11:48:58 +0000 (11:48 +0000)]
Fix a typo

llvm-svn: 222426

10 years ago[DFSan] Add flag to dump the labels when the program terminates.
Lorenzo Martignoni [Thu, 20 Nov 2014 10:01:08 +0000 (10:01 +0000)]
[DFSan] Add flag to dump the labels when the program terminates.

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

llvm-svn: 222425

10 years agoclang-format: [Java] Don't align after "return".
Daniel Jasper [Thu, 20 Nov 2014 09:54:49 +0000 (09:54 +0000)]
clang-format: [Java] Don't align after "return".

Doesn't seem to be common practice in Java.

Before:
  return aaaaaaaaaaaaaaaaaaa
         && bbbbbbbbbbbbbbbbbbb
         && ccccccccccccccccccc;

After:
  return aaaaaaaaaaaaaaaaaaa
      && bbbbbbbbbbbbbbbbbbb
      && ccccccccccccccccccc;

Patch by Harry Terkelsen.

llvm-svn: 222424

10 years agoclang-format: [Java] Don't force break before generic type method.
Daniel Jasper [Thu, 20 Nov 2014 09:48:11 +0000 (09:48 +0000)]
clang-format: [Java] Don't force break before generic type method.

Before:
  Foo.bar()
      .<X>
      baz();

After:
  Foo.bar()
      .<X>baz();

Patch by Harry Terkelsen.

llvm-svn: 222423

10 years agoSimplifyCFG.cpp: Tweak to let msc17 compliant.
NAKAMURA Takumi [Thu, 20 Nov 2014 08:59:02 +0000 (08:59 +0000)]
SimplifyCFG.cpp: Tweak to let msc17 compliant.

  - Use LLVM_DELETED_FUNCTION.
  - Don't use member initializers.
  - Don't use initializer list.

llvm-svn: 222422

10 years agoSimplifyCFG: Refactor GatherConstantCompares() result in a struct
Mehdi Amini [Thu, 20 Nov 2014 06:51:02 +0000 (06:51 +0000)]
SimplifyCFG: Refactor GatherConstantCompares() result in a struct

Code seems cleaner and easier to understand this way

llvm-svn: 222416

10 years ago[Mips] Configure GOTPLT entries in the corresponding constructor
Simon Atanasyan [Thu, 20 Nov 2014 06:34:04 +0000 (06:34 +0000)]
[Mips] Configure GOTPLT entries in the corresponding constructor

No functional changes.

llvm-svn: 222415

10 years ago[ELF] Prevent ARM ELF object writer from generating deprecated relocation code R_ARM_...
Jyoti Allur [Thu, 20 Nov 2014 05:58:11 +0000 (05:58 +0000)]
[ELF] Prevent ARM ELF object writer from generating deprecated relocation code R_ARM_PLT32

llvm-svn: 222414

10 years agoAdd a test for r221870
David Majnemer [Thu, 20 Nov 2014 05:32:10 +0000 (05:32 +0000)]
Add a test for r221870

bad-relocs.obj.coff-i386 has a relocation whose symbol index is outside
the symbol table.

llvm-svn: 222413

10 years agoFix a typo in a comment.
Craig Topper [Thu, 20 Nov 2014 05:22:37 +0000 (05:22 +0000)]
Fix a typo in a comment.

llvm-svn: 222412

10 years agoRemove unnecessary extra spaces from tablegen register info output.
Craig Topper [Thu, 20 Nov 2014 05:22:35 +0000 (05:22 +0000)]
Remove unnecessary extra spaces from tablegen register info output.

llvm-svn: 222411

10 years agoUse array_lengthof instead of sizeof(array)/sizeof(element) in a tablegen output.
Craig Topper [Thu, 20 Nov 2014 05:22:32 +0000 (05:22 +0000)]
Use array_lengthof instead of sizeof(array)/sizeof(element) in a tablegen output.

llvm-svn: 222410

10 years ago[OPENMP] Codegen for "omp flush" directive.
Alexey Bataev [Thu, 20 Nov 2014 04:34:54 +0000 (04:34 +0000)]
[OPENMP] Codegen for "omp flush" directive.
For each "omp flush" directive a call to "void kmpc_flush(ident_t *, ...)" function is generated.
Directive "omp flush" may have an associated list of variables to flush, but currently runtime function ignores them. So the patch generates just "call kmpc_flush(ident_t *<loc>, i32 0)".
Differential Revision: http://reviews.llvm.org/D6292

llvm-svn: 222409

10 years agoFix buildbots.
Richard Smith [Thu, 20 Nov 2014 04:09:55 +0000 (04:09 +0000)]
Fix buildbots.

llvm-svn: 222408

10 years ago[CMake] Use .svn/wc.db as our VC dependency if it's available.
Jordan Rose [Thu, 20 Nov 2014 03:57:45 +0000 (03:57 +0000)]
[CMake] Use .svn/wc.db as our VC dependency if it's available.

In order to keep SVNVersion.inc from being regenerated on every build, we need
to specify as a dependency a file that only changes when the VC state updates.
I previously just had .svn/entries, but that's only used by Subversion 1.6.
1.7 uses .svn/wc.db instead; prefer that if it's present.

(Thanks, Nico!)

llvm-svn: 222407

10 years agoRemove xfail tag for darwin from quick_exit test
Eric Fiselier [Thu, 20 Nov 2014 03:40:32 +0000 (03:40 +0000)]
Remove xfail tag for darwin from quick_exit test

llvm-svn: 222406

10 years agoRemove tests that va_copy is not defined when C++ < 11.
Eric Fiselier [Thu, 20 Nov 2014 03:39:25 +0000 (03:39 +0000)]
Remove tests that va_copy is not defined when C++ < 11.

llvm-svn: 222405

10 years agoPreserve numeric literal suffixes during type canonicalization.
Richard Smith [Thu, 20 Nov 2014 03:37:32 +0000 (03:37 +0000)]
Preserve numeric literal suffixes during type canonicalization.
Patch by Pierre Gousseau! Test cases altered significantly by me.

llvm-svn: 222404

10 years agoAvoid earlier test interfering with later one.
Richard Smith [Thu, 20 Nov 2014 01:50:37 +0000 (01:50 +0000)]
Avoid earlier test interfering with later one.

llvm-svn: 222403

10 years agoWhen mangling member-expressions, skip implicit accesses of anonymous union
Richard Smith [Thu, 20 Nov 2014 01:35:11 +0000 (01:35 +0000)]
When mangling member-expressions, skip implicit accesses of anonymous union
objects. This is consistent with GCC's behavior. Patch by Tomasz Miąsko!

llvm-svn: 222402

10 years agoRemove support for undocumented SpecialCaseList entries.
Alexey Samsonov [Thu, 20 Nov 2014 01:27:19 +0000 (01:27 +0000)]
Remove support for undocumented SpecialCaseList entries.

"global-init", "global-init-src" and "global-init-type" were originally
used to blacklist entities in ASan init-order checker. However, they
were never documented, and later were replaced by "=init" category.

Old blacklist entries should be converted as follows:
  * global-init:foo -> global:foo=init
  * global-init-src:bar -> src:bar=init
  * global-init-type:baz -> type:baz=init

llvm-svn: 222401

10 years agoPR21531: fix crash on invalid with unexpanded pack in case value.
Richard Smith [Thu, 20 Nov 2014 01:24:12 +0000 (01:24 +0000)]
PR21531: fix crash on invalid with unexpanded pack in case value.

llvm-svn: 222400

10 years ago[Hexagon] Adding A2_xor instruction with IR selection pattern and test.
Colin LeMahieu [Wed, 19 Nov 2014 23:22:23 +0000 (23:22 +0000)]
[Hexagon] Adding A2_xor instruction with IR selection pattern and test.

llvm-svn: 222399

10 years agoRevert "[Reassociate] As the expression tree is rewritten make sure the operands...
Chad Rosier [Wed, 19 Nov 2014 23:21:20 +0000 (23:21 +0000)]
Revert "[Reassociate] As the expression tree is rewritten make sure the operands are"

This reverts commit r222142.  This is causing/exposing an execution-time regression
in spec2006/gcc and coremark on AArch64/A57/Ofast.

Conflicts:

test/Transforms/Reassociate/optional-flags.ll

llvm-svn: 222398

10 years agoRevert "[Reassociate] Update test cases due to r222142."
Chad Rosier [Wed, 19 Nov 2014 23:20:35 +0000 (23:20 +0000)]
Revert "[Reassociate] Update test cases due to r222142."

This reverts commit r222144.  Commit r222142 is being reverted due to
a spec2006/gcc execution-time regression.

Update mips-varargs test as well.

llvm-svn: 222397

10 years ago[Hexagon] Adding A2_or instruction with IR selection pattern and test.
Colin LeMahieu [Wed, 19 Nov 2014 22:58:04 +0000 (22:58 +0000)]
[Hexagon] Adding A2_or instruction with IR selection pattern and test.

llvm-svn: 222396

10 years agogold-plugin: Fix typo in error message
Duncan P. N. Exon Smith [Wed, 19 Nov 2014 22:39:21 +0000 (22:39 +0000)]
gold-plugin: Fix typo in error message

Spotted while reading code.

llvm-svn: 222395

10 years agoclang-format: [Java] Accept generic types in enum declaration
Daniel Jasper [Wed, 19 Nov 2014 22:38:18 +0000 (22:38 +0000)]
clang-format: [Java] Accept generic types in enum declaration

Before:
  enum Foo implements Bar<X, Y> {
    ABC {
      ...
    }
    , CDE {
      ...
    };
  }

After:
  enum Foo implements Bar<X, Y> {
    ABC {
      ...
    },
    CDE {
      ...
    };
  }

Patch by Harry Terkelsen.

llvm-svn: 222394

10 years ago[CMake] Always include the Clang repo version, just like the autoconf build.
Jordan Rose [Wed, 19 Nov 2014 22:03:48 +0000 (22:03 +0000)]
[CMake] Always include the Clang repo version, just like the autoconf build.

Now that LLVM's helper script GetSVN.cmake actually works consistently,
there's no reason not to use it. We avoid having to regenerate SVNVersion.inc
every time by marking it as dependent on Git's reflog or SVN's entries file.

This should end most of the issues of the AST format changing and breaking
old module files: CMake-Clang should now detect that the version changed just
like Autoconf-Clang has.

Based on r190557. Depends on LLVM r222391.

llvm-svn: 222393

10 years agoConstify a few IdentifierInfo * parameters.
Jordan Rose [Wed, 19 Nov 2014 22:03:46 +0000 (22:03 +0000)]
Constify a few IdentifierInfo * parameters.

No functionality change.

llvm-svn: 222392

10 years ago[CMake] Update GetSVN.cmake to use LLVM version control helper scripts.
Jordan Rose [Wed, 19 Nov 2014 22:03:21 +0000 (22:03 +0000)]
[CMake] Update GetSVN.cmake to use LLVM version control helper scripts.

This allows the logic to work with Git, and also uses the variable names
to match what Clang is actually looking for.

This is a re-application of r190556 and r190808. This changes the interface
of GetSVN.cmake. Clang change to follow.

llvm-svn: 222391

10 years agoRevert r222363: "[clang-tidy] Count errors in ClangTidyDiagnosticConsumer"
Hans Wennborg [Wed, 19 Nov 2014 22:02:11 +0000 (22:02 +0000)]
Revert r222363: "[clang-tidy] Count errors in ClangTidyDiagnosticConsumer"

This was causing clang-tidy invocations that would previously pass despite
source errors to fail.

llvm-svn: 222390

10 years agoADT: windows itanium targets msvcrt.dll
Saleem Abdulrasool [Wed, 19 Nov 2014 21:55:31 +0000 (21:55 +0000)]
ADT: windows itanium targets msvcrt.dll

Update the isOSMSVCRT to correctly identify that windows-itanium uses
msvcrt.dll.

llvm-svn: 222389

10 years ago[MSan] [MIPS] Adding support for MIPS64 (patch by Mohit Bhakkad).
Alexey Samsonov [Wed, 19 Nov 2014 21:42:33 +0000 (21:42 +0000)]
[MSan] [MIPS] Adding support for MIPS64 (patch by Mohit Bhakkad).

Reviewed at http://reviews.llvm.org/D5906

llvm-svn: 222388

10 years agoFix bug where a trivial constexpr copy/move operation couldn't copy from an
Richard Smith [Wed, 19 Nov 2014 21:27:17 +0000 (21:27 +0000)]
Fix bug where a trivial constexpr copy/move operation couldn't copy from an
empty non-constexpr object. Such a copy doesn't break any of the constexpr
rules.

llvm-svn: 222387

10 years agoTry to fix MSVS build after r222384. No intended behavior change.
Nico Weber [Wed, 19 Nov 2014 21:16:11 +0000 (21:16 +0000)]
Try to fix MSVS build after r222384. No intended behavior change.

llvm-svn: 222386

10 years agoFix Use-of-uninitialized-value for adrp_addr and adrp_inst in MachODump.cpp
Kevin Enderby [Wed, 19 Nov 2014 20:20:16 +0000 (20:20 +0000)]
Fix Use-of-uninitialized-value for adrp_addr and adrp_inst in MachODump.cpp

Fixes PR21607

llvm-svn: 222385

10 years agoSimplifyCFG: turn recursive GatherConstantCompares into iterative
Mehdi Amini [Wed, 19 Nov 2014 20:09:11 +0000 (20:09 +0000)]
SimplifyCFG: turn recursive GatherConstantCompares into iterative

A long sequence of || or && could lead to a stack explosion.

llvm-svn: 222384

10 years agoChange contradictory wording in va_copy test error message.
Eric Fiselier [Wed, 19 Nov 2014 20:01:26 +0000 (20:01 +0000)]
Change contradictory wording in va_copy test error message.

llvm-svn: 222383

10 years agoRegisterCoalescer: Improve debug messages
Matthias Braun [Wed, 19 Nov 2014 19:46:17 +0000 (19:46 +0000)]
RegisterCoalescer: Improve debug messages

- Show "Considering..." message after flipping so you actually see the final
  destination vreg as destination.
- Add a message on final join, so you can grep for "Success" messages to obtain
  a list of which register got merged with which.

llvm-svn: 222382

10 years agoAdd a print and verify pass after the RegisterCoalescer
Matthias Braun [Wed, 19 Nov 2014 19:46:15 +0000 (19:46 +0000)]
Add a print and verify pass after the RegisterCoalescer

llvm-svn: 222381

10 years agoMachineVerifier: Report register for bad liveranges
Matthias Braun [Wed, 19 Nov 2014 19:46:13 +0000 (19:46 +0000)]
MachineVerifier: Report register for bad liveranges

llvm-svn: 222380

10 years agoIntroduce register dump helper
Matthias Braun [Wed, 19 Nov 2014 19:46:11 +0000 (19:46 +0000)]
Introduce register dump helper

llvm-svn: 222379

10 years agoImplement N4280 - 'Non-member size() and more'
Marshall Clow [Wed, 19 Nov 2014 19:43:23 +0000 (19:43 +0000)]
Implement N4280 - 'Non-member size() and more'

llvm-svn: 222378

10 years agoDebugInfo: Don't emit a 'global variable' when a static member declaration is referen...
David Blaikie [Wed, 19 Nov 2014 19:42:40 +0000 (19:42 +0000)]
DebugInfo: Don't emit a 'global variable' when a static member declaration is referenced without a definition, just ensure the enclosing class (with the static member declaration) is emitted.

Addresses PR21511 by emitting appropriate metadata rather than
faux-global definitions for a variable that doesn't have a definition.

llvm-svn: 222377

10 years agoAliasSet: Simplify mergeSetIn
David Majnemer [Wed, 19 Nov 2014 19:36:18 +0000 (19:36 +0000)]
AliasSet: Simplify mergeSetIn

No functional change intended.

llvm-svn: 222376

10 years ago[X86] Improved lowering of v4x32 build_vector dag nodes.
Andrea Di Biagio [Wed, 19 Nov 2014 19:34:29 +0000 (19:34 +0000)]
[X86] Improved lowering of v4x32 build_vector dag nodes.

This patch improves the lowering of v4f32 and v4i32 build_vector dag nodes
that are known to have at least two non-zero elements.

With this patch, a build_vector that performs a blend with zero is
converted into a shuffle. This is done to let the shuffle legalizer expand
the dag node in a optimal way. For example, if we know that a build_vector
performs a blend with zero, we can try to lower it as a movq/blend instead of
always selecting an insertps.

This patch also improves the logic that lowers a build_vector into a insertps
with zero masking. See for example the extra test cases added to test sse41.ll.

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

llvm-svn: 222375

10 years ago[ADT] Fix PR20728 - Incorrect APFloat::fusedMultiplyAdd results for x86_fp80.
Lang Hames [Wed, 19 Nov 2014 19:15:41 +0000 (19:15 +0000)]
[ADT] Fix PR20728 - Incorrect APFloat::fusedMultiplyAdd results for x86_fp80.

As detailed at http://llvm.org/PR20728, due to an internal overflow in
APFloat::multiplySignificand the APFloat::fusedMultiplyAdd method can return
incorrect results for x87DoubleExtended (x86_fp80) values. This commonly
manifests as incorrect constant folding of libm fmal calls on x86. E.g.

fmal(1.0L, 1.0L, 3.0L) == 0.0L      (should be 4.0L)

This patch fixes PR20728 by adding an extra bit to the significand for
intermediate results of APFloat::multiplySignificand, avoiding the overflow.

llvm-svn: 222374

10 years agoFix a temporary MDNode leak.
Frederic Riss [Wed, 19 Nov 2014 18:53:46 +0000 (18:53 +0000)]
Fix a temporary MDNode leak.

While emitting debug information for function forward decalrations, we
create DISubprogram objects that aran't stored in the AllSubprograms
list, and thus won't get finalized by the DIBuilder. During the DIBuilder
finalize(), the temporary MDNode allocated for the DISubprogram
Variables field gets RAUWd with a non temporary DIArray. For the forward
declarations, simply delete that temporary node before we delete the
parent node, so that it doesn't leak.

llvm-svn: 222373

10 years agoAdd test for denied process attach by pid and fix found bugs in Process/ProcessPOSIX.cpp
Oleksiy Vyalov [Wed, 19 Nov 2014 18:27:45 +0000 (18:27 +0000)]
Add test for denied process attach by pid and fix found bugs in Process/ProcessPOSIX.cpp
and FreeBSD/ProcessMonitor.

http://reviews.llvm.org/D6240

llvm-svn: 222372

10 years agoDriver: correct typo
Saleem Abdulrasool [Wed, 19 Nov 2014 17:59:00 +0000 (17:59 +0000)]
Driver: correct typo

Fix a typo in the search path identified by Justin Bogner.

llvm-svn: 222371

10 years agoFix broken build after removing StringMap::GetOrCreateValue in favor of StringMap...
Oleksiy Vyalov [Wed, 19 Nov 2014 17:24:58 +0000 (17:24 +0000)]
Fix broken build after removing StringMap::GetOrCreateValue in favor of StringMap::insert.

llvm-svn: 222370

10 years ago[llvm-readobj][NFC]
Colin LeMahieu [Wed, 19 Nov 2014 17:10:39 +0000 (17:10 +0000)]
[llvm-readobj][NFC]
Appeasing mingw without C++11 std::to_string

llvm-svn: 222369

10 years agoR600/SI: Make SIInstrInfo::isOperandLegal() more strict
Tom Stellard [Wed, 19 Nov 2014 16:58:49 +0000 (16:58 +0000)]
R600/SI: Make SIInstrInfo::isOperandLegal() more strict

A register operand that has a common sub-class with its instruction's
defined register class is not always legal.  For example,
SReg_32 and M0Reg both have a common sub-class, but we can't
use an SReg_32 in instructions that expect a M0Reg.

This prevents the llvm.SI.sendmsg.ll test from failing when the fold
operand pass is added.

llvm-svn: 222368

10 years ago[mips][micromips] Implement SWM32 and LWM32 instructions
Zoran Jovanovic [Wed, 19 Nov 2014 16:44:02 +0000 (16:44 +0000)]
[mips][micromips] Implement SWM32 and LWM32 instructions
Differential Revision: http://reviews.llvm.org/D5519

llvm-svn: 222367

10 years agotodo: We can support modifiable memory access functions
Tobias Grosser [Wed, 19 Nov 2014 16:31:33 +0000 (16:31 +0000)]
todo: We can support modifiable memory access functions

llvm-svn: 222366

10 years agotodo: We now have OpenMP support in isl backend
Tobias Grosser [Wed, 19 Nov 2014 16:30:16 +0000 (16:30 +0000)]
todo: We now have OpenMP support in isl backend

llvm-svn: 222365

10 years agoVectorize a reduction chain feeding into a 'return' statement.
Suyog Sarda [Wed, 19 Nov 2014 16:07:38 +0000 (16:07 +0000)]
Vectorize a reduction chain feeding into a 'return' statement.
e.x
return (a[0]+b[0]) + (a[1]+b[1])

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

llvm-svn: 222364

10 years ago[clang-tidy] Count errors in ClangTidyDiagnosticConsumer
Alexander Kornienko [Wed, 19 Nov 2014 16:07:26 +0000 (16:07 +0000)]
[clang-tidy] Count errors in ClangTidyDiagnosticConsumer

llvm-svn: 222363

10 years agoChange states in the www/todo.html list
Johannes Doerfert [Wed, 19 Nov 2014 15:59:50 +0000 (15:59 +0000)]
Change states in the www/todo.html list

llvm-svn: 222362

10 years agoAdded entries for bugs 2118 and 2306, which were closed in Urbana
Marshall Clow [Wed, 19 Nov 2014 15:59:16 +0000 (15:59 +0000)]
Added entries for bugs 2118 and 2306, which were closed in Urbana

llvm-svn: 222361