133996 Commits

Author SHA1 Message Date
Vitaly Buka
eb7016ef82 Debugging D21194 issues on bot
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272863 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-16 01:26:46 +00:00
Eric Christopher
4b29faaa07 Tidy the asm parser: 80-col, whitespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272861 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-16 01:00:53 +00:00
Matt Arsenault
11e5e3bbe1 AMDGPU: Disable scheduling in some slow tests
Disabling the pre-RA scheduler on large-work-group-registers
causes it to be ~50% slower.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272860 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-16 00:56:47 +00:00
Vitaly Buka
35825a3ed7 Enable libFuzzer's afl_driver to append stderr to a file.
Summary:
[libFuzzer] Enable afl_driver to append stderr to a user specified file.

Append stderr of afl_driver to the file specified by the environmental variable
AFL_DRIVER_STDERR_DUPLICATE_FILENAME if it is set. This lets users see outputs
on crashes without rerunning crashing test cases (which won't work for crashes
that are difficult to reproduce). Before this patch, stderr would only be sent to afl-fuzz
and users would have no way of seeing it.

Reviewers: llvm-commits, aizatsky, kcc, vitalybuka

Subscribers: vitalybuka

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272858 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-16 00:14:42 +00:00
Justin Lebar
60cc4971e1 [IR] [DAE] Copy comdats during DAE, and don't copy comdats in GlobalObject::copyAttributesFrom.
Summary: This reverts the changes to Globals.cpp and IRMover.cpp in
"[IR] Copy comdats in GlobalObject::copyAttributesFrom" (D20631,
rL270743).

The DeadArgElim test is left unchanged, and we change DAE to explicitly
copy comdats.

The reverted change breaks copyAttributesFrom when the destination lives
in a different module from the source.  The decision in D21255 was to
revert this patch and handle comdat copying separately from
copyAttributesFrom.

Reviewers: majnemer, rnk

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272855 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 23:20:15 +00:00
Justin Lebar
b570d71127 [Bugpoint] Erase comdat annotations after removing a global's initializer.
Summary:
This is necessary to keep the verifier happy after bugpoint removes an
initializer from a global variable with a comdat annotation, because
globals without initializers may not have comdats.

Reviewers: majnemer, rnk

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272854 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 23:20:12 +00:00
Adam Nemet
2978728dd2 [LV] Make the new getter return a const reference. NFC
LoopVectorizationLegality holds a constant reference to LAI, so this
will have to be const as well.

Also added missed function comment.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272851 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 22:58:27 +00:00
Xinliang David Li
ac1a58e7e9 Address review feedbacks of AddDiscriminator change
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272850 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 22:20:56 +00:00
Chad Rosier
1e8c62127b [DSE] Hoist a redundant check to simplify logic. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272849 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 22:17:38 +00:00
Sanjay Patel
2514d4ab55 fix comments; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272848 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 22:01:28 +00:00
Xinliang David Li
438355c7b4 [PM] Port Add discriminator pass to new PM
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272847 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:51:30 +00:00
Chad Rosier
57c478eeb8 Typo. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272846 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:41:22 +00:00
Rui Ueyama
fbe558b2f9 [Codeview] Add a class for LF_UDT_MOD_SRC_LINE.
Differential Revision: http://reviews.llvm.org/D21406

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272843 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:25:29 +00:00
Davide Italiano
f56a12348e [PM] Remove unneded doFinalization() override from LoopVersioningLICM.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272842 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:23:54 +00:00
Sanjay Patel
079ac1edc0 [x86, SSE] update packed FP compare tests for direct translation from builtin to IR
The clang side of this was r272840:
http://reviews.llvm.org/rL272840

A follow-up step would be to auto-upgrade and remove these LLVM intrinsics completely.

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



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272841 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:22:15 +00:00
Chad Rosier
357edbc1d6 Address a few coding style issues. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272838 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:14:02 +00:00
Kevin Enderby
04195353af Fix llvm-objdump when disassembling a stripped Mach-O binary with the -macho option.
It was printing out nothing in this case.

llvm-objdump tries to disassemble sections a symbol at a time.  In the case of a
fully stripped Mach-O executable the only symbol remaining in the (__TEXT,__text)
section is the special linker defined symbol __mh_execute_header . This
symbol is special in that while it is N_SECT symbol in the (__TEXT,__text)
its address is before the start of the (__TEXT,__text).  It’s address is the
start of the __TEXT segment which is where the mach header is statically
linked. So the code in DisassembleMachO() needs to deal with this case specially.

rdar://26778273


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272837 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:14:01 +00:00
Krzysztof Parzyszek
16185a2b7f [Hexagon] Fix/simplify some conditional statements
Fix for PR28138.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272836 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 21:05:04 +00:00
Kevin B. Smith
f258b9a271 [X86]: Fix for uninitialized access introduced in r272797.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272835 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:52:19 +00:00
Sanjay Patel
efa2e76536 [x86] delete unnecessary function declarations
Missed this in r272806, r272807.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272834 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:51:47 +00:00
George Burgess IV
3cdf3eb380 [CFLAA] Ignore non-pointers, move Attrs to graph nodes.
This patch makes CFLAA ignore non-pointer values, since we can now
sanely do that with the escaping/unknown attributes. Additionally,
StratifiedAttrs make more sense to sit on nodes than edges (since
they're properties of values, and ultimately end up on the nodes of
StratifiedSets). So, this patch puts said attributes on nodes.

Patch by Jia Chen.

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


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272833 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:43:41 +00:00
Tim Northover
4d6b849855 AArch64: stop trying to use 32-bit MOVZs when expanding patchpoints.
Of course the assembly was right but because the opcode was MOVZWi it was
encoded as "movz w16, #65535, lsl #32" which is an unallocated encoding and
would go horribly wrong on a CPU.

No idea how this bug survived this long. It seems nobody is using that aspect
of patchpoints.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272831 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:33:36 +00:00
Reid Kleckner
0fadb1f37c Axe some trailing whitespace from my last commit
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272830 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:32:42 +00:00
Reid Kleckner
f07202a7aa [codeview] Move deserialization methods out of line
They aren't performance critical and don't need to be inline.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272829 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:30:34 +00:00
Sanjay Patel
2df18c8dc0 [x86] add folds for x86 vector compare nodes (PR27924)
Ideally, we can get rid of most x86 LLVM intrinsics by transforming them to IR (and some of that happened 
with http://reviews.llvm.org/rL272807), but it doesn't cost much to have some simple folds in the backend
too while we're working on that and as a backstop.

This fixes:
https://llvm.org/bugs/show_bug.cgi?id=27924

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



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272828 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:26:58 +00:00
Matthias Braun
c882f76cf5 Statistic: Add machine parseable json output
- We lacked a short unique identifier for a statistics, so I renamed the
  current "Name" field that just contained the DEBUG_TYPE name of the
  current file to DebugType and added a new "Name" field that contains
  the C++ identifier of the statistic variable.
- Add the -stats-json option which outputs statistics in json format.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272826 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 20:19:16 +00:00
Davide Italiano
227b804262 [LoopSimplify] Analyses do not need to be member variables.
In preparation for porting this pass to the new PM.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272818 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 18:51:25 +00:00
Reid Kleckner
90392dad06 [codeview] Use ArrayRef instead of a non-const vector reference
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272817 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 18:48:35 +00:00
Rui Ueyama
69d870720c [pdbdump] Verify LF_{CLASS,ENUM,INTERFACE,STRUCTURE,UNION} records.
Differential Revision: http://reviews.llvm.org/D21361

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272815 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 18:26:59 +00:00
Kevin B. Smith
42abc92144 [X86]: Updated r272801 to promote 16 bit compares with immediate operand
to 32 bits. This is in response to a comment by Eli Friedman.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272814 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 18:18:05 +00:00
David Majnemer
b372f89f41 [CodeView] Add support for emitting S_UDT for typedefs
Emit a S_UDT record for typedefs.  We still need to do something for
class types.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272813 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 18:00:01 +00:00
Amaury Sechet
a2f727daf6 Add support for string attributes in the C API.
Summary: As per title. This completes the C API Attribute support.

Reviewers: Wallbraker, whitequark, echristo, rafael, jyknight

Subscribers: mehdi_amini

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272811 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 17:50:39 +00:00
Pankaj Gode
7d829a30aa Test commit after access grant. Modified comment by adding a period.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272808 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 17:24:52 +00:00
Sanjay Patel
3539217c1c [x86, SSE] remove the GCCBuiltins from the integer min/max intrinsics
This allows us to emit native IR in Clang (next commit).
Also, update the intrinsic tests to show that codegen already knows how to handle
the IR that Clang will soon produce.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272806 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 17:17:27 +00:00
Sanjay Patel
83a669a70f [x86] fix function name; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272805 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 17:12:29 +00:00
David Majnemer
7f26e26d0c [TargetLibraryInfo] Teach isValidProtoForLibFunc about tan
We would fail to validate the type of the tan function which would cause
downstream users of isValidProtoForLibFunc to assert.

This fixes PR28143.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272802 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 16:47:23 +00:00
Kevin B. Smith
746c3b7ff4 [X86]: Quit promoting 8 and 16 bit compares to 32 bit.
Differential Revision: http://reviews.llvm.org/D21144


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272801 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 16:37:46 +00:00
Nirav Dave
63a4b3937b Revert "Preserve DebugInfo when replacing values in DAGCombiner"
Reverting due to assertion failure in
lib/CodeGen/SelectionDAG/InstrEmitter.cpp

This reverts commit r272792.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272799 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 16:08:50 +00:00
Kevin B. Smith
8800861c19 [X86]: Improve Liveness checking for X86FixupBWInsts.cpp
Differential Revision: http://reviews.llvm.org/D21085


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272797 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 16:03:06 +00:00
Adam Nemet
30aa48372a [LV] Add getter function for LoopVectorizationLegality::Strides. NFC
This should help moving Strides to LAA later.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272796 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 15:49:46 +00:00
Vasileios Kalintiris
4eebd00d01 [mips] Eliminate unused code for addrRegReg complex pattern. NFC.
Reviewers: dsanders, sdardis

Subscribers: dsanders, sdardis, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272794 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 15:30:07 +00:00
Aaron Ballman
0774f89723 Add llvm_unreachable to silence a "not all control paths" false positive warning from MSVC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272793 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 15:27:53 +00:00
Nirav Dave
d2f1fe5fc1 Preserve DebugInfo when replacing values in DAGCombiner
[DAG] Previously debug values would transfer debuginfo for the selected
start node for a replacement which allows for debug to be dropped.

Push debug value transfer to occur with node/value replacement in
SelectionDAG, remove now extraneous transfers of debug values.

This refixes PR9817 which was being incompletely checked in the
testsuite.

Reviewers: jyknight

Subscribers: dblaikie, llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272792 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 14:50:08 +00:00
Ranjeet Singh
a94e734a24 Reverting r272778 because there's an assertion
failure when running the test CodeGen/ARM/intrinsics-coprocessor.ll



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272791 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 14:23:29 +00:00
Craig Topper
4b4f0e3aa3 [AVX512] Remove the GCCBuiltins from the mask pcmpeq/pcmpgt intrinsics so we can emit native IR from clang.
The intrinsics themselves can be removed in a future commit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272786 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 14:06:28 +00:00
Valery Pykhtin
2ab3f3b4e1 [AMDGPU] Fix few coding style issues. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272785 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 13:55:09 +00:00
Simon Dardis
b5361d7101 [mips] Missing test case
Add missing testcase from r272666.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272784 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 13:49:58 +00:00
Adam Nemet
77e7a065b2 [LV] Remove more unused functions. NFC
LoopVectorizationLegality::strides_begin/end are also unused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272781 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 12:26:15 +00:00
Adam Nemet
89bc11c112 [LV] Remove unused function. NFC
LoopVectorizationLegality::mustCheckStrides is unused.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272780 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 12:26:11 +00:00
Ranjeet Singh
c0f8f419a5 [ARM] Add support for mrrc/mrrc2 intrinsics.
Differential Revision: http://reviews.llvm.org/D21178



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@272778 91177308-0d34-0410-b5e6-96231b3b80d8
2016-06-15 11:32:24 +00:00