OSDN Git Service

android-x86/external-llvm.git
8 years agoUse false for bool instead of 0
Matt Arsenault [Thu, 2 Jun 2016 18:37:21 +0000 (18:37 +0000)]
Use false for bool instead of 0

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271562 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAMDGPU: Fix crashes on unknown processor name
Matt Arsenault [Thu, 2 Jun 2016 18:37:16 +0000 (18:37 +0000)]
AMDGPU: Fix crashes on unknown processor name

If the processor name failed to parse for amdgcn,
the resulting output would have R600 ISA in it.

If the processor name was missing or invalid for R600,
the wavefront size would not be set and there would be
crashes from missing itinerary data.

Fixes crashes in future commit caused by dividing by the unset/0
wavefront size.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271561 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86] Define segment MI operands as regs instead of i8imm.
Ahmed Bougacha [Thu, 2 Jun 2016 18:29:15 +0000 (18:29 +0000)]
[X86] Define segment MI operands as regs instead of i8imm.

We've been pretending that segments are i8imm since the initial
support (r68645), predating the addition of the SEGMENT_REG class
(r81895).  That happens to works, but is wrong, and inconsistent
with how we print (e.g., X86ATTInstPrinter::printMemReference)
and parse them (e.g., X86Operand::addMemOperands).

This change shouldn't affect any tool users, but is visible to
library users or out-of-tree tablegen backends: this causes
MCOperandInfo for the segment op to have an RC instead of "unknown",
and TII::getRegClass to actually return something.  As the registers
are reserved and no vregs of the class ever created, that shouldn't
change anything.

No test change; no suspicious getRegClass() in X86 and CodeGen.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271559 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoThis is yet another attempt to re-instate r220932 as discussed in
Chandler Carruth [Thu, 2 Jun 2016 18:22:12 +0000 (18:22 +0000)]
This is yet another attempt to re-instate r220932 as discussed in
D19271.

Previous attempt was broken by NetBSD, so in this version I've made the
fallback path generic rather than Windows specific and sent both Windows
and NetBSD to it.

I've also re-formatted the code some, and used an exact clone of the
code in PassSupport.h for doing manual call-once using our atomics
rather than rolling a new one.

If this sticks, we can replace the fallback path for Windows with
a Windows-specific implementation that is more reliable.

Original commit message:
This patch adds an llvm_call_once which is a wrapper around
std::call_once on platforms where it is available and devoid
of bugs. The patch also migrates the ManagedStatic mutex to
be allocated using llvm_call_once.

These changes are philosophically equivalent to the changes
added in r219638, which were reverted due to a hang on Win32
which was the result of a bug in the Windows implementation
of std::call_once.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271558 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agopdbdump: print out COFF section headers.
Rui Ueyama [Thu, 2 Jun 2016 18:20:20 +0000 (18:20 +0000)]
pdbdump: print out COFF section headers.

Unlike other sections that can grow to any size, the COFF section header
stream has maximum length because each record is fixed size and the COFF
file format limits the maximum number of sections. So I decided to not
create a specific stream class for it. Instead, I added a member function
to DbiStream class which returns a vector of COFF headers.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271557 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMake APInt negate just do a 2's complement negate instead of subtract. NFC.
Pete Cooper [Thu, 2 Jun 2016 18:11:54 +0000 (18:11 +0000)]
Make APInt negate just do a 2's complement negate instead of subtract.  NFC.

This is part of an effort to shave allocations from APInt heavy paths.  I'll
be moving many of the other operators to r-value references soon and this is
a step towards doing that without too much duplication.

Saves 15k allocations when doing 'opt -O2 verify-uselistorder.bc'.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271556 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAArch64: Do not test for CPUs, use SubtargetFeatures
Matthias Braun [Thu, 2 Jun 2016 18:03:53 +0000 (18:03 +0000)]
AArch64: Do not test for CPUs, use SubtargetFeatures

Testing for specific CPUs has a number of problems, better use subtarget
features:
- When some tweak is added for a specific CPU it is often desirable for
  the next version of that CPU as well, yet we often forget to add it.
- It is hard to keep track of checks scattered around the target code;
  Declaring all target specifics together with the CPU in the tablegen
  file is a clear representation.
- Subtarget features can be tweaked from the command line.

To discourage people from using CPU checks in the future I removed the
isCortexXX(), isCyclone(), ... functions. I added an getProcFamily()
function for exceptional circumstances but made it clear in the comment
that usage is discouraged.

Reformat feature list in AArch64.td to have 1 feature per line in
alphabetical order to simplify merging and sorting for out of tree
tweaks.

No functional change intended.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271555 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[InstCombine] remove guard for generating a vector select
Sanjay Patel [Thu, 2 Jun 2016 18:03:05 +0000 (18:03 +0000)]
[InstCombine] remove guard for generating a vector select

This is effectively NFC because we already do this transform after r175380:
http://reviews.llvm.org/rL175380

and also via foldBoolSextMaskToSelect().

This change should just make it a bit more efficient to match the pattern.
The original guard was added in r95058:
http://reviews.llvm.org/rL95058

A sampling of codegen for current in-tree targets shows no problems. This
makes sense given that we're already producing the vector selects via the
other transforms.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271554 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[PowerPC] Run reg2mem on tests to simplify them.
Geoff Berry [Thu, 2 Jun 2016 18:02:50 +0000 (18:02 +0000)]
[PowerPC] Run reg2mem on tests to simplify them.

Summary:
Also convert test/CodeGen/PowerPC/vsx-ldst-builtin-le.ll to use
FileCheck instead of two grep and count runs.

This change is needed to avoid spurious diffs in these tests when
EarlyCSE is improved to use MemorySSA and can do more load elimination.

Reviewers: hfinkel

Subscribers: mcrosier, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271553 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86][SSE] Added SSE41/AVX2 non-temporal tests
Simon Pilgrim [Thu, 2 Jun 2016 18:01:21 +0000 (18:01 +0000)]
[X86][SSE] Added SSE41/AVX2 non-temporal tests

Useful for when we add MOVNTDQA support

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271552 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[codeview] Fix crash when handling qualified void types
Reid Kleckner [Thu, 2 Jun 2016 17:40:51 +0000 (17:40 +0000)]
[codeview] Fix crash when handling qualified void types

The DIType* for void is the null pointer. A null DIType can never be a
qualified type, so we can just exit the loop at this point and go to
getTypeIndex(BaseTy).

Fixes PR27984

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271550 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRename IMAGE_DEBUG_TYPE_NO_TIMESTAMP to IMAGE_DEBUG_TYPE_REPRO
David Majnemer [Thu, 2 Jun 2016 17:32:11 +0000 (17:32 +0000)]
Rename IMAGE_DEBUG_TYPE_NO_TIMESTAMP to IMAGE_DEBUG_TYPE_REPRO

This matches the COFF spec

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271549 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoOnly attempt to detect AVG if SSE2 is available
Dimitry Andric [Thu, 2 Jun 2016 17:30:49 +0000 (17:30 +0000)]
Only attempt to detect AVG if SSE2 is available

Summary:
In PR29973 Sanjay Patel reported an assertion failure when a certain
loop was optimized, for a target without SSE2 support.  It turned out
this was because of the AVG pattern detection introduced in rL253952.

Prevent the assertion failure by bailing out early in
`detectAVGPattern()`, if the target does not support SSE2.

Also add a minimized test case.

Reviewers: congh, eli.friedman, spatel

Subscribers: emaste, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271548 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[esan|cfrag] Create the cfrag struct array for the runtime
Qin Zhao [Thu, 2 Jun 2016 17:30:47 +0000 (17:30 +0000)]
[esan|cfrag] Create the cfrag struct array for the runtime

Summary:
Fills the cfrag struct variable with an array of struct information
variables.

Reviewers: aizatsky, bruening

Subscribers: bruening, kcc, vitalybuka, eugenis, llvm-commits, zhaoqin

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271547 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[ADT] Pass ArrayRef::slice size_t instead of unsigned.
Ahmed Bougacha [Thu, 2 Jun 2016 17:26:03 +0000 (17:26 +0000)]
[ADT] Pass ArrayRef::slice size_t instead of unsigned.

Also fix slice wrappers drop_front and drop_back.
The unittests are pretty awkward, but do the job; alternatives
welcome!

..and yes, I do have ArrayRefs with more than 4 billion elements.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271546 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoIgnore Lexing errors in macro body definitions
Nirav Dave [Thu, 2 Jun 2016 17:15:05 +0000 (17:15 +0000)]
Ignore Lexing errors in macro body definitions

Do not issue lexing errors found during the parsing of macro body
definitions and parseIdentifier function in AsmParser. This changes the
Parser to not issue a lexing error when we reach an error, but rather
when it is consumed allowing us time to examine and recover from an
error.

As a result, of this, we stop issuing a both lexing error and a parsing
error in floating-literals test. Minor tweak to parseDirectiveRealValue
to favor more meaningful lexing error over less helpful parse error.

Reviewers: rnk, majnemer

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271542 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CodeView] Implement function-type indices
David Majnemer [Thu, 2 Jun 2016 17:13:53 +0000 (17:13 +0000)]
[CodeView] Implement function-type indices

We still need to do something about member functions and calling
conventions.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271541 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRemove all of the legacy home-grown atomic operations LLVM provided
Chandler Carruth [Thu, 2 Jun 2016 17:11:11 +0000 (17:11 +0000)]
Remove all of the legacy home-grown atomic operations LLVM provided
except for CompareAndSwap. That is the only one still being used
anywhere now that statistics have been moved onto std::atomic.

Also, add a warning to the header that we shouldn't introduce more uses
of these old style atomics and instead should be using C++11's
std::atomic facilities.

Really hoping that we can hammer out the last couple of users here and
replace them with something more localized and/or principled, but
figured this was a pretty good start. =]

Note that this patch will need to be reverted if r271504 needs to be
reverted as that removes the last user of these. However, the biggest
risk for that patch was MSVC 2013 and at least one bot has already
passed where it would have failed there. I've tested MSVC 2015 using
their web interfaces and other platforms seem fine, so I'm optimistic.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271540 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[COFF] Expose the PE debug data directory and dump it
Reid Kleckner [Thu, 2 Jun 2016 17:10:43 +0000 (17:10 +0000)]
[COFF] Expose the PE debug data directory and dump it

This directory is used to find if there is a PDB associated with an
executable. I plan to use this functionality to teach llvm-symbolizer
whether it should use DIA or DWARF to symbolize a given DLL.

Reviewers: majnemer

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271539 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[llvm-cov] Use string getters (NFC)
Vedant Kumar [Thu, 2 Jun 2016 17:00:50 +0000 (17:00 +0000)]
[llvm-cov] Use string getters (NFC)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271537 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[profile] value profiling bug fix -- missing icall targets in profile-use
Xinliang David Li [Thu, 2 Jun 2016 16:33:41 +0000 (16:33 +0000)]
[profile] value profiling bug fix -- missing icall targets in profile-use

Inline virtual functions has linkeonceodr linkage (emitted in comdat on
supporting targets). If the vtable for the class is not emitted in the
defining module, function won't be address taken thus its address is not
recorded. At the mercy of the linker, if the per-func prf_data from this
module (in comdat) is picked at link time, we will lose mapping from
function address to its hash val. This leads to missing icall promotion.
The second test case (currently disabled) in compiler_rt (r271528):
instrprof-icall-prom.test demostrates the bug. The first profile-use
subtest is fine due to linker order difference.

With this change, no missing icall targets is found in instrumented clang's
raw profile.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271532 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[cmake] Fix builds with LLVM_ENABLE_PIC=0
Pavel Labath [Thu, 2 Jun 2016 16:29:07 +0000 (16:29 +0000)]
[cmake] Fix builds with LLVM_ENABLE_PIC=0

Summary:
When this flag is specified, the target llvm-lto is not built, but is still
used as a dependency of the test targets. cmake 2.8 silently ignored this
situation, but with cmake_minimum_required(3.4) it becomes an error. Fix this
by avoiding the inclusion of the target as a dependency.

Reviewers: beanz

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271530 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFix uninitialized members in VarStreamArrayIterator.
Zachary Turner [Thu, 2 Jun 2016 16:28:52 +0000 (16:28 +0000)]
Fix uninitialized members in VarStreamArrayIterator.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271529 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[PEI, AArch64] Use empty spaces in stack area for local stack slot allocation.
Geoff Berry [Thu, 2 Jun 2016 16:22:07 +0000 (16:22 +0000)]
[PEI, AArch64] Use empty spaces in stack area for local stack slot allocation.

Summary:
If the target requests it, use emptry spaces in the fixed and
callee-save stack area to allocate local stack objects.

AArch64: Change last callee-save reg stack object alignment instead of
size to leave a gap to take advantage of above change.

Reviewers: t.p.northover, qcolombet, MatzeB

Subscribers: rengolin, mcrosier, llvm-commits, aemerson

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271527 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[DAG] use getBitcast() to reduce code
Sanjay Patel [Thu, 2 Jun 2016 16:01:15 +0000 (16:01 +0000)]
[DAG] use getBitcast() to reduce code

Although this was intended to be NFC, the test case wiggle shows a change in
code scheduling/RA caused by a difference in the SDLoc() generation.

Depending on how you look at it, this is the (dis)advantage of exact checking
in regression tests.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271526 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[Hexagon] Expand COPY pseudo-instruction
Krzysztof Parzyszek [Thu, 2 Jun 2016 14:33:08 +0000 (14:33 +0000)]
[Hexagon] Expand COPY pseudo-instruction

Handle it locally instead of having the target-independent pass deal
with it. The generic pass does not preserve implicit uses, which may
be necessary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271520 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[RDF] Ignore implicit defs when resetting <kill> flags
Krzysztof Parzyszek [Thu, 2 Jun 2016 14:30:09 +0000 (14:30 +0000)]
[RDF] Ignore implicit defs when resetting <kill> flags

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271519 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86][SSE] Added non-temporal load tests for vector types
Simon Pilgrim [Thu, 2 Jun 2016 13:51:50 +0000 (13:51 +0000)]
[X86][SSE] Added non-temporal load tests for vector types

These currently lower to regular loads instead of MOVNTDQA

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271516 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd assertions to MathExtras max/min functions
Dylan McKay [Thu, 2 Jun 2016 12:00:34 +0000 (12:00 +0000)]
Add assertions to MathExtras max/min functions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271515 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86][SSE] Replace (V)CVTTPS2DQ and VCVTTPD2DQ truncating (round to zero) f32/f64...
Simon Pilgrim [Thu, 2 Jun 2016 10:55:21 +0000 (10:55 +0000)]
[X86][SSE] Replace (V)CVTTPS2DQ and VCVTTPD2DQ truncating (round to zero) f32/f64 to i32 with generic IR (llvm)

This patch removes the llvm intrinsics (V)CVTTPS2DQ and VCVTTPD2DQ truncation (round to zero) conversions and auto-upgrades to FP_TO_SINT calls instead.

Note: I looked at updating CVTTPD2DQ as well but this still requires a lot more work to correctly lower.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271510 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoThis adds support for Cortex-A73 as an available target.
Sjoerd Meijer [Thu, 2 Jun 2016 10:48:52 +0000 (10:48 +0000)]
This adds support for Cortex-A73 as an available target.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271508 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd tests to Support/MathExtras
Dylan McKay [Thu, 2 Jun 2016 09:00:53 +0000 (09:00 +0000)]
Add tests to Support/MathExtras

In r271380, I added several functions to get the minimum/maximum values
of n-width integers.

This just adds tests for them.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271505 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSwitch statistics to use relaxed updates to a std::atomic.
Chandler Carruth [Thu, 2 Jun 2016 08:44:05 +0000 (08:44 +0000)]
Switch statistics to use relaxed updates to a std::atomic.

This removes usage of the hacky, incorrect, and TSan-unfriendly
home-grown atomics. It should actually be more efficient in some cases.

Based on our existing usage of <atomic>, all of this is portably
available AFAICT. One small challenge is initializing the stastic, but
I've tried a comparable sample out on MSVC (the most likely to complain
here) and it seems to work. Will have to watch the build bots of course.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271504 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[ADT] Remove unused multiply and divide operator overloads on
Chandler Carruth [Thu, 2 Jun 2016 08:37:14 +0000 (08:37 +0000)]
[ADT] Remove unused multiply and divide operator overloads on
statistics.

Scaling statistics atomically doesn't make any sense anyways, and none
were using these. If you find yourself wanting to do this, you should
probably keep a local count that you scale and then apply that after
scaling to the shared statistic object.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271503 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CodeView] Use the right type index for long long
David Majnemer [Thu, 2 Jun 2016 07:02:32 +0000 (07:02 +0000)]
[CodeView] Use the right type index for long long

We used T_INT8 instead of T_QUAD.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271497 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CodeView] Take the StreamRef::readBytes offset into account when validating
David Majnemer [Thu, 2 Jun 2016 06:21:44 +0000 (06:21 +0000)]
[CodeView] Take the StreamRef::readBytes offset into account when validating

We only considered the length of the operation and the length of the
StreamRef without considered what it meant for the offset to be at a
non-zero position.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271496 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CodeView] Remove superfluous bitmath
David Majnemer [Thu, 2 Jun 2016 06:21:42 +0000 (06:21 +0000)]
[CodeView] Remove superfluous bitmath

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271495 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[codeview] Return type indices for typedefs
David Majnemer [Thu, 2 Jun 2016 06:21:37 +0000 (06:21 +0000)]
[codeview] Return type indices for typedefs

Use the type index of the underlying type unless we have a typedef from
long to HRESULT; HRESULT typedefs are translated to T_HRESULT.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271494 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[libFuzzer] fix docs
Kostya Serebryany [Thu, 2 Jun 2016 06:06:34 +0000 (06:06 +0000)]
[libFuzzer] fix docs

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271493 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[LibFuzzer] Disable compiling and running the LibFuzzer dataflow sanitizer tests...
Dan Liew [Thu, 2 Jun 2016 05:48:09 +0000 (05:48 +0000)]
[LibFuzzer] Disable compiling and running the LibFuzzer dataflow sanitizer tests on Apple platforms.

This fixes a broken part of the build on OSX as the dataflow sanitizer is not supported
on OSX yet.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271492 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[LibFuzzer] Reimplement how the optional user functions are called.
Dan Liew [Thu, 2 Jun 2016 05:48:02 +0000 (05:48 +0000)]
[LibFuzzer] Reimplement how the optional user functions are called.

The motivation for this change is to fix linking issues on OSX.
However this only partially fixes linking issues (the uninstrumented
tests and a few others  won't succesfully link yet).

This change introduces a struct of function pointers
(``fuzzer::ExternalFuntions``) which when initialised will point to the
optional functions if they are available.  Currently these
``LLVMFuzzerInitialize`` and ``LLVMFuzzerCustomMutator`` functions.

Two implementations of ``fuzzer::ExternalFunctions`` constructor are
provided one for Linux and one for OSX.

The OSX implementation uses ``dlsym()`` because the prior implementation
using weak symbols does not work unless the additional flags are passed
to the linker.

The Linux implementation continues to use weak symbols because the
``dlsym()`` approach does not work unless additional flags are passed
to the linker.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271491 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[libFuzzer] docs: add contact, mention more trophies
Kostya Serebryany [Thu, 2 Jun 2016 05:45:42 +0000 (05:45 +0000)]
[libFuzzer] docs: add contact, mention more trophies

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271490 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[pdb] Parse and dump section map and section contribs
Zachary Turner [Thu, 2 Jun 2016 05:07:49 +0000 (05:07 +0000)]
[pdb] Parse and dump section map and section contribs

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271488 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[AVX512] Add 512-bit load/stores to fast isel.
Craig Topper [Thu, 2 Jun 2016 04:51:37 +0000 (04:51 +0000)]
[AVX512] Add 512-bit load/stores to fast isel.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271486 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86] No need to use 256-bit VMOVNTPS for integer types when only AVX1 is supported...
Craig Topper [Thu, 2 Jun 2016 04:19:48 +0000 (04:19 +0000)]
[X86] No need to use 256-bit VMOVNTPS for integer types when only AVX1 is supported. VMOVNTDQ is available with AVX1.

We were getting this right for v4i64 but not the other integer types.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271482 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86] Add AVX 256-bit load and stores to fast isel.
Craig Topper [Thu, 2 Jun 2016 04:19:45 +0000 (04:19 +0000)]
[X86] Add AVX 256-bit load and stores to fast isel.

I'm not sure why this was missing for so long.

This also exposed that we were picking floating point 256-bit VMOVNTPS for some integer types in normal isel for AVX1 even though VMOVNTDQ is available. In practice it doesn't matter due to the execution dependency fix pass, but it required extra isel patterns. Fixing that in a follow up commit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271481 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86] Use uint16_t for a couple arrays of instruction opcodes. NFC
Craig Topper [Thu, 2 Jun 2016 04:19:42 +0000 (04:19 +0000)]
[X86] Use uint16_t for a couple arrays of instruction opcodes. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271480 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[AVX512] Remove LOADA/LOADU/STOREA/STOREU intrinsic types now that they are unused.
Craig Topper [Thu, 2 Jun 2016 04:19:40 +0000 (04:19 +0000)]
[AVX512] Remove LOADA/LOADU/STOREA/STOREU intrinsic types now that they are unused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271479 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[AVX512] Remove masked load intrinsics. Clang now emits generic masked load intrinsic...
Craig Topper [Thu, 2 Jun 2016 04:19:36 +0000 (04:19 +0000)]
[AVX512] Remove masked load intrinsics. Clang now emits generic masked load intrinsics instead.

The intrinsics will be autoupgraded to the same generic masked loads.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271478 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd "REQUIRES-ANY" feature test
Eric Fiselier [Thu, 2 Jun 2016 01:59:57 +0000 (01:59 +0000)]
Add "REQUIRES-ANY" feature test

Summary:
This patch adds a "REQUIRES-ANY" feature test that is disjunctive. This marks a test as `UNSUPPORTED` if none of the specified features are available.

Libc++ has the need to write feature test such as `// REQUIRES-ANY: c++98, c++03`  when testing of behavior that is specific to older dialects but has since changed.

Reviewers: rnk, ddunbar

Subscribers: ddunbar, probinson, llvm-commits, cfe-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271468 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agomake icall pass name consistent /NFC
Xinliang David Li [Thu, 2 Jun 2016 01:52:05 +0000 (01:52 +0000)]
make icall pass name consistent /NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271467 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[libFuzzer] use __sanitizer_print_memory_profile to print the memory profile on OOM
Kostya Serebryany [Thu, 2 Jun 2016 01:33:11 +0000 (01:33 +0000)]
[libFuzzer] use __sanitizer_print_memory_profile to print the memory profile on OOM

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271465 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoInline isDereferenceableFromAttribute; NFC
Sanjoy Das [Thu, 2 Jun 2016 00:52:53 +0000 (00:52 +0000)]
Inline isDereferenceableFromAttribute; NFC

Now that `Value::getPointerDereferenceableBytes` looks beyond just
attributes, the name `isDereferenceableFromAttribute` is misleading.
Just inline the function, since it is small and only used once.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271456 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRemove Value::isPointerDereferenceable; NFCI
Sanjoy Das [Thu, 2 Jun 2016 00:52:48 +0000 (00:52 +0000)]
Remove Value::isPointerDereferenceable; NFCI

... and merge into `Value::getPointerDereferenceableBytes`. This was
suggested by Artur Pilipenko in D20764 -- since we no longer allow loads
of unsized types, there is no need anymore to have this special logic.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271455 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoTry to fix docs build after rL271440
Tamas Berghammer [Thu, 2 Jun 2016 00:26:18 +0000 (00:26 +0000)]
Try to fix docs build after rL271440

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271452 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[asan] Rename *UAR* into *UseAfterReturn*
Vitaly Buka [Thu, 2 Jun 2016 00:06:42 +0000 (00:06 +0000)]
[asan] Rename *UAR* into *UseAfterReturn*

Summary:
To improve readability.

PR27453

Reviewers: kcc, eugenis, aizatsky

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271447 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAMDGPU: Fix incorrectly setting kill flag when copying register tuples
Matt Arsenault [Thu, 2 Jun 2016 00:04:30 +0000 (00:04 +0000)]
AMDGPU: Fix incorrectly setting kill flag when copying register tuples

This fixes some verifier errors when trackLivenessAfterRegAlloc is
enabled.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271446 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMake MachineCopyPropagation preserve CFG
Matt Arsenault [Thu, 2 Jun 2016 00:04:26 +0000 (00:04 +0000)]
Make MachineCopyPropagation preserve CFG

This doesn't touch it as far as I can tell.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271445 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAMDGPU: SIDebuggerInsertNops preserves CFG
Matt Arsenault [Thu, 2 Jun 2016 00:04:22 +0000 (00:04 +0000)]
AMDGPU: SIDebuggerInsertNops preserves CFG

This saves an additional run of the DominatorTree and
MachineLoopInfo

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271444 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agocmake: Fix color diags under ninja if the compiler is "AppleClang"
Justin Bogner [Wed, 1 Jun 2016 23:29:26 +0000 (23:29 +0000)]
cmake: Fix color diags under ninja if the compiler is "AppleClang"

Apparently cmake differentiates between Clang and AppleClang, and we
fail to color our diagnostics if you have the latter. Fix that.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271442 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRework r271439. I forgot to save the buffer for editing.
NAKAMURA Takumi [Wed, 1 Jun 2016 23:03:46 +0000 (23:03 +0000)]
Rework r271439. I forgot to save the buffer for editing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271441 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd new LLVM_EXTERNAL_PROJECTS option to cmake
Tamas Berghammer [Wed, 1 Jun 2016 23:00:45 +0000 (23:00 +0000)]
Add new LLVM_EXTERNAL_PROJECTS option to cmake

The new option makes it possible to build external projects as part of
the llvm build without copying (or symlinking) then into llvm/tool with
specifying a few additional cmake variables.

Example usage (2 additional project called foo and bar):
-DLLVM_EXTERNAL_PROJECTS="Foo;Bar"
-DLLVM_EXTERNAL_FOO_SOURCE_DIR=/src/foo
-DLLVM_EXTERNAL_BAR_SOURCE_DIR=/src/bar

Note: This is the extension of the approach we already support for
clang/lldb/poly with adding an option to specify additional supported
projects.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271440 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMappedBlockStreamTest.cpp: Simplify array initializers.
NAKAMURA Takumi [Wed, 1 Jun 2016 22:59:06 +0000 (22:59 +0000)]
MappedBlockStreamTest.cpp: Simplify array initializers.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271439 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAvoid a load for local functions.
Rafael Espindola [Wed, 1 Jun 2016 21:57:11 +0000 (21:57 +0000)]
Avoid a load for local functions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271437 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[x86, AVX2] regenerate checks
Sanjay Patel [Wed, 1 Jun 2016 21:32:56 +0000 (21:32 +0000)]
[x86, AVX2] regenerate checks

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271434 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[MemorySSA] Port to new pass manager
Geoff Berry [Wed, 1 Jun 2016 21:30:40 +0000 (21:30 +0000)]
[MemorySSA] Port to new pass manager

Add support for the new pass manager to MemorySSA pass.

Change MemorySSA to be computed eagerly upon construction.

Change MemorySSAWalker to be owned by the MemorySSA object that creates
it.

Reviewers: dberlin, george.burgess.iv

Subscribers: mcrosier, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271432 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSDAG: Drop a redundant replace and move the dead node removal closer. NFC
Justin Bogner [Wed, 1 Jun 2016 20:55:26 +0000 (20:55 +0000)]
SDAG: Drop a redundant replace and move the dead node removal closer. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271429 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[DAG] Improve legalization of INSERT_SUBVECTOR
Michael Kuperstein [Wed, 1 Jun 2016 20:49:35 +0000 (20:49 +0000)]
[DAG] Improve legalization of INSERT_SUBVECTOR

When the index is known to be constant 0, insert directly into the the low half,
instead of spilling, performing the insert in-memory, and reloading.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271428 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[PPC64] Fix SUBFC8 Defs list
Keno Fischer [Wed, 1 Jun 2016 20:31:07 +0000 (20:31 +0000)]
[PPC64] Fix SUBFC8 Defs list

Fix PR27943 "Bad machine code: Using an undefined physical register".
SUBFC8 implicitly defines the CR0 register, but this was omitted in
the instruction definition.

Patch by Jameson Nash <jameson@juliacomputing.com>

Reviewers: hfinkel
Differential Revision: http://reviews.llvm.org/D20802

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271425 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[SCEV] Keep SCEVExpander insert points consistent.
Geoff Berry [Wed, 1 Jun 2016 20:03:09 +0000 (20:03 +0000)]
[SCEV] Keep SCEVExpander insert points consistent.

Summary:
Make sure that the SCEVExpander Builder insert point and any
saved/restored insert points are kept consistent (i.e. their Instruction
and BasicBlock match) when moving instructions in SCEVExpander.

This fixes an issue triggered by
http://reviews.llvm.org/D18001 [LSR] Create fewer redundant instructions.

Test case will be added in reapply commit of above change:
http://reviews.llvm.org/D18480 Reapply [LSR] Create fewer redundant instructions.

Reviewers: sanjoy

Subscribers: mzolotukhin, sanjoy, qcolombet, mcrosier, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271424 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRevert "Claim NoAlias if two GEPs index different fields of the same struct"
Daniel Berlin [Wed, 1 Jun 2016 18:55:32 +0000 (18:55 +0000)]
Revert "Claim NoAlias if two GEPs index different fields of the same struct"

This reverts commit 2d5d6493f43eb68493a3852b8c226ac9fafdc7eb.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271422 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CFLAA] Recognize builtin allocation functions.
George Burgess IV [Wed, 1 Jun 2016 18:39:54 +0000 (18:39 +0000)]
[CFLAA] Recognize builtin allocation functions.

This patch extends CFLAA to recognize allocation functions such as
malloc, free, etc, so we can treat them more aggressively.

Patch by Jia Chen.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271421 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[pdb] silence warnings about moving from a temporary.
Zachary Turner [Wed, 1 Jun 2016 18:18:55 +0000 (18:18 +0000)]
[pdb] silence warnings about moving from a temporary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271420 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CodeView] Simplify StreamArray operator++
David Majnemer [Wed, 1 Jun 2016 18:13:08 +0000 (18:13 +0000)]
[CodeView] Simplify StreamArray operator++

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271419 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[CodeView] Make sure StreamRef::readBytes doesn't read too much
David Majnemer [Wed, 1 Jun 2016 18:13:06 +0000 (18:13 +0000)]
[CodeView] Make sure StreamRef::readBytes doesn't read too much

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271418 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[PDB] Make ModStream::symbols report errors
David Majnemer [Wed, 1 Jun 2016 18:13:04 +0000 (18:13 +0000)]
[PDB] Make ModStream::symbols report errors

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271417 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[PDB] Silence sign comparison warnings in MappedBlockStreamTest
David Majnemer [Wed, 1 Jun 2016 18:13:02 +0000 (18:13 +0000)]
[PDB] Silence sign comparison warnings in MappedBlockStreamTest

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271416 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoClaim NoAlias if two GEPs index different fields of the same struct
Daniel Berlin [Wed, 1 Jun 2016 18:12:01 +0000 (18:12 +0000)]
Claim NoAlias if two GEPs index different fields of the same struct

Patch by Taewook Oh

Summary: Patch for Bug 27478. Make BasicAliasAnalysis claims NoAlias if two GEPs index different fields of the same structure.

Reviewers: hfinkel, dberlin

Subscribers: dberlin, mcrosier, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271415 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoBetter fix for PR27903.
Than McIntosh [Wed, 1 Jun 2016 17:55:10 +0000 (17:55 +0000)]
Better fix for PR27903.

Summary:
Re-enable lifetime-start-on-first-use for stack coloring,
but explicitly disable it for slots with more than one start
or end lifetime marker.

Bug: 27903

Reviewers: wmi, tejohnson, qcolombet, gbiv

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271412 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFix the NDEBUG build
Reid Kleckner [Wed, 1 Jun 2016 17:31:24 +0000 (17:31 +0000)]
Fix the NDEBUG build

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271411 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[LV] For some IVs, use vector phis instead of widening in the loop body
Michael Kuperstein [Wed, 1 Jun 2016 17:16:46 +0000 (17:16 +0000)]
[LV] For some IVs, use vector phis instead of widening in the loop body

Previously, whenever we needed a vector IV, we would create it on the fly,
by splatting the scalar IV and adding a step vector. Instead, we can create a
real vector IV. This tends to save a couple of instructions per iteration.

This only changes the behavior for the most basic case - integer primary
IVs with a constant step.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271410 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[codeview] Translate basic DITypes to CV type records
Reid Kleckner [Wed, 1 Jun 2016 17:05:51 +0000 (17:05 +0000)]
[codeview] Translate basic DITypes to CV type records

Summary:
This is meant to be the tiniest step towards DIType to CV type index
translation that I could come up with. Whenever translation fails, we use type
index zero, which is the unknown type.

Reviewers: aaboud, zturner

Subscribers: llvm-commits, amccarth

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271408 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoReduce dependence on pointee types when deducing dereferenceability
Sanjoy Das [Wed, 1 Jun 2016 16:47:45 +0000 (16:47 +0000)]
Reduce dependence on pointee types when deducing dereferenceability

Summary:
Change some of the internal interfaces in Loads.cpp to keep track of the
number of bytes we're trying to prove dereferenceable using an explicit
`Size` parameter.

Before this, the `Size` parameter was implicitly inferred from the
pointee type of the pointer whose dereferenceability we were trying to
prove, causing us to be conservative around bitcasts. This was
unfortunate since bitcast instructions are no-ops and should never
break optimizations.  With an explicit `Size` parameter, we're more
precise (as shown in the test cases), and the code is simpler.

We should eventually move towards a `DerefQuery` struct that groups
together a base pointer, an offset, a size and an alignment; but this
patch is a first step.

Reviewers: apilipenko, dblaikie, hfinkel, reames

Subscribers: mcrosier, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271406 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[libFuzzer] when an invalid flag is given, warn, but don't crash
Kostya Serebryany [Wed, 1 Jun 2016 16:41:12 +0000 (16:41 +0000)]
[libFuzzer] when an invalid flag is given, warn, but don't crash

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271404 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[IR] Disallow loading and storing unsized types
Sanjoy Das [Wed, 1 Jun 2016 16:13:10 +0000 (16:13 +0000)]
[IR] Disallow loading and storing unsized types

Summary:
It isn't clear what is the operational meaning of loading or storing an
unsized types, since it cannot be lowered into something meaningful.
Since there does not seem to be any practical need for it either, make
such loads and stores illegal IR.

Reviewers: majnemer, chandlerc

Subscribers: mcrosier, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271402 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMappedBlockStreamTest.cpp: Appease msc18 to avoid initializer for std::vector.
NAKAMURA Takumi [Wed, 1 Jun 2016 14:26:54 +0000 (14:26 +0000)]
MappedBlockStreamTest.cpp: Appease msc18 to avoid initializer for std::vector.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271397 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUpdate usage(), make sure srcdir is really empty.
Joerg Sonnenberger [Wed, 1 Jun 2016 14:16:00 +0000 (14:16 +0000)]
Update usage(), make sure srcdir is really empty.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271396 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86][SSE] Added non-temporal store tests for all 512-bit vector types
Simon Pilgrim [Wed, 1 Jun 2016 13:58:00 +0000 (13:58 +0000)]
[X86][SSE] Added non-temporal store tests for all 512-bit vector types

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271393 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86][SSE] Added non-temporal store tests for all 256-bit vector types
Simon Pilgrim [Wed, 1 Jun 2016 13:20:25 +0000 (13:20 +0000)]
[X86][SSE] Added non-temporal store tests for all 256-bit vector types

Also added KNL AVX-512 checks

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271391 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[X86][SSE] Added non-temporal store tests for all 128-bit integer vector types
Simon Pilgrim [Wed, 1 Jun 2016 13:05:00 +0000 (13:05 +0000)]
[X86][SSE] Added non-temporal store tests for all 128-bit integer vector types

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271389 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdding back-end support to two bit scanning intrinsics
Michael Zuckerman [Wed, 1 Jun 2016 12:02:37 +0000 (12:02 +0000)]
Adding back-end support to two bit scanning intrinsics

Adding LLVM back-end support to two intrinsics dealing with bit scan: _bit_scan_forward and _bit_scan_reverse.
Their functionality is as described in Intel intrinsics guide:
https://software.intel.com/sites/landingpage/IntrinsicsGuide/#text=_bit_scan_forward&expand=371,370
https://software.intel.com/sites/landingpage/IntrinsicsGuide/#text=_bit_scan_reverse&expand=371,370

Commit on behalf of Omer Paparo Bivas

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271386 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[ARM] Add additional matching for UBFX instructions
Oliver Stannard [Wed, 1 Jun 2016 12:01:01 +0000 (12:01 +0000)]
[ARM] Add additional matching for UBFX instructions

This adds an additional matcher to select UBFX(..) from SRL(AND(..)) in
ARMISelDAGToDAG to help with code size.

Patch by David Green.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271384 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFix off-by-one error in max integer functions
Dylan McKay [Wed, 1 Jun 2016 11:15:25 +0000 (11:15 +0000)]
Fix off-by-one error in max integer functions

I recently added these functions, but implemented them poorly. This
fixes that.

Sorry for the spam.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271380 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRevert "Fix up the definition of the integer max function"
Dylan McKay [Wed, 1 Jun 2016 09:39:42 +0000 (09:39 +0000)]
Revert "Fix up the definition of the integer max function"

This reverts commit eadf45dafe4597589f0f07f665bb4d1faf7a63fe.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271376 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFix up the definition of the integer max function
Dylan McKay [Wed, 1 Jun 2016 09:21:42 +0000 (09:21 +0000)]
Fix up the definition of the integer max function

Technically they were returning MAXIMUM+1

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271375 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[Sparc] Allow passing of empty structs.
Chris Dewhurst [Wed, 1 Jun 2016 08:48:56 +0000 (08:48 +0000)]
[Sparc] Allow passing of empty structs.

Passing an empty struct as a function call argument is now supported.

unit tests for various scenarios added.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271374 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd max/min functions to MathExtras.h
Dylan McKay [Wed, 1 Jun 2016 07:58:15 +0000 (07:58 +0000)]
Add max/min functions to MathExtras.h

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271371 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRevert r271362 "[AVX512] Remove masked load intrinsics. Clang now emits generic maske...
Craig Topper [Wed, 1 Jun 2016 05:57:55 +0000 (05:57 +0000)]
Revert r271362 "[AVX512] Remove masked load intrinsics. Clang now emits generic masked load intrinsics instead."

Looks like something isn't quite right still. Also forgot to move the test cases to an autoupgrade test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271363 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[AVX512] Remove masked load intrinsics. Clang now emits generic masked load intrinsic...
Craig Topper [Wed, 1 Jun 2016 05:35:16 +0000 (05:35 +0000)]
[AVX512] Remove masked load intrinsics. Clang now emits generic masked load intrinsics instead.

The intrinsics will be autoupgraded to the same generic masked loads.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271362 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoDwarfDebug: Simplify. NFC.
Peter Collingbourne [Wed, 1 Jun 2016 02:58:40 +0000 (02:58 +0000)]
DwarfDebug: Simplify. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@271360 91177308-0d34-0410-b5e6-96231b3b80d8