platform/upstream/llvm.git
9 years agoUnrevert r244412 (reverted in r244414), and delete the bogus line left behind
Richard Smith [Sun, 9 Aug 2015 06:03:55 +0000 (06:03 +0000)]
Unrevert r244412 (reverted in r244414), and delete the bogus line left behind
in the unit test that was checking a file the test no longer creates.

llvm-svn: 244415

9 years agoRevert "[modules] Don't leak -M flags for dependency file generation into the module"
Justin Bogner [Sun, 9 Aug 2015 05:40:38 +0000 (05:40 +0000)]
Revert "[modules] Don't leak -M flags for dependency file generation into the module"

This was failing tests on a bunch of bots:

http://lab.llvm.org:8011/builders/clang-hexagon-elf/builds/29919/steps/check-all
http://lab.llvm.org:8011/builders/clang-x86_64-debian-fast/builds/29627/steps/check-all
http://lab.llvm.org:8080/green/job/clang-stage1-configure-RA_check/9959/
http://lab.llvm.org:8080/green/job/clang-stage2-configure-Rlto_check/5591/

This reverts r244412

llvm-svn: 244414

9 years ago[modules] When building a dependency file, include module maps parsed in the
Richard Smith [Sun, 9 Aug 2015 04:46:57 +0000 (04:46 +0000)]
[modules] When building a dependency file, include module maps parsed in the
current compilation, not just those from imported modules.

llvm-svn: 244413

9 years ago[modules] Don't leak -M flags for dependency file generation into the module
Richard Smith [Sun, 9 Aug 2015 02:44:20 +0000 (02:44 +0000)]
[modules] Don't leak -M flags for dependency file generation into the module
build process when we implicitly build a module. Previously, we'd create the
specified .d file once for each implicitly-built module and then finally
overwrite it with the correct contents after the requested build completes.
(This fails if you use stdout as a dependency file, which is what the provided
testcase does, and is how I discovered this brokenness.)

llvm-svn: 244412

9 years ago[modules] Attach dependency listeners to the module manager once when it's
Richard Smith [Sun, 9 Aug 2015 02:28:42 +0000 (02:28 +0000)]
[modules] Attach dependency listeners to the module manager once when it's
created, rather than creating and attaching a new listener each time we load a
module file (yes, the old ones were kept around too!). No functionality change
intended, but a bit more sanity.

llvm-svn: 244411

9 years agoAdd file missed from r244409.
Richard Smith [Sun, 9 Aug 2015 01:50:14 +0000 (01:50 +0000)]
Add file missed from r244409.

llvm-svn: 244410

9 years ago[modules] When loading a template specialization, re-canonicalize its template
Richard Smith [Sun, 9 Aug 2015 01:05:31 +0000 (01:05 +0000)]
[modules] When loading a template specialization, re-canonicalize its template
arguments because the reloaded form might have become non-canonical across the
serialization/deserialization step (this particularly happens when the
canonical form of the type involves an expression).

llvm-svn: 244409

9 years ago[IR] Remove unused declaration
David Majnemer [Sun, 9 Aug 2015 00:32:18 +0000 (00:32 +0000)]
[IR] Remove unused declaration

CatchReturnInst::init is never referenced, remove it.
No functionality change is intended.

llvm-svn: 244408

9 years agoTeach mingw toolchain driver to properly emit static or dynamic linking of ligcc.
Yaron Keren [Sun, 9 Aug 2015 00:24:07 +0000 (00:24 +0000)]
Teach mingw toolchain driver to properly emit static or dynamic linking of ligcc.
Implemented in MinGW::Linker::AddLibGCC since AddLibgcc is a logic puzzle even
before adding one more boolean. A first step towards simplification of AddLibgcc
would be to factor out the Android AddLibgcc code into its own routine.

llvm-svn: 244407

9 years agocmake: Error on invalid CMAKE_BUILD_TYPE
Justin Bogner [Sat, 8 Aug 2015 21:04:45 +0000 (21:04 +0000)]
cmake: Error on invalid CMAKE_BUILD_TYPE

Apparently if you make a typo in the argument to CMAKE_BUILD_TYPE,
cmake silently accepts this but doesn't apply any particular build
type to your build. This means you get a build that doesn't really
make any sense - it's sort of a debug build with asserts disabled.

Error out instead.

llvm-svn: 244406

9 years agoFix dangling reference in DwarfLinker.cpp. The original code
Yaron Keren [Sat, 8 Aug 2015 21:03:19 +0000 (21:03 +0000)]
Fix dangling reference in DwarfLinker.cpp. The original code

  Seq.emplace_back(Seq.back());

does not work as planned, since Seq.back() may become a dangling reference
when emplace_back is called and possibly reallocates vector. To avoid this,
the vector allocation should be reserved first and only then used.

This broke test/tools/dsymutil/X86/custom-line-table.test with Visual C++ 2013.

llvm-svn: 244405

9 years ago[Polly] Remove dead code in IndependentBlocks
Michael Kruse [Sat, 8 Aug 2015 20:31:20 +0000 (20:31 +0000)]
[Polly] Remove dead code in IndependentBlocks

Summary: The splitExitBlock function is never called. Going to replace its functionality in successive patches that do not modify the IR.

Reviewers: grosser

Subscribers: pollydev

Projects: #polly

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

llvm-svn: 244404

9 years ago[x86] enable machine combiner reassociations for 128-bit vector single/double adds
Sanjay Patel [Sat, 8 Aug 2015 19:08:20 +0000 (19:08 +0000)]
[x86] enable machine combiner reassociations for 128-bit vector single/double adds

llvm-svn: 244403

9 years agoFix some comment typos.
Benjamin Kramer [Sat, 8 Aug 2015 18:27:36 +0000 (18:27 +0000)]
Fix some comment typos.

llvm-svn: 244402

9 years agoAdd an assertion
Michael Kruse [Sat, 8 Aug 2015 18:10:54 +0000 (18:10 +0000)]
Add an assertion

Check whether a block is a direct predecessor.

llvm-svn: 244401

9 years ago[Static Analyzer] Add --analyzer-target option to scan-build.
Ted Kremenek [Sat, 8 Aug 2015 17:58:47 +0000 (17:58 +0000)]
[Static Analyzer] Add --analyzer-target option to scan-build.

When interposing on a compiler doing cross-compilation, scan-build
does not infer the target triple needed to pass to clang for
doing static analysis.  The --analyzer-target option allows one
to manually specify the target triple used during static analysis
(and only static analysis) for such cases.

Patch by Honggyu Kim!

Reviewed in http://reviews.llvm.org/D10356.

llvm-svn: 244400

9 years ago[IR] Cleanup some formatting issues in the EH instructions
David Majnemer [Sat, 8 Aug 2015 17:41:21 +0000 (17:41 +0000)]
[IR] Cleanup some formatting issues in the EH instructions

No functionality change is intended.

llvm-svn: 244399

9 years ago[ASAN/AArch64] Disable forkpty tests until we can fix them
Renato Golin [Sat, 8 Aug 2015 15:47:17 +0000 (15:47 +0000)]
[ASAN/AArch64] Disable forkpty tests until we can fix them

Reported in PR24400. Disable until it works, so we can keep the rest
tested and green.

llvm-svn: 244398

9 years agoReturn early on error. Should fix the asan bots.
Rafael Espindola [Sat, 8 Aug 2015 14:54:09 +0000 (14:54 +0000)]
Return early on error. Should fix the asan bots.

llvm-svn: 244397

9 years ago[X86] Add ADX and RDSEED to Skylake processor.
Craig Topper [Sat, 8 Aug 2015 07:31:15 +0000 (07:31 +0000)]
[X86] Add ADX and RDSEED to Skylake processor.

llvm-svn: 244396

9 years agoAdd SlowBTMem to Sandy Bridge and newer Intel CPUs. Reading through Agner Fog's table...
Craig Topper [Sat, 8 Aug 2015 07:20:04 +0000 (07:20 +0000)]
Add SlowBTMem to Sandy Bridge and newer Intel CPUs. Reading through Agner Fog's table suggests there have been no improvements to these processors relative to Westmere for bit test instructions.

llvm-svn: 244395

9 years agoRevert "[analyzer] Add checkers for OS X / iOS localizability issues"
Anna Zaks [Sat, 8 Aug 2015 04:53:04 +0000 (04:53 +0000)]
Revert "[analyzer] Add checkers for OS X / iOS localizability issues"

This reverts commit fc885033a30b6e30ccf82398ae7c30e646727b10.

Revert all localization checker commits until the proper fix is implemented.

llvm-svn: 244394

9 years agoRevert "[analyzer] Fixup to r244389 to make this build on windows."
Anna Zaks [Sat, 8 Aug 2015 04:52:59 +0000 (04:52 +0000)]
Revert "[analyzer] Fixup to r244389 to make this build on windows."

This reverts commit 57a46a75b408245cf4154a838fe13ad702065745.

Revert all localization checker commits until the proper fix is implemented.

llvm-svn: 244393

9 years ago[InstCombine] Don't try to sink EH pad instructions
David Majnemer [Sat, 8 Aug 2015 03:51:49 +0000 (03:51 +0000)]
[InstCombine] Don't try to sink EH pad instructions

Found by inspection, this change should not effect the existing
landingpad behavior.

llvm-svn: 244391

9 years ago[analyzer] Fixup to r244389 to make this build on windows.
Anna Zaks [Sat, 8 Aug 2015 02:26:07 +0000 (02:26 +0000)]
[analyzer] Fixup to r244389 to make this build on windows.

llvm-svn: 244390

9 years ago[analyzer] Add checkers for OS X / iOS localizability issues
Anna Zaks [Sat, 8 Aug 2015 01:49:26 +0000 (01:49 +0000)]
[analyzer] Add checkers for OS X / iOS localizability issues

Add checkers that detect code-level localizability issues for OS X / iOS:
 - A path sensitive checker that warns about uses of non-localized
 NSStrings passed to UI methods expecting localized strings.
 - A syntax checker that warns against not including a comment in
 NSLocalizedString macros.

A patch by Kulpreet Chilana!

llvm-svn: 244389

9 years ago244368: Fix a comment line introduced in r244368. [-Wdocumentation]
NAKAMURA Takumi [Sat, 8 Aug 2015 01:34:20 +0000 (01:34 +0000)]
244368: Fix a comment line introduced in r244368. [-Wdocumentation]

llvm-svn: 244388

9 years ago[IR] Stop hacking around a bug in GCC 4.5
David Majnemer [Sat, 8 Aug 2015 01:33:30 +0000 (01:33 +0000)]
[IR] Stop hacking around a bug in GCC 4.5

GCC 4.5 miscompiled this aspect of LLVM.  We support a minimum version
of 4.7.

llvm-svn: 244387

9 years ago[analyzer] Don't issue alarm in ObjCSuperCallChecker for the super class itself.
Devin Coughlin [Sat, 8 Aug 2015 01:31:51 +0000 (01:31 +0000)]
[analyzer] Don't issue alarm in ObjCSuperCallChecker for the super class itself.

The ObjCSuperCallChecker issues alarms for various Objective-C APIs that require
a subclass to call to its superclass's version of a method when overriding it.
So, for example, it raises an alarm when the -viewDidLoad method in a subclass
of UIViewController does not call [super viewDidLoad].

This patch fixes a false alarm where the analyzer erroneously required the
implementation of the superclass itself (e.g., UIViewController) to call
super.

rdar://problem/18416944

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

llvm-svn: 244386

9 years agoAdd model numbers for Skylake CPUs and an additional Broadwell model.
Craig Topper [Sat, 8 Aug 2015 01:29:15 +0000 (01:29 +0000)]
Add model numbers for Skylake CPUs and an additional Broadwell model.

llvm-svn: 244385

9 years agoAdd Intel family 6 model 93 as Silvermont.
Craig Topper [Sat, 8 Aug 2015 01:16:05 +0000 (01:16 +0000)]
Add Intel family 6 model 93 as Silvermont.

llvm-svn: 244384

9 years agoAMDGPU/SI: Another attempt to fix Windows bots broken by r244372
Tom Stellard [Sat, 8 Aug 2015 01:11:07 +0000 (01:11 +0000)]
AMDGPU/SI: Another attempt to fix Windows bots broken by r244372

llvm-svn: 244383

9 years agoRemove unnecessary includes
Matt Arsenault [Sat, 8 Aug 2015 00:41:53 +0000 (00:41 +0000)]
Remove unnecessary includes

llvm-svn: 244382

9 years agoAMDGPU: Implement AMDGPUOperand::print()
Matt Arsenault [Sat, 8 Aug 2015 00:41:51 +0000 (00:41 +0000)]
AMDGPU: Implement AMDGPUOperand::print()

llvm-svn: 244381

9 years agoAMDGPU/SI: Remove VCCReg
Matt Arsenault [Sat, 8 Aug 2015 00:41:48 +0000 (00:41 +0000)]
AMDGPU/SI: Remove VCCReg

llvm-svn: 244380

9 years agoAMDGPU/SI: Remove source uses of VCCReg
Matt Arsenault [Sat, 8 Aug 2015 00:41:45 +0000 (00:41 +0000)]
AMDGPU/SI: Remove source uses of VCCReg

llvm-svn: 244379

9 years agoDelete dead code. NFC.
Rafael Espindola [Sat, 8 Aug 2015 00:25:57 +0000 (00:25 +0000)]
Delete dead code. NFC.

llvm-svn: 244378

9 years agoCOFF: Simplify.
Rui Ueyama [Sat, 8 Aug 2015 00:23:37 +0000 (00:23 +0000)]
COFF: Simplify.

SymbolTable::find(mangle(X)) is equivalent to SymbolTable::findUnderscore(X)
except that the latter is slightly efficient as that doesn't allocate a new
string.

llvm-svn: 244377

9 years agoAMDGPU/SI: Attempt to fix Windows bots broken by r244372
Tom Stellard [Sat, 8 Aug 2015 00:17:59 +0000 (00:17 +0000)]
AMDGPU/SI: Attempt to fix Windows bots broken by r244372

llvm-svn: 244376

9 years agoConvert getSymbolSection to return an ErrorOr.
Rafael Espindola [Fri, 7 Aug 2015 23:27:14 +0000 (23:27 +0000)]
Convert getSymbolSection to return an ErrorOr.

This function can actually fail since the symbol contains an index to the
section and that can be invalid.

llvm-svn: 244375

9 years agoAST: Implement mangling support for function types without a prototype.
Peter Collingbourne [Fri, 7 Aug 2015 23:25:47 +0000 (23:25 +0000)]
AST: Implement mangling support for function types without a prototype.

Function types without prototypes can arise when mangling a function type
within an overloadable function in C. We mangle these as the absence of
any parameter types (not even an empty parameter list).

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

llvm-svn: 244374

9 years agoadd a missing regression test for a DAGCombiner FDIV optimization
Sanjay Patel [Fri, 7 Aug 2015 23:19:41 +0000 (23:19 +0000)]
add a missing regression test for a DAGCombiner FDIV optimization

There's no test for this transform in any backend. Discovered
while debugging fast-math-flag propagation in the DAG (r244053).

llvm-svn: 244373

9 years agoAMDGPU: Add pass to lower OpenCL image and sampler arguments.
Tom Stellard [Fri, 7 Aug 2015 23:19:30 +0000 (23:19 +0000)]
AMDGPU: Add pass to lower OpenCL image and sampler arguments.

The pass adds new kernel arguments for image attributes, and
resolves calls to dummy attribute and resource id getter functions.

Patch by: Zoltan Gilian

llvm-svn: 244372

9 years ago[SPARC] Disable unsupported ExecutionEngine tests, and XFAIL a couple
James Y Knight [Fri, 7 Aug 2015 23:01:16 +0000 (23:01 +0000)]
[SPARC] Disable unsupported ExecutionEngine tests, and XFAIL a couple
of DebugInfo tests.

llvm-svn: 244371

9 years ago[Sparc] XFAIL CodeGen/atomic_ops test.
James Y Knight [Fri, 7 Aug 2015 22:52:34 +0000 (22:52 +0000)]
[Sparc] XFAIL CodeGen/atomic_ops test.

llvm-svn: 244370

9 years ago[LAA] Remove unused pointer partition argument from getNumberOfChecks, NFC
Adam Nemet [Fri, 7 Aug 2015 22:44:21 +0000 (22:44 +0000)]
[LAA] Remove unused pointer partition argument from getNumberOfChecks, NFC

This is unused after filtering checks was moved to the clients.

As a result, we can just return the number of the checks in the
precomputed set.

llvm-svn: 244369

9 years ago[LAA] Make the set of runtime checks part of the state of LAA, NFC
Adam Nemet [Fri, 7 Aug 2015 22:44:15 +0000 (22:44 +0000)]
[LAA] Make the set of runtime checks part of the state of LAA, NFC

This is the full set of checks that clients can further filter. IOW,
it's client-agnostic.  This makes LAA complete in the sense that it now
provides the two main results of its analysis precomputed:

1. memory dependences via getDepChecker().getInsterestingDependences()
2. run-time checks via getRuntimePointerCheck().getChecks()

However, as a consequence we now compute this information pro-actively.
Thus if the client decides to skip the loop based on the dependences
we've computed the checks unnecessarily.  In order to see whether this
was a significant overhead I checked compile time on SPEC2k6 LTO bitcode
files.  The change was in the noise.

The checks are generated in canCheckPtrAtRT, at the same place where we
used to call groupChecks to merge checks.

llvm-svn: 244368

9 years agoCOFF: Handle _load_config_used in the same way as other special symbols.
Rui Ueyama [Fri, 7 Aug 2015 22:43:53 +0000 (22:43 +0000)]
COFF: Handle _load_config_used in the same way as other special symbols.

Handling the symbol this way is consistent with other symbols, such as
_tls_used. NFC.

llvm-svn: 244367

9 years ago[AArch64][LoadStoreOptimizer] Turn a test into an assert. NFC.
Quentin Colombet [Fri, 7 Aug 2015 22:40:51 +0000 (22:40 +0000)]
[AArch64][LoadStoreOptimizer] Turn a test into an assert. NFC.

At this point the given Opc must be valid, otherwise we should
not look for a matching pair to form paired load or store.

Thanks to Chad to point out this piece of code!

llvm-svn: 244366

9 years agoRemove unused variable.
Rui Ueyama [Fri, 7 Aug 2015 22:40:13 +0000 (22:40 +0000)]
Remove unused variable.

llvm-svn: 244365

9 years ago[asan] Try different values of the shadow gap start.
Evgeniy Stepanov [Fri, 7 Aug 2015 22:38:44 +0000 (22:38 +0000)]
[asan] Try different values of the shadow gap start.

The number of unaccessible pages at the beginning of the address
space can differ between processes on the same machine. Try different
values at runtime to protect as much memory as possible.

llvm-svn: 244364

9 years agoDo not use -fvisibility option with Visual C
Michael Kruse [Fri, 7 Aug 2015 22:16:44 +0000 (22:16 +0000)]
Do not use -fvisibility option with Visual C

It doesn't know the option and prints a warning.

llvm-svn: 244363

9 years agoAMDGPU/SI: Use InstAlias instead of MnemonicAlias for VOPC instructions
Tom Stellard [Fri, 7 Aug 2015 22:00:56 +0000 (22:00 +0000)]
AMDGPU/SI: Use InstAlias instead of MnemonicAlias for VOPC instructions

Summary:
With InstAlias, we don't need to print the _e32 portion of the mnemonic
when we print the $dst operand.  This change makes it possible to
include vcc in the asm string when we switch VOPC over to having
implicit vcc defs.

Reviewers: arsenm

Subscribers: llvm-commits

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

llvm-svn: 244362

9 years agoredo r244360 (tighten checks...) after specifying triple
Sanjay Patel [Fri, 7 Aug 2015 21:42:24 +0000 (21:42 +0000)]
redo r244360 (tighten checks...) after specifying triple

llvm-svn: 244361

9 years agotighten checks using update_llc_test_checks.py
Sanjay Patel [Fri, 7 Aug 2015 21:38:53 +0000 (21:38 +0000)]
tighten checks using update_llc_test_checks.py

llvm-svn: 244360

9 years ago[asan] Reduce shadow gap start on 32-bit Android.
Evgeniy Stepanov [Fri, 7 Aug 2015 21:17:46 +0000 (21:17 +0000)]
[asan] Reduce shadow gap start on 32-bit Android.

This fixes an internal assertion failure when running out of
the address space in the large allocator.

llvm-svn: 244359

9 years agoCOFF: Remove lld-link2 alias.
Rui Ueyama [Fri, 7 Aug 2015 21:02:36 +0000 (21:02 +0000)]
COFF: Remove lld-link2 alias.

llvm-svn: 244358

9 years agoMIR Serialization: Serialize the base alignment for the machine memory operands.
Alex Lorenz [Fri, 7 Aug 2015 20:48:30 +0000 (20:48 +0000)]
MIR Serialization: Serialize the base alignment for the machine memory operands.

llvm-svn: 244357

9 years agoMIR Serialization: Serialize the offsets for the machine memory operands.
Alex Lorenz [Fri, 7 Aug 2015 20:26:52 +0000 (20:26 +0000)]
MIR Serialization: Serialize the offsets for the machine memory operands.

llvm-svn: 244356

9 years agoMIR Parser: Extract the parsing of the operand's offset into a new method. NFC.
Alex Lorenz [Fri, 7 Aug 2015 20:21:00 +0000 (20:21 +0000)]
MIR Parser: Extract the parsing of the operand's offset into a new method. NFC.

This commit extract the code that parses the 64-bit offset from the method
'parseOperandsOffset' to a new method 'parseOffset' so that we can reuse it
when parsing the offset for the machine memory operands.

llvm-svn: 244355

9 years agoAMDGPU: Assume SMRD access for constant address space
Matt Arsenault [Fri, 7 Aug 2015 20:18:34 +0000 (20:18 +0000)]
AMDGPU: Assume SMRD access for constant address space

Since r243294 these are selected to SMRD and
moved later if required.

llvm-svn: 244354

9 years agoDon't look for a SHT_DYNSYM in the ELFFile's constructor.
Rafael Espindola [Fri, 7 Aug 2015 20:11:08 +0000 (20:11 +0000)]
Don't look for a SHT_DYNSYM in the ELFFile's constructor.

Yet another step in not having it scan every section.

llvm-svn: 244353

9 years agoAdd Intel family 6 model 90 as Silvermont. Fixes PR24392.
Craig Topper [Fri, 7 Aug 2015 20:09:42 +0000 (20:09 +0000)]
Add Intel family 6 model 90 as Silvermont. Fixes PR24392.

llvm-svn: 244352

9 years agoRemove the symbol iteration functions that don't take a symbol table.
Rafael Espindola [Fri, 7 Aug 2015 20:07:27 +0000 (20:07 +0000)]
Remove the symbol iteration functions that don't take a symbol table.

Another step in making ELFFile's constructor not iterate over all sections.

llvm-svn: 244351

9 years agoAvoid using getDotDynSymSec in lld. It is going away.
Rafael Espindola [Fri, 7 Aug 2015 20:01:24 +0000 (20:01 +0000)]
Avoid using getDotDynSymSec in lld. It is going away.

llvm-svn: 244350

9 years ago[LAA] Remove unused pointer partition argument from print(), NFC
Adam Nemet [Fri, 7 Aug 2015 19:44:48 +0000 (19:44 +0000)]
[LAA] Remove unused pointer partition argument from print(), NFC

This is now handled in the client.  No need for LAA to provide this
variant.

llvm-svn: 244349

9 years ago[ConstantFoldTerminator] Preserve make.implicit metadata when converting SwitchInst...
Chen Li [Fri, 7 Aug 2015 19:30:12 +0000 (19:30 +0000)]
[ConstantFoldTerminator] Preserve make.implicit metadata when converting SwitchInst to BranchInst

Summary: llvm::ConstantFoldTerminator function can convert SwitchInst with single case (and default) to a conditional BranchInst. This patch adds support to preserve make.implicit metadata on this conversion.

Reviewers: sanjoy, weimingz, chenli

Subscribers: mcrosier, llvm-commits

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

llvm-svn: 244348

9 years ago[MCDwarf] Use more idiomatic [u]int8_t types.
Frederic Riss [Fri, 7 Aug 2015 19:19:44 +0000 (19:19 +0000)]
[MCDwarf] Use more idiomatic [u]int8_t types.

llvm-svn: 244347

9 years agoUpdate a comment to be more descriptive.
Eric Christopher [Fri, 7 Aug 2015 19:07:08 +0000 (19:07 +0000)]
Update a comment to be more descriptive.

llvm-svn: 244346

9 years agoUse lowercase for local cmake variables.
Chaoren Lin [Fri, 7 Aug 2015 18:54:06 +0000 (18:54 +0000)]
Use lowercase for local cmake variables.

llvm-svn: 244345

9 years agoHide cmake variables related to static linking Android lldb-server.
Chaoren Lin [Fri, 7 Aug 2015 18:54:04 +0000 (18:54 +0000)]
Hide cmake variables related to static linking Android lldb-server.

llvm-svn: 244344

9 years agoUpdate to D11825.
Chaoren Lin [Fri, 7 Aug 2015 18:54:02 +0000 (18:54 +0000)]
Update to D11825.

Summary:
Adding `-latomic` to `ANDROID_LINKER_FLAGS` doesn't actually work.
Adding `atomic` to `LLDB_SYSTEM_LIBS` does.

Related: D11831.

Reviewers: Andrzej, ovyalov

Subscribers: tberghammer, danalbert, srhines, lldb-commits

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

llvm-svn: 244343

9 years agoMove the cpu validating virtual method down to the feature routines
Eric Christopher [Fri, 7 Aug 2015 18:31:25 +0000 (18:31 +0000)]
Move the cpu validating virtual method down to the feature routines
where it belongs.

llvm-svn: 244342

9 years ago[InstCombine] Fix SSE2/AVX2 vector logical shift by constant
Simon Pilgrim [Fri, 7 Aug 2015 18:22:50 +0000 (18:22 +0000)]
[InstCombine] Fix SSE2/AVX2 vector logical shift by constant

This patch fixes the sse2/avx2 vector shift by constant instcombine call to correctly deal with the fact that the shift amount is formed from the entire lower 64-bit and not just the lowest element as it currently assumes.

e.g.

%1 = tail call <4 x i32> @llvm.x86.sse2.psrl.d(<4 x i32> %v, <4 x i32> <i32 15, i32 15, i32 15, i32 15>)

In this case, (V)PSRLD doesn't perform a lshr by 15 but in fact attempts to shift by 64424509455 ((15 << 32) | 15) - giving a zero result.

In addition, this review also recognizes shift-by-zero from a ConstantAggregateZero type (PR23821).

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

llvm-svn: 244341

9 years agoNFC.
Cong Hou [Fri, 7 Aug 2015 18:04:17 +0000 (18:04 +0000)]
NFC.

Use a parent class to avoid reduncant code when specializing GraphTraits for T and const T.

llvm-svn: 244340

9 years agoRestore PrettyStackTrace state on crash.
Nico Weber [Fri, 7 Aug 2015 17:48:57 +0000 (17:48 +0000)]
Restore PrettyStackTrace state on crash.

Last part of PR11974.

llvm-svn: 244339

9 years agoAdd functions to save and restore the PrettyStackTrace state.
Nico Weber [Fri, 7 Aug 2015 17:47:03 +0000 (17:47 +0000)]
Add functions to save and restore the PrettyStackTrace state.

PrettyStackTraceHead is a LLVM_THREAD_LOCAL, which means it's just a global
in LLVM_ENABLE_THREADS=NO builds.  If a CrashRecoveryContext is used with
code that uses PrettyStackEntries, and a crash happens, PrettyStackTraceHead is
currently not reset to its pre-crash value.  These functions make it possible
to add a cleanup to such code that does this.

(Not reseting the value then causes the assert in ~PrettyStackTraceEntry() to
fire if the code outside of the CrashRecoveryContext also uses
PrettyStackEntries -- for example, clang when building a module.)

Part of PR11974.

llvm-svn: 244338

9 years agoAdd a comment.
Nico Weber [Fri, 7 Aug 2015 17:32:06 +0000 (17:32 +0000)]
Add a comment.

llvm-svn: 244337

9 years agoUse already available symbol tables. NFC.
Rafael Espindola [Fri, 7 Aug 2015 17:16:28 +0000 (17:16 +0000)]
Use already available symbol tables. NFC.

llvm-svn: 244336

9 years agoDelete dead code. NFC.
Rafael Espindola [Fri, 7 Aug 2015 17:06:05 +0000 (17:06 +0000)]
Delete dead code. NFC.

llvm-svn: 244335

9 years ago[ARM] Remove an unused reference to MachineRegisterInfo. NFC.
Chad Rosier [Fri, 7 Aug 2015 17:02:29 +0000 (17:02 +0000)]
[ARM] Remove an unused reference to MachineRegisterInfo. NFC.

llvm-svn: 244334

9 years agoDon't use a DenseMap to handle SHT_SYMTAB_SHNDX.
Rafael Espindola [Fri, 7 Aug 2015 16:51:44 +0000 (16:51 +0000)]
Don't use a DenseMap to handle SHT_SYMTAB_SHNDX.

It is already a convenient table.

llvm-svn: 244333

9 years agoAMDGPU/SI: Use correct encoding of vopc for VI in the assembler
Tom Stellard [Fri, 7 Aug 2015 16:45:33 +0000 (16:45 +0000)]
AMDGPU/SI: Use correct encoding of vopc for VI in the assembler

Summary: We were using the SI encoding for VI.

Reviewers: arsenm

Subscribers: llvm-commits

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

llvm-svn: 244332

9 years agoAMDGPU/SI: Add VI checks to vop3 assembler tests
Tom Stellard [Fri, 7 Aug 2015 16:45:30 +0000 (16:45 +0000)]
AMDGPU/SI: Add VI checks to vop3 assembler tests

Reviewers: arsenm

Subscribers: llvm-commits

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

llvm-svn: 244331

9 years agoWe're actually -Wmissing-field-initializers clean thanks to the cmake
Eric Christopher [Fri, 7 Aug 2015 16:44:47 +0000 (16:44 +0000)]
We're actually -Wmissing-field-initializers clean thanks to the cmake
build so check and turn on -Wmissing-field-initializers. While there,
reorganize the conditional warning code based on compiler to be a bit
more obvious and inside a switch statement.

llvm-svn: 244330

9 years agoSilence gcc 5.1 unused variable warnings using LLVM_ATTRIBUTE_UNUSED.
Yaron Keren [Fri, 7 Aug 2015 16:37:34 +0000 (16:37 +0000)]
Silence gcc 5.1 unused variable warnings using LLVM_ATTRIBUTE_UNUSED.

llvm-svn: 244329

9 years agoDelete dead typedef. NFC.
Rafael Espindola [Fri, 7 Aug 2015 16:36:47 +0000 (16:36 +0000)]
Delete dead typedef. NFC.

llvm-svn: 244328

9 years agoUse 'signed char' instead of 'char'
Frederic Riss [Fri, 7 Aug 2015 16:31:59 +0000 (16:31 +0000)]
Use 'signed char' instead of 'char'

Hope this fixes the s390 and aarch64 bots.

llvm-svn: 244327

9 years agoUse LLVM_ATTRIBUTE_UNUSED to hide gcc 5.1 unused variable warning.
Yaron Keren [Fri, 7 Aug 2015 16:21:23 +0000 (16:21 +0000)]
Use LLVM_ATTRIBUTE_UNUSED to hide gcc 5.1 unused variable warning.
Suggestion by David Blaikie!

llvm-svn: 244326

9 years agoThis patch commits OpenMP 4 target device clauses
Michael Wong [Fri, 7 Aug 2015 16:16:36 +0000 (16:16 +0000)]
This patch commits OpenMP 4 target device clauses
This is committed on behalf of Kelvin Li
http://reviews.llvm.org/D11469?id=31227

llvm-svn: 244325

9 years ago[Compiler-RT] Disable TSAN on AArch64 temporarily
Renato Golin [Fri, 7 Aug 2015 15:41:43 +0000 (15:41 +0000)]
[Compiler-RT] Disable TSAN on AArch64 temporarily

Until all problems with the buildbot can be identified and fixed.

llvm-svn: 244324

9 years agoadd missing tests files
Rafael Espindola [Fri, 7 Aug 2015 15:35:49 +0000 (15:35 +0000)]
add missing tests files

llvm-svn: 244323

9 years agoAMDGPU/SI: v_mac_legacy_f32 does not exist on VI
Tom Stellard [Fri, 7 Aug 2015 15:34:30 +0000 (15:34 +0000)]
AMDGPU/SI: v_mac_legacy_f32 does not exist on VI

Reviewers: arsenm

Subscribers: llvm-commits

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

llvm-svn: 244322

9 years agoAMDGPU/SI: Remove unused outs parameter from VOPC TableGen classes
Tom Stellard [Fri, 7 Aug 2015 15:34:27 +0000 (15:34 +0000)]
AMDGPU/SI: Remove unused outs parameter from VOPC TableGen classes

Reviewers: arsenm

Subscribers: llvm-commits

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

llvm-svn: 244321

9 years agoAdd dynamic_table iterators back to ELF.h.
Rafael Espindola [Fri, 7 Aug 2015 15:25:20 +0000 (15:25 +0000)]
Add dynamic_table iterators back to ELF.h.

In tree they are only used by llvm-readobj, but it is also used by
https://github.com/mono/CppSharp.

While at it, add some missing error checking.

llvm-svn: 244320

9 years ago[dsymutil] Use the new MCDwarfLineTableParams customization to emit linetables
Frederic Riss [Fri, 7 Aug 2015 15:14:13 +0000 (15:14 +0000)]
[dsymutil] Use the new MCDwarfLineTableParams customization to emit linetables

llvm-dsymutil has to be able to process debug info produced by other compilers
which use different line table settings. The testcase wasn't generated by
another compiler, but by a modified clang.

llvm-svn: 244319

9 years ago[MC/Dwarf] Allow to specify custom parameters for linetable emission.
Frederic Riss [Fri, 7 Aug 2015 15:14:08 +0000 (15:14 +0000)]
[MC/Dwarf] Allow to specify custom parameters for linetable emission.

NFC patch for current users, but llvm-dsymutil will use the new
functionality to adapt to the input linetable.

Based on a patch by Adrian Prantl.

llvm-svn: 244318

9 years agoELF: Correctly identify SHT_NOTE sections with !SHF_ALLOC as type*Note
Tom Stellard [Fri, 7 Aug 2015 14:36:04 +0000 (14:36 +0000)]
ELF: Correctly identify SHT_NOTE sections with !SHF_ALLOC as type*Note

Subscribers: llvm-commits

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

llvm-svn: 244317

9 years ago[ASAN] Disable ManyThreadsTest in AArch64
Renato Golin [Fri, 7 Aug 2015 12:40:05 +0000 (12:40 +0000)]
[ASAN] Disable ManyThreadsTest in AArch64

This test was in an infinite loop in AArch64. We're investigating it
on PR24389, but I'm disabling it for now, so that we continue testing
everything else.

llvm-svn: 244316

9 years agoFix unused variable warning introduced in r244314
Silviu Baranga [Fri, 7 Aug 2015 12:05:46 +0000 (12:05 +0000)]
Fix unused variable warning introduced in r244314

llvm-svn: 244315