OSDN Git Service
Nicolai Haehnle [Mon, 2 May 2016 17:37:01 +0000 (17:37 +0000)]
AMDGPU: llvm.SI.fs.constant is a source of divergence
Summary:
This intrinsic is used to get flat-shaded fragment shader inputs. Those are
uniform across a primitive, but a fragment shader wave may process pixels from
multiple primitives (as indicated by the prim_mask), and so that's where
divergence can arise.
Reviewers: arsenm, tstellarAMD
Subscribers: arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D19747
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268259
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Mon, 2 May 2016 17:29:55 +0000 (17:29 +0000)]
ScheduleDAGInstrs.cpp: Don't peel the iterator when it points the end. This will fix the crash in r268143.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268257
91177308-0d34-0410-b5e6-
96231b3b80d8
Derek Schuff [Mon, 2 May 2016 17:25:22 +0000 (17:25 +0000)]
[WebAssembly] Rename memory_size intrinsic to current_memory
This follows the recent renaming in the wasm spec.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268255
91177308-0d34-0410-b5e6-
96231b3b80d8
Hans Wennborg [Mon, 2 May 2016 17:22:54 +0000 (17:22 +0000)]
[SimplifyCFG] Extend TryToSimplifyUncondBranchFromEmptyBlock for empty block including lifetime intrinsics
Make it possible that TryToSimplifyUncondBranchFromEmptyBlock merges empty
basic block including lifetime intrinsics as well as phi nodes and
unconditional branch into its successor or predecessor(s).
If successor of empty block has single predecessor, all contents including
lifetime intrinsics are sinked into the successor. Otherwise, they are
hoisted into its predecessor(s) and then merged into the predecessor(s).
Patch by Josh Yoon <josh.yoon@samsung.com>!
Differential Revision: http://reviews.llvm.org/D19257
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268254
91177308-0d34-0410-b5e6-
96231b3b80d8
Mehdi Amini [Mon, 2 May 2016 16:53:16 +0000 (16:53 +0000)]
Move createReversePostOrderFunctionAttrsPass right after the inliner is done
This is where it was originally, until LoopVersioningLICM was
inserted before in r259986, I don't believe it was on purpose.
Differential Revision: http://reviews.llvm.org/D19809
From: Mehdi Amini <mehdi.amini@apple.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268252
91177308-0d34-0410-b5e6-
96231b3b80d8
Adam Nemet [Mon, 2 May 2016 16:52:00 +0000 (16:52 +0000)]
[LLE] Fix typo from r263058
This was meant to check unit stride for both the load and the store.
Thanks to Roman Shirokiy for noticing this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268251
91177308-0d34-0410-b5e6-
96231b3b80d8
Pete Cooper [Mon, 2 May 2016 16:51:26 +0000 (16:51 +0000)]
Add llvm-pdbdump to the tool substitutions list in lit. NFC.
This adds llvm-pdbdump to the list of tools which get printed with
the full path in verbose mode. This makes it easier to take the
whole run line from verbose output and run it again without prepending
with the builds bin directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268250
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Mon, 2 May 2016 16:45:02 +0000 (16:45 +0000)]
Fixed signed/unsigned comparison warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268249
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Mon, 2 May 2016 16:45:00 +0000 (16:45 +0000)]
Remove extra whitespace. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268248
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Mon, 2 May 2016 16:23:09 +0000 (16:23 +0000)]
AMDGPU/SI: Use hazard recognizer to detect DPP hazards
Reviewers: arsenm
Subscribers: arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D18603
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268247
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 15:49:09 +0000 (15:49 +0000)]
remove blank lines
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268246
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 15:32:10 +0000 (15:32 +0000)]
[InstCombine] regenerate checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268245
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 15:25:49 +0000 (15:25 +0000)]
[InstCombine] regenerate checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268244
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 15:21:41 +0000 (15:21 +0000)]
[InstCombine] regenerate checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268242
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 15:18:13 +0000 (15:18 +0000)]
[InstCombine] regenerate checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268241
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 15:06:55 +0000 (15:06 +0000)]
[InstCombine] regenerate checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268239
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Mon, 2 May 2016 14:58:22 +0000 (14:58 +0000)]
[X86][SSE] Dropped X86ISD::FGETSIGNx86 and use MOVMSK instead for FGETSIGN lowering
movmsk.ll tests are unchanged.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268237
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Mon, 2 May 2016 14:56:21 +0000 (14:56 +0000)]
Cleanup comments. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268236
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Mon, 2 May 2016 14:50:30 +0000 (14:50 +0000)]
Cleanup comments. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268235
91177308-0d34-0410-b5e6-
96231b3b80d8
Aaron Ballman [Mon, 2 May 2016 14:48:03 +0000 (14:48 +0000)]
Silence unused variable warnings; NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268234
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Mon, 2 May 2016 14:32:17 +0000 (14:32 +0000)]
Cleanup comments. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268233
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 2 May 2016 14:21:55 +0000 (14:21 +0000)]
[InstCombine] regenerate checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268232
91177308-0d34-0410-b5e6-
96231b3b80d8
David L Kreitzer [Mon, 2 May 2016 13:45:25 +0000 (13:45 +0000)]
Enable the X86 call frame optimization for the 64-bit targets that allow it.
Fixes PR27241.
Differential Revision: http://reviews.llvm.org/D19688
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268227
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 2 May 2016 13:45:06 +0000 (13:45 +0000)]
Expose a getFullName for thin archive members.
It will be used in lld.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268226
91177308-0d34-0410-b5e6-
96231b3b80d8
Jonas Paulsson [Mon, 2 May 2016 10:42:47 +0000 (10:42 +0000)]
[SystemZ] Temporarily disable codegen test int-add-12.ll.
This checks for AGSI transformation, which is temporarily disabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268219
91177308-0d34-0410-b5e6-
96231b3b80d8
Jonas Paulsson [Mon, 2 May 2016 09:37:44 +0000 (09:37 +0000)]
[SystemZ] Fix in restoreCalleeSavedRegisters()
Only add operands for GRs to the LMG.
Reviewed by Ulrich Weigand.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268216
91177308-0d34-0410-b5e6-
96231b3b80d8
Jonas Paulsson [Mon, 2 May 2016 09:37:40 +0000 (09:37 +0000)]
[SystemZ] Mark CC defs as dead whenever possible.
Marking implicit CC defs as dead everywhere except when CC is actually
defined and used explicitly, is important since the post-ra scheduler
will otherwise insert edges between instructions unnecessarily.
Also temporarily disable LA(Y)-> AGSI optimization in
foldMemoryOperandImpl(), since this inroduces a def of the CC reg,
which is illegal unless it is known to be dead.
Reviewed by Ulrich Weigand.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268215
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Mon, 2 May 2016 05:44:21 +0000 (05:44 +0000)]
[X86] Fix a bug in LOCK arithmetic operation pattern matching where the wrong immediate predicate check was being used for 64-bit instructions with 8-bit immediates.
This didn't cause a bug because the order of the patterns ensured that the 64-bit instructions with 32-bit immediates were selected first.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268212
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Mon, 2 May 2016 05:30:26 +0000 (05:30 +0000)]
Fix grammar and correct comment - the debug information wasn't incorrect, rather suboptimal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268211
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Mon, 2 May 2016 02:30:18 +0000 (02:30 +0000)]
[llvm-readobj] Dump hash as part of -version-info.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268210
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Mon, 2 May 2016 01:53:30 +0000 (01:53 +0000)]
[CodeGen] Add OPC_MoveChild0-OPC_MoveChild7 opcodes to isel matching tables to optimize table size. Shaves about 12K off the X86 matcher table.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268209
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Sun, 1 May 2016 22:51:14 +0000 (22:51 +0000)]
[GlobalDCE] Modernize. Use FileCheck instead of grep.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268207
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 20:43:02 +0000 (20:43 +0000)]
[InstCombine][SSE] Added support to VPERMD/VPERMPS to shuffle combine to accept UNDEF elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268206
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 20:33:25 +0000 (20:33 +0000)]
Dropped FIXME comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268205
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 20:22:42 +0000 (20:22 +0000)]
[InstCombine][SSE] Added support to VPERMILVAR to shuffle combine to accept UNDEF elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268204
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 20:06:47 +0000 (20:06 +0000)]
[InstCombine][AVX] Fixed PERMILVAR identity tests and added additional decode tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268203
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 19:26:21 +0000 (19:26 +0000)]
[InstCombine][SSE] Added support to PSHUFB to shuffle combine to accept UNDEF elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268202
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 18:28:45 +0000 (18:28 +0000)]
[InstCombine][SSE] Regenerate MOVSX/MOVZX tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268201
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 17:38:32 +0000 (17:38 +0000)]
[AVX512] VPACKUSWB/VPACKSSWB should not be encoded with EVEX.W=1. While there fix the execution domain for VPACKSSDW/VPACKUSDW.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268200
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 16:41:22 +0000 (16:41 +0000)]
[InstCombine][AVX2] Combine VPERMD/VPERMPS intrinsics with constant masks to shufflevector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268199
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 15:52:31 +0000 (15:52 +0000)]
Fixed MSVC 'not all control paths return a value' warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268198
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sun, 1 May 2016 15:27:47 +0000 (15:27 +0000)]
Document the LLVM_ENABLE_EXPENSIVE_CHECKS cmake option introduced in r268050
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268197
91177308-0d34-0410-b5e6-
96231b3b80d8
Igor Breger [Sun, 1 May 2016 13:29:12 +0000 (13:29 +0000)]
getelementptr instruction, support index vector of EVT.
Differential Revision: http://reviews.llvm.org/D19775
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268195
91177308-0d34-0410-b5e6-
96231b3b80d8
Igor Breger [Sun, 1 May 2016 08:40:00 +0000 (08:40 +0000)]
Change AVX512 braodcastsd/ss patterns interaction with spilling . New implementation take a scalar register and generate a vector without COPY_TO_REGCLASS (turn it into a VR128 register ) .The issue is that during register allocation we may spill a scalar value using 128-bit loads and stores, wasting cache bandwidth.
Differential Revision: http://reviews.llvm.org/D19579
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268190
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 06:52:19 +0000 (06:52 +0000)]
[AVX512] Prefer AVX512 VPACK instructions over AVX/AVX2 instructions when VLX and BWI are supported.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268189
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 06:24:57 +0000 (06:24 +0000)]
[AVX512] Add HasVLX to the 128/256-bit versions of VPACKSSDW/USDW/SSWB/USWB and VPMADDUBSW/VPMADDWD.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268188
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 05:57:06 +0000 (05:57 +0000)]
[AVX512] Make sure 128/256-bit DQI versions of VAND/VANDN/VOR/VXOR are also marked as requiring VLX.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268186
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 05:22:15 +0000 (05:22 +0000)]
[X86] Add an AddedComplexity to another pattern to put it near similar in the output file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268184
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 05:22:13 +0000 (05:22 +0000)]
[X86] Remove a seemlingly unused pattern. The same pattern appears elsewhere with an AddedComplexity that made this unreachable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268183
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 04:59:49 +0000 (04:59 +0000)]
[X86] Add AddedComplexity to keep some similar patterns near each other in the output file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268181
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 04:59:46 +0000 (04:59 +0000)]
[X86] Remove some redundant selection patterns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268180
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 04:59:44 +0000 (04:59 +0000)]
[AVX512] Replace vector_extract with extractelt in some patterns. They mean the same thing but vector_extract is deprecated. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268179
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Sun, 1 May 2016 04:51:05 +0000 (04:51 +0000)]
[SCEV] When printing via -analysis, dump loop disposition
There are currently some bugs in tree around SCEV caching an incorrect
loop disposition. Printing out loop dispositions will let us write
whitebox tests as those are fixed.
The dispositions are printed as a list in "inside out" order,
i.e. innermost loop first.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268177
91177308-0d34-0410-b5e6-
96231b3b80d8
Amaury Sechet [Sun, 1 May 2016 02:23:14 +0000 (02:23 +0000)]
Properly name LLVMSetIsInBounds's argument. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268176
91177308-0d34-0410-b5e6-
96231b3b80d8
Amaury Sechet [Sun, 1 May 2016 01:42:34 +0000 (01:42 +0000)]
Capitalize align argument in the C API as per convention. NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268175
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 1 May 2016 01:03:56 +0000 (01:03 +0000)]
[AVX512] Add hasSideEffects/mayLoad/mayStore flags to some instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268174
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Sun, 1 May 2016 00:14:45 +0000 (00:14 +0000)]
[ORC] Save AArch64 NEON state in the JIT reentry block.
The earlier version of the resolver code did not save NEON state, so it would
have broken any callees that used floating point.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268173
91177308-0d34-0410-b5e6-
96231b3b80d8
Rui Ueyama [Sat, 30 Apr 2016 21:32:12 +0000 (21:32 +0000)]
[lit] Add %:[STpst] to represent paths without colons on Windows.
Summary:
We need these variables to concatenate two absolute paths to construct
a valid path. Currently, %t\%t is, for example, expanded to C:\foo\C:\foo,
which is not a valid path because ":" is not a valid path character
on Windows. With this patch, %t will be expanded to C\foo.
Differential Revision: http://reviews.llvm.org/D19757
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268168
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sat, 30 Apr 2016 20:41:52 +0000 (20:41 +0000)]
[InstCombine][AVX2] Added VPERMD/VPERMPS shuffle combining placeholder tests.
For future support for VPERMD/VPERMPS to generic shuffles combines
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268166
91177308-0d34-0410-b5e6-
96231b3b80d8
Saleem Abdulrasool [Sat, 30 Apr 2016 18:15:34 +0000 (18:15 +0000)]
CodeGen: convert to range based loops
Convert to using some range based loops, avoid unnecessary variables for
unchecked casts. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268165
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sat, 30 Apr 2016 17:59:49 +0000 (17:59 +0000)]
[X86] Reduce memory usage of MemOp2RegOp and RegOp2MemOp folding maps.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268164
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 30 Apr 2016 15:18:21 +0000 (15:18 +0000)]
Add missing override.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268163
91177308-0d34-0410-b5e6-
96231b3b80d8
Marcin Koscielnicki [Sat, 30 Apr 2016 09:57:34 +0000 (09:57 +0000)]
[ASan] Add shadow offset for SystemZ.
SystemZ on Linux currently has 53-bit address space. In theory, the hardware
could support a full 64-bit address space, but that's not supported due to
kernel limitations (it'd require 5-level page tables), and there are no plans
for that. The default process layout stays within first 4TB of address space
(to avoid creating 4-level page tables), so any offset >= (1 << 42) is fine.
Let's use 1 << 52 here, ie. exactly half the address space.
I've originally used 7 << 50 (uses top 1/8th of the address space), but ASan
runtime assumes there's some space after the shadow area. While this is
fixable, it's simpler to avoid the issue entirely.
Also, I've originally wanted to have the shadow aligned to 1/8th the address
space, so that we can use OR like X86 to assemble the offset. I no longer
think it's a good idea, since using ADD enables us to load the constant just
once and use it with register + register indexed addressing.
Differential Revision: http://reviews.llvm.org/D19650
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268161
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sat, 30 Apr 2016 07:32:19 +0000 (07:32 +0000)]
[InstCombine][AVX] Split off VPERMILVAR tests and added additional tests for UNDEF mask elements
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268159
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Sat, 30 Apr 2016 07:23:30 +0000 (07:23 +0000)]
[InstCombine][AVX] VPERMILVAR to shuffle combine to use general aggregate elements. NFCI.
Make use of Constant::getAggregateElement instead of checking constant types - first step towards adding support for UNDEF mask elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268158
91177308-0d34-0410-b5e6-
96231b3b80d8
Sriraman Tallam [Sat, 30 Apr 2016 04:18:52 +0000 (04:18 +0000)]
Differential Revision: reviews.llvm.org/D19753
Delete Target Option PositionIndependentExecutable as PIE is now part of module flags.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268155
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Sat, 30 Apr 2016 04:04:48 +0000 (04:04 +0000)]
AMDGPU/SI: Remove wait state handling for SMRD in SIInsertWaits
This was supposed to be part of r268143.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268154
91177308-0d34-0410-b5e6-
96231b3b80d8
Hal Finkel [Sat, 30 Apr 2016 01:59:28 +0000 (01:59 +0000)]
[PowerPC/QPX] Fix the load/splat peephole with overlapping reads
If, in between the splat and the load (which does an implicit splat), there is
a read of the splat register, then that register must have another earlier
definition. In that case, we can't replace the load's destination register with
the splat's destination register.
Unfortunately, I don't have a small or non-fragile test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268152
91177308-0d34-0410-b5e6-
96231b3b80d8
Amjad Aboud [Sat, 30 Apr 2016 01:44:07 +0000 (01:44 +0000)]
Reverting 268054 & 268063 as they caused PR27579.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268150
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Sat, 30 Apr 2016 00:55:59 +0000 (00:55 +0000)]
[LowerGuardIntrinsics] Keep track of !make.implicit metadata
If a guard call being lowered by LowerGuardIntrinsics has the
`!make.implicit` metadata attached, then reattach the metadata to the
branch in the resulting expanded form of the intrinsic. This allows us
to implement null checks as guards and still get the benefit of implicit
null checks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268148
91177308-0d34-0410-b5e6-
96231b3b80d8
Lawrence Hu [Sat, 30 Apr 2016 00:51:22 +0000 (00:51 +0000)]
Reroll loops with multiple IV and negative step part 3
support multiple induction variables
This patch enable loop reroll for the following case:
for(int i=0; i<N; i += 2) {
S += *a++;
S += *a++;
};
Differential Revision: http://reviews.llvm.org/D16550
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268147
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Sat, 30 Apr 2016 00:50:26 +0000 (00:50 +0000)]
[Orc] Fix the AArch64 resolver size.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268146
91177308-0d34-0410-b5e6-
96231b3b80d8
Vedant Kumar [Sat, 30 Apr 2016 00:32:54 +0000 (00:32 +0000)]
Fix a typo (NFC)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268144
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Sat, 30 Apr 2016 00:23:06 +0000 (00:23 +0000)]
AMDGPU/SI: Enable the post-ra scheduler
Summary:
This includes a hazard recognizer implementation to replace some of
the hazard handling we had during frame index elimination.
Reviewers: arsenm
Subscribers: qcolombet, arsenm, llvm-commits
Differential Revision: http://reviews.llvm.org/D18602
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268143
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Sat, 30 Apr 2016 00:17:47 +0000 (00:17 +0000)]
[LowerGuardIntrinsics] Preserve calling conv when lowering
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268142
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Sat, 30 Apr 2016 00:12:54 +0000 (00:12 +0000)]
add minimal test to show dropped metadata
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268141
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Sat, 30 Apr 2016 00:02:36 +0000 (00:02 +0000)]
remove the metadata added with r267827
We can demonstrate the 'select' bug and fix with a simpler test case.
The merged weight values are already tested in another test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268139
91177308-0d34-0410-b5e6-
96231b3b80d8
Xinliang David Li [Fri, 29 Apr 2016 22:59:36 +0000 (22:59 +0000)]
Reapply r268107 after fixing a bug breaks debug build.
Makes the new method to set data needed by debug dump.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268130
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Fri, 29 Apr 2016 22:23:16 +0000 (22:23 +0000)]
Mark guards on true as "trivially dead"
This moves some logic added to EarlyCSE in rL268120 into
`llvm::isInstructionTriviallyDead`. Adds a test case for DCE to
demonstrate that passes other than EarlyCSE can now pick up on the new
information.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268126
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Fri, 29 Apr 2016 22:19:35 +0000 (22:19 +0000)]
[CMake] [Xcode] Improving Xcode toolchain generation to support distribution targets
This adds a new target `install-distribution-toolchain` which will install an Xcode toolchain featuring just the LLVM components specified in LLVM_DISTRIBUTION_COMPONENTS.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268125
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Fri, 29 Apr 2016 22:03:27 +0000 (22:03 +0000)]
clean up documentation comments; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268122
91177308-0d34-0410-b5e6-
96231b3b80d8
Haicheng Wu [Fri, 29 Apr 2016 22:01:10 +0000 (22:01 +0000)]
[MBP] Use Function::optForSize() instead of checking OptimizeForSize directly.
Fix a FIXME. Disable loop alignment if compiled with -Oz now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268121
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjoy Das [Fri, 29 Apr 2016 21:52:58 +0000 (21:52 +0000)]
[EarlyCSE] Simplify guard intrinsics
Summary:
This change teaches EarlyCSE some basic properties of guard intrinsics:
- Guard intrinsics read all memory, but don't write to any memory
- After a guard has executed, the condition it was guarding on can be
assumed to be true
- Guard intrinsics on a constant `true` are no-ops
Reviewers: reames, hfinkel
Subscribers: mcrosier, llvm-commits
Differential Revision: http://reviews.llvm.org/D19578
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268120
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Fri, 29 Apr 2016 21:52:13 +0000 (21:52 +0000)]
AMDGPU: Fix crash with unreachable terminators.
If a block has no successors because it ends in unreachable,
this was accessing an invalid iterator.
Also stop counting instructions that don't emit any
real instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268119
91177308-0d34-0410-b5e6-
96231b3b80d8
Xinliang David Li [Fri, 29 Apr 2016 21:43:28 +0000 (21:43 +0000)]
Revert r268107 -- debug build failure
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268116
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Fri, 29 Apr 2016 21:34:54 +0000 (21:34 +0000)]
[InstCombine][SSE] PSHUFB to shuffle combine to use general aggregate elements. NFCI.
Make use of Constant::getAggregateElement instead of checking constant types - first step towards adding support for UNDEF mask elements.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268115
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Fri, 29 Apr 2016 21:32:00 +0000 (21:32 +0000)]
[Orc] Add ORC lazy-compilation support for AArch64.
The ORC compile callbacks and indirect stubs APIs will now work for AArc64,
allowing functions to be lazily compiled and/or updated.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268112
91177308-0d34-0410-b5e6-
96231b3b80d8
Lang Hames [Fri, 29 Apr 2016 21:29:48 +0000 (21:29 +0000)]
[Orc] Make sure we don't drop the internal error in OrcRemoteTargetClient when
the constructor fails, as this would lead to an 'unchecked error' crash.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268111
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Fri, 29 Apr 2016 21:23:24 +0000 (21:23 +0000)]
[Docs] Refer to the CMakePrimer from CMake doc
The "Building LLVM with CMake" document should have a reference to the CMakePrimer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268109
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Fri, 29 Apr 2016 21:22:04 +0000 (21:22 +0000)]
[ValueTracking] Make the code in lookThroughCast
No functionality change is intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268108
91177308-0d34-0410-b5e6-
96231b3b80d8
Xinliang David Li [Fri, 29 Apr 2016 21:21:44 +0000 (21:21 +0000)]
[inliner]: Refactor inline deferring logic into its own method /NFC
The implemented heuristic has a large body of code which better sits
in its own function for better readability. It also allows adding more
heuristics easier in the future.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268107
91177308-0d34-0410-b5e6-
96231b3b80d8
Sriraman Tallam [Fri, 29 Apr 2016 21:19:16 +0000 (21:19 +0000)]
Differential Revision: reviews.llvm.org/D19733
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268106
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Fri, 29 Apr 2016 21:16:52 +0000 (21:16 +0000)]
AMDGPU: Add kernarg.segment.ptr intrinsic
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268105
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Fri, 29 Apr 2016 21:12:31 +0000 (21:12 +0000)]
[InstCombine] Determine the result of a select based on a dominating condition.
Differential Revision: http://reviews.llvm.org/D19550
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268104
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Fri, 29 Apr 2016 21:02:04 +0000 (21:02 +0000)]
Fix comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268102
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Fri, 29 Apr 2016 20:54:56 +0000 (20:54 +0000)]
[InstCombine] clean up; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268099
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Fri, 29 Apr 2016 20:34:54 +0000 (20:34 +0000)]
[Docs] Add CMake Primer document
This document is intended to provide a basic overview of the CMake scripting language for LLVM developers. It was unorthodoxly reviewed for accuracy and content on the CMake developer list:
http://public.kitware.com/pipermail/cmake-developers/2016-April/028300.html
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268096
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Fri, 29 Apr 2016 20:23:42 +0000 (20:23 +0000)]
AMDGPU/SI: Move post regalloc run of SIShrinkInstructions
Move to addPreEmitPass. This is so it runs after post-RA
scheduling so we can merge s_nops emitted by the scheduler
and hazard recognizer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268095
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Fri, 29 Apr 2016 19:53:16 +0000 (19:53 +0000)]
DAGCombiner: Reduce truncated shl width
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268094
91177308-0d34-0410-b5e6-
96231b3b80d8
Kostya Serebryany [Fri, 29 Apr 2016 19:28:24 +0000 (19:28 +0000)]
[libFuzzer] fix docs
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@268092
91177308-0d34-0410-b5e6-
96231b3b80d8