]> granicus.if.org Git - llvm/log
llvm
5 years agoRevert r369210 which got committed to the branch by mistake release_80 origin/release_80
Hans Wennborg [Tue, 20 Aug 2019 09:10:27 +0000 (09:10 +0000)]
Revert r369210 which got committed to the branch by mistake

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@369350 91177308-0d34-0410-b5e6-96231b3b80d8

5 years ago[bindings/go] Add ParseIR
Ayke van Laethem [Sun, 18 Aug 2019 15:40:39 +0000 (15:40 +0000)]
[bindings/go] Add ParseIR

This commit adds a single method to the Context object to parse a
textual IR file. This is useful for reading input IR in unit tests.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@369210 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoAdd release note for DIBuilder API changes
Tom Stellard [Tue, 11 Jun 2019 03:07:31 +0000 (03:07 +0000)]
Add release note for DIBuilder API changes

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@363027 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r358042:
Tom Stellard [Mon, 10 Jun 2019 23:34:50 +0000 (23:34 +0000)]
Merging r358042:

------------------------------------------------------------------------
r358042 | jimlin | 2019-04-09 18:56:32 -0700 (Tue, 09 Apr 2019) | 34 lines

[Sparc] Fix incorrect MI insertion position for spilling f128.

Summary:
Obviously, new built MI (sethi+add or sethi+xor+add) for constructing large offset
should be inserted before new created MI for storing even register into memory.
So the insertion position should be *StMI instead of II.

before fixed:

std %f0, [%g1+80]
sethi 4, %g1        <<<
add %g1, %sp, %g1   <<< this two instructions should be put before "std %f0, [%g1+80]".
sethi 4, %g1
add %g1, %sp, %g1
std %f2, [%g1+88]

after fixed:

sethi 4, %g1
add %g1, %sp, %g1
std %f0, [%g1+80]
sethi 4, %g1
add %g1, %sp, %g1
std %f2, [%g1+88]

Reviewers: venkatra, jyknight

Reviewed By: jyknight

Subscribers: jyknight, fedor.sergeev, jrtc27, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D60397
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@363010 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r351577:
Tom Stellard [Mon, 10 Jun 2019 23:25:00 +0000 (23:25 +0000)]
Merging r351577:

------------------------------------------------------------------------
r351577 | ssijaric | 2019-01-18 11:34:20 -0800 (Fri, 18 Jan 2019) | 5 lines

Fix the buildbot issue introduced by r351421

The EXPENSIVE_CHECK x86_64 Windows buildbot is failing due to this change. Fix
the map access.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@363006 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r355154:
Tom Stellard [Thu, 6 Jun 2019 18:24:30 +0000 (18:24 +0000)]
Merging r355154:

------------------------------------------------------------------------
r355154 | joerg | 2019-02-28 15:33:09 -0800 (Thu, 28 Feb 2019) | 2 lines

[PPC] Secure PLT only has meaning for PIC

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362729 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r361237:
Tom Stellard [Thu, 6 Jun 2019 03:18:22 +0000 (03:18 +0000)]
Merging r361237:

------------------------------------------------------------------------
r361237 | maskray | 2019-05-21 03:41:25 -0700 (Tue, 21 May 2019) | 14 lines

[PPC64] Update LocalEntry from assigned symbols

On PowerPC64 ELFv2 ABI, functions may have 2 entry points: global and local.
The local entry point location of a function is stored in the st_other field of the symbol, as an offset relative to the global entry point.

In order to make symbol assignments (e.g. .equ/.set) work properly with this, PPCTargetELFStreamer already copies the local entry bits from the source symbol to the destination one, on emitAssignment(). The problem is that this copy is performed only at the assignment location, where the source symbol may not yet have processed the .localentry directive, that sets the local entry. This may cause the destination symbol to end up with wrong local entry information. Other symbol info is not affected by this because, in this case, the destination symbol value is actually a symbol reference.

This change keeps track of these assignments, and update all needed st_other fields when finish() is called.

Patch by Leandro Lupori!

Reviewed By: MaskRay

Differential Revision: https://reviews.llvm.org/D56586
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362671 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r360442:
Tom Stellard [Thu, 6 Jun 2019 02:32:26 +0000 (02:32 +0000)]
Merging r360442:

------------------------------------------------------------------------
r360442 | maskray | 2019-05-10 10:09:25 -0700 (Fri, 10 May 2019) | 12 lines

[MC][ELF] Copy top 3 bits of st_other to .symver aliases

On PowerPC64 ELFv2 ABI, the top 3 bits of st_other encode the local
entry offset. A versioned symbol alias created by .symver should copy
the bits from the source symbol.

This partly fixes PR41048. A full fix needs tracking of .set assignments
and updating st_other fields when finish() is called, see D56586.

Patch by Alfredo Dal'Ava JĂșnior

Differential Revision: https://reviews.llvm.org/D59436
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362669 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r360439:
Tom Stellard [Thu, 6 Jun 2019 02:22:34 +0000 (02:22 +0000)]
Merging r360439:

------------------------------------------------------------------------
r360439 | maskray | 2019-05-10 09:24:57 -0700 (Fri, 10 May 2019) | 8 lines

[llvm-objdump] Print st_other

Add support for ".hidden" ".internal" ".protected" and " 0x%02x" for
other st_other bits used by some architectures.

Reviewed By: sfertile

Differential Revision: https://reviews.llvm.org/D61718
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362668 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r360293:
Matt Arsenault [Wed, 5 Jun 2019 21:43:28 +0000 (21:43 +0000)]
Merging r360293:
------------------------------------------------------------------------
r360293 | arsenm | 2019-05-08 15:09:57 -0700 (Wed, 08 May 2019) | 21 lines

AMDGPU: Select VOP3 form of add

The VOP3 form should always be the preferred selection, to be shrunk
later. This should only be an optimization issue, but this partially
works around a problem from clobbering VCC when SIFixSGPRCopies
rewrites an SCC defining operation directly to VCC.

3 of the testcases are regressions from failing to fold the immediate
in cases it should. These can be avoided by improving the VCC liveness
handling in SIFoldOperands. Simply increasing the threshold to
computeRegisterLiveness works, although this is common enough that VCC
liveness should probably be tracked throughout the pass. The hack of
leaving behind an implicit_def instruction to avoid breaking iterator
wastes instruction count, which inhibits finding the VCC def in long
chains of adds. Doing this however exposes different, worse looking
regressions from poor scheduling behavior. This could probably be
avoided around by forcing the shrink of the addc here, but the
scheduler should probably be fixed.

The r600 add test needs to be split out because it asserts on the
arguments in the new test during the calling convention lowering.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362658 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359899:
Matt Arsenault [Wed, 5 Jun 2019 21:23:44 +0000 (21:23 +0000)]
Merging r359899:
------------------------------------------------------------------------
r359899 | arsenm | 2019-05-03 08:37:07 -0700 (Fri, 03 May 2019) | 7 lines

AMDGPU: Select VOP3 form of sub

The VOP3 form should always be the preferred selection form to be
shrunk later.

The r600 sub test needs to be split out because it asserts on the
arguments in the new test during the calling convention lowering.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362654 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359898:
Matt Arsenault [Wed, 5 Jun 2019 21:02:10 +0000 (21:02 +0000)]
Merging r359898:
------------------------------------------------------------------------
r359898 | arsenm | 2019-05-03 08:21:53 -0700 (Fri, 03 May 2019) | 3 lines

AMDGPU: Support shrinking add with FI in SIFoldOperands

Avoids test regression in a future patch
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362648 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoCorrect test in r362634
Matt Arsenault [Wed, 5 Jun 2019 19:42:03 +0000 (19:42 +0000)]
Correct test in r362634

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362635 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359891:
Matt Arsenault [Wed, 5 Jun 2019 19:06:41 +0000 (19:06 +0000)]
Merging r359891:
------------------------------------------------------------------------
r359891 | arsenm | 2019-05-03 07:40:10 -0700 (Fri, 03 May 2019) | 9 lines

AMDGPU: Replace shrunk instruction with dummy implicit_def

This was broken if the original operand was killed. The kill flag
would appear on both instructions, and fail the verifier. Keep the
kill flag, but remove the operands from the old instruction. This has
an added benefit of really reducing the use count for future folds.

Ideally the pass would be structured more like what PeepholeOptimizer
does to avoid this hack to avoid breaking instruction iterators.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362634 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359883:
Matt Arsenault [Thu, 30 May 2019 21:54:55 +0000 (21:54 +0000)]
Merging r359883:
------------------------------------------------------------------------
r359883 | arsenm | 2019-05-03 06:42:56 -0700 (Fri, 03 May 2019) | 6 lines

AMDGPU: Fix incorrect commute with sub when folding immediates

When a fold of an immediate into a sub/subrev required shrinking the
instruction, the wrong VOP2 opcode was used. This was using the VOP2
equivalent of the original instruction, not the commuted instruction
with the inverted opcode.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362161 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r353865, r353866, and r353874:
Tom Stellard [Thu, 30 May 2019 00:31:30 +0000 (00:31 +0000)]
Merging r353865, r353866, and r353874:

------------------------------------------------------------------------
r353865 | sfertile | 2019-02-12 09:48:22 -0800 (Tue, 12 Feb 2019) | 1 line

[PowerPC] Fix printing of negative offsets in call instruction dissasembly.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353866 | sfertile | 2019-02-12 09:49:04 -0800 (Tue, 12 Feb 2019) | 4 lines

[PPC64] Update tests to reflect change in printing of call operand. [NFC]

The printing of branch operands for call instructions was changed to properly
handle negative offsets. Updating the tests to reflect that.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353874 | sfertile | 2019-02-12 12:03:04 -0800 (Tue, 12 Feb 2019) | 5 lines

Fix undefined behaviour in PPCInstPrinter::printBranchOperand.

Fix the undefined behaviour introduced by my previous patch r353865 (left
shifting a potentially negative value), which was caught by the bots that run
UBSan.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@362043 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r351523:
Tom Stellard [Thu, 23 May 2019 20:44:14 +0000 (20:44 +0000)]
Merging r351523:

------------------------------------------------------------------------
r351523 | dylanmckay | 2019-01-17 22:10:41 -0800 (Thu, 17 Jan 2019) | 12 lines

[AVR] Expand 8/16-bit multiplication to libcalls on MCUs that don't have hardware MUL

This change modifies the LLVM ISel lowering settings so that
8-bit/16-bit multiplication is expanded to calls into the compiler
runtime library if the MCU being targeted does not support
multiplication in hardware.

Before this, MUL instructions would be generated on CPUs like the
ATtiny85, triggering a CPU reset due to an illegal instruction at
runtime.

First raised in https://github.com/avr-rust/rust/issues/124.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@361551 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r355038:
Tom Stellard [Thu, 16 May 2019 22:49:01 +0000 (22:49 +0000)]
Merging r355038:

------------------------------------------------------------------------
r355038 | joerg | 2019-02-27 13:53:14 -0800 (Wed, 27 Feb 2019) | 3 lines

Default to Secure PLT on PPC for NetBSD and OpenBSD.
This matches the default settings of clang.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360950 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r352806:
Tom Stellard [Thu, 16 May 2019 22:36:46 +0000 (22:36 +0000)]
Merging r352806:

------------------------------------------------------------------------
r352806 | sbc | 2019-01-31 14:38:22 -0800 (Thu, 31 Jan 2019) | 5 lines

[WebAssembly] MC: Fix for outputing wasm object to /dev/null

Subscribers: dschuff, jgravelle-google, aheejin, sunfish, llvm-commits

Differential Revision: https://reviews.llvm.org/D57479
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360949 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r354846:
Tom Stellard [Wed, 15 May 2019 23:31:56 +0000 (23:31 +0000)]
Merging r354846:

------------------------------------------------------------------------
r354846 | djg | 2019-02-25 21:20:19 -0800 (Mon, 25 Feb 2019) | 12 lines

[WebAssembly] Properly align fp128 arguments in outgoing varargs arguments

For outgoing varargs arguments, it's necessary to check the OrigAlign field
of the corresponding OutputArg entry to determine argument alignment, rather
than just computing an alignment from the argument value type. This is
because types like fp128 are split into multiple argument values, with
narrower types that don't reflect the ABI alignment of the full fp128.

This fixes the printf("printfL: %4.*Lf\n", 2, lval); testcase.

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360826 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359569:
Tom Stellard [Wed, 15 May 2019 20:12:49 +0000 (20:12 +0000)]
Merging r359569:

------------------------------------------------------------------------
r359569 | russell_gallop | 2019-04-30 08:35:16 -0700 (Tue, 30 Apr 2019) | 7 lines

Add llvm-profdata to LLVM_TOOLCHAIN_TOOLS

This is required for using PGO on Windows but isn't in the Windows
release packages. Windows packages are built with
LLVM_INSTALL_TOOLCHAIN_ONLY so only includes llvm "tools" listed here.

Differential Revision: https://reviews.llvm.org/D61317
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360801 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r360099:
Tom Stellard [Wed, 15 May 2019 18:59:16 +0000 (18:59 +0000)]
Merging r360099:

------------------------------------------------------------------------
r360099 | efriedma | 2019-05-06 16:21:59 -0700 (Mon, 06 May 2019) | 26 lines

[ARM] Glue register copies to tail calls.

This generally follows what other targets do. I don't completely
understand why the special case for tail calls existed in the first
place; even when the code was committed in r105413, call lowering didn't
work in the way described in the comments.

Stack protector lowering breaks if the register copies are not glued to
a tail call: we have to insert the stack protector check before the tail
call, and we choose the location based on the assumption that all
physical register dependencies of a tail call are adjacent to the tail
call. (See FindSplitPointForStackProtector.) This is sort of fragile,
but I don't see any reason to break that assumption.

I'm guessing nobody has seen this before just because it's hard to
convince the scheduler to actually schedule the code in a way that
breaks; even without the glue, the only computation that could actually
be scheduled after the register copies is the computation of the call
address, and the scheduler usually prefers to schedule that before the
copies anyway.

Fixes https://bugs.llvm.org/show_bug.cgi?id=41417

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360793 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359883:
Tom Stellard [Wed, 15 May 2019 05:35:34 +0000 (05:35 +0000)]
Merging r359883:

------------------------------------------------------------------------
r359883 | arsenm | 2019-05-03 06:42:56 -0700 (Fri, 03 May 2019) | 6 lines

AMDGPU: Fix incorrect commute with sub when folding immediates

When a fold of an immediate into a sub/subrev required shrinking the
instruction, the wrong VOP2 opcode was used. This was using the VOP2
equivalent of the original instruction, not the commuted instruction
with the inverted opcode.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360752 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r356982:
Tom Stellard [Wed, 15 May 2019 04:59:27 +0000 (04:59 +0000)]
Merging r356982:

------------------------------------------------------------------------
r356982 | mstorsjo | 2019-03-26 02:02:44 -0700 (Tue, 26 Mar 2019) | 12 lines

[llvm-dlltool] Set a proper machine type for weak symbol object files

This makes GNU binutils not reject the libraries outright.

GNU ld handles weak externals slightly differently though, so it
can't use them for aliases in import libraries, but this makes GNU
ld able to use the rest of the import libraries.

LLD accepted object files with machine type 0 aka
IMAGE_FILE_MACHINE_UNKNOWN.

Differential Revision: https://reviews.llvm.org/D59742
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360750 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r360512:
Tom Stellard [Wed, 15 May 2019 04:49:11 +0000 (04:49 +0000)]
Merging r360512:

------------------------------------------------------------------------
r360512 | ctopper | 2019-05-10 21:19:33 -0700 (Fri, 10 May 2019) | 5 lines

[X86] Don't emit MOVNTDQA loads from fast-isel without SSE4.1.

We were checking for SSE4.1 for FP types, but not integer 128-bit types.

Fixes PR41837.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@360749 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359496:
Tom Stellard [Sat, 4 May 2019 00:24:26 +0000 (00:24 +0000)]
Merging r359496:

------------------------------------------------------------------------
r359496 | mstorsjo | 2019-04-29 13:25:51 -0700 (Mon, 29 Apr 2019) | 8 lines

[X86] Run CFIInstrInserter on Windows if Dwarf is used

This is necessary since SVN r330706, as tail merging can include
CFI instructions since then.

This fixes PR40322 and PR40012.

Differential Revision: https://reviews.llvm.org/D61252
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@359952 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r359834:
Tom Stellard [Fri, 3 May 2019 23:50:08 +0000 (23:50 +0000)]
Merging r359834:

------------------------------------------------------------------------
r359834 | evandro | 2019-05-02 15:01:39 -0700 (Thu, 02 May 2019) | 3 lines

[AArch64] Update for Exynos

Fix the forwarding of multiplication results for Exynos M4.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@359946 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r357701:
Tom Stellard [Fri, 3 May 2019 01:51:07 +0000 (01:51 +0000)]
Merging r357701:

------------------------------------------------------------------------
r357701 | mgorny | 2019-04-04 07:21:38 -0700 (Thu, 04 Apr 2019) | 8 lines

[llvm] [cmake] Add additional headers only if they exist

Modify the add_header_files_for_glob() function to only add files
that do exist, rather than all matches of the glob.  This fixes CMake
error when one of the include directories (which happen to include
/usr/include) contain broken symlinks.

Differential Revision: https://reviews.llvm.org/D59632
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@359857 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r355607:
Tom Stellard [Fri, 3 May 2019 00:12:22 +0000 (00:12 +0000)]
Merging r355607:

------------------------------------------------------------------------
r355607 | petarj | 2019-03-07 08:31:08 -0800 (Thu, 07 Mar 2019) | 11 lines

[DebugInfo] Fix the type of the formated variable

Change the format type of *Personality and *LSDAAddress to PRIx64 since
they are of type uint64_t.
The problem was detected on mips builds, where it was printing junk values
and causing test failure.

Patch by Milos Stojanovic.

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@359851 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r356039:
Tom Stellard [Tue, 23 Apr 2019 02:28:49 +0000 (02:28 +0000)]
Merging r356039:

------------------------------------------------------------------------
r356039 | atanasyan | 2019-03-13 04:04:38 -0700 (Wed, 13 Mar 2019) | 11 lines

[MIPS][microMIPS] Fix PseudoMTLOHI_MM matching and expansion

On micromips MipsMTLOHI is always matched to PseudoMTLOHI_DSP regardless
of +dsp argument. This patch checks is HasDSP predicate is present for
PseudoMTLOHI_DSP so PseudoMTLOHI_MM can be matched when appropriate.

Add expansion of PseudoMTLOHI_MM instruction into a mtlo/mthi pair.

Patch by Mirko Brkusanin.

Differential Revision: http://reviews.llvm.org/D59203
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@358941 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r355825:
Tom Stellard [Mon, 22 Apr 2019 23:47:28 +0000 (23:47 +0000)]
Merging r355825:

------------------------------------------------------------------------
r355825 | petarj | 2019-03-11 07:13:31 -0700 (Mon, 11 Mar 2019) | 10 lines

[MIPS][microMIPS] Add a pattern to match TruncIntFP

A pattern needed to match TruncIntFP was missing. This was causing multiple
tests from llvm test suite to fail during compilation for micromips.

Patch by Mirko Brkusanin.

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@358936 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r354882:
Tom Stellard [Mon, 22 Apr 2019 22:57:01 +0000 (22:57 +0000)]
Merging r354882:

------------------------------------------------------------------------
r354882 | atanasyan | 2019-02-26 06:45:17 -0800 (Tue, 26 Feb 2019) | 4 lines

[mips] Emit `.module softfloat` directive

This change fixes crash on an assertion in case of using
`soft float` ABI for mips32r6 target.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@358934 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r354808:
Tom Stellard [Mon, 22 Apr 2019 22:31:50 +0000 (22:31 +0000)]
Merging r354808:

------------------------------------------------------------------------
r354808 | nikic | 2019-02-25 10:54:17 -0800 (Mon, 25 Feb 2019) | 11 lines

[Mips] Fix missing masking in fast-isel of br (PR40325)

Fixes https://bugs.llvm.org/show_bug.cgi?id=40325 by zero extending
(and x, 1) the condition before branching on it.

To avoid regressing trivial cases, I'm combining emission of cmp+br
sequences for the single-use + same block case (similar to what we
do in x86). icmpbr1.ll still regresses due to the cross-bb usage
of the condition.

Differential Revision: https://reviews.llvm.org/D58576
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@358925 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r354672:
Tom Stellard [Mon, 22 Apr 2019 21:24:13 +0000 (21:24 +0000)]
Merging r354672:

------------------------------------------------------------------------
r354672 | petarj | 2019-02-22 06:53:58 -0800 (Fri, 22 Feb 2019) | 13 lines

[mips][micromips] fix filling delay slots for PseudoIndirectBranch_MM

Filling a delay slot in 32bit jump instructions with a 16bit instruction
can cause issues. According to the documentation such an operation is
unpredictable.
This patch adds opcode Mips::PseudoIndirectBranch_MM alongside
Mips::PseudoIndirectBranch and other instructions that are expanded to jr
instruction and do not allow a 16bit instruction in their delay slots.

Patch by Mirko Brkusanin.

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@358920 91177308-0d34-0410-b5e6-96231b3b80d8

5 years agoMerging r355854:
Tom Stellard [Mon, 22 Apr 2019 18:15:57 +0000 (18:15 +0000)]
Merging r355854:

------------------------------------------------------------------------
r355854 | jonpa | 2019-03-11 12:00:37 -0700 (Mon, 11 Mar 2019) | 13 lines

[RegAlloc]  Avoid compile time regression with multiple copy hints.

As a fix for https://bugs.llvm.org/show_bug.cgi?id=40986 ("excessive compile
time building opencollada"), this patch makes sure that no phys reg is hinted
more than once from getRegAllocationHints().

This handles the case were many virtual registers are assigned to the same
physreg. The previous compile time fix (r343686) in weightCalcHelper() only
made sure that physical/virtual registers are passed no more than once to
addRegAllocationHint().

Review: Dimitry Andric, Quentin Colombet
https://reviews.llvm.org/D59201
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@358905 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r356924:
Tom Stellard [Fri, 29 Mar 2019 03:37:22 +0000 (03:37 +0000)]
Merging r356924:

------------------------------------------------------------------------
r356924 | tstellar | 2019-03-25 10:01:29 -0700 (Mon, 25 Mar 2019) | 1 line

merge-request.sh: Update 8.0 metabug for 8.0.1
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@357234 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agogit-llvm: Update for release_80 branch
Tom Stellard [Thu, 21 Mar 2019 20:45:59 +0000 (20:45 +0000)]
git-llvm: Update for release_80 branch

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@356714 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoBump version to 8.0.1
Tom Stellard [Thu, 21 Mar 2019 20:32:00 +0000 (20:32 +0000)]
Bump version to 8.0.1

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@356708 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: Changes to the JIT APIs; by Lang Hames
Hans Wennborg [Wed, 13 Mar 2019 08:53:49 +0000 (08:53 +0000)]
ReleaseNotes: Changes to the JIT APIs; by Lang Hames

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@356034 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: SystemZ, by Ulrich Weigand.
Hans Wennborg [Tue, 12 Mar 2019 12:52:54 +0000 (12:52 +0000)]
ReleaseNotes: SystemZ, by Ulrich Weigand.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@355916 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: Open Dylan; by Peter Housel
Hans Wennborg [Thu, 7 Mar 2019 08:47:57 +0000 (08:47 +0000)]
ReleaseNotes: Open Dylan; by Peter Housel

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@355584 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r355227 and r355228:
Hans Wennborg [Tue, 5 Mar 2019 09:58:41 +0000 (09:58 +0000)]
Merging r355227 and r355228:

------------------------------------------------------------------------
r355227 | ctopper | 2019-03-01 22:02:34 +0100 (Fri, 01 Mar 2019) | 3 lines

[X86] Add test case for D58805. NFC

This demonstrates dead store elimination removing a store that may alias a gather that uses null as its base.
------------------------------------------------------------------------

------------------------------------------------------------------------
r355228 | ctopper | 2019-03-01 22:02:40 +0100 (Fri, 01 Mar 2019) | 7 lines

[X86] Remove IntrArgMemOnly from target specific gather/scatter intrinsics

IntrArgMemOnly implies that only memory pointed to by pointer typed arguments will be accessed. But these intrinsics allow you to pass null to the pointer argument and put the full address into the index argument. Other passes won't be able to understand this.

A colleague found that ISPC was creating gathers like this and then dead store elimination removed some stores because it didn't understand what the gather was doing since the pointer argument was null.

Differential Revision: https://reviews.llvm.org/D58805
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@355383 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r355136:
Hans Wennborg [Mon, 4 Mar 2019 12:56:31 +0000 (12:56 +0000)]
Merging r355136:
------------------------------------------------------------------------
r355136 | efriedma | 2019-02-28 21:38:45 +0100 (Thu, 28 Feb 2019) | 12 lines

[AArch64] [Windows] Don't skip constructing UnwindHelp.

In certain cases, the first non-frame-setup instruction in a function is
a branch.  For example, it could be a cbz on an argument.  Make sure we
correctly allocate the UnwindHelp, and find an appropriate register to
use to initialize it.

Fixes https://bugs.llvm.org/show_bug.cgi?id=40184

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@355313 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352465:
Hans Wennborg [Mon, 4 Mar 2019 12:44:42 +0000 (12:44 +0000)]
Merging r352465:
------------------------------------------------------------------------
r352465 | mstorsjo | 2019-01-29 10:36:48 +0100 (Tue, 29 Jan 2019) | 17 lines

[COFF, ARM64] Don't put jump table into a separate COFF section for EK_LabelDifference32

Windows ARM64 has PIC relocation model and uses jump table kind
EK_LabelDifference32. This produces jump table entry as
".word LBB123 - LJTI1_2" which represents the distance between the block
and jump table.

A new relocation type (IMAGE_REL_ARM64_REL32) is needed to do the fixup
correctly if they are in different COFF section.

This change saves the jump table to the same COFF section as the
associated code. An ideal fix could be utilizing IMAGE_REL_ARM64_REL32
relocation type.

Patch by Tom Tan!

Differential Revision: https://reviews.llvm.org/D57277
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@355311 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r355116 and r355117:
Hans Wennborg [Mon, 4 Mar 2019 12:41:39 +0000 (12:41 +0000)]
Merging r355116 and r355117:

------------------------------------------------------------------------
r355116 | ctopper | 2019-02-28 19:49:29 +0100 (Thu, 28 Feb 2019) | 7 lines

[X86] Don't peek through bitcasts before checking ISD::isBuildVectorOfConstantSDNodes in combineTruncatedArithmetic

We don't have any combines that can look through a bitcast to truncate a build vector of constants. So the truncate will stick around and give us something like this pattern (binop (trunc X), (trunc (bitcast (build_vector)))) which has two truncates in it. Which will be reversed by hoistLogicOpWithSameOpcodeHands in the generic DAG combiner. Thus causing an infinite loop.

Even if we had a combine for (truncate (bitcast (build_vector))), I think it would need to be implemented in getNode otherwise DAG combiner visit ordering would probably still visit the binop first and reverse it. Or combineTruncatedArithmetic would need to do its own constant folding.

Differential Revision: https://reviews.llvm.org/D58705
------------------------------------------------------------------------

------------------------------------------------------------------------
r355117 | ctopper | 2019-02-28 19:50:16 +0100 (Thu, 28 Feb 2019) | 1 line

[X86] Add test case that was supposed to go with r355116.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@355310 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354505:
Hans Wennborg [Wed, 27 Feb 2019 14:56:14 +0000 (14:56 +0000)]
Merging r354505:
------------------------------------------------------------------------
r354505 | ibiryukov | 2019-02-20 20:08:06 +0100 (Wed, 20 Feb 2019) | 13 lines

[clangd] Store index in '.clangd/index' instead of '.clangd-index'

Summary: To take up the .clangd folder for other potential uses in the future.

Reviewers: kadircet, sammccall

Reviewed By: kadircet

Subscribers: ioeric, MaskRay, jkorous, arphaman, cfe-commits

Tags: #clang

Differential Revision: https://reviews.llvm.org/D58440
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354981 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: add Known Issues, clean up, etc.
Hans Wennborg [Wed, 27 Feb 2019 13:54:21 +0000 (13:54 +0000)]
ReleaseNotes: add Known Issues, clean up, etc.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354973 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354207:
Hans Wennborg [Wed, 27 Feb 2019 10:14:58 +0000 (10:14 +0000)]
Merging r354207:
------------------------------------------------------------------------
r354207 | whitequark | 2019-02-16 23:33:10 +0100 (Sat, 16 Feb 2019) | 16 lines

[bindings/go] Fix building on 32-bit systems (ARM etc.)

Summary:
The patch in https://reviews.llvm.org/D53883 (by me) fails to build on 32-bit systems like ARM. Fix the array size to be less ridiculously large. 2<<20 should still be enough for all practical purposes.

Bug: https://bugs.llvm.org/show_bug.cgi?id=40426

Reviewers: whitequark, pcc

Reviewed By: whitequark

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

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D58030
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354956 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoAdd note on libFuzzer for Windows to release notes
Hans Wennborg [Tue, 26 Feb 2019 16:19:38 +0000 (16:19 +0000)]
Add note on libFuzzer for Windows to release notes

By Jonathan Metzman!

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354892 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354733:
Hans Wennborg [Tue, 26 Feb 2019 10:31:22 +0000 (10:31 +0000)]
Merging r354733:
------------------------------------------------------------------------
r354733 | nikic | 2019-02-23 19:59:01 +0100 (Sat, 23 Feb 2019) | 10 lines

[WebAssembly] Fix select of and (PR40805)

Fixes https://bugs.llvm.org/show_bug.cgi?id=40805 introduced by
patterns added in D53676.

I'm removing the patterns entirely here, as they are not correct
in the general case. If necessary something more specific can be
added in the future.

Differential Revision: https://reviews.llvm.org/D58575
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354860 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354756:
Hans Wennborg [Tue, 26 Feb 2019 10:21:19 +0000 (10:21 +0000)]
Merging r354756:
------------------------------------------------------------------------
r354756 | ctopper | 2019-02-24 20:33:37 +0100 (Sun, 24 Feb 2019) | 36 lines

[X86] Fix tls variable lowering issue with large code model

Summary:
The problem here is the lowering for tls variable. Below is the DAG for the code.
SelectionDAG has 11 nodes:

t0: ch = EntryToken
      t8: i64,ch = load<(load 8 from `i8 addrspace(257)* null`, addrspace 257)> t0, Constant:i64<0>, undef:i64
        t10: i64 = X86ISD::WrapperRIP TargetGlobalTLSAddress:i64<i32* @x> 0 [TF=10]
      t11: i64,ch = load<(load 8 from got)> t0, t10, undef:i64
    t12: i64 = add t8, t11
  t4: i32,ch = load<(dereferenceable load 4 from @x)> t0, t12, undef:i64
t6: ch = CopyToReg t0, Register:i32 %0, t4
And when mcmodel is large, below instruction can NOT be folded.

  t10: i64 = X86ISD::WrapperRIP TargetGlobalTLSAddress:i64<i32* @x> 0 [TF=10]
t11: i64,ch = load<(load 8 from got)> t0, t10, undef:i64
So "t11: i64,ch = load<(load 8 from got)> t0, t10, undef:i64" is lowered to " Morphed node: t11: i64,ch = MOV64rm<Mem:(load 8 from got)> t10, TargetConstant:i8<1>, Register:i64 $noreg, TargetConstant:i32<0>, Register:i32 $noreg, t0"

When llvm start to lower "t10: i64 = X86ISD::WrapperRIP TargetGlobalTLSAddress:i64<i32* @x> 0 [TF=10]", it fails.

The patch is to fold the load and X86ISD::WrapperRIP.

Fixes PR26906

Patch by LuoYuanke

Reviewers: craig.topper, rnk, annita.zhang, wxiao3

Reviewed By: rnk

Subscribers: llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D58336
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354857 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354764:
Hans Wennborg [Tue, 26 Feb 2019 10:02:05 +0000 (10:02 +0000)]
Merging r354764:
------------------------------------------------------------------------
r354764 | lebedevri | 2019-02-25 08:39:07 +0100 (Mon, 25 Feb 2019) | 123 lines

[XRay][tools] Revert "Use Support/JSON.h in llvm-xray convert"

Summary:
This reverts D50129 / rL338834: [XRay][tools] Use Support/JSON.h in llvm-xray convert

Abstractions are great.
Readable code is great.
JSON support library is a *good* idea.

However unfortunately, there is an internal detail that one needs
to be aware of in `llvm::json::Object` - it uses `llvm::DenseMap`.
So for **every** `llvm::json::Object`, even if you only store a single `int`
entry there, you pay the whole price of `llvm::DenseMap`.

Unfortunately, it matters for `llvm-xray`.

I was trying to analyse the `llvm-exegesis` analysis mode performance,
and for that i wanted to view the LLVM X-Ray log visualization in Chrome
trace viewer. And the `llvm-xray convert` is sluggish, and sometimes
even ended up being killed by OOM.

`xray-log.llvm-exegesis.lwZ0sT` was acquired from `llvm-exegesis`
(compiled with ` -fxray-instruction-threshold=128`)
analysis mode over `-benchmarks-file` with 10099 points (one full
latency measurement set), with normal runtime of 0.387s.

Timings:
Old: (copied from D58580)
```
$ perf stat -r 5 ./bin/llvm-xray convert -sort -symbolize -instr_map=./bin/llvm-exegesis -output-format=trace_event -output=/tmp/trace.yml xray-log.llvm-exegesis.lwZ0sT

 Performance counter stats for './bin/llvm-xray convert -sort -symbolize -instr_map=./bin/llvm-exegesis -output-format=trace_event -output=/tmp/trace.yml xray-log.llvm-exegesis.lwZ0sT' (5 runs):

          21346.24 msec task-clock                #    1.000 CPUs utilized            ( +-  0.28% )
               314      context-switches          #   14.701 M/sec                    ( +- 59.13% )
                 1      cpu-migrations            #    0.037 M/sec                    ( +-100.00% )
           2181354      page-faults               # 102191.251 M/sec                  ( +-  0.02% )
       85477442102      cycles                    # 4004415.019 GHz                   ( +-  0.28% )  (83.33%)
       14526427066      stalled-cycles-frontend   #   16.99% frontend cycles idle     ( +-  0.70% )  (83.33%)
       32371533721      stalled-cycles-backend    #   37.87% backend cycles idle      ( +-  0.27% )  (33.34%)
       67896890228      instructions              #    0.79  insn per cycle
                                                  #    0.48  stalled cycles per insn  ( +-  0.03% )  (50.00%)
       14592654840      branches                  # 683631198.653 M/sec               ( +-  0.02% )  (66.67%)
         212207534      branch-misses             #    1.45% of all branches          ( +-  0.94% )  (83.34%)

           21.3502 +- 0.0585 seconds time elapsed  ( +-  0.27% )
```
New:
```
$ perf stat -r 9 ./bin/llvm-xray convert -sort -symbolize -instr_map=./bin/llvm-exegesis -output-format=trace_event -output=/tmp/trace.yml xray-log.llvm-exegesis.lwZ0sT

 Performance counter stats for './bin/llvm-xray convert -sort -symbolize -instr_map=./bin/llvm-exegesis -output-format=trace_event -output=/tmp/trace.yml xray-log.llvm-exegesis.lwZ0sT' (9 runs):

           7178.38 msec task-clock                #    1.000 CPUs utilized            ( +-  0.26% )
               182      context-switches          #   25.402 M/sec                    ( +- 28.84% )
                 0      cpu-migrations            #    0.046 M/sec                    ( +- 70.71% )
             33701      page-faults               # 4694.994 M/sec                    ( +-  0.88% )
       28761053971      cycles                    # 4006833.933 GHz                   ( +-  0.26% )  (83.32%)
        2028297997      stalled-cycles-frontend   #    7.05% frontend cycles idle     ( +-  1.61% )  (83.32%)
       10773154901      stalled-cycles-backend    #   37.46% backend cycles idle      ( +-  0.38% )  (33.36%)
       36199132874      instructions              #    1.26  insn per cycle
                                                  #    0.30  stalled cycles per insn  ( +-  0.03% )  (50.02%)
        6434504227      branches                  # 896420204.421 M/sec               ( +-  0.03% )  (66.68%)
          73355176      branch-misses             #    1.14% of all branches          ( +-  1.46% )  (83.33%)

            7.1807 +- 0.0190 seconds time elapsed  ( +-  0.26% )
```

So using `llvm::json` nearly triples run-time on that test case.
(+3x is times, not percent.)

Memory:
Old:
```
total runtime: 39.88s.
bytes allocated in total (ignoring deallocations): 79.07GB (1.98GB/s)
calls to allocation functions: 33267816 (834135/s)
temporary memory allocations: 5832298 (146235/s)
peak heap memory consumption: 9.21GB
peak RSS (including heaptrack overhead): 147.98GB
total memory leaked: 1.09MB
```
New:
```
total runtime: 17.42s.
bytes allocated in total (ignoring deallocations): 5.12GB (293.86MB/s)
calls to allocation functions: 21382982 (1227284/s)
temporary memory allocations: 232858 (13364/s)
peak heap memory consumption: 350.69MB
peak RSS (including heaptrack overhead): 2.55GB
total memory leaked: 79.95KB
```
Diff:
```
total runtime: -22.46s.
bytes allocated in total (ignoring deallocations): -73.95GB (3.29GB/s)
calls to allocation functions: -11884834 (529155/s)
temporary memory allocations: -5599440 (249307/s)
peak heap memory consumption: -8.86GB
peak RSS (including heaptrack overhead): 0B
total memory leaked: -1.01MB
```
So using `llvm::json` increases *peak* memory consumption on *this* testcase ~+27x.
And total allocation count +15x. Both of these numbers are times, *not* percent.

And note that memory usage is clearly unbound with `llvm::json`, it directly depends
on the length of the log, so peak memory consumption is always increasing.
This isn't so with the dumb code, there is no accumulating memory consumption,
peak memory consumption is fixed. Naturally, that means it will handle *much*
larger logs without OOM'ing.

Readability is good, but the price is simply unacceptable here.
Too bad none of this analysis was done as part of the development/review D50129 itself.

Reviewers: dberris, kpw, sammccall

Reviewed By: dberris

Subscribers: riccibruno, hans, courbet, jdoerfert, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D58584
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354856 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoRelease notes: a few lldb changes, by Raphael Isemann!
Hans Wennborg [Fri, 22 Feb 2019 08:09:08 +0000 (08:09 +0000)]
Release notes: a few lldb changes, by Raphael Isemann!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354659 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: speculative load hardening; text by Kristof
Hans Wennborg [Thu, 21 Feb 2019 14:16:48 +0000 (14:16 +0000)]
ReleaseNotes: speculative load hardening; text by Kristof

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354582 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354497:
Hans Wennborg [Thu, 21 Feb 2019 08:57:12 +0000 (08:57 +0000)]
Merging r354497:
------------------------------------------------------------------------
r354497 | tstellar | 2019-02-20 19:43:45 +0100 (Wed, 20 Feb 2019) | 16 lines

AArch64/test: Add check for function name to machine-outliner-bad-adrp.mir

Summary:
This test was failing in one of our setups because the generated ModuleID
had the full path of the test file and that path contained the string
BL.

Reviewers: t.p.northover, jpaquette, paquette

Reviewed By: paquette

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

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D58217
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354555 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: profile-driven cache prefetching. Text by Mircea!
Hans Wennborg [Thu, 21 Feb 2019 08:53:01 +0000 (08:53 +0000)]
ReleaseNotes: profile-driven cache prefetching. Text by Mircea!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354554 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: all PowerPC changes
Hans Wennborg [Wed, 20 Feb 2019 12:43:20 +0000 (12:43 +0000)]
ReleaseNotes: all PowerPC changes

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354458 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: AArch64 tiny code model
Hans Wennborg [Wed, 20 Feb 2019 12:38:35 +0000 (12:38 +0000)]
ReleaseNotes: AArch64 tiny code model

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354457 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes: initial ppc support in llvm-exegesis
Hans Wennborg [Wed, 20 Feb 2019 11:31:40 +0000 (11:31 +0000)]
ReleaseNotes: initial ppc support in llvm-exegesis

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354448 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoremove another in-progress note
Hans Wennborg [Tue, 19 Feb 2019 13:19:05 +0000 (13:19 +0000)]
remove another in-progress note

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354321 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agodocs: Remove in-progress warning
Hans Wennborg [Tue, 19 Feb 2019 13:14:28 +0000 (13:14 +0000)]
docs: Remove in-progress warning

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354320 91177308-0d34-0410-b5e6-96231b3b80d8

6 years ago[ReleaseNotes] Add note about removal of Nios2 backend. Add some notes on X86 changes.
Craig Topper [Mon, 18 Feb 2019 17:59:47 +0000 (17:59 +0000)]
[ReleaseNotes] Add note about removal of Nios2 backend. Add some notes on X86 changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354281 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354034 and r354117:
Hans Wennborg [Mon, 18 Feb 2019 11:21:42 +0000 (11:21 +0000)]
Merging r354034 and r354117:

------------------------------------------------------------------------
r354034 | rksimon | 2019-02-14 15:45:32 +0100 (Thu, 14 Feb 2019) | 1 line

[X86][AVX] Add PR40730 test case
------------------------------------------------------------------------

------------------------------------------------------------------------
r354117 | rksimon | 2019-02-15 12:39:21 +0100 (Fri, 15 Feb 2019) | 9 lines

[X86][AVX] lowerShuffleAsLanePermuteAndPermute - fully populate the lane shuffle mask (PR40730)

As detailed on PR40730, we are not correctly filling in the lane shuffle mask (D53148/rL344446) - we fill in for the correct src lane but don't add it to the correct mask element, so any reference to the correct element is likely to see an UNDEF mask index.

This allows constant folding to propagate UNDEFs prior to the lane mask being (correctly) lowered to vperm2f128.

This patch fixes the issue by fully populating the lane shuffle mask - this is more than is necessary (if we only filled in the required mask elements we might be able to match other shuffle instructions - broadcasts etc.), but its the most cautious approach as this needs to be cherrypicked into the 8.0.0 release branch.

Differential Revision: https://reviews.llvm.org/D58237
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354260 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353907:
Hans Wennborg [Mon, 18 Feb 2019 10:39:35 +0000 (10:39 +0000)]
Merging r353907:
------------------------------------------------------------------------
r353907 | rnk | 2019-02-13 02:39:32 +0100 (Wed, 13 Feb 2019) | 6 lines

[MC] Make symbol version errors non-fatal

We stil don't have a source location, which is pretty lame, but at least
we won't tell the user to file a clang bug report anymore.

Fixes PR40712
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354257 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354144:
Hans Wennborg [Mon, 18 Feb 2019 10:23:16 +0000 (10:23 +0000)]
Merging r354144:
------------------------------------------------------------------------
r354144 | spatel | 2019-02-15 17:31:55 +0100 (Fri, 15 Feb 2019) | 3 lines

[InstCombine] fix crash while trying to narrow a binop of shuffles (PR40734)

https://bugs.llvm.org/show_bug.cgi?id=40734
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354252 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r354128 and r354131:
Hans Wennborg [Mon, 18 Feb 2019 09:56:01 +0000 (09:56 +0000)]
Merging r354128 and r354131:

------------------------------------------------------------------------
r354128 | courbet | 2019-02-15 13:58:06 +0100 (Fri, 15 Feb 2019) | 1 line

[MergeICmps][NFC] Improve doc.
------------------------------------------------------------------------

------------------------------------------------------------------------
r354131 | courbet | 2019-02-15 15:17:17 +0100 (Fri, 15 Feb 2019) | 15 lines

[MergeICmps] Make base ordering really deterministic.

Summary:
The idea is that we now manipulate bases through a `unsigned BaseID` based on
order of appearance in the comparison chain rather than through the `Value*`.

Fixes 40714.

Reviewers: gchatelet

Subscribers: mgrang, jfb, jdoerfert, llvm-commits, hans

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D58274
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@354249 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352707, r352714, r352886, r352892, r352895, r352908, r352917, r352935, r3532...
Hans Wennborg [Wed, 13 Feb 2019 10:30:16 +0000 (10:30 +0000)]
Merging r352707, r352714, r352886, r352892, r352895, r352908, r352917, r352935, r353213, r353733, and r353758

------------------------------------------------------------------------
r352707 | evandro | 2019-01-31 01:49:27 +0100 (Thu, 31 Jan 2019) | 1 line

[InstCombine] Simplify check clauses in test (NFC)
------------------------------------------------------------------------

------------------------------------------------------------------------
r352714 | evandro | 2019-01-31 02:41:39 +0100 (Thu, 31 Jan 2019) | 3 lines

[InstCombine] Expand testing for Windows (NFC)

Added the checks to the existing cases when the target is Win64.
------------------------------------------------------------------------

------------------------------------------------------------------------
r352886 | evandro | 2019-02-01 17:57:53 +0100 (Fri, 01 Feb 2019) | 1 line

[InstCombine] Refactor test checks (NFC)
------------------------------------------------------------------------

------------------------------------------------------------------------
r352892 | evandro | 2019-02-01 18:39:48 +0100 (Fri, 01 Feb 2019) | 3 lines

[InstCombine] Expand Windows test (NFC)

Add checks for Win64 to existing cases.
------------------------------------------------------------------------

------------------------------------------------------------------------
r352895 | evandro | 2019-02-01 19:34:20 +0100 (Fri, 01 Feb 2019) | 1 line

[InstCombine] Refactor test checks (NFC)
------------------------------------------------------------------------

------------------------------------------------------------------------
r352908 | evandro | 2019-02-01 21:42:03 +0100 (Fri, 01 Feb 2019) | 3 lines

[InstCombine] Expand Windows test (NFC)

Run checks for Win64 as well.
------------------------------------------------------------------------

------------------------------------------------------------------------
r352917 | evandro | 2019-02-01 22:14:10 +0100 (Fri, 01 Feb 2019) | 3 lines

[InstCombine] Expand Windows test (NFC)

Run checks for Win32 as well.
------------------------------------------------------------------------

------------------------------------------------------------------------
r352935 | evandro | 2019-02-01 23:52:05 +0100 (Fri, 01 Feb 2019) | 1 line

[InstCombine] Refactor test checks (NFC)
------------------------------------------------------------------------

------------------------------------------------------------------------
r353213 | evandro | 2019-02-05 21:24:21 +0100 (Tue, 05 Feb 2019) | 3 lines

[TargetLibraryInfo] Regroup run time functions for Windows (NFC)

Regroup supported and unsupported functions by precision and C standard.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353733 | evandro | 2019-02-11 20:02:28 +0100 (Mon, 11 Feb 2019) | 8 lines

[TargetLibraryInfo] Update run time support for Windows

It seems that the run time for Windows has changed and supports more math
functions than it used to, especially on AArch64, ARM, and AMD64.

Fixes PR40541.

Differential revision: https://reviews.llvm.org/D57625
------------------------------------------------------------------------

------------------------------------------------------------------------
r353758 | evandro | 2019-02-11 23:12:01 +0100 (Mon, 11 Feb 2019) | 6 lines

[TargetLibraryInfo] Update run time support for Windows

It seems that, since VC19, the `float` C99 math functions are supported for all
targets, unlike the C89 ones.

According to the discussion at https://reviews.llvm.org/D57625.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353934 91177308-0d34-0410-b5e6-96231b3b80d8

6 years ago[WebAssembly] Backport custom import name changes for LLVM to 8.0.
Hans Wennborg [Tue, 12 Feb 2019 12:27:08 +0000 (12:27 +0000)]
[WebAssembly] Backport custom import name changes for LLVM to 8.0.

Specifically, this backports r352479, r352931, r353474, and r353476
to the 8.0 branch. The trunk patches don't apply cleanly to 8.0 due to
some contemporaneous mass-rename and mass-clang-tidy patches, so
this merges them to simplify rebasing.

r352479 [WebAssembly] Re-enable main-function signature rewriting
r352931 [WebAssembly] Add codegen support for the import_field attribute
r353474 [WebAssembly] Fix imported function symbol names that differ from their import names in the .o format
r353476 [WebAssembly] Update test output after rL353474. NFC.

By Dan Gohman!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353835 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351322:
Hans Wennborg [Tue, 12 Feb 2019 11:17:08 +0000 (11:17 +0000)]
Merging r351322:
------------------------------------------------------------------------
r351322 | pfaffe | 2019-01-16 12:14:07 +0100 (Wed, 16 Jan 2019) | 9 lines

[MSan] Apply the ctor creation scheme of TSan

Summary: To avoid adding an extern function to the global ctors list, apply the changes of D56538 also to MSan.

Reviewers: chandlerc, vitalybuka, fedor.sergeev, leonardchan

Subscribers: hiraditya, bollu, llvm-commits

Differential Revision: https://reviews.llvm.org/D56734
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353830 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353480:
Hans Wennborg [Tue, 12 Feb 2019 11:05:22 +0000 (11:05 +0000)]
Merging r353480:
------------------------------------------------------------------------
r353480 | petarj | 2019-02-07 23:57:33 +0100 (Thu, 07 Feb 2019) | 15 lines

[mips][micromips] Fix how values in .gcc_except_table are calculated

When a landing pad is calculated in a program that is compiled for micromips
with -fPIC flag, it will point to an even address.
Such an error will cause a segmentation fault, as the instructions in
micromips are aligned on odd addresses. This patch sets the last bit of the
offset where a landing pad is, to 1, which will effectively be an odd
address and point to the instruction exactly.

r344591 fixed this issue for -static compilation.

Patch by Aleksandar Beserminji.

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353827 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353308 and r353383:
Hans Wennborg [Tue, 12 Feb 2019 10:45:41 +0000 (10:45 +0000)]
Merging r353308 and r353383:

------------------------------------------------------------------------
r353308 | tnorthover | 2019-02-06 16:26:35 +0100 (Wed, 06 Feb 2019) | 5 lines

AArch64: enforce even/odd register pairs for CASP instructions.

ARMv8.1a CASP instructions need the first of the pair to be an even register
(otherwise the encoding is unallocated). We enforced this during assembly, but
not CodeGen before.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353383 | tnorthover | 2019-02-07 11:35:34 +0100 (Thu, 07 Feb 2019) | 4 lines

AArch64: implement copy for paired GPR registers.

When doing 128-bit atomics using CASP we might need to copy a GPRPair to a
different register, but that was unimplemented up to now.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353822 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352607 r352608 r353015 r353061 r353138 r353141 r353334 r353489
Hans Wennborg [Tue, 12 Feb 2019 10:13:48 +0000 (10:13 +0000)]
Merging r352607 r352608 r353015 r353061 r353138 r353141 r353334 r353489

And re-generate expectations for a test:
$ utils/update_llc_test_checks.py --llc-binary ../build.release/bin/llc test/CodeGen/X86/x87-schedule.ll

Will also merge cfe r353142 for a clang-side test.

This merge was requested in PR40667.

------------------------------------------------------------------------
r352607 | ctopper | 2019-01-30 08:08:44 +0100 (Wed, 30 Jan 2019) | 1 line

[X86] Add FPSW as a Def on some FP instructions that were missing it.
------------------------------------------------------------------------

------------------------------------------------------------------------
r352608 | ctopper | 2019-01-30 08:33:24 +0100 (Wed, 30 Jan 2019) | 5 lines

[X86] Remove a couple places where we unnecessarily pass 0 to the EmitPriority of some FP instruction aliases. NFC

As far as I can tell we already won't emit these aliases due to an operand count check in the tablegen code. Removing these because I couldn't make sense of the inconsistency between fadd and fmul from reading the code.

I checked the AsmMatcher and AsmWriter files before and after this change and there were no differences.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353015 | ctopper | 2019-02-04 05:15:10 +0100 (Mon, 04 Feb 2019) | 3 lines

[X86] Print %st(0) as %st when its implicit to the instruction. Continue printing it as %st(0) when its encoded in the instruction.

This is a step back from the change I made in r352985. This appears to be more consistent with gcc and objdump behavior.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353061 | ctopper | 2019-02-04 18:28:18 +0100 (Mon, 04 Feb 2019) | 5 lines

[X86] Print all register forms of x87 fadd/fsub/fdiv/fmul as having two arguments where on is %st.

All of these instructions consume one encoded register and the other register is %st. They either write the result to %st or the encoded register. Previously we printed both arguments when the encoded register was written. And we printed one argument when the result was written to %st. For the stack popping forms the encoded register is always the destination and we didn't print both operands. This was inconsistent with gcc and objdump and just makes the output assembly code harder to read.

This patch changes things to always print both operands making us consistent with gcc and objdump. The parser should still be able to handle the single register forms just as it did before. This also matches the GNU assembler behavior.
------------------------------------------------------------------------

------------------------------------------------------------------------
r353138 | ctopper | 2019-02-05 05:48:23 +0100 (Tue, 05 Feb 2019) | 1 line

[X86] Add test case from PR40529. NFC
------------------------------------------------------------------------

------------------------------------------------------------------------
r353141 | ctopper | 2019-02-05 07:13:06 +0100 (Tue, 05 Feb 2019) | 16 lines

[X86] Connect the default fpsr and dirflag clobbers in inline assembly to the registers we have defined for them.

Summary:
We don't currently map these constraints to physical register numbers so they don't make it to the MachineIR representation of inline assembly.

This could have problems for proper dependency tracking in the machine schedulers though I don't have a test case that shows that.

Reviewers: rnk

Reviewed By: rnk

Subscribers: eraman, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D57641
------------------------------------------------------------------------

------------------------------------------------------------------------
r353334 | ctopper | 2019-02-06 20:50:59 +0100 (Wed, 06 Feb 2019) | 1 line

[X86] Change the CPU on the test case for pr40529.ll to really show the bug. NFC
------------------------------------------------------------------------

------------------------------------------------------------------------
r353489 | ctopper | 2019-02-08 01:44:39 +0100 (Fri, 08 Feb 2019) | 14 lines

[X86] Add FPCW as a register and start using it as an implicit use on floating point instructions.

Summary:
FPCW contains the rounding mode control which we manipulate to implement fp to integer conversion by changing the roudning mode, storing the value to the stack, and then changing the rounding mode back. Because we didn't model FPCW and its dependency chain, other instructions could be scheduled into the middle of the sequence.

This patch introduces the register and adds it as an implciit def of FLDCW and implicit use of the FP binary arithmetic instructions and store instructions. There are more instructions that need to be updated, but this is a good start. I believe this fixes at least the reduced test case from PR40529.

Reviewers: RKSimon, spatel, rnk, efriedma, andrew.w.kaylor

Subscribers: dim, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D57735
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353818 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353551 and r353809:
Hans Wennborg [Tue, 12 Feb 2019 09:11:50 +0000 (09:11 +0000)]
Merging r353551 and r353809:

Also removed the text about Clang 9.

------------------------------------------------------------------------
r353551 | metzman | 2019-02-08 20:35:04 +0100 (Fri, 08 Feb 2019) | 13 lines

Document libFuzzer on Windows.

Summary:
Document that libFuzzer supports Windows, how to get it,
and its limitations.

Reviewers: kcc, morehouse, rnk, metzman

Reviewed By: kcc, rnk, metzman

Subscribers: hans, rnk

Differential Revision: https://reviews.llvm.org/D57597
------------------------------------------------------------------------

------------------------------------------------------------------------
r353809 | hans | 2019-02-12 10:08:52 +0100 (Tue, 12 Feb 2019) | 1 line

LibFuzzer.rst: double backticks
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353811 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoReleaseNotes about the toolchain version cmake check
Hans Wennborg [Tue, 12 Feb 2019 08:45:37 +0000 (08:45 +0000)]
ReleaseNotes about the toolchain version cmake check

Based on text from JF!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353808 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353463:
Hans Wennborg [Fri, 8 Feb 2019 14:17:53 +0000 (14:17 +0000)]
Merging r353463:
------------------------------------------------------------------------
r353463 | smeenai | 2019-02-07 21:58:04 +0100 (Thu, 07 Feb 2019) | 4 lines

[cmake] Pass LLVM_TEMPORARILY_ALLOW_OLD_TOOLCHAIN to NATIVE configure

We should propagate this down to host builds so that e.g. people using
an optimized tablegen can do the sub-configure successfully.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353517 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351387, r351765, and r353374:
Hans Wennborg [Fri, 8 Feb 2019 11:06:27 +0000 (11:06 +0000)]
Merging r351387, r351765, and r353374:

------------------------------------------------------------------------
r351387 | jfb | 2019-01-16 23:22:38 +0100 (Wed, 16 Jan 2019) | 7 lines

[NFC] Factor out + document build requirements

Summary: This change factors out compiler checking / warning, and documents LLVM_FORCE_USE_OLD_TOOLCHAIN. It doesn't introduce any functional changes nor policy changes, these will come late.

Subscribers: mgorny, jkorous, dexonsmith, llvm-commits

Differential Revision: https://reviews.llvm.org/D56799
------------------------------------------------------------------------

------------------------------------------------------------------------
r351765 | jfb | 2019-01-22 00:53:52 +0100 (Tue, 22 Jan 2019) | 24 lines

Document toolchain update policy

Summary:
Capture the current agreed-upon toolchain update policy based on the following
discussions:

  - LLVM dev meeting 2018 BoF "Migrating to C++14, and beyond!"
    llvm.org/devmtg/2018-10/talk-abstracts.html#bof3
  - A Short Policy Proposal Regarding Host Compilers
    lists.llvm.org/pipermail/llvm-dev/2018-May/123238.html
  - Using C++14 code in LLVM (2018)
    lists.llvm.org/pipermail/llvm-dev/2018-May/123182.html
  - Using C++14 code in LLVM (2017)
    lists.llvm.org/pipermail/llvm-dev/2017-October/118673.html
  - Using C++14 code in LLVM (2016)
    lists.llvm.org/pipermail/llvm-dev/2016-October/105483.html
  - Document and Enforce new Host Compiler Policy
    llvm.org/D47073
  - Require GCC 5.1 and LLVM 3.5 at a minimum
    llvm.org/D46723

Subscribers: jkorous, dexonsmith, llvm-commits

Differential Revision: https://reviews.llvm.org/D56819
------------------------------------------------------------------------

------------------------------------------------------------------------
r353374 | jfb | 2019-02-07 06:20:00 +0100 (Thu, 07 Feb 2019) | 12 lines

Bump minimum toolchain version

Summary:
The RFC on moving past C++11 got good traction:
  http://lists.llvm.org/pipermail/llvm-dev/2019-January/129452.html

This patch therefore bumps the toolchain versions according to our policy:
  llvm.org/docs/DeveloperPolicy.html#toolchain

Subscribers: mgorny, jkorous, dexonsmith, llvm-commits, mehdi_amini, jyknight, rsmith, chandlerc, smeenai, hans, reames, lattner, lhames, erichkeane

Differential Revision: https://reviews.llvm.org/D57264
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353512 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoAdd external project LDC to release notes.
Kai Nacke [Thu, 7 Feb 2019 21:09:53 +0000 (21:09 +0000)]
Add external project LDC to release notes.

LDC, the LLVM-based D compiler, is already ready for LLVM 8.0.0.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353466 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoFix sphinx warning
Hans Wennborg [Thu, 7 Feb 2019 12:32:55 +0000 (12:32 +0000)]
Fix sphinx warning

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353398 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353367:
Hans Wennborg [Thu, 7 Feb 2019 10:58:25 +0000 (10:58 +0000)]
Merging r353367:
------------------------------------------------------------------------
r353367 | brad | 2019-02-07 03:06:58 +0100 (Thu, 07 Feb 2019) | 2 lines

Add OpenBSD support to be able to get the thread name

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353388 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353304:
Hans Wennborg [Thu, 7 Feb 2019 08:47:14 +0000 (08:47 +0000)]
Merging r353304:
------------------------------------------------------------------------
r353304 | uweigand | 2019-02-06 16:10:13 +0100 (Wed, 06 Feb 2019) | 18 lines

[SystemZ] Do not return INT_MIN from strcmp/memcmp

The IPM sequence currently generated to compute the strcmp/memcmp
result will return INT_MIN for the "less than zero" case.  While
this is in compliance with the standard, strictly speaking, it
turns out that common applications cannot handle this, e.g. because
they negate a comparison result in order to implement reverse
compares.

This patch changes code to use a different sequence that will result
in -2 for the "less than zero" case (same as GCC).  However, this
requires that the two source operands of the compare instructions
are inverted, which breaks the optimization in removeIPMBasedCompare.
Therefore, I've removed this (and all of optimizeCompareInstr), and
replaced it with a mostly equivalent optimization in combineCCMask
at the DAGcombine level.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353379 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353155:
Hans Wennborg [Wed, 6 Feb 2019 08:31:22 +0000 (08:31 +0000)]
Merging r353155:
------------------------------------------------------------------------
r353155 | hans | 2019-02-05 12:01:54 +0100 (Tue, 05 Feb 2019) | 11 lines

Fix format string in bindings/go/llvm/ir_test.go (PR40561)

The test started failing for me recently. I don't see any changes around
this code, so maybe it's my local go version that changed or something.

The error seems real to me: we're trying to print an Attribute with %d.
The test talks about "attribute masks" I'm not sure what that refers to,
but I suppose we could print the raw pointer value, since that's
what the test seems to be comparing.

Differential revision: https://reviews.llvm.org/D57672
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353279 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging rr353218:
Reid Kleckner [Tue, 5 Feb 2019 21:25:23 +0000 (21:25 +0000)]
Merging rr353218:
------------------------------------------------------------------------
r353218 | rnk | 2019-02-05 13:14:09 -0800 (Tue, 05 Feb 2019) | 19 lines

[MC] Don't error on numberless .file directives on MachO

Summary:
Before r349976, MC ignored such directives when producing an object file
and asserted when re-producing textual assembly output. I turned this
assertion into a hard error in both cases in r349976, but this makes it
unnecessarily difficult to write a single assembly file that supports
both MachO and other object formats that support .file. A user reported
this as PR40578, and we decided to go back to ignoring the directive.

Fixes PR40578

Reviewers: mstorsjo

Subscribers: hiraditya, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D57772
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353220 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352555:
Hans Wennborg [Tue, 5 Feb 2019 12:55:45 +0000 (12:55 +0000)]
Merging r352555:
------------------------------------------------------------------------
r352555 | asbirlea | 2019-01-29 23:33:20 +0100 (Tue, 29 Jan 2019) | 12 lines

Check bool attribute value in getOptionalBoolLoopAttribute.

Summary:
Check the bool value of the attribute in getOptionalBoolLoopAttribute
not just its existance.
Eliminates the warning noise generated when vectorization is explicitly disabled.

Reviewers: Meinersbur, hfinkel, dmgreen

Subscribers: jlebar, sanjoy, llvm-commits

Differential Revision: https://reviews.llvm.org/D57260
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353167 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r353082:
Hans Wennborg [Tue, 5 Feb 2019 12:51:49 +0000 (12:51 +0000)]
Merging r353082:
------------------------------------------------------------------------
r353082 | meinersbur | 2019-02-04 20:55:59 +0100 (Mon, 04 Feb 2019) | 10 lines

[WarnMissedTransforms] Do not warn about already vectorized loops.

LoopVectorize adds llvm.loop.isvectorized, but leaves
llvm.loop.vectorize.enable. Do not consider such a loop for user-forced
vectorization since vectorization already happened -- by prioritizing
llvm.loop.isvectorized except for TM_SuppressedByUser.

Fixes http://llvm.org/PR40546

Differential Revision: https://reviews.llvm.org/D57542
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353166 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352945:
Hans Wennborg [Tue, 5 Feb 2019 11:27:12 +0000 (11:27 +0000)]
Merging r352945:
------------------------------------------------------------------------
r352945 | mgrang | 2019-02-02 02:32:48 +0100 (Sat, 02 Feb 2019) | 13 lines

[AutoUpgrade] Fix AutoUpgrade for x86.seh.recoverfp

Summary: This fixes the bug in https://reviews.llvm.org/D56747#inline-502711.

Reviewers: efriedma

Reviewed By: efriedma

Subscribers: javed.absar, llvm-commits

Tags: #llvm

Differential Revision: https://reviews.llvm.org/D57614
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353159 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352889:
Hans Wennborg [Mon, 4 Feb 2019 09:31:37 +0000 (09:31 +0000)]
Merging r352889:
------------------------------------------------------------------------
r352889 | wolfgangp | 2019-02-01 18:11:58 +0100 (Fri, 01 Feb 2019) | 6 lines

[DWARF v5] Fix DWARF emitter and consumer to produce/expect a uleb for a location description's length.

Reviewer: davide, JDevliegere

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353029 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoRelease Notes: Add Zig to External Open Source Projects Using LLVM 8
Hans Wennborg [Mon, 4 Feb 2019 08:51:28 +0000 (08:51 +0000)]
Release Notes: Add Zig to External Open Source Projects Using LLVM 8

Zig has all tests passing in the llvm8 branch with rc1.
Zig 0.4.0 is scheduled to be released 1 week after LLVM 8.0.0,
and it will depend on LLVM 8.

Patch by Andrew Kelley!

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@353019 91177308-0d34-0410-b5e6-96231b3b80d8

6 years ago[Hexagon] Update release notes with the changes to the Hexagon backend
Krzysztof Parzyszek [Fri, 1 Feb 2019 20:55:52 +0000 (20:55 +0000)]
[Hexagon] Update release notes with the changes to the Hexagon backend

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352915 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352246:
Hans Wennborg [Fri, 1 Feb 2019 12:44:23 +0000 (12:44 +0000)]
Merging r352246:
------------------------------------------------------------------------
r352246 | mtrofin | 2019-01-25 22:49:54 +0100 (Fri, 25 Jan 2019) | 23 lines

[llvm] Opt-in flag for X86DiscriminateMemOps

Summary:
Currently, if an instruction with a memory operand has no debug information,
X86DiscriminateMemOps will generate one based on the first line of the
enclosing function, or the last seen debug info.

This may cause confusion in certain debugging scenarios. The long term
approach would be to use the line number '0' in such cases, however, that
brings in challenges: the base discriminator value range is limited
(4096 values).

For the short term, adding an opt-in flag for this feature.

See bug 40319 (https://bugs.llvm.org/show_bug.cgi?id=40319)

Reviewers: dblaikie, jmorse, gbedwell

Reviewed By: dblaikie

Subscribers: aprantl, eraman, hiraditya

Differential Revision: https://reviews.llvm.org/D57257
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352867 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352770:
Hans Wennborg [Fri, 1 Feb 2019 11:01:12 +0000 (11:01 +0000)]
Merging r352770:
------------------------------------------------------------------------
r352770 | tejohnson | 2019-01-31 18:18:11 +0100 (Thu, 31 Jan 2019) | 3 lines

Recommit "[ThinLTO] Rename COMDATs for COFF when promoting/renaming COMDAT leader"

Recommit of r352763 with fix for use after free.
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352856 91177308-0d34-0410-b5e6-96231b3b80d8

6 years ago[docs][mips] 8.0 Release notes
Simon Atanasyan [Wed, 30 Jan 2019 22:45:12 +0000 (22:45 +0000)]
[docs][mips] 8.0 Release notes

MIPS specific part of LLVM 8.0 Release notes.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352682 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351910:
Hans Wennborg [Tue, 29 Jan 2019 21:21:14 +0000 (21:21 +0000)]
Merging r351910:
------------------------------------------------------------------------
r351910 | cuviper | 2019-01-23 01:53:22 +0100 (Wed, 23 Jan 2019) | 18 lines

[CodeView] Allow empty types in member functions

Summary:
`CodeViewDebug::lowerTypeMemberFunction` used to default to a `Void`
return type if the function's type array was empty. After D54667, it
started blindly indexing the 0th item for the return type, which fails
in `getOperand` for empty arrays if assertions are enabled.

This patch restores the `Void` return type for empty type arrays, and
adds a test generated by Rust in line-only debuginfo mode.

Reviewers: zturner, rnk

Reviewed By: rnk

Subscribers: hiraditya, JDevlieghere, llvm-commits

Differential Revision: https://reviews.llvm.org/D57070
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352546 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352374:
Hans Wennborg [Tue, 29 Jan 2019 14:23:17 +0000 (14:23 +0000)]
Merging r352374:
------------------------------------------------------------------------
r352374 | mgorny | 2019-01-28 16:16:03 +0100 (Mon, 28 Jan 2019) | 18 lines

[cmake] Fix get_llvm_lit_path() to respect LLVM_EXTERNAL_LIT always

Refactor the get_llvm_lit_path() logic to respect LLVM_EXTERNAL_LIT,
and require the fallback to be defined explicitly
as LLVM_DEFAULT_EXTERNAL_LIT. This fixes building libcxx standalone
after r346888.

The old logic was using LLVM_EXTERNAL_LIT both as user-defined cache
variable and an optional pre-definition of default value from caller
(e.g. libcxx). It included a hack to make this work by assigning
the value back and forth but it was fragile and stopped working
in libcxx.

The new logic is simpler and more transparent. Default value is
provided in a separate variable, and used only when user-specified
variable is empty (i.e. not overriden).

Differential Revision: https://reviews.llvm.org/D57282
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352495 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352204:
Hans Wennborg [Fri, 25 Jan 2019 19:31:17 +0000 (19:31 +0000)]
Merging r352204:
------------------------------------------------------------------------
r352204 | sammccall | 2019-01-25 16:05:33 +0100 (Fri, 25 Jan 2019) | 7 lines

[JSON] Work around excess-precision issue when comparing T_Integer numbers.

Reviewers: bkramer

Subscribers: kristina, llvm-commits

Differential Revision: https://reviews.llvm.org/D57237
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352233 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r352034:
Hans Wennborg [Fri, 25 Jan 2019 00:18:40 +0000 (00:18 +0000)]
Merging r352034:
------------------------------------------------------------------------
r352034 | atanasyan | 2019-01-24 10:13:14 +0100 (Thu, 24 Jan 2019) | 18 lines

Reapply: [mips] Handle MipsMCExpr sub-expression for the MEK_DTPREL tag

This reapplies commit r351987 with a failed test fix. Now the test
accepts both DW_OP_GNU_push_tls_address and DW_OP_form_tls_address
opcode.

Original commit message:
```
  This is a fix for a regression introduced by the rL348194 commit. In
  that change new type (MEK_DTPREL) of MipsMCExpr expression was added,
  but in some places of the code this type of expression considered as
  unexpected.

  This change fixes the bug. The MEK_DTPREL type of expression is used for
  marking TLS DIEExpr only and contains a regular sub-expression. Where we
  need to handle the expression, we retrieve the sub-expression and
  handle it in a common way.
```
------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352140 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351485:
Hans Wennborg [Fri, 25 Jan 2019 00:12:01 +0000 (00:12 +0000)]
Merging r351485:
------------------------------------------------------------------------
r351485 | vstefanovic | 2019-01-17 22:50:37 +0100 (Thu, 17 Jan 2019) | 10 lines

[mips] Emit .reloc R_{MICRO}MIPS_JALR along with j(al)r(c) $25

The callee address is added as an optional operand (MCSymbol) in
AdjustInstrPostInstrSelection() and then used by asm printer to insert:
'.reloc tmplabel, R_MIPS_JALR, symbol
tmplabel:'.
Controlled with '-mips-jalr-reloc', default is true.

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

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352137 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351930 and r351932:
Hans Wennborg [Thu, 24 Jan 2019 22:07:01 +0000 (22:07 +0000)]
Merging r351930 and r351932:
------------------------------------------------------------------------
r351930 | kbeyls | 2019-01-23 09:18:39 +0100 (Wed, 23 Jan 2019) | 30 lines

[SLH] AArch64: correctly pick temporary register to mask SP

As part of speculation hardening, the stack pointer gets masked with the
taint register (X16) before a function call or before a function return.
Since there are no instructions that can directly mask writing to the
stack pointer, the stack pointer must first be transferred to another
register, where it can be masked, before that value is transferred back
to the stack pointer.
Before, that temporary register was always picked to be x17, since the
ABI allows clobbering x17 on any function call, resulting in the
following instruction pattern being inserted before function calls and
returns/tail calls:

mov x17, sp
and x17, x17, x16
mov sp, x17
However, x17 can be live in those locations, for example when the call
is an indirect call, using x17 as the target address (blr x17).

To fix this, this patch looks for an available register just before the
call or terminator instruction and uses that.

In the rare case when no register turns out to be available (this
situation is only encountered twice across the whole test-suite), just
insert a full speculation barrier at the start of the basic block where
this occurs.

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

------------------------------------------------------------------------

------------------------------------------------------------------------
r351932 | kbeyls | 2019-01-23 10:10:12 +0100 (Wed, 23 Jan 2019) | 3 lines

[SLH][AArch64] Remove accidentally retained -debug-only line from test.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@352115 91177308-0d34-0410-b5e6-96231b3b80d8

6 years ago[docs] Add release notes for notable things I've contributed since last release
Martin Storsjo [Tue, 22 Jan 2019 20:36:23 +0000 (20:36 +0000)]
[docs] Add release notes for notable things I've contributed since last release

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@351870 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351754:
Hans Wennborg [Tue, 22 Jan 2019 19:04:30 +0000 (19:04 +0000)]
Merging r351754:
------------------------------------------------------------------------
r351754 | spatel | 2019-01-21 18:46:35 +0100 (Mon, 21 Jan 2019) | 6 lines

[AArch64] add more tests for buildvec to shuffle transform; NFC

These are copied from the sibling x86 file. I'm not sure which
of the current outputs (if any) is considered optimal, but
someone more familiar with AArch may want to take a look.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@351858 91177308-0d34-0410-b5e6-96231b3b80d8

6 years agoMerging r351753:
Hans Wennborg [Tue, 22 Jan 2019 19:02:30 +0000 (19:02 +0000)]
Merging r351753:
------------------------------------------------------------------------
r351753 | spatel | 2019-01-21 18:30:14 +0100 (Mon, 21 Jan 2019) | 8 lines

[DAGCombiner] fix crash when converting build vector to shuffle

The regression test is reduced from the example shown in D56281.
This does raise a question as noted in the test file: do we want
to handle this pattern? I don't have a motivating example for
that on x86 yet, but it seems like we could have that pattern
there too, so we could avoid the back-and-forth using a shuffle.

------------------------------------------------------------------------

git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_80@351857 91177308-0d34-0410-b5e6-96231b3b80d8