1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-19 02:52:53 +02:00
Commit Graph

131533 Commits

Author SHA1 Message Date
Chris Lattner
31916392c5 Most common problem is that I get md5 hashes, not crypt hashes.
llvm-svn: 269157
2016-05-11 03:47:36 +00:00
Rafael Espindola
230e95e2b4 Replace PrintLinkage with getLinkagePrintName. NFC.
llvm-svn: 269155
2016-05-11 01:45:31 +00:00
Weiming Zhao
4edbc2b61e [AArch64] Fix DAG selection for cmps for fp16 type
Summary: When emitting comparison for fp16, in addition to promote the LHS and RHS to fp32, we need to change the VT as well.

Reviewers: t.p.northover

Subscribers: t.p.northover, aemerson, rengolin, llvm-commits

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

llvm-svn: 269151
2016-05-11 01:26:32 +00:00
Rafael Espindola
0e8dbafdec Delete mayBeOverridden.
It is the same as isInterposable which seems to be the preferred name.

llvm-svn: 269150
2016-05-11 01:26:06 +00:00
Matt Arsenault
2d6199b2c2 AMDGPU: Make some instructions convergent
llvm-svn: 269147
2016-05-11 00:32:31 +00:00
Rong Xu
10f4270a9f [PGO] Use WeakAny linkage for __llvm_profile_raw_version
Use WeakAny linkage instead of LinkOnceAny, as the symbol can be removed with
LinkOnceAny in O2 (not referenced).

llvm-svn: 269146
2016-05-11 00:31:59 +00:00
Matt Arsenault
37fceca98a AMDGPU: Change private_element_size to 4
llvm-svn: 269145
2016-05-11 00:28:54 +00:00
Justin Bogner
fcc7baa77e SDAG: Implement Select instead of SelectImpl in X86
This is part of the work to have Select return void instead of an
SDNode *, which is in turn part of llvm.org/pr26808.

llvm-svn: 269144
2016-05-10 23:55:37 +00:00
Kostya Serebryany
ee5ec94de0 [libFuzzer] mention the AFL driver in the docs
llvm-svn: 269143
2016-05-10 23:52:47 +00:00
Kostya Serebryany
ad8675582f [libFuzzer] add a driver file to use AFL on LLVMFuzzerTestOneInput
llvm-svn: 269141
2016-05-10 23:46:50 +00:00
Mike Aizatsky
af34cb696d [libfuzzer] Refactoring coverage state-management code.
It is now less state-dependent and will allow easier comparing of
coverages of different units.

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

llvm-svn: 269140
2016-05-10 23:43:15 +00:00
Xinliang David Li
d085eb04c2 Add missing tests for new PM
llvm-svn: 269139
2016-05-10 23:37:19 +00:00
Easwaran Raman
bf64a7664e Revert r269131
llvm-svn: 269138
2016-05-10 23:26:04 +00:00
Dehao Chen
735b361b8a Propagate branch metadata when some branch probability is missing.
Summary: In sample profile, some branches may have profile missing due to profile inaccuracy. We want existing branch probability still valid after propagation.

Reviewers: hfinkel, davidxl, spatel

Subscribers: llvm-commits

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

llvm-svn: 269137
2016-05-10 23:07:19 +00:00
Justin Bogner
d72ab7a6b6 SDAG: Make SelectCodeCommon return void
This means SelectCode unconditionally returns nullptr now. I'll follow
up with a change to make that return void as well, but it seems best
to keep that one very mechanical.

This is part of the work to have Select return void instead of an
SDNode *, which is in turn part of llvm.org/pr26808.

llvm-svn: 269136
2016-05-10 22:58:26 +00:00
Sanjay Patel
67dc5d77f9 auto-generate checks
llvm-svn: 269134
2016-05-10 22:33:26 +00:00
Tim Northover
8b5733c2a6 AArch64: allow vN to represent 64-bit registers in inline asm.
Unlike xN/wN, the size of vN is genuinely ambiguous in the assembly, so we
should try to infer what was intended from the type. But only down to 64-bits
(vN can never represent sN, hN or bN).

llvm-svn: 269132
2016-05-10 22:26:45 +00:00
Easwaran Raman
80787ca12d Reapply r266477 and r266488
llvm-svn: 269131
2016-05-10 22:03:23 +00:00
Xinliang David Li
cde638dcef [PM]: port IR based profUse pass to new pass manager
llvm-svn: 269129
2016-05-10 21:59:52 +00:00
Sanjay Patel
1f4208a29c remove some comments and other cruft from checks
llvm-svn: 269128
2016-05-10 21:52:15 +00:00
Tim Northover
ae4c0a6787 Revert "MemCpyOpt: combine local load/store sequences into memcpy."
This reverts commit r269125. It was in my tree when I ran "git svn dcommit".
It's really still under review.

llvm-svn: 269127
2016-05-10 21:49:40 +00:00
Tim Northover
e30f78b380 ARM: report an error when attempting to target a misalgined BLX
The CodeGen problem was fixed in r269101, but we still miscompiled assembly
that tried the same thing.

llvm-svn: 269126
2016-05-10 21:48:48 +00:00
Tim Northover
3d78a3c8b7 MemCpyOpt: combine local load/store sequences into memcpy.
Sort of the BB-local equivalent to idiom-recognizer: if we have a basic-block
that really implements a memcpy operation, backends can benefit from seeing
this.

llvm-svn: 269125
2016-05-10 21:48:11 +00:00
Hans Wennborg
0d10a020ff Loop unroller: set thresholds for optsize and minsize functions to zero
Before r268509, Clang would disable the loop unroll pass when optimizing
for size. That commit enabled it to be able to support unroll pragmas
in -Os builds. However, this regressed binary size in one of Chromium's
DLLs with ~100 KB.

This restores the original behaviour of no unrolling at -Os, but doing it
in LLVM instead of Clang makes more sense, and also allows the pragmas to
keep working.

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

llvm-svn: 269124
2016-05-10 21:45:55 +00:00
Sanjay Patel
5c208fd1d0 update test to use FileCheck for tighter checking
llvm-svn: 269123
2016-05-10 21:45:51 +00:00
Sanjay Patel
6a6e980686 update test to use FileCheck for tighter checking
llvm-svn: 269122
2016-05-10 21:42:09 +00:00
Lawrence Hu
84f170e1c6 Enable loopreroll for sext of loop control only IV
This patch extend loopreroll to allow the instruction chain
        of loop control only IV has sext.

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

llvm-svn: 269121
2016-05-10 21:16:49 +00:00
Justin Bogner
a84242c7a0 SDAG: Avoid relying on the return value of SelectCode in SystemZ. NFC
This is a bit of a spot fix for now. I'll try to fix this up more
comprehensively soon.

This is part of the work to have Select return void instead of an
SDNode *, which is in turn part of llvm.org/pr26808.

llvm-svn: 269120
2016-05-10 21:11:26 +00:00
Lawrence Hu
ebbd866e5b Revert r26084: Enable loopreroll for sext of loop control only IV
llvm-svn: 269119
2016-05-10 21:11:09 +00:00
Lawrence Hu
7230587586 Revert r269093: Enable loopreroll for sext of loop control only IV
llvm-svn: 269117
2016-05-10 21:04:28 +00:00
Quentin Colombet
04d02a370e [X86] Properly check that EAX is dead when copying EFLAGS.
This fixes a bug introduced in r267623, where we got smarter and avoided to save
EAX before using it. However, we failed to check if any of the subregister of
EAX were alive and thus, missed cases where we have to save EAX before using it.

The problem may happen on every X86/i386/... platform.

This fixes llvm.org/PR27624

llvm-svn: 269115
2016-05-10 20:49:46 +00:00
Sanjay Patel
7746d548c9 [InstSimplify] use computeKnownBits on shift amount operands
Do simplifications common to all shift instructions based on the amount shifted:
1. If the shift amount is known larger than the bitwidth, the result is undefined.
2. If the valid bits of the shift amount are all known to be 0, it's a shift by zero, so the shift operand is the result.

Note that we could generalize the shift-by-zero transform into a shift-by-constant if all of the valid bits in the shift
amount are known, but that would have to be done in InstCombine rather than here because it would mean we need to create
a new shift instruction.

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

llvm-svn: 269114
2016-05-10 20:46:54 +00:00
Justin Bogner
05ddcaf8c0 SDAG: Avoid relying on the return value of SelectCode in Hexagon. NFC
This is a bit of a spot fix for now. I'll try to fix this up more
comprehensively soon.

This is part of the work to have Select return void instead of an
SDNode *, which is in turn part of llvm.org/pr26808.

llvm-svn: 269112
2016-05-10 20:31:53 +00:00
Peter Collingbourne
e728c537a2 Cloning: Clean up the interface to the CloneFunction function.
Remove the ModuleLevelChanges argument, and the ability to create new
subprograms for cloned functions. The latter was added without review in
r203662, but it has no in-tree clients (all non-test callers pass false
for ModuleLevelChanges [1], so it isn't reachable outside of tests). It
also isn't clear that adding a duplicate subprogram to the compile unit is
always the right thing to do when cloning a function within a module. If
this functionality comes back it should be accompanied with a more concrete
use case.

Furthermore, all in-tree clients add the returned function to the module.
Since that's pretty much the only sensible thing you can do with the function,
just do that in CloneFunction.

[1] http://llvm-cs.pcc.me.uk/lib/Transforms/Utils/CloneFunction.cpp/rCloneFunction

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

llvm-svn: 269110
2016-05-10 20:23:24 +00:00
Chad Rosier
1293f2b484 [InstCombine] Fold icmp ugt/ult (udiv i32 C2, X), C1.
This patch adds support for two optimizations:
icmp ugt (udiv C2, X), C1 -> icmp ule X, C2/(C1+1)
icmp ult (udiv C2, X), C1 -> icmp ugt X, C2/C1

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

llvm-svn: 269109
2016-05-10 20:22:09 +00:00
Matthias Braun
c52cf8b481 ScheduleDAGInstrs: Comment on why subreg defs are not seen as uses; NFC
Usually subregister definitions are consider uses of the remaining
lanes that did not get defined. Add a comment why the code in
ScheduleDAGInstrs does not add use dependencies regardless.

llvm-svn: 269107
2016-05-10 20:11:58 +00:00
Kit Barton
ba51a4197e [SystemZ] Add support for additional branch extended mnemonics
Added support for extended mnemonics for the following branch instructions and
load/store-on-condition opcodes:

BR, LOCR, LOCGR, LOC, LOCG, STOC, STOCG

Phabricator: http://reviews.llvm.org/D19729

Committing on behalf of Zhan Liau

llvm-svn: 269106
2016-05-10 20:11:24 +00:00
Davide Italiano
04252ed302 [SCCP] Partially propagate informations when the input is not fully defined.
With this patch:
%r1 = lshr i64 -1, 4294967296 -> undef

Before this patch:
%r1 = lshr i64 -1, 4294967296 -> 0

llvm-svn: 269105
2016-05-10 19:49:47 +00:00
Chris Bieneman
07ab4cac09 [CMake] Add some extra variables to LLVMConfig.cmake.in
Compiler-RT needs LLVM_LIBRARY_DIR, LLVM_BINARY_DIR.

Setting these in LLVMConfig.cmake will allow Compiler-RT to not need to run llvm-config as long as the LLVMConfig.cmake module is in the CMake module path.

llvm-svn: 269104
2016-05-10 19:45:17 +00:00
Adrian Prantl
43e932c3ee Debug Info: Prevent DW_AT_abstract_origin from being emitted twice
for the same subprogram.

This fixes a bug where DW_AT_abstract_origin is being emitted twice for
the same subprogram if a function is both inlined and emitted in the same
translation unit, by restoring the pre-r266446 behavior.

http://reviews.llvm.org/D20072

llvm-svn: 269103
2016-05-10 19:38:51 +00:00
Tim Northover
3173845201 ARM: stop emitting blx instructions for most calls on MachO.
I'm really not sure why we were in the first place, it's the linker's job to
convert between BL/BLX as necessary. Even worse, using BLX left Thumb calls
that could be locally resolved completely unencodable since all offsets to BLX
are multiples of 4.

rdar://26182344

llvm-svn: 269101
2016-05-10 19:17:47 +00:00
Konstantin Zhuravlyov
29da687ed7 [AMDGPU][NFC] Rename SIInsertNops -> SIDebuggerInsertNops
Differential Revision: http://reviews.llvm.org/D20117

llvm-svn: 269098
2016-05-10 18:33:41 +00:00
Justin Bogner
b41d2978a0 LPM: Drop require<loops> from these tests, it's redundant. NFC
The LoopPassManager needs to calculate the loops analysis in order to
iterate over the loops at all. Requiring it is redundant and just adds
noise to the RUN lines here.

llvm-svn: 269097
2016-05-10 18:28:10 +00:00
Rafael Espindola
3560edede3 Make "@name =" mandatory for globals in .ll files.
An oddity of the .ll syntax is that the "@var = " in

@var = global i32 42

is optional. Writing just

global i32 42

is equivalent to

@0 = global i32 42

This means that there is a pretty big First set at the top level. The
current implementation maintains it manually. I was trying to refactor
it, but then started wondering why keep it a all. I personally find the
above syntax confusing. It looks like something is missing.

This patch removes the feature and simplifies the parser.

llvm-svn: 269096
2016-05-10 18:22:45 +00:00
Peter Collingbourne
1e468d612b Re-apply r269081 and r269082 with a fix for MSVC.
llvm-svn: 269094
2016-05-10 18:07:21 +00:00
Lawrence Hu
df161bc96d Enable loopreroll for sext of loop control only IV
This patch extend loopreroll to allow the instruction chain
    of loop control only IV has sext.

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

llvm-svn: 269093
2016-05-10 18:00:42 +00:00
Mandeep Singh Grang
bc857175cc Fix PR26655: Bail out if all regs of an inst BUNDLE have the correct kill flag
Summary:
While setting kill flags on instructions inside a BUNDLE, we bail out as soon
as we set kill flag on a register.  But we are missing a check when all the
registers already have the correct kill flag set. We need to bail out in that
case as well.

This patch refactors the old code and simply makes use of the addRegisterKilled
function in MachineInstr.cpp in order to determine whether to set/remove kill
on an instruction.

Reviewers: apazos, t.p.northover, pete, MatzeB

Subscribers: MatzeB, davide, llvm-commits

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

llvm-svn: 269092
2016-05-10 17:57:27 +00:00
Peter Collingbourne
309c855e45 Revert r269081 and r269082 while I try to find the right incantation to fix MSVC build.
llvm-svn: 269091
2016-05-10 17:54:43 +00:00
Rong Xu
cc0ee912d1 [PGO] resubmit r268969
Put the test into a target specific directory.

llvm-svn: 269090
2016-05-10 17:45:33 +00:00
Lawrence Hu
8953864da8 Enable loopreroll for sext of loop control only IV
This patch extend loopreroll to allow the instruction chain
    of loop control only IV has sext.

llvm-svn: 269084
2016-05-10 17:42:27 +00:00