Commit Graph

205764 Commits

Author SHA1 Message Date
Tom Stellard 8fa3309796 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
2015-07-18 01:49:05 +00:00
Davide Italiano 7842c3fcea [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
2015-07-18 01:15:19 +00:00
Chaoren Lin 857a43c70a 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
2015-07-18 01:09:43 +00:00
Chaoren Lin e9bbabcc69 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
2015-07-18 00:37:55 +00:00
Kostya Serebryany 86e4a3e0a3 [libFuzzer] require the files and directories passed to the fuzzer to exist
llvm-svn: 242596
2015-07-18 00:03:37 +00:00
Evgeniy Stepanov 9cb08f823f [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
2015-07-17 23:51:18 +00:00
Alexey Samsonov e6c614d48a [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
2015-07-17 23:50:08 +00:00
Greg Clayton 2e309076f2 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
2015-07-17 23:42:28 +00:00
David Majnemer 6d1780cfb8 [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
2015-07-17 23:36:49 +00:00
Justin Bogner dceaaadf5c 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
2015-07-17 23:31:21 +00:00
Naomi Musgrave 41b3226637 added test file
llvm-svn: 242590
2015-07-17 23:28:02 +00:00
Naomi Musgrave 9a5e3922bf re-added changes due to svn config setting issues
llvm-svn: 242589
2015-07-17 23:28:00 +00:00
Matthias Braun 9e85980658 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
2015-07-17 23:18:30 +00:00
Matthias Braun 141d1c9d8f 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
2015-07-17 23:18:26 +00:00
Greg Clayton a7a5e5a684 Handle dumping many more packet types including the A packet, qC, QSetDisableASLR, qLaunchSuccess and QLaunchArch.
llvm-svn: 242586
2015-07-17 23:08:14 +00:00
Quentin Colombet 11922946fe [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
2015-07-17 23:04:06 +00:00
Alex Lorenz 484903ecd2 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
2015-07-17 22:48:04 +00:00
Enrico Granata 91443edff1 Remove a static helper function and use the StringPrinter API exclusively to format NSStrings
llvm-svn: 242583
2015-07-17 22:39:35 +00:00
Evgeniy Stepanov fdcaafa2b8 [asan] Fix sanitizer_allocator_test on AArch64.
llvm-svn: 242582
2015-07-17 22:29:05 +00:00
Eric Fiselier 88558e22b0 Cleanup tests that fail in C++1z and with Clang 3.8
llvm-svn: 242581
2015-07-17 22:27:43 +00:00
Chaoren Lin 9070f53079 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
2015-07-17 22:13:29 +00:00
Alex Lorenz d225595dcf 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
2015-07-17 22:07:03 +00:00
James Y Knight 8041e59370 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
2015-07-17 21:58:11 +00:00
Keno Fischer 3b3380ec44 [Makefiles] Re-add OSX specific code that got lost in lldbHost consolidation
llvm-svn: 242577
2015-07-17 21:47:35 +00:00
Chaoren Lin 636a0e3836 Check if altsep exists before replace.
llvm-svn: 242576
2015-07-17 21:40:11 +00:00
Chaoren Lin f355eda567 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
2015-07-17 21:37:26 +00:00
Saleem Abdulrasool 94f4951187 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
2015-07-17 21:26:41 +00:00
Enrico Granata b873e84bd9 Make this test case be somewhat less verbose when not asked to
llvm-svn: 242573
2015-07-17 21:11:46 +00:00
Enrico Granata 8a1cedddd8 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
2015-07-17 20:54:52 +00:00
Steven Wu 3db51cbc21 Fix test case in r242565
llvm-svn: 242571
2015-07-17 20:49:01 +00:00
Adrian McCarthy 633594c261 Implement FileSystem::GetPermissions for Windows. Differential Revision: http://reviews.llvm.org/D11303
llvm-svn: 242568
2015-07-17 20:23:03 +00:00
Richard Smith cab8980229 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
2015-07-17 20:19:56 +00:00
Greg Clayton 205d6189b4 Added support for dumping 'x', 'X', 'qSymbol' packets. Also dump any XML retrieved from a qXfer packets.
llvm-svn: 242566
2015-07-17 20:16:50 +00:00
Steven Wu 546a19628b 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
2015-07-17 20:09:56 +00:00
Richard Smith 76c2f2c9da Refactor to remove repetition, no functionality change.
llvm-svn: 242564
2015-07-17 20:09:43 +00:00
Richard Smith a8d5b6ad45 Remove redundant bouncing between StringRef and a pair of 'const char *'.
llvm-svn: 242562
2015-07-17 19:51:03 +00:00
Kuba Brecka 7f54753180 [asan] Add a comment explaining why non-instrumented allocas are moved.
Addition to r242510.

llvm-svn: 242561
2015-07-17 19:20:21 +00:00
Chaoren Lin 2e3b97d4fb freeaddrinfo(NULL) segfaults on Android.
Reviewers: tberghammer

Subscribers: tberghammer, danalbert, lldb-commits

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

llvm-svn: 242560
2015-07-17 19:12:33 +00:00
Enrico Granata 01dcaa36de Teach the NSString data formatter to handle embedded NULs in short ASCII strings
llvm-svn: 242559
2015-07-17 19:06:39 +00:00
Arnold Schwaighofer 690cd87dcd MergeFuncs: Transfer the function parameter attributes to the call site
rdar://21516488

llvm-svn: 242558
2015-07-17 18:59:08 +00:00
Rafael Espindola 3116f6eb86 Start adding documentation for llvm-lib.
llvm-svn: 242557
2015-07-17 18:49:26 +00:00
Enrico Granata f219885fb5 Improve the NSString data formatter so that explicitly-lengthed Unicode strings print embedded NULs correctly
llvm-svn: 242555
2015-07-17 18:22:51 +00:00
James Y Knight 53c7616e2e 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
2015-07-17 18:21:37 +00:00
Adam Nemet 5a6d5bc17b 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
2015-07-17 18:14:19 +00:00
Enrico Granata 4cb0ba311a Split the portion of the data-formatter-objc test case that deals with NSString into its own separate test case
llvm-svn: 242552
2015-07-17 17:54:39 +00:00
Matthias Braun 244a6773c7 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
2015-07-17 17:50:11 +00:00
Peter Zotov f1192cd7e4 [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
2015-07-17 17:33:23 +00:00
James Molloy a6702e2f14 [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
2015-07-17 17:10:55 +00:00
James Molloy faf4e3c33b [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
2015-07-17 17:10:45 +00:00
Hans Wennborg cfb85e0c0c Add libunwind to the release scripts
llvm-svn: 242543
2015-07-17 16:49:59 +00:00