Commit Graph

234044 Commits

Author SHA1 Message Date
Rafael Espindola ed44cf6ccd Refactor duplicated code.
llvm-svn: 272936
2016-06-16 18:50:12 +00:00
Jonathan Peyton 7cf08d4299 Bug fix: crash if teams executed on host
Added argv array check/allocation for parallel directly nested inside the teams
construct, as new coming Fortran codegen passes parameters directly into
kmpc_fork_call missing same parameters in kmpc_fork_teams (earlier codegen
passed to parallel the subset of parameter passed to teams, and thus
no check/allocation needed).

Patch by Andrey Churbanov

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

llvm-svn: 272935
2016-06-16 18:47:38 +00:00
George Rimar 95eeb7730d [ELF] - Handle every global as unversioned export in versioned script.
Patch updates the version script parser to parse versioned files.
In a simple way, just adding them to VersionScriptGlobals list.

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

llvm-svn: 272934
2016-06-16 18:47:04 +00:00
Sanjay Patel dbd68dd09d [x86] generate IR for AVX2 integer min/max builtins
Sibling patch to r272932:
http://reviews.llvm.org/rL272932

llvm-svn: 272933
2016-06-16 18:45:01 +00:00
Sanjay Patel 0e9afea3c8 [x86] autoupgrade and remove AVX2 integer min/max intrinsics
This will (hopefully very temporarily) break clang.
The clang side of this should be the next commit.

llvm-svn: 272932
2016-06-16 18:44:20 +00:00
Samuel Antao 6d0042642a Re-apply r272900 - [OpenMP] Cast captures by copy when passed to fork call so that they are compatible to what the runtime library expects.
An issue in one of the regression tests was fixed for 32-bit hosts.

llvm-svn: 272931
2016-06-16 18:39:34 +00:00
Rui Ueyama 74c4341dde [codeview] Use hashBufferV8 to verify all type records.
Differential Revision: http://reviews.llvm.org/D21393

llvm-svn: 272930
2016-06-16 18:39:17 +00:00
Zachary Turner 01ee3dae04 Resubmit "[pdb] Change type visitor pattern to be dynamic."
There was a regression introduced during type stream merging when
visiting a field list record.  This has been fixed in this patch.

llvm-svn: 272929
2016-06-16 18:22:27 +00:00
Rafael Espindola 5a07687a8e dos2unix this test. NFC.
llvm-svn: 272928
2016-06-16 18:21:11 +00:00
Zachary Turner 73b0b2f555 Revert "[pdb] Change type visitor pattern to be dynamic."
This reverts commit fb0dd311e1ad945827b8ffd5354f4810e2be1579.

This breaks some llvm-readobj tests.

llvm-svn: 272927
2016-06-16 18:09:04 +00:00
Zachary Turner 1f6372c429 [pdb] Change type visitor pattern to be dynamic.
This allows better catching of compiler errors since we can use
the override keyword to verify that methods are actually
overridden.

Also in this patch I've changed from storing a boolean Error
code everywhere to returning an llvm::Error, to propagate richer
error information up the call stack.

Reviewed By: ruiu, rnk
Differential Revision: http://reviews.llvm.org/D21410

llvm-svn: 272926
2016-06-16 18:00:28 +00:00
Davide Italiano 41315f7873 [PM] Revert the port of MergeLoadStoreMotion to the new pass manager.
Daniel Berlin expressed some real concerns about the port and proposed
and alternative approach. I'll revert this for now while working on a
new patch, which I hope to put up for review shortly. Sorry for the churn.

llvm-svn: 272925
2016-06-16 17:40:53 +00:00
Rui Ueyama 727cd2f73f Simplify. NFC.
llvm-svn: 272924
2016-06-16 17:18:25 +00:00
Rui Ueyama e517de655b Inline a small function. NFC.
llvm-svn: 272923
2016-06-16 17:06:24 +00:00
Chad Rosier 624fee55bc [DSE] Minor style cleanup. NFC.
llvm-svn: 272922
2016-06-16 17:06:04 +00:00
Sanjay Patel d09a21682f remove old FileCheck lines that are no longer used
llvm-svn: 272921
2016-06-16 17:04:16 +00:00
Sanjay Patel f664f3a578 [DAG] Remove redundant FMUL in Newton-Raphson SQRT code
When calculating a square root using Newton-Raphson with two constants,
a naive implementation is to use five multiplications (four muls to calculate
reciprocal square root and another one to calculate the square root itself).
However, after some reassociation and CSE the same result can be obtained
with only four multiplications. Unfortunately, there's no reliable way to do
such a reassociation in the back-end. So, the patch modifies NR code itself
so that it directly builds optimal code for SQRT and doesn't rely on any
further reassociation.

Patch by Nikolai Bozhenov!

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

llvm-svn: 272920
2016-06-16 16:58:54 +00:00
Wei Ding ab3d91b8f1 AMDGPU: Add v_mad 16-bit instructions definition.
Differential Revision: http://reviews.llvm.org/D21362

llvm-svn: 272919
2016-06-16 16:50:04 +00:00
Adam Nemet 776346848a [LLE] New test to check that no versioning for symbolic strides occurs. NFC
This is currently only performed in the Vectorizer.  I will change this
as symbolic stride collection is moved to LAA.

This test will track when the actual functional change occurs.

llvm-svn: 272918
2016-06-16 16:45:29 +00:00
Rui Ueyama f9d5620029 Early return. NFC.
llvm-svn: 272917
2016-06-16 16:44:52 +00:00
Omair Javaid 43507f573d Allow installing watchpoints at less than 8-byte alligned addresses for AArch64 targets
This patch allows LLDB for AArch64 to watch all bytes, words or double words individually on non 8-byte alligned addresses.

This patch also adds tests to verify this functionality.

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

llvm-svn: 272916
2016-06-16 16:41:22 +00:00
Rui Ueyama d089a43de4 Early return. NFC.
llvm-svn: 272915
2016-06-16 16:40:36 +00:00
Matt Arsenault 7020f255b1 LangRef: Note expectations when loading with extra alignment
llvm-svn: 272914
2016-06-16 16:33:41 +00:00
Rui Ueyama 4a90f57ef2 Rename PltZero -> PltHeader.
PltZero (or PLT[0]) was an appropriate name for the little code
we have at beginning of the PLT section when we only supported x86
since the code for x86 just fits in the first PLT slot.

It's not the case anymore. The code for ARM64 occupies first two
slots, so PltZero spans PLT[0] and PLT[1], for example.
This patch renames it to avoid confusion.

llvm-svn: 272913
2016-06-16 16:28:50 +00:00
Igor Laevsky 87f0d0e185 Revert r272891 "[JumpThreading] Prevent dangling pointer problems in BranchProbabilityInfo"
It was causing failures in Profile-i386 and Profile-x86_64 tests.

llvm-svn: 272912
2016-06-16 16:25:53 +00:00
Reid Kleckner 0166a71386 [PATCH] Fix RuntimeDyldCOFFI386 to handle relocations with a non-zero addend
This fixes IMAGE_REL_I386_DIR32, IMAGE_REL_I386_DIR32NB,
IMAGE_REL_I386_SECREL, and IMAGE_REL_I386_REL32 relocations.

Based on patch by Jon Turney <jon.turney@dronecode.org.uk>

llvm-svn: 272911
2016-06-16 16:21:41 +00:00
Rui Ueyama c9fee5fee6 Eliminate unnecessary call of SymbolBody::getPltVA.
For ARM and MIPS, we don't need to call this function.
This patch passes a symbol instead of a PLT entry address
so that the target handler can call it if necessary.

llvm-svn: 272910
2016-06-16 16:14:50 +00:00
Rafael Espindola afade35003 Don't print (PLT) on arm.
The R_ARM_PLT32 relocation is deprecated and is not produced by MC.

This means that the code being deleted is dead from the .o point of
view and was making the .s more confusing.

llvm-svn: 272909
2016-06-16 16:09:53 +00:00
Samuel Antao b1f9501242 Revert r272900 - [OpenMP] Cast captures by copy when passed to fork call so that they are compatible to what the runtime library expects.
Was causing trouble in one of the regression tests for a 32-bit address space.

llvm-svn: 272908
2016-06-16 16:06:22 +00:00
Sanjay Patel 51ab757941 [x86] autoupgrade and remove SSE2/SSE41 integer min/max intrinsics
Follow-up to:
http://reviews.llvm.org/rL272806
http://reviews.llvm.org/rL272807

llvm-svn: 272907
2016-06-16 15:48:30 +00:00
Daniel Sanders 8e3c74210f Remove redundant -mattr options from llvm-objdump commands.
The -mattr options in these four tests have no effect on the output of
llvm-objdump. In the case of the two Mips tests, removing the -mattr option
left duplicate RUN lines so the duplicates have been removed.

llvm-svn: 272906
2016-06-16 15:47:19 +00:00
Rafael Espindola 9ba9c5bde5 Refactor duplicated code. NFC.
llvm-svn: 272905
2016-06-16 15:44:06 +00:00
Rafael Espindola c1d739f253 Refactor duplicated code. NFC.
llvm-svn: 272904
2016-06-16 15:40:24 +00:00
Rafael Espindola c24f0eeb8d Refactor duplicated code. NFC.
llvm-svn: 272903
2016-06-16 15:31:06 +00:00
Todd Fiala 85bc3f83f4 xfail TestWithModuleDebugging.py on macOS
Tracked by:
https://llvm.org/bugs/show_bug.cgi?id=28156

llvm-svn: 272902
2016-06-16 15:22:49 +00:00
Rafael Espindola 3888bdb022 Refactor duplicated code. NFC.
llvm-svn: 272901
2016-06-16 15:22:01 +00:00
Samuel Antao 4951617980 [OpenMP] Cast captures by copy when passed to fork call so that they are compatible to what the runtime library expects.
Summary:
This patch fixes an issue detected when firstprivate variables are passed to an OpenMP outlined function vararg list. Currently they are not compatible with what the runtime library expects causing malfunction in some targets.

This patch fixes the issue by moving the casting logic already in place for offloading to the common code that creates the outline function and arguments and updates the regression tests accordingly.

Reviewers: hfinkel, arpith-jacob, carlo.bertolli, kkwli0, ABataev

Subscribers: cfe-commits, caomhin

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

llvm-svn: 272900
2016-06-16 15:09:31 +00:00
Rui Ueyama 43ed08efa3 [codeview] Pass CVRecord to visitTypeBegin callback.
Both parameters to visitTypeBegin are actually members of CVRecord,
so we can just pass CVRecord instead of destructuring it.

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

llvm-svn: 272899
2016-06-16 14:47:23 +00:00
Rui Ueyama b9095ae7ee [codeview] Remove unused parameter.
Differential Revision: http://reviews.llvm.org/D21433

llvm-svn: 272898
2016-06-16 14:41:22 +00:00
Alexander Kornienko b0f613bfc8 [clang-tidy] misc-move-const-arg: Fix typos
Reviewers: alexfh

Subscribers: cfe-commits

Patch by Martin Boehme!

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

llvm-svn: 272897
2016-06-16 14:32:54 +00:00
Alexander Kornienko 28b34b043e [clang-tidy] misc-move-const-arg: Detect if result of std::move() is being passed as a const ref argument
Summary:
Conceptually, this is very close to the existing functionality of misc-move-const-arg, which is why I'm adding it here and not creating a new check. For example, for a type A that is both movable and copyable, this

  const A a1;
  A a2(std::move(a1));

is not only a case where a const argument is being passed to std::move(), but the result of std::move() is also being passed as a const reference (due to overload resolution).

The new check typically triggers (exclusively) in cases where people think they're dealing with a movable type, but in fact the type is not movable.

Reviewers: hokein, aaron.ballman, alexfh

Subscribers: aaron.ballman, cfe-commits

Patch by Martin Boehme!

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

llvm-svn: 272896
2016-06-16 14:32:41 +00:00
Vasileios Kalintiris 22ec97fb24 [mips] Fix small typo. NFC.
llvm-svn: 272895
2016-06-16 14:25:13 +00:00
Rui Ueyama 5c7248c959 Implement pdb::hashBufferV8 hash function.
llvm-svn: 272894
2016-06-16 13:48:16 +00:00
Marcin Koscielnicki a46fade624 [Builtin] Make __builtin_thread_pointer target-independent.
This is now supported for ARM, AArch64, PowerPC, SystemZ, SPARC, Mips.

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

llvm-svn: 272893
2016-06-16 13:41:54 +00:00
Rafael Espindola cf1d4987b9 Add support for # comments.
llvm-svn: 272892
2016-06-16 13:29:48 +00:00
Igor Laevsky c9179fd2c2 [JumpThreading] Prevent dangling pointer problems in BranchProbabilityInfo
We should update results of the BranchProbabilityInfo after removing block in JumpThreading. Otherwise 
we will get dangling pointer inside BranchProbabilityInfo cache.

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

llvm-svn: 272891
2016-06-16 13:28:25 +00:00
Haojian Wu 00cfe279c1 A follow-up fixing on cuda-march.cu: Don't match clang to other place.
llvm-svn: 272890
2016-06-16 13:27:02 +00:00
Rui Ueyama 9caea82d3e Remove redundant namespace specifiers.
llvm-svn: 272889
2016-06-16 13:17:59 +00:00
Rui Ueyama 8b0ae136e2 [codeview] Use CVTypeVisitor instead of a hand-written switch-cases.
Differential Revision: http://reviews.llvm.org/D21418

llvm-svn: 272888
2016-06-16 13:14:42 +00:00
Andrey Turetskiy 83491bb7a5 Patch "Compilation for Intel MCU (Part 2/3)" caused the clang-x64-ninja-win7
buildbot to fail because of inaccurate CHECK in the test. This is a quick fix
for the test to make it platform independent.

llvm-svn: 272887
2016-06-16 12:26:20 +00:00