Commit Graph

198018 Commits

Author SHA1 Message Date
Matthias Braun b6ac8fa39e AArch64: Don't lower ISD::SELECT to ISD::SELECT_CC
Instead of lowering SELECT to SELECT_CC which is further lowered later
immediately call the SELECT_CC lowering code. This is preferable
because:
- Avoids an unnecessary roundtrip through the legalization queues with
  an intermediate node.
- More importantly: Lowered operations get visited last leading to SELECT_CC
  getting visited with legalized operands and unlegalized ones for preexisting
  SELECT_CC nodes. This does not hurt the current code (hence no testcase) but
  is required for another patch I am working on.

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

llvm-svn: 234334
2015-04-07 17:33:05 +00:00
Duncan P. N. Exon Smith cb9b43b359 Revert "Workaround bot failure with explicit conversion to MDTuple*"
This reverts commit r234329, which insufficiently appeased older
`clang`s (apparently that wasn't the only call site).  r234331 was a
more complete fix.

llvm-svn: 234333
2015-04-07 17:30:52 +00:00
Oleksiy Vyalov 1c1d76b379 Delete port forwarding if ConnectRemote fails.
http://reviews.llvm.org/D8826

llvm-svn: 234332
2015-04-07 17:23:15 +00:00
Duncan P. N. Exon Smith 7acdbfc84b Workaround continued bot failures with MDTupleTypedArrayWrapper
Change the explicit constructor to be more specific.  I think this will
get us past the continued bot failures [1] with older clangs.

[1]: http://lab.llvm.org:8080/green/job/clang-stage1-cmake-RA-incremental_build/8203

llvm-svn: 234331
2015-04-07 17:07:01 +00:00
Sean Callanan 157f1af743 Fixed a problem where the second @import statement
in a session would be silently ignored by the compiler
because the compiler looked at its SourceLocation and
decided it had already handled it.

Also updated the relevant test case.

<rdar://problem/20315447>

llvm-svn: 234330
2015-04-07 17:02:02 +00:00
Duncan P. N. Exon Smith d382ed25f6 Workaround bot failure with explicit conversion to MDTuple*
A bot is failing [1] after r234326, apparently because this code doesn't
do what I think it should:

    template <class U>
    explicit MDTupleTypedArrayWrapper(
        const U &Tuple,
        typename std::enable_if<
            std::is_constructible<const MDTuple *, U>::value>::type * = nullptr)
        : N(Tuple) {}

Just be explicit for now.

[1]: http://lab.llvm.org:8080/green/job/clang-stage1-cmake-RA-incremental_build/8201/

llvm-svn: 234329
2015-04-07 17:00:12 +00:00
Fariborz Jahanian d436b2a4ce [Objective-C Sema] Patch to not issue unavailbility/deprecated
warning when multiple method declarations are found in global pool
with differing types and some are available.
rdar://20408445

llvm-svn: 234328
2015-04-07 16:56:27 +00:00
Duncan P. N. Exon Smith ebad0aa3ba DebugInfo: LLVM API change in r234326 for array-like tuple wrappers
Update a few calls to `DIBuilder` now that `MDTuple` array-wrappers
don't have implicit conversions to `MDTuple*`.  I may circle back and
update `DIBuilder` to take arrays here, to make it easier for the
callers.

llvm-svn: 234327
2015-04-07 16:50:49 +00:00
Duncan P. N. Exon Smith 1134473f51 IR: Remove MDTupleTypedArrayWrapper::operator MDTuple*()
Remove `MDTupleTypedArrayWrapper::operator MDTuple*()`, since it causes
ambiguity (at least in some [1] compilers [2]) when using indexes to
`MDTupleTypedArrayWrapper::operator[](unsigned)` that are convertible to
(but not the same as) `unsigned`.

[1]: http://lab.llvm.org:8011/builders/sanitizer-windows/builds/2308
[2]: http://lab.llvm.org:8011/builders/clang-cmake-mips/builds/4442

llvm-svn: 234326
2015-04-07 16:50:39 +00:00
Daniel Jasper e87e82bf79 Cleanup register pressure calculation in MachineLICM.
There were four almost identical implementations of calculating/updating
the register pressure for a certain MachineInstr. Cleanup to have a
single implementation (well, controlled with two bool flags until this
is cleaned up more).

No functional changes intended.

Tested by verify that there are no binary changes in the entire llvm
test-suite. A new test was added separately in r234309 as it revealed a
pre-existing error in the register pressure calculation.

llvm-svn: 234325
2015-04-07 16:42:35 +00:00
Tom Stellard da2969fca7 Implement atanh builtin
This implementation was ported from the AMD builtin library
and has been tested with piglit, OpenCV, and the ocl conformance tests.

llvm-svn: 234324
2015-04-07 16:20:22 +00:00
Tom Stellard ca4d382e11 Implement acosh builtin
This implementation was ported from the AMD builtin library
and has been tested with piglit, OpenCV, and the ocl conformance tests.

llvm-svn: 234323
2015-04-07 16:20:20 +00:00
Tamas Berghammer c85b580e98 Fix host config for Android and remove android specific part form Linux.
llvm-svn: 234322
2015-04-07 16:08:32 +00:00
Pavel Labath 76d5df132a Remove check for windows when compiling scripts directory
this is a followup to r234319, change requested in http://reviews.llvm.org/D8855.

llvm-svn: 234321
2015-04-07 15:30:23 +00:00
Daniel Jasper 53395406da clang-format: Fix regression formatting QT's "signals:" from r234318.
llvm-svn: 234320
2015-04-07 15:04:40 +00:00
Pavel Labath e4651eb033 Don't compile scripts directory if LLDB_DISABLE_PYTHON is set
Summary:
What looks like a typo has caused the scripts/Python directory to be compiled on non-Windows
platforms even with LLDB_DISABLE_PYTHON, which failed if Python.h was unavaiable. This changes
the condition to avoid compilation if LLDB_DISABLE_PYTHON is set.

Test Plan: Remove Python.h, verify compilation is successful.

Reviewers: zturner

Subscribers: lldb-commits

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

llvm-svn: 234319
2015-04-07 14:55:11 +00:00
Daniel Jasper 676e516354 clang-format: Don't allow labels when expecting declarations.
This fixes formatting unnamed bitfields (llvm.org/PR21999).

Before:
  struct MyStruct {
    uchar data;
  uchar:
    8;
  uchar:
    8;
    uchar other;
  };

After:
  struct MyStruct {
    uchar data;
    uchar : 8;
    uchar : 8;
    uchar other;
  };

llvm-svn: 234318
2015-04-07 14:36:33 +00:00
Pavel Labath 67239b2f73 Add some documentation about cross-compilation to www.
Reviewers: zturner, vharron, tberghammer, omjavaid

Subscribers: tberghammer, lldb-commits

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

llvm-svn: 234317
2015-04-07 14:36:23 +00:00
Toma Tabacu f25949b588 [mips] [IAS] Allow .set assignments for already defined symbols.
Summary:
This is not possible when using the IAS for MIPS, but it is possible when using the IAS for other architectures and when using GAS for MIPS.


Reviewers: dsanders

Reviewed By: dsanders

Subscribers: llvm-commits

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

llvm-svn: 234316
2015-04-07 13:59:39 +00:00
Rafael Espindola b91455b5c0 Refactor a lot of duplicated code for stub output.
This also moves it earlier so that it they are produced before we print
an end symbol for the data section.

llvm-svn: 234315
2015-04-07 13:42:44 +00:00
Aaron Ballman ac33624075 Silencing several "enumeral and non-enumeral type in conditional expression" warnings; NFC.
llvm-svn: 234314
2015-04-07 13:28:37 +00:00
Rafael Espindola d1294d9bb3 Clear the stub map in getSortedStubs.
This makes sure they are only output once (and frees a bit of memory).

llvm-svn: 234313
2015-04-07 12:59:28 +00:00
Toma Tabacu 3d5ce49ce5 [TableGen] Prevent invalid code generation when emitting AssemblerPredicate conditions.
Summary:
The loop which emits AssemblerPredicate conditions also links them together by emitting a '&&'.
If the 1st predicate is not an AssemblerPredicate, while the 2nd one is, nothing gets emitted for the 1st one, but we still emit the '&&' because of the 2nd predicate.
This generated code looks like "( && Cond2)" and is invalid.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: dsanders, llvm-commits

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

llvm-svn: 234312
2015-04-07 12:10:11 +00:00
Denis Protivensky 14ed198ff7 [ARM] Use getMappingAtomName in Release only
llvm-svn: 234311
2015-04-07 11:51:39 +00:00
Daniel Jasper 40c8194097 [MachineLICM] Remove obsolete comment about not considering reg pressure.
llvm-svn: 234310
2015-04-07 11:43:32 +00:00
Daniel Jasper c234535e04 Add test showing that MachineLICM is calculating register pressure wrong
More details: http://llvm.org/PR23143

llvm-svn: 234309
2015-04-07 11:41:40 +00:00
Timur Iskhodzhanov 90639edd3d Fix a compiler error under MSVC
Error message was:
CGDebugInfo.cpp(1047) : error C2666: 'llvm::MDTypeRefArray::operator []' : 2 overloads have similar conversions
  DebugInfoMetadata.h(106): could be 'llvm::MDTypeRef llvm::MDTypeRefArray::operator [](unsigned int) const'
  while trying to match the argument list '(llvm::DITypeArray, int)'

llvm-svn: 234308
2015-04-07 11:26:00 +00:00
Tamas Berghammer 83544cf660 Ignore mapping symbols on aarch64
ELF symbol tables on aarch64 may contains some mapping symbols. They
provide information about the underlying data but interfere with symbol
look-up of lldb. They are already ignored on arm32. With this CL they
will be ignored on aarch64 also.

Differential revision: http://reviews.llvm.org/D8776

llvm-svn: 234307
2015-04-07 10:43:50 +00:00
Daniel Jasper 303c3ac925 Revert "[SEH] Implement filter capturing in CodeGen"
Test fails:
http://lab.llvm.org:8080/green/job/clang-stage2-configure-Rlto_check/3182/

llvm-svn: 234306
2015-04-07 10:07:47 +00:00
Ilia K 68757ed2e9 implement gdb-set output-radix
Summary: Patch from chuckr@microsoft.com

Reviewers: abidh, ChuckR

Reviewed By: abidh

Subscribers: paulmaybee, ki.stfu, greggm, scarroll, lldb-commits

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

llvm-svn: 234305
2015-04-07 09:47:23 +00:00
Daniel Jasper acf67e3ecd clang-format: Improve nested block formatting.
Before:
  functionA(functionB({
    int i;
    int j;
  }),
            aaaa, bbbb, cccc);

After:
  functionA(functionB({
              int i;
              int j;
            }),
            aaaa, bbbb, cccc);

llvm-svn: 234304
2015-04-07 08:20:35 +00:00
Denis Protivensky dd7adf7a18 [ARM] Rename applyThmReloc => applyThumb32Reloc
llvm-svn: 234302
2015-04-07 07:14:13 +00:00
Denis Protivensky 6c50e88c0d [ARM] Add mapping symbols to PLT entries
Make PLT entry atoms represent mapping symbols in the Release mode,
while in the Debug mode they are still function-like symbols
with regular names.
It's legal that mapping symbols denote unnamed parts of code,
and PLT entries are not required to have function-like names.

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

llvm-svn: 234301
2015-04-07 07:04:42 +00:00
Daniel Jasper 9dedc775d7 clang-format: Indent relative to the ./-> and not the function name.
Before:
  aaaaaaaaaaa     //
      .aaaa(      //
           bbbb)  // This is different ..
      .aaaa(      //
          cccc);  // .. from this.

After:
  aaaaaaaaaaa     //
      .aaaa(      //
          bbbb)   // This is identical ..
      .aaaa(      //
          cccc);  // .. to this.

llvm-svn: 234300
2015-04-07 06:41:24 +00:00
Lang Hames 2be1bbea7e [RuntimeDyld] Always allocate at least 1 byte for object sections in the JIT to
ensure that section addresses are distinct.

mapSectionAddress will fail if two sections are allocated the same address,
which can happen if any section has zero size (since malloc(0) is implementation
defined). Unfortunately I've been unable to repro this with a simple test case.

Fixes <rdar://problem/20314015>.

llvm-svn: 234299
2015-04-07 06:27:56 +00:00
Lang Hames ed96cb7fc6 [Orc] Save all the x86-64 GPRs before re-entering the JIT.
The re-entry code should work for all calling conventions.

llvm-svn: 234298
2015-04-07 06:12:21 +00:00
David Majnemer 06864814e5 [Sema] Don't crash when __attribute__((nonnull)) is applied to blocks
A simple case of asserting isFunctionOrMethod when we should have
asserted isFunctionOrMethodOrBlock.

This fixes PR23117.

llvm-svn: 234297
2015-04-07 06:01:53 +00:00
Marshall Clow 1f508014df In many places, there was an #ifdef/#else block that selected one of two implmentations of rebind_alloc based on whether or not we had template aliases. Create a helper struct to encapsulate that bit of logic, and replace all the ifdefs with uses of that struct. No functionality change intented.
llvm-svn: 234296
2015-04-07 05:21:38 +00:00
Duncan P. N. Exon Smith 1c0844bdfb Try a third time to fix MSVC build after r234290
I have no idea what MSVC means with its error text here :(.

http://lab.llvm.org:8011/builders/sanitizer-windows/builds/2310

llvm-svn: 234295
2015-04-07 05:03:47 +00:00
Duncan P. N. Exon Smith 8a4569bd2b Try again to fix MSVC build after r234290
Still failing:

http://lab.llvm.org:8011/builders/sanitizer-windows/builds/2309

llvm-svn: 234294
2015-04-07 04:49:13 +00:00
Simon Atanasyan d526486763 [ELF] Remove redundant const_cast
No functional changes.

llvm-svn: 234293
2015-04-07 04:38:30 +00:00
Duncan P. N. Exon Smith 4ddfd73aa1 Try to fix MSVC build after r234290
http://lab.llvm.org:8011/builders/sanitizer-windows/builds/2308

llvm-svn: 234292
2015-04-07 04:33:42 +00:00
Duncan P. N. Exon Smith a98fac64ea DebugInfo: Update for LLVM change in r234290
The API for `DIArray` changed; use the new one.

llvm-svn: 234291
2015-04-07 04:14:45 +00:00
Duncan P. N. Exon Smith 000fa2c646 DebugInfo: Remove DITypedArray<>, replace with typedefs
Replace all uses of `DITypedArray<>` with `MDTupleTypedArrayWrapper<>`
and `MDTypeRefArray`.  The APIs are completely different, but the
provided functionality is the same: treat an `MDTuple` as if it's an
array of a particular element type.

To simplify this patch a bit, I've temporarily typedef'ed
`DebugNodeArray` to `DIArray` and `MDTypeRefArray` to `DITypeArray`.
I've also temporarily conditionalized the accessors to check for null --
eventually these should be changed to asserts and the callers should
check for null themselves.

There's a tiny accompanying patch to clang.

llvm-svn: 234290
2015-04-07 04:14:33 +00:00
Duncan P. N. Exon Smith 8d33fdc3bf DebugInfo: Remove DICompositeType mutation API
Change `DIBuilder` to mutate `MDCompositeTypeBase` directly, and remove
the wrapping API in `DICompositeType`.

llvm-svn: 234289
2015-04-07 04:12:02 +00:00
Duncan P. N. Exon Smith d5e6a153ad DebugInfo: Use DebugNodeRef in MDImportedEntity::getEntity()
A quick cleanup to sue `DebugNodeRef` instead of `Metadata*` for
`MDImportedEntity::getEntity()`.

llvm-svn: 234288
2015-04-07 04:07:31 +00:00
Duncan P. N. Exon Smith bd42d5d7e0 DebugInfo: Move DIFlag accessors from DIVariable to MDLocalVariable
llvm-svn: 234287
2015-04-07 03:55:30 +00:00
Duncan P. N. Exon Smith 86cc332462 DebugInfo: Move DIExpression bit-piece API to MDExpression
llvm-svn: 234286
2015-04-07 03:49:59 +00:00
Duncan P. N. Exon Smith 76c9184434 DebugInfo: Remove special iterators from DIExpression
Remove special iterators from `DIExpression` in favour of same in
`MDExpression`.  There should be no functionality change here.

Note that the APIs are slightly different: `getArg(unsigned)` counts
from 0, not 1, in the `MDExpression` version of the iterator.

llvm-svn: 234285
2015-04-07 03:45:57 +00:00
Rui Ueyama 752a8c3e55 ELF: Minimum alignment value is 1, not 0. NFC.
Maybe we can interpret alignment 0 as "don't care", but for
consistency, it's good to set 1 instead of 0 where we allow
any alignments.

llvm-svn: 234284
2015-04-07 03:44:26 +00:00