1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-11-23 19:23:23 +01:00
Commit Graph

182007 Commits

Author SHA1 Message Date
David Green
d548563c8f [ARM] MVE VRINT support
This adds support for the floor/ceil/trunc/... series of instructions,
converting to various forms of VRINT. They use the same suffixes as their
floating point counterparts. There is not VTINTR, so nearbyint is expanded.

Also added a copysign test, to show it is expanded.

Differential Revision: https://reviews.llvm.org/D63985

llvm-svn: 366003
2019-07-13 14:38:53 +00:00
David Green
33ed732806 [ARM] MVE minnm and maxnm instructions
This adds the patterns for minnm and maxnm from the fminnum and fmaxnum nodes,
similar to scalar types.

Original patch by Simon Tatham

Differential Revision: https://reviews.llvm.org/D63870

llvm-svn: 366002
2019-07-13 14:29:02 +00:00
Thomas Preud'homme
04e17bdb7c FileCheck [7/12]: Arbitrary long numeric expressions
Summary:
This patch is part of a patch series to add support for FileCheck
numeric expressions. This specific patch extend numeric expression to
support an arbitrary number of operands, either variable or literals.

Copyright:
    - Linaro (changes up to diff 183612 of revision D55940)
    - GraphCore (changes in later versions of revision D55940 and
                 in new revision created off D55940)

Reviewers: jhenderson, chandlerc, jdenny, probinson, grimar, arichardson, rnk

Subscribers: hiraditya, llvm-commits, probinson, dblaikie, grimar, arichardson, tra, rnk, kristina, hfinkel, rogfer01, JonChesterfield

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D60387

llvm-svn: 366001
2019-07-13 13:24:30 +00:00
Sanjay Patel
04a7ee7970 Revert "[InstCombine] add tests for umin/umax via usub.sat; NFC"
This reverts commit rL365999 / 0f6148df23edcd3081f5e761de19edd4f823f16d.
The tests already exist in this file, and the hoped-for transform
(mentioned in D62871) is invalid because of undef as discussed in
D63060.

llvm-svn: 366000
2019-07-13 13:16:46 +00:00
Sanjay Patel
fe7c6172e8 [InstCombine] add tests for umin/umax via usub.sat; NFC
llvm-svn: 365999
2019-07-13 12:54:48 +00:00
Sanjay Patel
d9b989ce66 [x86] simplify cmov with same true/false operands
llvm-svn: 365998
2019-07-13 12:04:52 +00:00
Fangrui Song
096e6c6d94 [Object] isNotObjectErrorInvalidFileType: simplify
llvm-svn: 365997
2019-07-13 09:28:33 +00:00
Fangrui Song
12629a9a6d [Object] isNotObjectErrorInvalidFileType: fix use-after-move
llvm-svn: 365996
2019-07-13 09:23:35 +00:00
Johannes Doerfert
fc429f73d6 [Attributor][NFC] Run clang-format on the attributor files (.h/.cpp)
The Attributor files are kept formatted with clang-format, we should try
to keep this state.

llvm-svn: 365984
2019-07-13 01:09:27 +00:00
Johannes Doerfert
c70caafbd6 [Attributor] Only return attributes with a valid state
Attributor::getAAFor will now only return AbstractAttributes with a
valid AbstractState. This simplifies call sites as they only need to
check if the returned pointer is non-null. It also reduces the potential
for accidental misuse.

llvm-svn: 365983
2019-07-13 01:09:21 +00:00
Evgeniy Stepanov
85c790896c Extend function attributes bitset size from 64 to 96.
Summary: We are going to add a function attribute number 64.

Reviewers: pcc, jdoerfert, lebedev.ri

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64663

llvm-svn: 365980
2019-07-13 00:29:03 +00:00
Johannes Doerfert
1edf4f3db1 [Attributor][FIX] Lookup of (call site) argument attributes
llvm-svn: 365977
2019-07-13 00:09:27 +00:00
Nico Weber
70b8986c96 PDB HashTable: Move TraitsT from class parameter to the methods that need it
The traits object is only used by a few methods. Deserializing a hash
table and walking it is possible without the traits object, so it
shouldn't be required to build a dummy object for that use case.

The TraitsT object used to be a function template parameter before
r327647, this restores it to that state.

This makes it clear that the traits object isn't needed at all in 1 of
the current 3 uses of HashTable (and I am going to add another use that
doesn't need it), and that the default PdbHashTraits isn't used outside
of tests.

While here, also re-enable 3 checks in the test that were commented out
(which requires making HashTableInternals templated and giving FooBar
an operator==).

No intended behavior change.

Differential Revision: https://reviews.llvm.org/D64640

llvm-svn: 365974
2019-07-12 23:30:55 +00:00
Stanislav Mekhanoshin
de1357af49 [AMDGPU] use v32f32 for 3 mfma intrinsics
These should really use v32f32, but were defined as v32i32
due to the lack of the v32f32 type.

Differential Revision: https://reviews.llvm.org/D64667

llvm-svn: 365972
2019-07-12 22:42:01 +00:00
Vitaly Buka
efa8f57b0d isBytewiseValue checks ConstantVector element by element
Summary: Vector of the same value with few undefs will sill be considered "Bytewise"

Reviewers: eugenis, pcc, jfb

Reviewed By: jfb

Subscribers: dexonsmith, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64031

llvm-svn: 365971
2019-07-12 22:37:55 +00:00
Alina Sbirlea
2b74d7bbd0 [MemorySSA] Use SetVector to avoid nondeterminism.
Summary:
Use a SetVector for DeadBlockSet.
Resolves PR42574.

Reviewers: george.burgess.iv, uabelho, dblaikie

Subscribers: jlebar, Prazek, mgrang, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64601

llvm-svn: 365970
2019-07-12 22:30:30 +00:00
Wouter van Oortmerssen
a3b1095a5b [WebAssembly] refactored utilities to not depend on MachineInstr
Summary:
Most of these functions can work for MachineInstr and MCInst
equally now.

Reviewers: dschuff

Subscribers: MatzeB, sbc100, jgravelle-google, aheejin, sunfish, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64643

llvm-svn: 365965
2019-07-12 22:08:25 +00:00
Alex Lorenz
63721a457e [macCatalyst] Use macCatalyst pretty name in .build_version darwin
assembly command

'macCatalyst' is more readable than 'maccatalyst'. I renamed the objdump output,
but the assembly should match it as well.

llvm-svn: 365964
2019-07-12 22:06:08 +00:00
Douglas Yung
d706f2be63 [test][AArch64] Relax the opcode tests for FP min/max instructions.
llvm-svn: 365961
2019-07-12 21:39:45 +00:00
David Bolvansky
26f1215ef9 [InstCombine] Disable fold from D64285 for non-integer types
llvm-svn: 365959
2019-07-12 21:14:21 +00:00
Evgeniy Stepanov
d38d077cb1 Factor out resolveFrameOffsetReference (NFC).
Split AArch64FrameLowering::resolveFrameIndexReference in two parts
* Finding frame offset for the index.
* Finding base register and offset to that register.

The second part will be used to implement a virtual frame pointer in
armv8.5 MTE stack instrumentation lowering.

Reviewers: pcc, vitalybuka, hctim, ostannard

Subscribers: javed.absar, kristof.beyls, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64171

llvm-svn: 365958
2019-07-12 21:13:55 +00:00
Matt Arsenault
cccd12337a AMDGPU: Drop remnants of byval support for shaders
Before 2018, mesa used to use byval interchangably with inreg, which
didn't really make sense. Fix tests still using it to avoid breaking
in a future commit.

llvm-svn: 365953
2019-07-12 20:12:17 +00:00
David Tenty
c0757a2f72 Fix missing use of defined() in include guard
Subscribers: arsenm, jvesely, nhaehnle, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64657

llvm-svn: 365952
2019-07-12 20:12:15 +00:00
Nikita Popov
882c74ee42 [SystemZ] Fix addcarry of addcarry of const carry (PR42606)
This fixes https://bugs.llvm.org/show_bug.cgi?id=42606 by extending
D64213. Instead of only checking if the carry comes from a matching
operation, we now check the full chain of carries. Otherwise we might
custom lower the outermost addcarry, but then generically legalize
an inner addcarry.

Differential Revision: https://reviews.llvm.org/D64658

llvm-svn: 365949
2019-07-12 20:03:34 +00:00
Craig Topper
238fa1a861 [X86] Use MachineInstr::findRegisterDefOperand to simplify some code in optimizeCompareInstr. NFCI
llvm-svn: 365946
2019-07-12 19:26:35 +00:00
Jonas Devlieghere
007f6b3016 [DebugInfo] Add column info for inline sites
The column field is missing for all inline sites, currently it's always
zero. This changes populates DW_AT_call_column field for inline sites.
Test case modified to cover this change.

Patch by: Wenlei He

Differential revision: https://reviews.llvm.org/D64033

llvm-svn: 365945
2019-07-12 19:25:45 +00:00
Sterling Augustine
64b39b6689 The variable "Latch" is only used in an assert, which makes builds that use "-DNDEBUG" fail with unused variable messages.
Summary: Move the logic into the assert itself.

Subscribers: hiraditya, sanjoy, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64654

llvm-svn: 365943
2019-07-12 18:51:08 +00:00
Ulrich Weigand
b70dffb65e [SystemZ] Fix build bot failure after r365932
Insert LLVM_FALLTHROUGH to avoid compiler warning.

llvm-svn: 365942
2019-07-12 18:44:51 +00:00
Sanjay Patel
754405cb22 [x86] add test for bogus cmov (PR40483); NFC
llvm-svn: 365941
2019-07-12 18:38:29 +00:00
Stanislav Mekhanoshin
fc66d260f5 [AMDGPU] Extend MIMG opcode to 8 bits
This is NFC, but required for future commit.

Differential Revision: https://reviews.llvm.org/D64649

llvm-svn: 365940
2019-07-12 18:38:06 +00:00
Stefan Stipanovic
0bfb39ca4b Addition to rL365925, removing remaining virtuals
llvm-svn: 365938
2019-07-12 18:34:06 +00:00
Nico Weber
fb12a4dfa5 Slightly simplify MappedBlockStream::createIndexedStream() calls
All callers had a PDBFile object at hand, so call
Pdb.createIndexedStream() instead, which pre-populates all the arguments
(and returns nullptr for kInvalidStreamIndex).

Also change safelyCreateIndexedStream() to only take the string index,
and update callers. Make the method public and call it in two places
that manually did the bounds checking before.

No intended behavior change.

Differential Revision: https://reviews.llvm.org/D64633

llvm-svn: 365936
2019-07-12 18:24:38 +00:00
Nico Weber
3173717585 Add explicit newline at end of llvm-pdbutil dump
All dump modes I checked didn't print a trailing newline, so add one.

llvm-svn: 365934
2019-07-12 18:22:47 +00:00
Ulrich Weigand
1d5f4c66da [SystemZ] Add support for new cpu architecture - arch13
This patch series adds support for the next-generation arch13
CPU architecture to the SystemZ backend.

This includes:
- Basic support for the new processor and its features.
- Assembler/disassembler support for new instructions.
- CodeGen for new instructions, including new LLVM intrinsics.
- Scheduler description for the new processor.
- Detection of arch13 as host processor.

Note: No currently available Z system supports the arch13
architecture.  Once new systems become available, the
official system name will be added as supported -march name.

llvm-svn: 365932
2019-07-12 18:13:16 +00:00
Leonard Chan
d10c8bf511 Remove unused methods in Sancov.
llvm-svn: 365931
2019-07-12 18:09:09 +00:00
Craig Topper
a262a2636b [X86] Add NEG to isUseDefConvertible.
We can use the C flag from NEG to detect that the input was zero.

Really we could probably use the Z flag too. But C matches what
we'd do for usubo 0, X.

Haven't found a test case for this due to the usubo formation
in CGP. But I verified if I comment out the CGP code this
transformation catches some of the same cases.

llvm-svn: 365929
2019-07-12 17:52:17 +00:00
Simon Pilgrim
7f2a0e6b10 [X86][AVX] Add PR34359 shuffle test case.
llvm-svn: 365926
2019-07-12 17:42:32 +00:00
Stefan Stipanovic
db0c03ccab [Attributor] Removing unnecessary virtual keywords.
Some function in the Attributor framework are unnecessarily
marked virtual. This patch removes virtual keyword

Reviewers: jdoerfert

Subscribers: hiraditya, llvm-commits

Differential Revision: https://reviews.llvm.org/D64637

llvm-svn: 365925
2019-07-12 17:42:14 +00:00
Hideto Ueno
99b1ea457c [Attributor] Deduce "nofree" function attribute
Summary: Deduce "nofree" function attribute. A more concise description of "nofree" is on D49165.

Reviewers: jdoerfert

Reviewed By: jdoerfert

Subscribers: homerdin, hfinkel, lebedev.ri, hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D62687

llvm-svn: 365924
2019-07-12 17:38:51 +00:00
Philip Reames
4edda29b32 [IndVars] Use exit count reasoning to discharge obviously untaken exits
Continue in the spirit of D63618, and use exit count reasoning to prove away loop exits which can not be taken since the backedge taken count of the loop as a whole is provably less than the minimal BE count required to take this particular loop exit.

As demonstrated in the newly added tests, this triggers in a number of cases where IndVars was previously unable to discharge obviously redundant exit tests. And some not so obvious ones.

Differential Revision: https://reviews.llvm.org/D63733

llvm-svn: 365920
2019-07-12 17:05:35 +00:00
James Y Knight
443f7255d2 Fix some minor coding-style issues in git-llvm.
llvm-svn: 365918
2019-07-12 16:41:28 +00:00
James Y Knight
902e0a60c1 Allow the 'git-llvm' tool to push to svn from the split repositories
for 'test-suite', 'lnt', 'zorg', and 'www'.

This is done by looking at the pathname of the git remote named
'origin', which is not 100% reliable, but should work in most cases.

llvm-svn: 365917
2019-07-12 16:40:46 +00:00
Hideto Ueno
f2b21cc133 [FunctionAttrs] Add a test for "nofree" function attribute
This patch adds a test for nofree function attribute.

llvm-svn: 365916
2019-07-12 16:29:14 +00:00
Fangrui Song
9aeee7bc57 [Support] Move the static initializer install_out_memory_new_handler to InitLLVM
An application linking against LLVMSupport should not get the gratuitous
set::std_new_handler call.

Reviewed By: jfb

Differential Revision: https://reviews.llvm.org/D64505

llvm-svn: 365915
2019-07-12 16:23:25 +00:00
Simon Pilgrim
ff5c1896b1 Add missing <atomic> include to appease MSVC builds.
llvm-svn: 365914
2019-07-12 16:16:23 +00:00
Artem Belevich
094f90bc65 Minor cleanup.
Simplify things a bit by removing unnecessary full type qualification.
This also happens to avoid a build break with now-unsupported
Visual Studio 2015.

Differential Review: https://reviews.llvm.org/D64588

llvm-svn: 365913
2019-07-12 16:13:29 +00:00
Hideto Ueno
845b0733cb Test commit
llvm-svn: 365912
2019-07-12 16:08:32 +00:00
Jordan Rose
598654b4db Support for dumping current PrettyStackTrace on SIGINFO (Ctrl-T)
Support SIGINFO (and SIGUSR1 for POSIX purposes) to tell what
long-running jobs are doing, as inspired by BSD tools (including on
macOS), by dumping the current PrettyStackTrace.

This adds a new kind of signal handler for non-fatal "info" signals,
similar to the "interrupt" handler that already exists for SIGINT
(Ctrl-C). It then uses that handler to update a "generation count"
managed by the PrettyStackTrace infrastructure, which is then checked
whenever a PrettyStackTraceEntry is pushed or popped on each
thread. If the generation has changed---i.e. if the user has pressed
Ctrl-T---the stack trace is dumped, though unfortunately it can't
include the deepest entry because that one is currently being
constructed/destructed.

https://reviews.llvm.org/D63750

llvm-svn: 365911
2019-07-12 16:05:09 +00:00
Jay Foad
631612d948 [AMDGPU] Fix DPP combiner check for exec modification
Summary:
r363675 changed the exec modification helper function, now called
execMayBeModifiedBeforeUse, so that if no UseMI is specified it checks
all instructions in the basic block, even beyond the last use. That
meant that the DPP combiner no longer worked in any basic block that
ended with a control flow instruction, and in particular it didn't work
on code sequences generated by the atomic optimizer.

Fix it by reinstating the old behaviour but in a new helper function
execMayBeModifiedBeforeAnyUse, and limiting the number of instructions
scanned.

Reviewers: arsenm, vpykhtin

Subscribers: kzhuravl, nemanjai, jvesely, wdng, nhaehnle, yaxunl, dstuttard, tpr, t-tye, hiraditya, kbarton, MaskRay, jfb, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D64393

llvm-svn: 365910
2019-07-12 15:59:40 +00:00
Fangrui Song
d812aa1a3c [LegacyPassManager] Small ModuleCount cleanup
llvm-svn: 365907
2019-07-12 15:18:29 +00:00