Commit Graph

284923 Commits

Author SHA1 Message Date
Pavel Labath 322711f529 DWARF: Unify form size handling code
Summary:
This patch replaces the two switches which are deducing the size of
various forms with a single implementation. I have put the new
implementation into BinaryFormat, to avoid introducing dependencies
between the two independent libraries (DebugInfo and CodeGen) that need
this functionality.

Reviewers: aprantl, JDevlieghere, dblaikie

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D44418

llvm-svn: 327486
2018-03-14 09:39:54 +00:00
Jonas Devlieghere bc683cced8 [dsymutil] Print architecture in warning
Make the architecture part of the warning in the DebugMapParser. This
makes things consistent with the Apple's internal version of dsymutil.

llvm-svn: 327485
2018-03-14 09:34:54 +00:00
Pavel Labath d54c34722c Export LLVM_DYLIB_COMPONENTS in LLVMConfig.cmake
Summary:
This is needed so that external projects (e.g. a standalone build of
lldb) can link to the LLVM shared library via the USE_SHARED argument of
llvm_config. Without this, llvm_config would add LLVM to the link list,
but then also add the constituent static libraries, resulting in
multiply defined symbols.

Reviewers: beanz, mgorny

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D44391

llvm-svn: 327484
2018-03-14 09:28:38 +00:00
Pavel Labath 5a48f95a0f Skip TestWatchedVarHitWhenInScope.py everywhere
The expression-hits tracking logic is not available on any platform. The
reason this tests happens to pass on some platforms is that the test is
written poorly -- it relies on the fact that post-main cleanup code will
write to the stack memory once occupied by the watched variable, but
this is not the case everywhere (e.g. linux glibc does not seem to do
this, but android's bionic library does).

llvm-svn: 327483
2018-03-14 09:13:33 +00:00
Alexander Ivchenko 327de80529 [GlobalIsel][X86] Support for G_ZEXT instruction
Reviewed By: igorb

Differential Revision: https://reviews.llvm.org/D44378

llvm-svn: 327482
2018-03-14 09:11:23 +00:00
George Rimar 2ab9362bf5 [ELF] - Never create .gnu_hash with NBuckets == 0.
Currently, we can end up with NBuckets==0 and android loader
does not like it (PR36537).

Seems we can go with a minimal amount of changes here for simplicity
and be consistent with gold and so just always use >= 1 value for NBuckets.

Differential revision: https://reviews.llvm.org/D44422

llvm-svn: 327481
2018-03-14 08:52:39 +00:00
George Rimar 271ed6eb0d [ELF] - Convert overlapping-sections.s testcase to x86 and cleanup.
Patch do the following changes:

* Test case was converted from MIPS to x86.

* Removed part of the test checking we are able to produce a valid output.
  Since we do that already in other tests, this one's intention should be
  only to check we are still able to report overlaps and/or produce
  broken output with overlaps.

Differential revision: https://reviews.llvm.org/D44438

llvm-svn: 327480
2018-03-14 07:44:23 +00:00
Robert Widmann 4bb481b2f2 [LLVM-C] Redo unnamed_address attribute bindings
Summary:
The old bindings should have used an enum instead of a boolean.  This
deprecates LLVMHasUnnamedAddr and LLVMSetUnnamedAddr , replacing them
with LLVMGetUnnamedAddress and LLVMSetUnnamedAddress respectively that do.
Though it is unlikely LLVM will gain more supported global value linker
hints, the new API can scale to accommodate this.

Reviewers: deadalnix, whitequark

Reviewed By: whitequark

Subscribers: llvm-commits, harlanhaskins

Differential Revision: https://reviews.llvm.org/D43448

llvm-svn: 327479
2018-03-14 06:45:51 +00:00
Lang Hames 2d603a1860 [RuntimeDyld] Silence a compiler error.
This should fix the error at
http://lab.llvm.org:8011/builders/lld-x86_64-darwin13/builds/19008

llvm-svn: 327478
2018-03-14 06:39:49 +00:00
Lang Hames b2facd6479 [ORC] Fix a data race in the lookup function.
The Error locals need to be protected by a mutex. (This could be fixed by
having the promises / futures contain Expected and Error values, but
MSVC's future implementation does not support this yet).

Hopefully this will fix some of the errors seen on the builders due to
r327474.

llvm-svn: 327477
2018-03-14 06:25:08 +00:00
Lang Hames 313f590aee [ExecutionEngine] Add a getSymbolTable method to RuntimeDyld.
This can be used to extract the symbol table from a RuntimeDyld instance prior
to disposing of it.

This patch also updates RTDyldObjectLinkingLayer to use the new method, rather
than requesting symbols one at a time via getSymbol.

llvm-svn: 327476
2018-03-14 06:25:07 +00:00
Lang Hames d4a768e78f [ORC] Silence a compiler error.
This should fix the builder error at
http://lab.llvm.org:8011/builders/lld-x86_64-darwin13/builds/19006

llvm-svn: 327475
2018-03-14 05:23:56 +00:00
Lang Hames 817f1f64d9 [ORC] Add a 'lookup' convenience function for finding symbols in a list of VSOs.
The lookup function takes a list of VSOs, a set of symbol names (or just one
symbol name) and a materialization function object. It returns an
Expected<SymbolMap> (if given a set of names) or an Expected<JITEvaluatedSymbol>
(if given just one name). The lookup method constructs an
AsynchronousSymbolQuery for the given names, applies that query to each VSO in
the list in turn, and then blocks waiting for the query to complete. If
threading is enabled then the materialization function object can be used to
execute the materialization on different threads. If threading is disabled the
MaterializeOnCurrentThread utility must be used.

llvm-svn: 327474
2018-03-14 04:18:04 +00:00
Aaron Smith 66b84079f9 [SymbolFilePDB] Rewrite ParseTypes method
Summary:
The types for the compiland's children are parsed when parsing types for a PDB compiland. Global types also need to be parsed but unfortunately PDBs do not have compiland information about each global type. So we parse them all on the first call to ParseTypes.

If a sc.function is provided then parse the types for that function. Otherwise parse the types for the overall sc.comp_unit.

The ParseTypes method can be very slow if a program has a long list of compile units containing needed modules. Debugging clang-cl with lldb will show the problem.



Reviewers: zturner, rnk, lldb-commits

Reviewed By: zturner

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D44253

llvm-svn: 327473
2018-03-14 04:05:27 +00:00
Eugene Zemtsov ccf30835e1 Disable test debuglineinfo-path on powerpc
llvm-svn: 327472
2018-03-14 02:10:07 +00:00
Kostya Serebryany 79fa418d59 [hwasan] update docs
llvm-svn: 327471
2018-03-14 01:55:49 +00:00
Eugene Zemtsov c6d8fcb168 grep for global functions only
llvm-svn: 327469
2018-03-14 01:07:18 +00:00
Sam Clegg 37fbfc6815 [WebAssembly] Fix expected contents of relocations with addends
This fixes issues found on the wasm waterfall related to relocations
with addends. Undefined symbols, even those with addends should
always have a provisional value of zero. At least this is what llvm
emits (and I believe this is true for ELF too).

Differential Revision: https://reviews.llvm.org/D44451

llvm-svn: 327468
2018-03-14 00:53:34 +00:00
Matt Arsenault 41e5ac4fa4 TargetMachine: Add address space to getPointerSize
llvm-svn: 327467
2018-03-14 00:36:23 +00:00
Eugene Zemtsov e2d3ce2339 Add extra output/check to debug clang-ppc64be-linux test failure
llvm-svn: 327466
2018-03-14 00:15:16 +00:00
Teresa Johnson 30b9f24fb0 Revert "[LTO/gold] Support --wrap"
This reverts commit r327459. The new gold plugin interface is not
available with older gold installations, leading to compile failures:
http://lab.llvm.org:8011/builders/clang-with-thin-lto-ubuntu/builds/9109/steps/build-stage2-LLVMgold.so/logs/stdio

llvm-svn: 327465
2018-03-13 23:55:34 +00:00
Akira Hatanaka ceb66521ba Check that a field is not annotated with attribute "unavailable" before
setting the NonTrivialToPrimitive* flags of a record.

Union fields that have non-trivial Objective-C ownership qualifications
are normally not legal, but if the union is declared in a system header,
the fields are annotated with attribute "unavailable".

rdar://problem/38431072

llvm-svn: 327464
2018-03-13 23:37:51 +00:00
Vedant Kumar 48ffd5cc6e [test] Replace some references to Apple-internal bugs
This removes around 10 references to Apple-internal radars. I've filed
fresh bugs on bugs.llvm.org as appropriate for open issues.

llvm-svn: 327463
2018-03-13 23:37:11 +00:00
Craig Topper 9ca7e67c4c [X86] Re-generate test to get proper capitalization of its CHECK lines. NFC
llvm-svn: 327462
2018-03-13 23:31:48 +00:00
Aditya Nandakumar b808e3ad8b [GISel]: Fix incorrect type used in Pattern Match for ICst
getConstantVRegVal() returns int64_t but we use uint64_t.

llvm-svn: 327461
2018-03-13 23:21:13 +00:00
Gheorghe-Teodor Bercea 0d5aa84ad9 [OpenMP] Add flag for linking runtime bitcode library
Summary: This patch adds an additional flag to the OpenMP device offloading toolchain to link in the runtime library bitcode.

Reviewers: Hahnfeld, ABataev, carlo.bertolli, caomhin, grokos, hfinkel

Reviewed By: ABataev, grokos

Subscribers: jholewinski, guansong, cfe-commits

Differential Revision: https://reviews.llvm.org/D43197

llvm-svn: 327460
2018-03-13 23:19:52 +00:00
Teresa Johnson e8f3b0782a [LTO/gold] Support --wrap
Summary:
Utilize new gold plugin api interface for obtaining --wrap option
arguments, and LTO API handling (added for --wrap support in lld LTO),
to mark symbols so that LTO does not optimize them inappropriately.

Note the test cases will be in a new gold test subdirectory that
is dependent on the next release of gold which will contain the new
interfaces.

Reviewers: pcc, tmsriram

Subscribers: mehdi_amini, llvm-commits, inglorion

Differential Revision: https://reviews.llvm.org/D44235

llvm-svn: 327459
2018-03-13 23:06:19 +00:00
Eugene Zemtsov b9d2908cd3 Disable optimizations in debuglineinfo-path test
llvm-svn: 327458
2018-03-13 22:48:39 +00:00
Craig Topper ec4881ad53 [X86] Simplify the LowerAVXCONCAT_VECTORS code a little by creating a single path for insert_subvector handling.
We now only create recursive concats if we have more than two non-zero values. This keeps our subvector broadcast DAG combine functioning.

llvm-svn: 327457
2018-03-13 22:36:07 +00:00
Joel E. Denny b17a329f5e [Attr] Merge two dependent tests from different directories
Suggested at: https://reviews.llvm.org/D43248

llvm-svn: 327456
2018-03-13 22:18:29 +00:00
Sjoerd Meijer a7463df6e2 [ARM] ACLE FP16 feature test macros
This is a partial recommit of r327189 that was reverted
due to test issues. I.e., this recommits minimal functional
change, the FP16 feature test macros, and adds tests that 
were missing in the original commit.

llvm-svn: 327455
2018-03-13 22:11:06 +00:00
Craig Topper cc060e921b [X86] Rewrite LowerAVXCONCAT_VECTORS similar to how we handle vXi1 concats.
This better able to detect undef and zeros pieces in the concat. Or cases when only one subvector is non-zero. This allows us to avoid silly things like double inserts into progressively larger undefs.

This still builds 512 bit concats of 128 bits by building up through 256 bits first. But I don't know if that's best.

We probably want to merge this with the vXi1 concat code since they are very similar.

llvm-svn: 327454
2018-03-13 22:05:25 +00:00
Eugene Zelenko bc32433062 [Analysis] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).
llvm-svn: 327453
2018-03-13 21:32:01 +00:00
Julie Hockett c12d753fad [clang-tidy] Fixing incorrect comment
llvm-svn: 327452
2018-03-13 21:24:08 +00:00
Zachary Turner 1ccae9d943 Disable PDB injected sources test temporarily.
llvm-svn: 327451
2018-03-13 21:18:00 +00:00
Hiroshi Yamauchi e6a3dc7699 Simplify more cases of logical ops of masked icmps.
Summary:
For example,

((X & 255) != 0) && ((X & 15) == 8) -> ((X & 15) == 8).
((X & 7) != 0) && ((X & 15) == 8) -> false.

Reviewers: davidxl

Reviewed By: davidxl

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D43835

llvm-svn: 327450
2018-03-13 21:13:18 +00:00
Eugene Zemtsov f69d07e788 Remove explicit triple and data layout from the test
llvm-svn: 327449
2018-03-13 21:10:15 +00:00
Jim Ingham ca38766c9c Add a missing return in SBPlatform::IsConnected and test
for the behavior - using the fact that the Host platform
is always present & connected.

llvm-svn: 327448
2018-03-13 21:06:05 +00:00
Gheorghe-Teodor Bercea 0805b80a73 Revert revision 327438.
llvm-svn: 327447
2018-03-13 20:50:12 +00:00
Craig Topper 4aeec51986 [DAGCombiner] Allow visitEXTRACT_SUBVECTOR to combine with BUILD_VECTORS between LegalizeVectorOps and LegalizeDAG.
BUILD_VECTORs aren't themselves legalized until LegalizeDAG so we should still be able to create an "illegal" one before that. This helps combine with BUILD_VECTORS that are introduced during LegalizeVectorOps due to unrolling.

llvm-svn: 327446
2018-03-13 20:36:28 +00:00
Davide Italiano 5bcb9d7211 [DataFormatter] Remove dead code for the NSDictionary formatter.
I'm going to make changes in this area soon, so I figured I
could clean things a bit while I was around.

llvm-svn: 327445
2018-03-13 20:26:38 +00:00
Zachary Turner 5cbf567921 Update modulemap to exclude new DIA headers.
llvm-svn: 327444
2018-03-13 20:16:37 +00:00
Eugene Zemtsov d6a1ca761a Fix debuglineinfo-path.ll
This fix is based on an assumption that some build bots are missing 'echo
-n'

llvm-svn: 327443
2018-03-13 20:06:33 +00:00
Francis Visoiu Mistrih 3abf05739f [MIR] Allow frame-setup and frame-destroy on the same instruction
Nothing prevents us from having both frame-setup and frame-destroy on
the same instruction.

When merging:
* frame-setup OPCODE1
* frame-destroy OPCODE2
into
* frame-setup frame-destroy OPCODE3

we want to be able to print and parse both flags.

llvm-svn: 327442
2018-03-13 19:53:16 +00:00
Eugene Zemtsov 27c1afbb0b Temporary disable debuglineinfo-path.ll to fix build
llvm-svn: 327441
2018-03-13 19:48:31 +00:00
Gheorghe-Teodor Bercea 49b62649cf [OpenMP][libomptarget] Add global memory data sharing support for master-worker sharing.
Summary:
This patch adds support for the sharing of variables from the master thread of a team to the worker threads of the team.
The runtime uses a stack structure implemented as a doubly-linked list of slots with each slot having the exact same size as the size requested. This implementation leverages existing data structures. The runtime functions are added as separate functions to avoid interfering with the current interface. 

Limitations to be addressed in future patches:
- This current patch only employs global memory. In a future patch we will enable to usage for shared memory as an optimization.
- Allow the allocation of several requested sizes in the same slot.

Reviewers: ABataev, grokos, caomhin, carlo.bertolli

Reviewed By: grokos

Subscribers: Hahnfeld, guansong, openmp-commits

Differential Revision: https://reviews.llvm.org/D44260

llvm-svn: 327440
2018-03-13 19:44:53 +00:00
Gheorghe-Teodor Bercea 148046c11b [OpenMP] Add flag for linking runtime bitcode library
Summary: This patch adds an additional flag to the OpenMP device offloading toolchain to link in the runtime library bitcode.

Reviewers: Hahnfeld, ABataev, carlo.bertolli, caomhin, grokos, hfinkel

Reviewed By: ABataev, grokos

Subscribers: jholewinski, guansong, cfe-commits

Differential Revision: https://reviews.llvm.org/D43197

llvm-svn: 327438
2018-03-13 19:39:19 +00:00
Sjoerd Meijer 95da875898 This reverts "r327189 - [ARM] Add ARMv8.2-A FP16 vector intrinsic"
This is causing problems in testing, and PR36683 was raised.
Reverting it until we have sorted out how to pass f16 vectors.

llvm-svn: 327437
2018-03-13 19:38:56 +00:00
Anna Thomas 5ac72f94f3 Test Commit NFC. Updated comment
llvm-svn: 327436
2018-03-13 19:38:45 +00:00
Sanjay Patel bb45cc126d [x86] add test for WriteZero sched class instructions; NFC
Nops should have zero latency because there is no result.
Idioms like 'xorps xmm0, xmm0' may have zero latency because 
they are handled without using an execution unit.

llvm-svn: 327435
2018-03-13 19:20:01 +00:00