platform/upstream/llvm.git
9 years ago[DAGCombiner] Fixed minor typo that was missed in D9097.
Simon Pilgrim [Sun, 19 Jul 2015 11:31:40 +0000 (11:31 +0000)]
[DAGCombiner] Fixed minor typo that was missed in D9097.

We don't bitcast the UNDEFs - that is done in visitVECTOR_SHUFFLE, and the getValueType should come from the operand's SDValue not the SDNode.

llvm-svn: 242640

9 years ago[X86] Add support for tbyte memory operand size for Intel-syntax x86 assembly
Michael Kuperstein [Sun, 19 Jul 2015 11:03:08 +0000 (11:03 +0000)]
[X86] Add support for tbyte memory operand size for Intel-syntax x86 assembly

Differential Revision: http://reviews.llvm.org/D11257
Patch by: marina.yatsina@intel.com

llvm-svn: 242639

9 years agoRemove TargetInstrInfo::canFoldMemoryOperand
Simon Pilgrim [Sun, 19 Jul 2015 10:50:53 +0000 (10:50 +0000)]
Remove TargetInstrInfo::canFoldMemoryOperand

canFoldMemoryOperand is not actually used anywhere in the codebase - all existing users instead call foldMemoryOperand directly when they wish to fold and can correctly deduce what they need from the return value.

This patch removes the canFoldMemoryOperand base function and the target implementations; only x86 had a real (bit-rotted) implementation, although AMDGPU had a preparatory stub that had never needed to be completed.

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

llvm-svn: 242638

9 years agoAVX-512: Floating point conversions for SKX - DAG Lowering.
Elena Demikhovsky [Sun, 19 Jul 2015 10:17:33 +0000 (10:17 +0000)]
AVX-512: Floating point conversions for SKX - DAG Lowering.
SKX supports conversion for all FP types. Integer types include doublewords and quardwords.
I added "Legal" status for these nodes and a bunch of tests.
I added "NoVLX" for AVX DAG selection to force VLX instructions selection when VLX is supported.

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

llvm-svn: 242637

9 years agoUse SDValue bool check. NFCI.
Simon Pilgrim [Sun, 19 Jul 2015 09:56:36 +0000 (09:56 +0000)]
Use SDValue bool check. NFCI.

llvm-svn: 242636

9 years ago[X86][AVX512BW] add clang intrinsics for pmulhrsw / pmulhuw / pmulhw
Asaf Badouh [Sun, 19 Jul 2015 08:47:31 +0000 (08:47 +0000)]
[X86][AVX512BW] add clang intrinsics for pmulhrsw / pmulhuw / pmulhw

also made minor fix in "test_mm512_maskz_permutex2var_epi16"

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

llvm-svn: 242635

9 years agoFix warnings in unordered_map
Eric Fiselier [Sun, 19 Jul 2015 03:16:47 +0000 (03:16 +0000)]
Fix warnings in unordered_map

llvm-svn: 242634

9 years agoFix warnings in forwardlist
Eric Fiselier [Sun, 19 Jul 2015 00:38:37 +0000 (00:38 +0000)]
Fix warnings in forwardlist

llvm-svn: 242633

9 years agoFix warnings in deque tests
Eric Fiselier [Sun, 19 Jul 2015 00:31:54 +0000 (00:31 +0000)]
Fix warnings in deque tests

llvm-svn: 242632

9 years ago[LIT] Allow for executeCommand to take the stdin input.
Eric Fiselier [Sun, 19 Jul 2015 00:28:14 +0000 (00:28 +0000)]
[LIT] Allow for executeCommand to take the stdin input.

Summary: This patch allows executeCommand to pass a string to the processes stdin.

Reviewers: ddunbar, jroelofs

Subscribers: llvm-commits

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

llvm-svn: 242631

9 years agoCommit file missing from r242629
Eric Fiselier [Sun, 19 Jul 2015 00:11:50 +0000 (00:11 +0000)]
Commit file missing from r242629

llvm-svn: 242630

9 years agoFix warnings in array and assoc containers
Eric Fiselier [Sat, 18 Jul 2015 23:56:04 +0000 (23:56 +0000)]
Fix warnings in array and assoc containers

llvm-svn: 242629

9 years agoRemove unused typedefs in random and regex
Eric Fiselier [Sat, 18 Jul 2015 22:57:14 +0000 (22:57 +0000)]
Remove unused typedefs in random and regex

llvm-svn: 242628

9 years agoCleanup warnings in test/std/depr
Eric Fiselier [Sat, 18 Jul 2015 22:51:51 +0000 (22:51 +0000)]
Cleanup warnings in test/std/depr

llvm-svn: 242627

9 years agoFix warnings in test/std/algorithms
Eric Fiselier [Sat, 18 Jul 2015 21:53:16 +0000 (21:53 +0000)]
Fix warnings in test/std/algorithms

llvm-svn: 242626

9 years agoFix unused variable warnings in atomic tests
Eric Fiselier [Sat, 18 Jul 2015 21:40:37 +0000 (21:40 +0000)]
Fix unused variable warnings in atomic tests

llvm-svn: 242625

9 years agoFix warnings in test/std/language.support
Eric Fiselier [Sat, 18 Jul 2015 21:17:16 +0000 (21:17 +0000)]
Fix warnings in test/std/language.support

llvm-svn: 242624

9 years agoEnable and fix warnings during the build.
Eric Fiselier [Sat, 18 Jul 2015 20:40:46 +0000 (20:40 +0000)]
Enable and fix warnings during the build.

Although CMake adds warning flags, they are ignored in the libc++ headers
because the headers '#pragma system header' themselves.

This patch disables the system header pragma when building libc++ and fixes
the warnings that arose.

The warnings fixed were:
1. <memory> - anonymous structs are a GNU extension
2. <functional> - anonymous structs are a GNU extension.
3. <__hash_table> - Embedded preprocessor directives have undefined behavior.
4. <string> - Definition is missing noexcept from declaration.
5. <__std_stream> - Unused variable.

llvm-svn: 242623

9 years ago[CodeGen] Don't dereference vector::end if the vector can be empty
Benjamin Kramer [Sat, 18 Jul 2015 20:30:11 +0000 (20:30 +0000)]
[CodeGen] Don't dereference vector::end if the vector can be empty

MSVC complains about this in debug mode. NFC.

llvm-svn: 242622

9 years ago[X86][SSE] Updated SHL/LSHR i64 vectorization costs.
Simon Pilgrim [Sat, 18 Jul 2015 20:06:30 +0000 (20:06 +0000)]
[X86][SSE] Updated SHL/LSHR i64 vectorization costs.

This was missed in D8416.

llvm-svn: 242621

9 years ago[AggressiveAntiDepBreaker] Use range loops for multimap access.
Benjamin Kramer [Sat, 18 Jul 2015 20:05:10 +0000 (20:05 +0000)]
[AggressiveAntiDepBreaker] Use range loops for multimap access.

No functionality change intended.

llvm-svn: 242620

9 years agoRangify for loops in GlobalDCE, NFC.
Yaron Keren [Sat, 18 Jul 2015 19:57:34 +0000 (19:57 +0000)]
Rangify for loops in GlobalDCE, NFC.

llvm-svn: 242619

9 years agoFix up typos in a couple of tests; due to agressive short-circuiting, they never...
Marshall Clow [Sat, 18 Jul 2015 18:24:15 +0000 (18:24 +0000)]
Fix up typos in a couple of tests; due to agressive short-circuiting, they never failed on clang or gcc, but MSVC whined. Patch by Andrew Parker.

llvm-svn: 242618

9 years agoAdd missing instrumentation in vector::insert - Patch from Anna Zaks
Eric Fiselier [Sat, 18 Jul 2015 18:22:12 +0000 (18:22 +0000)]
Add missing instrumentation in vector::insert - Patch from Anna Zaks

This patch was reviewed as D10859. http://reviews.llvm.org/D10859

llvm-svn: 242617

9 years ago[Hexagon] Use composition instead of inheritance from STL types
Benjamin Kramer [Sat, 18 Jul 2015 17:43:23 +0000 (17:43 +0000)]
[Hexagon] Use composition instead of inheritance from STL types

The standard containers are not designed to be inherited from, as
illustrated by the MSVC hacks for NodeOrdering. No functional change
intended.

llvm-svn: 242616

9 years ago[AST] Remove StmtRange in favor of an iterator_range.
Benjamin Kramer [Sat, 18 Jul 2015 17:09:36 +0000 (17:09 +0000)]
[AST] Remove StmtRange in favor of an iterator_range.

StmtRange was just a convenient wrapper for two StmtIterators before
we had real range support. This removes some of the implicit conversions
StmtRange had leading to slightly more verbose code but also should make
more obvious what's going on. No functional change intended.

llvm-svn: 242615

9 years ago[X86][SSE] Added additional fp/int tests.
Simon Pilgrim [Sat, 18 Jul 2015 17:05:39 +0000 (17:05 +0000)]
[X86][SSE] Added additional fp/int tests.

Demonstrates some shortfalls in subvector(cvt(x)) compared to cvt(subvector(x)) patterns - especially on AVX/AVX2 targets.

llvm-svn: 242614

9 years agoRefreshed tests.
Simon Pilgrim [Sat, 18 Jul 2015 16:53:51 +0000 (16:53 +0000)]
Refreshed tests.

llvm-svn: 242613

9 years ago[libcxx] Get is_*_destructible tests passing in C++03.
Eric Fiselier [Sat, 18 Jul 2015 16:43:58 +0000 (16:43 +0000)]
[libcxx] Get is_*_destructible tests passing in C++03.

Summary: This patch adds proper guards to the is_destructible tests depending on the standard version so that they pass in c++03.

Reviewers: mclow.lists, EricWF

Subscribers: cfe-commits

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

llvm-svn: 242612

9 years agoclang-format: Take nested lines into account when detection C++03
Daniel Jasper [Sat, 18 Jul 2015 16:35:30 +0000 (16:35 +0000)]
clang-format: Take nested lines into account when detection C++03
compatibility and variable alignment.

llvm-svn: 242611

9 years agoRefreshed tests and reordered in descending integer size.
Simon Pilgrim [Sat, 18 Jul 2015 16:14:56 +0000 (16:14 +0000)]
Refreshed tests and reordered in descending integer size.

llvm-svn: 242610

9 years agoTidyup shufflevector calls - don't repeat inputs if you can avoid it.
Simon Pilgrim [Sat, 18 Jul 2015 15:56:33 +0000 (15:56 +0000)]
Tidyup shufflevector calls - don't repeat inputs if you can avoid it.

llvm-svn: 242609

9 years ago[AST] Cleanup ExprIterator.
Benjamin Kramer [Sat, 18 Jul 2015 14:35:53 +0000 (14:35 +0000)]
[AST] Cleanup ExprIterator.

- Make it a proper random access iterator with a little help from iterator_adaptor_base
- Clean up users of magic dereferencing. The iterator should behave like an Expr **.
- Make it an implementation detail of Stmt. This allows inlining of the assertions.

llvm-svn: 242608

9 years ago[clang-modernize] Don't rely on iterator auto-dereferencing.
Benjamin Kramer [Sat, 18 Jul 2015 14:35:41 +0000 (14:35 +0000)]
[clang-modernize] Don't rely on iterator auto-dereferencing.

llvm-svn: 242607

9 years agoSilence the driver warnings, if we see "-w" on the Driver.
Filipe Cabecinhas [Sat, 18 Jul 2015 06:35:24 +0000 (06:35 +0000)]
Silence the driver warnings, if we see "-w" on the Driver.

Summary:
We can enable warnings after that -w, so the patch might not be 100%
correct.

The problem that triggered this is: we have some amount of tests that
expect 0 warnings (including unit tests for -w), but -w ends up not fully
silencing everything.

Reviewers: echristo, chandlerc

Subscribers: cfe-commits

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

llvm-svn: 242606

9 years ago[PM/AA] Remove the addEscapingUse update API that won't be easy to
Chandler Carruth [Sat, 18 Jul 2015 03:26:46 +0000 (03:26 +0000)]
[PM/AA] Remove the addEscapingUse update API that won't be easy to
directly model in the new PM.

This also was an incredibly brittle and expensive update API that was
never fully utilized by all the passes that claimed to preserve AA, nor
could it reasonably have been extended to all of them. Any number of
places add uses of values. If we ever wanted to reliably instrument
this, we would want a callback hook much like we have with ValueHandles,
but doing this for every use addition seems *extremely* expensive in
terms of compile time.

The only user of this update mechanism is GlobalsModRef. The idea of
using this to keep it up to date doesn't really work anyways as its
analysis requires a symmetric analysis of two different memory
locations. It would be very hard to make updates be sufficiently
rigorous to *guarantee* symmetric analysis in this way, and it pretty
certainly isn't true today.

However, folks have been using GMR with this update for a long time and
seem to not be hitting the issues. The reported issue that the update
hook fixes isn't even a problem any more as other changes to
GetUnderlyingObject worked around it, and that issue stemmed from *many*
years ago. As a consequence, a prior patch provided a flag to control
the unsafe behavior of GMR, and this patch removes the update mechanism
that has questionable compile-time tradeoffs and is causing problems
with moving to the new pass manager. Note the lack of test updates --
not one test in tree actually requires this update, even for a contrived
case.

All of this was extensively discussed on the dev list, this patch will
just enact what that discussion decides on. I'm sending it for review in
part to show what I'm planning, and in part to show the *amazing* amount
of work this avoids. Every call to the AA here is something like three
to six indirect function calls, which in the non-LTO pipeline never do
any work! =[

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

llvm-svn: 242605

9 years ago[cmake] Support enabling -Werror in the OpenMP runtime CMake build and
Chandler Carruth [Sat, 18 Jul 2015 03:14:02 +0000 (03:14 +0000)]
[cmake] Support enabling -Werror in the OpenMP runtime CMake build and
clean up the build.

This disables all of the Clang warnings that fire for me when building
libomp.so on Linux with a recent Clang binary. Lots of these should
probably be fixed, but I want to at least get the build warning-clean
and make it easy to keep that way.

I also switched a bunch of the warnings that are used both for C and C++
compiles to check the flag with C compilation test.

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

llvm-svn: 242604

9 years agoDriver/ToolChain/AMDGPU: Attempt to fix buildbots after r242601
Tom Stellard [Sat, 18 Jul 2015 02:11:07 +0000 (02:11 +0000)]
Driver/ToolChain/AMDGPU: Attempt to fix buildbots after r242601

llvm-svn: 242602

9 years agoDriver: Add AMDGPU toolchain
Tom Stellard [Sat, 18 Jul 2015 01:49:05 +0000 (01:49 +0000)]
Driver: Add AMDGPU toolchain

Summary:
This is a minimal toolchain, which sets the integrated assembler as default,
and uses lld for linking.

Reviewers: arsenm, mcrosier

Subscribers: cfe-commits

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

llvm-svn: 242601

9 years ago[Sema] Emit correct warning when copy-elision is not possible.
Davide Italiano [Sat, 18 Jul 2015 01:15:19 +0000 (01:15 +0000)]
[Sema] Emit correct warning when copy-elision is not possible.

If we're returning a function parameter, copy elision isn't possible,
so we now warn for redundant move.

PR: 23819
Differential Revision:  http://reviews.llvm.org/D11305

llvm-svn: 242600

9 years agoAdd evil hack to workaround the missing libdl.a in the Android toolchain.
Chaoren Lin [Sat, 18 Jul 2015 01:09:43 +0000 (01:09 +0000)]
Add evil hack to workaround the missing libdl.a in the Android toolchain.

Reviewers: vharron, ovyalov

Subscribers: tberghammer, danalbert, srhines, lldb-commits

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

llvm-svn: 242599

9 years agoApply Android -pie switch to buildDefault as well.
Chaoren Lin [Sat, 18 Jul 2015 00:37:55 +0000 (00:37 +0000)]
Apply Android -pie switch to buildDefault as well.

Reviewers: ovyalov

Subscribers: tberghammer, danalbert, srhines, lldb-commits

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

llvm-svn: 242598

9 years ago[libFuzzer] require the files and directories passed to the fuzzer to exist
Kostya Serebryany [Sat, 18 Jul 2015 00:03:37 +0000 (00:03 +0000)]
[libFuzzer] require the files and directories passed to the fuzzer to exist

llvm-svn: 242596

9 years ago[asan] Fix shadow mapping on Android/AArch64.
Evgeniy Stepanov [Fri, 17 Jul 2015 23:51:18 +0000 (23:51 +0000)]
[asan] Fix shadow mapping on Android/AArch64.

Instrumentation and the runtime library were in disagreement about
ASan shadow offset on Android/AArch64.

This fixes a large number of existing tests on Android/AArch64.

llvm-svn: 242595

9 years ago[Sanitizer] Teach ReadFileToBuffer to distinguish empty file from inaccessible file.
Alexey Samsonov [Fri, 17 Jul 2015 23:50:08 +0000 (23:50 +0000)]
[Sanitizer] Teach ReadFileToBuffer to distinguish empty file from inaccessible file.

Summary:
This fixes https://code.google.com/p/address-sanitizer/issues/detail?id=399
(sanitizers crash with empty suppression files).

Reviewers: kcc

Subscribers: llvm-commits

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

llvm-svn: 242594

9 years agoMore packet performance improvements.
Greg Clayton [Fri, 17 Jul 2015 23:42:28 +0000 (23:42 +0000)]
More packet performance improvements.

Changed the "jthreads" key/value in the stop reply packets to be "jstopinfo". This JSON only contains threads with valid stop reasons and allows us not to have to ask about other threads via qThreadStopInfo when we are stepping. The "jstopinfo" only gets sent if there are more than one thread since the stop reply packet contains all the info needed for a single thread.

Added a Process::WillPublicStop() in case process subclasses want to do any extra gathering for public stops. For ProcessGDBRemote, we end up sending a jThreadsInfo packet to gather all expedited registers, expedited memory and MacOSX queue information. We only do this for public stops to minimize the packets we send when we have multiple private stops. Multiple private stops happen when a source level single step, step into or step out run the process multiple times while implementing the stepping, and none of these private stops make it out to the UI via notifications because they are private stops.

llvm-svn: 242593

9 years ago[MS ABI] Explicit specialization of static data members are weak
David Majnemer [Fri, 17 Jul 2015 23:36:49 +0000 (23:36 +0000)]
[MS ABI] Explicit specialization of static data members are weak

Normally, explicit specializations are treated like strong external
definitions.  However, MSVC treats explicit specializations of static
data members as weak.  MSVC 2013's <regex> implementation has such an
explicit specialization which leads to clang emitting a strong
definition in each translation unit which includes it.  Tweak clang's
linkage calculation to give such entities GVA_StrongODR linkage instead.

This fixes PR24165.

llvm-svn: 242592

9 years agoInstrProf: Promote this assert to a report_fatal_error
Justin Bogner [Fri, 17 Jul 2015 23:31:21 +0000 (23:31 +0000)]
InstrProf: Promote this assert to a report_fatal_error

If this assert does fire, the no-asserts behaviour is an infinite
loop. It's better to crash in this case so we get a crash report and
stop wasting the user's cpu cycles.

llvm-svn: 242591

9 years agoadded test file
Naomi Musgrave [Fri, 17 Jul 2015 23:28:02 +0000 (23:28 +0000)]
added test file

llvm-svn: 242590

9 years agore-added changes due to svn config setting issues
Naomi Musgrave [Fri, 17 Jul 2015 23:28:00 +0000 (23:28 +0000)]
re-added changes due to svn config setting issues

llvm-svn: 242589

9 years agoARM: Enable MachineScheduler and disable PostRAScheduler for swift.
Matthias Braun [Fri, 17 Jul 2015 23:18:30 +0000 (23:18 +0000)]
ARM: Enable MachineScheduler and disable PostRAScheduler for swift.

Reapply r242500 now that the swift schedmodel includes LDRLIT.

This is mostly done to disable the PostRAScheduler which optimizes for
instruction latencies which isn't a good fit for out-of-order
architectures. This also allows to leave out the itinerary table in
swift in favor of the SchedModel ones.

This change leads to performance improvements/regressions by as much as
10% in some benchmarks, in fact we loose 0.4% performance over the
llvm-testsuite for reasons that appear to be unknown or out of the
compilers control. rdar://20803802 documents the investigation of
these effects.

While it is probably a good idea to perform the same switch for the
other ARM out-of-order CPUs, I limited this change to swift as I cannot
perform the benchmark verification on the other CPUs.

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

llvm-svn: 242588

9 years agoARM: Add scheduling information for LDRLIT instructions to swift scheduling model
Matthias Braun [Fri, 17 Jul 2015 23:18:26 +0000 (23:18 +0000)]
ARM: Add scheduling information for LDRLIT instructions to swift scheduling model

These pseudo instructions are only lowered after register allocation and
are therefore still present when the machine scheduler runs.
Add a run: line to a testcase that uses the uncommon flags necessary to
actually produce a LDRLIT instruction on swift.

llvm-svn: 242587

9 years agoHandle dumping many more packet types including the A packet, qC, QSetDisableASLR...
Greg Clayton [Fri, 17 Jul 2015 23:08:14 +0000 (23:08 +0000)]
Handle dumping many more packet types including the A packet, qC, QSetDisableASLR, qLaunchSuccess and QLaunchArch.

llvm-svn: 242586

9 years ago[RAGreedy] Add an experimental deferred spilling feature.
Quentin Colombet [Fri, 17 Jul 2015 23:04:06 +0000 (23:04 +0000)]
[RAGreedy] Add an experimental deferred spilling feature.

The idea of deferred spilling is to delay the insertion of spill code until the
very end of the allocation. A "candidate" to spill variable might not required
to be spilled because of other evictions that happened after this decision was
taken. The spirit is similar to the optimistic coloring strategy implemented in
Preston and Briggs graph coloring algorithm.

For now, this feature is highly experimental. Although correct, it would require
much more modification to properly model the effect of spilling.

Anyway, this early patch helps prototyping this feature.

Note: The test case cannot unfortunately be reduced and is probably fragile.
llvm-svn: 242585

9 years agoMIR Parser: Allow the dollar characters in all of the identifier tokens.
Alex Lorenz [Fri, 17 Jul 2015 22:48:04 +0000 (22:48 +0000)]
MIR Parser: Allow the dollar characters in all of the identifier tokens.

This commit modifies the machine instruction lexer so that it now accepts the
'$' characters in identifier tokens.

This change makes the syntax for unquoted global value tokens consistent with
the syntax for the global idenfitier tokens in the LLVM's assembly language.

llvm-svn: 242584

9 years agoRemove a static helper function and use the StringPrinter API exclusively to format...
Enrico Granata [Fri, 17 Jul 2015 22:39:35 +0000 (22:39 +0000)]
Remove a static helper function and use the StringPrinter API exclusively to format NSStrings

llvm-svn: 242583

9 years ago[asan] Fix sanitizer_allocator_test on AArch64.
Evgeniy Stepanov [Fri, 17 Jul 2015 22:29:05 +0000 (22:29 +0000)]
[asan] Fix sanitizer_allocator_test on AArch64.

llvm-svn: 242582

9 years agoCleanup tests that fail in C++1z and with Clang 3.8
Eric Fiselier [Fri, 17 Jul 2015 22:27:43 +0000 (22:27 +0000)]
Cleanup tests that fail in C++1z and with Clang 3.8

llvm-svn: 242581

9 years agoDetect if necessary to build inferior with -pie for Android.
Chaoren Lin [Fri, 17 Jul 2015 22:13:29 +0000 (22:13 +0000)]
Detect if necessary to build inferior with -pie for Android.

Summary:
- Add target_is_android check (with cached results).
- Make android_device_api also cache results.
- Also removes the need to pass --env OS=Android when testing against Android.

Reviewers: sivachandra, tberghammer, clayborg, danalbert

Subscribers: chaoren, tberghammer, danalbert, srhines, lldb-commits

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

llvm-svn: 242580

9 years agoAsmParser: Add a function to parse a standalone constant value.
Alex Lorenz [Fri, 17 Jul 2015 22:07:03 +0000 (22:07 +0000)]
AsmParser: Add a function to parse a standalone constant value.

This commit extends the interface provided by the AsmParser library by adding a
function that allows the user to parse a standalone contant value.

This change is useful for MIR serialization, as it will allow the MIR Parser to
parse the constant values in a machine constant pool.

Reviewers: Duncan P. N. Exon Smith

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

llvm-svn: 242579

9 years agoHopefully fix android i386 build after r242554.
James Y Knight [Fri, 17 Jul 2015 21:58:11 +0000 (21:58 +0000)]
Hopefully fix android i386 build after r242554.

That platform has alignof(uint64_t) == 4, but, since LLVM_ALIGNAS(...)
cannot take anything but literal integers due to MSVC limitations, the
literal '8' used there didn't match. Switch ScopeStackAlignment to
just use 8, as well.

llvm-svn: 242578

9 years ago[Makefiles] Re-add OSX specific code that got lost in lldbHost consolidation
Keno Fischer [Fri, 17 Jul 2015 21:47:35 +0000 (21:47 +0000)]
[Makefiles] Re-add OSX specific code that got lost in lldbHost consolidation

llvm-svn: 242577

9 years agoCheck if altsep exists before replace.
Chaoren Lin [Fri, 17 Jul 2015 21:40:11 +0000 (21:40 +0000)]
Check if altsep exists before replace.

llvm-svn: 242576

9 years agoHandle altsep ('/' on Windows) in compiler path for log files.
Chaoren Lin [Fri, 17 Jul 2015 21:37:26 +0000 (21:37 +0000)]
Handle altsep ('/' on Windows) in compiler path for log files.

Reviewers: chying

Subscribers: lldb-commits

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

llvm-svn: 242575

9 years agobasic: default to MSVC on Windows
Saleem Abdulrasool [Fri, 17 Jul 2015 21:26:41 +0000 (21:26 +0000)]
basic: default to MSVC on Windows

The "armv7-windows", "i686-windows", and "x86_64-windows" targets should be
equivalent to the MSVC environment.  This was previously discussed when the
triples for Windows werw canonicalised.  Im not sure how this was overlooked.
This fixes the emission of non-COFF formats on Windows.

Thanks to ki9a for reporting this issue over IRC!

llvm-svn: 242574

9 years agoMake this test case be somewhat less verbose when not asked to
Enrico Granata [Fri, 17 Jul 2015 21:11:46 +0000 (21:11 +0000)]
Make this test case be somewhat less verbose when not asked to

llvm-svn: 242573

9 years agoTeach the "extend char types" (char16_t, char32_t and wchar_t) formatters that a...
Enrico Granata [Fri, 17 Jul 2015 20:54:52 +0000 (20:54 +0000)]
Teach the "extend char types" (char16_t, char32_t and wchar_t) formatters that a *single character* whose value is 0 is actually a valid thing to print out

llvm-svn: 242572

9 years agoFix test case in r242565
Steven Wu [Fri, 17 Jul 2015 20:49:01 +0000 (20:49 +0000)]
Fix test case in r242565

llvm-svn: 242571

9 years agoImplement FileSystem::GetPermissions for Windows. Differential Revision: http://revie...
Adrian McCarthy [Fri, 17 Jul 2015 20:23:03 +0000 (20:23 +0000)]
Implement FileSystem::GetPermissions for Windows. Differential Revision: reviews.llvm.org/D11303

llvm-svn: 242568

9 years agoStop treating extension keywords as 'interesting'; we don't allow the extension
Richard Smith [Fri, 17 Jul 2015 20:19:56 +0000 (20:19 +0000)]
Stop treating extension keywords as 'interesting'; we don't allow the extension
flag to change between serialization and deserialization, so it does not
require the identifier to be serialized.

llvm-svn: 242567

9 years agoAdded support for dumping 'x', 'X', 'qSymbol' packets. Also dump any XML retrieved...
Greg Clayton [Fri, 17 Jul 2015 20:16:50 +0000 (20:16 +0000)]
Added support for dumping 'x', 'X', 'qSymbol' packets. Also dump any XML retrieved from a qXfer packets.

llvm-svn: 242566

9 years agoFix -save-temp when using objc-arc, sanitizer and profiling
Steven Wu [Fri, 17 Jul 2015 20:09:56 +0000 (20:09 +0000)]
Fix -save-temp when using objc-arc, sanitizer and profiling

Currently, -save-temp will cause ObjCARC optimization to be dropped,
sanitizer pass to run early in the pipeline, and profiling
instrumentation to run twice.
Fix the issue by properly disable all passes in the optimization
pipeline when generating bitcode output and parse some of the Language
Options even when the input is bitcode so the passes can be setup
correctly.

llvm-svn: 242565

9 years agoRefactor to remove repetition, no functionality change.
Richard Smith [Fri, 17 Jul 2015 20:09:43 +0000 (20:09 +0000)]
Refactor to remove repetition, no functionality change.

llvm-svn: 242564

9 years agoRemove redundant bouncing between StringRef and a pair of 'const char *'.
Richard Smith [Fri, 17 Jul 2015 19:51:03 +0000 (19:51 +0000)]
Remove redundant bouncing between StringRef and a pair of 'const char *'.

llvm-svn: 242562

9 years ago[asan] Add a comment explaining why non-instrumented allocas are moved.
Kuba Brecka [Fri, 17 Jul 2015 19:20:21 +0000 (19:20 +0000)]
[asan] Add a comment explaining why non-instrumented allocas are moved.

Addition to r242510.

llvm-svn: 242561

9 years agofreeaddrinfo(NULL) segfaults on Android.
Chaoren Lin [Fri, 17 Jul 2015 19:12:33 +0000 (19:12 +0000)]
freeaddrinfo(NULL) segfaults on Android.

Reviewers: tberghammer

Subscribers: tberghammer, danalbert, lldb-commits

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

llvm-svn: 242560

9 years agoTeach the NSString data formatter to handle embedded NULs in short ASCII strings
Enrico Granata [Fri, 17 Jul 2015 19:06:39 +0000 (19:06 +0000)]
Teach the NSString data formatter to handle embedded NULs in short ASCII strings

llvm-svn: 242559

9 years agoMergeFuncs: Transfer the function parameter attributes to the call site
Arnold Schwaighofer [Fri, 17 Jul 2015 18:59:08 +0000 (18:59 +0000)]
MergeFuncs: Transfer the function parameter attributes to the call site

rdar://21516488

llvm-svn: 242558

9 years agoStart adding documentation for llvm-lib.
Rafael Espindola [Fri, 17 Jul 2015 18:49:26 +0000 (18:49 +0000)]
Start adding documentation for llvm-lib.

llvm-svn: 242557

9 years agoImprove the NSString data formatter so that explicitly-lengthed Unicode strings print...
Enrico Granata [Fri, 17 Jul 2015 18:22:51 +0000 (18:22 +0000)]
Improve the NSString data formatter so that explicitly-lengthed Unicode strings print embedded NULs correctly

llvm-svn: 242555

9 years agoFix alignment issues in Clang.
James Y Knight [Fri, 17 Jul 2015 18:21:37 +0000 (18:21 +0000)]
Fix alignment issues in Clang.

Some const-correctness changes snuck in here too, since they were in the
area of code I was modifying.

This seems to make Clang actually work without Bus Error on
32bit-sparc.

Follow-up patches will factor out a trailing-object helper class, to
make classes using the idiom of appending objects to other objects
easier to understand, and to ensure (with static_assert) that required
alignment guarantees continue to hold.

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

llvm-svn: 242554

9 years agoRevert "ARM: Enable MachineScheduler and disable PostRAScheduler for swift."
Adam Nemet [Fri, 17 Jul 2015 18:14:19 +0000 (18:14 +0000)]
Revert "ARM: Enable MachineScheduler and disable PostRAScheduler for swift."

This reverts commit r242500.

It broke some internal tests and Matthias asked me to revert it while he
is investigating.

llvm-svn: 242553

9 years agoSplit the portion of the data-formatter-objc test case that deals with NSString into...
Enrico Granata [Fri, 17 Jul 2015 17:54:39 +0000 (17:54 +0000)]
Split the portion of the data-formatter-objc test case that deals with NSString into its own separate test case

llvm-svn: 242552

9 years agoUse llvm_unreachable() instead of report_fatal_error() if the machine model is incomplete
Matthias Braun [Fri, 17 Jul 2015 17:50:11 +0000 (17:50 +0000)]
Use llvm_unreachable() instead of report_fatal_error() if the machine model is incomplete

This error is for developers only so it makes sense to abort and get a
backtrace.

llvm-svn: 242551

9 years ago[OCaml] Do not use -warn-error in tests.
Peter Zotov [Fri, 17 Jul 2015 17:33:23 +0000 (17:33 +0000)]
[OCaml] Do not use -warn-error in tests.

This -warn-error flag invariably gets into release tarballs
and breaks builds on distributions that run tests as a part
of release process. The OCaml binding tests are especially
critical, since they often expose lingering toolchain bugs,
and so it is replaced with -w +A (equivalent to -Wall).

llvm-svn: 242550

9 years ago[ARM] Use [SU]ABSDIFF nodes instead of intrinsics for VABD/VABA
James Molloy [Fri, 17 Jul 2015 17:10:55 +0000 (17:10 +0000)]
[ARM] Use [SU]ABSDIFF nodes instead of intrinsics for VABD/VABA

No functional change, but it preps codegen for the future when SABSDIFF
will start getting generated in anger.

llvm-svn: 242546

9 years ago[AArch64] Use [SU]ABSDIFF nodes instead of intrinsics for ABD/ABA
James Molloy [Fri, 17 Jul 2015 17:10:45 +0000 (17:10 +0000)]
[AArch64] Use [SU]ABSDIFF nodes instead of intrinsics for ABD/ABA

No functional change, but it preps codegen for the future when SABSDIFF
will start getting generated in anger.

llvm-svn: 242545

9 years agoAdd libunwind to the release scripts
Hans Wennborg [Fri, 17 Jul 2015 16:49:59 +0000 (16:49 +0000)]
Add libunwind to the release scripts

llvm-svn: 242543

9 years agoUse inbounds GEPs for memcpy and memset lowering
Eli Bendersky [Fri, 17 Jul 2015 16:42:33 +0000 (16:42 +0000)]
Use inbounds GEPs for memcpy and memset lowering

Follow-up on discussion in http://reviews.llvm.org/D11220

llvm-svn: 242542

9 years agoBump libc++ version # to 3.8
Marshall Clow [Fri, 17 Jul 2015 16:36:44 +0000 (16:36 +0000)]
Bump libc++ version # to 3.8

llvm-svn: 242541

9 years agoAdd missing chkstk.S files from r242539
Reid Kleckner [Fri, 17 Jul 2015 16:31:59 +0000 (16:31 +0000)]
Add missing chkstk.S files from r242539

llvm-svn: 242540

9 years agocompiler-rt: add support for mingw-w64 in builtins
Reid Kleckner [Fri, 17 Jul 2015 16:23:05 +0000 (16:23 +0000)]
compiler-rt: add support for mingw-w64 in builtins

The is so that we can avoid using libgcc and use compiler-rt with
mingw-w64.

Related driver patch
http://reviews.llvm.org/D11077

I have tested this with mingw-w64 and everything seems to be in order.
I also sent this patch to the mingw-w64 mailing list for them to look at.

Patch by Martell Malone.

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

llvm-svn: 242539

9 years ago[msan] Fix open_memstream handling.
Evgeniy Stepanov [Fri, 17 Jul 2015 16:10:37 +0000 (16:10 +0000)]
[msan] Fix open_memstream handling.

For open_memstream() files, buffer pointer is only valid immediately after
fflush() or fclose(). Fix the fclose() interceptor to unpoison after the
REAL(fclose) call, not before it.

llvm-svn: 242535

9 years ago[ASTMatchers] Use provided target NodeKind instead of inferring it from the matchers.
Samuel Benzaquen [Fri, 17 Jul 2015 16:05:27 +0000 (16:05 +0000)]
[ASTMatchers] Use provided target NodeKind instead of inferring it from the matchers.

Individual matchers might not be convertible to each other's kind, but
they might still all be convertible to the target kind.
All the callers already know the target kind, so just pass it down.

llvm-svn: 242534

9 years agoAdd support for producing thin archives in llvm-lib.
Rafael Espindola [Fri, 17 Jul 2015 16:01:11 +0000 (16:01 +0000)]
Add support for producing thin archives in llvm-lib.

I will send an entry in docs/CommandGuide for review today.

llvm-svn: 242533

9 years agoStandalone cmake build improvements (bug #23889)
Pavel Labath [Fri, 17 Jul 2015 15:50:48 +0000 (15:50 +0000)]
Standalone cmake build improvements (bug #23889)

patch by Eugene Zelenko.

llvm-svn: 242529

9 years agoEdited the CPUNames table of TargetParser
Alexandros Lamprineas [Fri, 17 Jul 2015 15:49:32 +0000 (15:49 +0000)]
Edited the CPUNames table of TargetParser
- Changed the default FPU of cortex-m4.
- Removed "cortex-m4f" entry. Currently not supported.

Change-Id: I73121e358aa9e7ba68eb001c2143df390ff2352a
Phabricator: http://reviews.llvm.org/D11100
llvm-svn: 242528

9 years agoFix liblldb linking on RHEL 6 (bug #24140)
Pavel Labath [Fri, 17 Jul 2015 15:26:27 +0000 (15:26 +0000)]
Fix liblldb linking on RHEL 6 (bug #24140)

Patch by Eugene Zelenko.

llvm-svn: 242525

9 years agoGPURuntimeDebugPrinter: Printer pointer values (except if they are strings)
Tobias Grosser [Fri, 17 Jul 2015 13:57:57 +0000 (13:57 +0000)]
GPURuntimeDebugPrinter: Printer pointer values (except if they are strings)

Only pointer values in constant address space are assumed to be strings. For
all other pointers their address is printed.

llvm-svn: 242524

9 years agoR600: Add macro defs for all supported OpenCL extensions
Tom Stellard [Fri, 17 Jul 2015 13:16:52 +0000 (13:16 +0000)]
R600: Add macro defs for all supported OpenCL extensions

llvm-svn: 242523