OSDN Git Service
Eugene Zelenko [Tue, 6 Dec 2016 22:00:57 +0000 (22:00 +0000)]
[IR] Fix some Clang-tidy modernize-use-equals-delete and Include What You Use warnings; other minor fixes (NFC).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288853
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Tue, 6 Dec 2016 21:53:10 +0000 (21:53 +0000)]
AMDGPU/SI: Set correct value for amd_kernel_code_t::kernarg_segment_alignment
Reviewers: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, llvm-commits, tony-tye
Differential Revision: https://reviews.llvm.org/D27416
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288852
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Tue, 6 Dec 2016 21:52:47 +0000 (21:52 +0000)]
[BDCE/DebugInfo] Preserve llvm.dbg.value's argument.
BDCE has two phases:
1. It asks SimplifyDemandedBits if all the bits of an instruction are dead, and if so,
replaces all its uses with the constant zero.
2. Then, it asks SimplifyDemandedBits again if the instruction is really dead
(no side effects etc..) and if so, eliminates it.
Now, in 1) if all the bits of an instruction are dead, we may end up replacing a dbg use:
%call = tail call i32 (...) @g() #4, !dbg !15
tail call void @llvm.dbg.value(metadata i32 %call, i64 0, metadata !8, metadata !16), !dbg !17
->
%call = tail call i32 (...) @g() #4, !dbg !15
tail call void @llvm.dbg.value(metadata i32 0, i64 0, metadata !8, metadata !16), !dbg !17
but not eliminating the call because it may have arbitrary side effects.
In other words, we lose some debug informations.
This patch fixes the problem making sure that BDCE does nothing with the instruction if
it has side effects and no non-dbg uses.
Differential Revision: https://reviews.llvm.org/D27471
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288851
91177308-0d34-0410-b5e6-
96231b3b80d8
Tom Stellard [Tue, 6 Dec 2016 21:13:30 +0000 (21:13 +0000)]
AMDGPU/SI: Don't move copies of immediates to the VALU
Summary:
If we write an immediate to a VGPR and then copy the VGPR to an
SGPR, we can replace the copy with a S_MOV_B32 sgpr, imm, rather than
moving the copy to the SALU.
Reviewers: arsenm
Subscribers: kzhuravl, wdng, nhaehnle, yaxunl, llvm-commits, tony-tye
Differential Revision: https://reviews.llvm.org/D27272
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288849
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Tue, 6 Dec 2016 21:02:19 +0000 (21:02 +0000)]
GlobalISel: correctly handle small args via memory.
We were rounding size in bits down rather than up, leading to 0-sized slots for
i1 (assert!) and bugs for other types not byte-aligned.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288848
91177308-0d34-0410-b5e6-
96231b3b80d8
Zvi Rackover [Tue, 6 Dec 2016 19:35:20 +0000 (19:35 +0000)]
[X86] Prefer reduced width multiplication over pmulld on Silvermont
Summary:
Prefer expansions such as: pmullw,pmulhw,unpacklwd,unpackhwd over pmulld.
On Silvermont [source: Optimization Reference Manual]:
PMULLD has a throughput of 1/11 [instruction/cycles].
PMULHUW/PMULHW/PMULLW have a throughput of 1/2 [instruction/cycles].
Fixes pr31202.
Analysis of this issue was done by Fahana Aleen.
Reviewers: wmi, delena, mkuper
Subscribers: RKSimon, llvm-commits
Differential Revision: https://reviews.llvm.org/D27203
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288844
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 19:09:37 +0000 (19:09 +0000)]
[DAGCombine] Add (sext_in_reg (zext x)) -> (sext x) combine
Handle the case where a sign extension has ended up being split into separate stages (typically to get around vector legal ops) and a zext + sext_in_reg gets inserted.
Differential Revision: https://reviews.llvm.org/D27461
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288842
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Tue, 6 Dec 2016 19:05:46 +0000 (19:05 +0000)]
[InstSimplify] add folds for and-of-icmps with same operands
All of these (and a few more) are already handled by InstCombine,
but we shouldn't have to wait until then to simplify these because
they're cheap to deal with here in InstSimplify.
This is the 'and' sibling of the earlier 'or' patch:
https://reviews.llvm.org/rL288833
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288841
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Tue, 6 Dec 2016 19:02:15 +0000 (19:02 +0000)]
GlobalISel: fall back gracefully when we hit unhandled legalizer default.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288840
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 18:58:25 +0000 (18:58 +0000)]
[SelectionDAG] We can ignore knownbits from an undef shuffle vector index if we don't actually demand that element
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288839
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Tue, 6 Dec 2016 18:46:54 +0000 (18:46 +0000)]
[InstSimplify] add tests for and-of-icmps; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288837
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Tue, 6 Dec 2016 18:38:38 +0000 (18:38 +0000)]
GlobalISel: handle G_SEQUENCE fallbacks gracefully.
There were two problems:
+ AArch64 was reusing random data from its binary op tables, which is
complete nonsense for G_SEQUENCE.
+ Even when AArch64 gave up and said it couldn't handle G_SEQUENCE,
the generic code asserted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288836
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Tue, 6 Dec 2016 18:38:34 +0000 (18:38 +0000)]
GlobalISel: allow G_SELECT instructions for pointers.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288835
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Tue, 6 Dec 2016 18:38:29 +0000 (18:38 +0000)]
GlobalISel: stop the legalizer from trying to handle oddly-sized types.
It'll almost immediately fail because it always tries to half/double the size
until it finds a legal one. Unfortunately, this triggers an assertion
preventing the DAG fallback from being possible.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288834
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Tue, 6 Dec 2016 18:09:37 +0000 (18:09 +0000)]
[InstSimplify] add folds for or-of-icmps with same operands
All of these (and a few more) are already handled by InstCombine,
but we shouldn't have to wait until then to simplify these because
they're cheap to deal with here in InstSimplify.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288833
91177308-0d34-0410-b5e6-
96231b3b80d8
George Rimar [Tue, 6 Dec 2016 17:55:52 +0000 (17:55 +0000)]
[llvm-readobj] - Teach readobj to print PT_OPENBSD_BOOTDATA header
These are OpenBSD specific program headers.
OpenBSD commit:
https://github.com/openbsd/src/commit/
d39116912b9536bd77326260dc5c6e593fd4ee24
It is required for fixing PR31288.
Differential revision: https://reviews.llvm.org/D27456
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288831
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Tue, 6 Dec 2016 17:49:10 +0000 (17:49 +0000)]
[InstSimplify] add tests for or-of-icmps; NFC
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288830
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Tue, 6 Dec 2016 17:09:29 +0000 (17:09 +0000)]
[CMake] Fixing clang standalone build
I broke this in r288770.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288829
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 17:00:47 +0000 (17:00 +0000)]
[X86][SSE] Add knownbits test demonstrating demandedelts not ignoring undef shuffle elements
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288825
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 15:57:26 +0000 (15:57 +0000)]
[X86][SSE] Added vector sext_in_reg combine tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288819
91177308-0d34-0410-b5e6-
96231b3b80d8
George Rimar [Tue, 6 Dec 2016 15:40:02 +0000 (15:40 +0000)]
Removed trailing whitespaces. NFC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288817
91177308-0d34-0410-b5e6-
96231b3b80d8
George Rimar [Tue, 6 Dec 2016 15:38:15 +0000 (15:38 +0000)]
[Support/ELF] - Add OpenBSD PT_OPENBSD_BOOTDATA constant.
OpenBSD commit for reference:
https://github.com/openbsd/src/commit/
d39116912b9536bd77326260dc5c6e593fd4ee24
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288816
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 15:17:50 +0000 (15:17 +0000)]
[X86] Improve UMAX/UMIN knownbits test
Test the sequential effect of each op
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288815
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 14:50:09 +0000 (14:50 +0000)]
Avoid repeated calls to Op.getOpcode(). NFCI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288814
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 6 Dec 2016 14:39:57 +0000 (14:39 +0000)]
[globalisel][aarch64] Fix unintended assumptions about PartialMappingIdx. NFC.
Summary:
This is NFC but prevents assertions when PartialMappingIdx is tablegen-erated.
The assumptions were:
1) FirstGPR is 0
2) FirstGPR is the first of the First* enumerators.
GPR32 is changed to 1 to demonstrate that assumption #1 is fixed. #2 will
be covered by a subsequent patch that tablegen-erates information and swaps
the order of GPR and FPR as a side effect.
Depends on D27336
Reviewers: ab, t.p.northover, qcolombet
Subscribers: aemerson, rengolin, vkalintiris, dberris, rovka, llvm-commits
Differential Revision: https://reviews.llvm.org/D27337
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288812
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 6 Dec 2016 13:55:01 +0000 (13:55 +0000)]
[globalisel][aarch64] Replace magic numbers with corresponding enumerators in ValMappings. NFC
Reviewers: ab, t.p.northover, qcolombet
Subscribers: aemerson, rengolin, vkalintiris, dberris, llvm-commits, rovka
Differential Revision: https://reviews.llvm.org/D27336
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288810
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 6 Dec 2016 13:48:58 +0000 (13:48 +0000)]
[globalisel][aarch64] Correct argument names in comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288809
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 13:29:55 +0000 (13:29 +0000)]
[SLPVectorizer][X86] Tests to show missed buildvector sitofp/fptosi vectorizations
e.g.
buildvector(sitofp(i32), sitofp(i32), sitofp(i32), sitofp(i32)) --> sitofp(buildvector(i32, i32, i32, i32))
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288807
91177308-0d34-0410-b5e6-
96231b3b80d8
Oliver Stannard [Tue, 6 Dec 2016 12:59:08 +0000 (12:59 +0000)]
[ARM] Better error message for invalid flag-preserving Thumb1 insts
When we see a non flag-setting instruction for which only the flag-setting
version is available in Thumb1, we should give a better error message than
"invalid instruction".
Differential Revision: https://reviews.llvm.org/D27414
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288805
91177308-0d34-0410-b5e6-
96231b3b80d8
Ayman Musa [Tue, 6 Dec 2016 12:24:14 +0000 (12:24 +0000)]
[X86][AVX512] Detect repeated constant patterns in BUILD_VECTOR suitable for broadcasting.
Check if a build_vector node includes a repeated constant pattern and replace it with a broadcast of that pattern.
For example:
"build_vector <0, 1, 2, 3, 0, 1, 2, 3>" would be replaced by "broadcast <0, 1, 2, 3>"
Differential Revision: https://reviews.llvm.org/D26802
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288804
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 12:12:20 +0000 (12:12 +0000)]
[X86] Add tests to show missed opportunities to calculate knownbits in SMAX/SMIN/UMAX/UMIN
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288801
91177308-0d34-0410-b5e6-
96231b3b80d8
Nemanja Ivanovic [Tue, 6 Dec 2016 11:47:14 +0000 (11:47 +0000)]
[PowerPC] Improvements for BUILD_VECTOR Vol. 4
This is the final patch in the series of patches that improves
BUILD_VECTOR handling on PowerPC. This adds a few peephole optimizations
to remove redundant instructions. It also adds a large test case which
encompasses a large set of code patterns that build vectors - this test
case was the motivator for this series of patches.
Differential Revision: https://reviews.llvm.org/D26066
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288800
91177308-0d34-0410-b5e6-
96231b3b80d8
Daniel Sanders [Tue, 6 Dec 2016 11:33:04 +0000 (11:33 +0000)]
[globalisel][aarch64] Prefix PartialMappingIdx enumerators with 'PMI_' to fit coding standards.
This also stops things like 'None' polluting the llvm::AArch64 namespace.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288799
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 11:27:19 +0000 (11:27 +0000)]
Fix MSVC -Wmicrosoft-enum-value 'enumerator value is not representable' warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288798
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Tue, 6 Dec 2016 11:12:53 +0000 (11:12 +0000)]
Fix MSVC bool to uint64_t promotion warning
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288796
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Tue, 6 Dec 2016 10:29:23 +0000 (10:29 +0000)]
[LCG] Add some much needed asserts and verify runs to uncover
a hilarious bug and fix it.
We somehow were never verifying the RefSCCs newly formed when
splitting an existing one apart, and when verifying them we weren't
really checking the SCC indices mapping effectively.
If we had been, it would have been blindingly obvious that right after
putting something int `RC.SCCs` we should update `RC.SCCIndices` instead
of `SCCIndices` which we were about to clear and rebuild anyways. =[
Anyways, this is thoroughly covered by existing tests now that we
actually verify things properly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288795
91177308-0d34-0410-b5e6-
96231b3b80d8
Florian Hahn [Tue, 6 Dec 2016 10:24:55 +0000 (10:24 +0000)]
[framelowering] Improve tracking of first CS pop instruction.
Summary: This patch makes sure FirstCSPop and MBBI never point to DBG_VALUE instructions, which affected the code generated.
Reviewers: mkuper, aprantl, MatzeB
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D27343
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288794
91177308-0d34-0410-b5e6-
96231b3b80d8
Sam McCall [Tue, 6 Dec 2016 10:14:36 +0000 (10:14 +0000)]
Add missing parens in assert.
Summary: Add missing parens in assert, which warn in GCC.
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D27448
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288792
91177308-0d34-0410-b5e6-
96231b3b80d8
Chandler Carruth [Tue, 6 Dec 2016 10:06:06 +0000 (10:06 +0000)]
[PM] Basic cleanups to CGSCC update code, NFC.
Just using InstIterator, simpler loop structures, and making better use
of the visit callback infrastructure.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288790
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 08:08:12 +0000 (08:08 +0000)]
[X86] Remove another weird scalar sqrt/rcp/rsqrt pattern.
This pattern turned a vector sqrt/rcp/rsqrt operation of sse_load_f32/f64 into the the scalar instruction for the operation and put undef into the upper bits. For correctness, the resulting code should still perform the sqrt/rcp/rsqrt on the upper bits after the load is extended since that's what the operation asked for. Particularly in the case where the upper bits are 0, in that case we need calculate the sqrt/rcp/rsqrt of the zeroes and keep the result in the upper-bits. This implies we should be using the packed instruction still.
The only test case for this pattern is one I just added so there was no coverage of this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288784
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 08:08:09 +0000 (08:08 +0000)]
[X86] Add test case demonstrating a case where a vector sqrt being passed (scalar_to_vector loadf64) uses a scalar sqrt instruction.
This occurs due to a pattern that uses sse_load_f32/f64 with vector sqrt/rcp/rsqrt operations and turns them into scalar instructions. Perhaps for the case were the upper bits come from undef this is ok. I believe a (vzmovl load64) would do the same thing but those seems to become vzload instead and selectScalarSSELoad doesn't handle that today. In that case we should be performing the vector operation on the zeros in the upper bits which is not equivalent to using a scalar instruction.
I will remove this pattern in a follow up patch. There appears to be no other test content for it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288783
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 08:08:07 +0000 (08:08 +0000)]
[X86] Regenerate a test using update_llc_test_checks.py
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288782
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 08:08:04 +0000 (08:08 +0000)]
[X86] Remove bad pattern that caused 128-bit loads being used by scalar sqrt/rcp/rsqrt intrinsics to select the memory form of the corresponding instruction and violate the semantics of the intrinsic.
The intrinsics are supposed to pass the upper bits straight through to their output register. This means we need to make sure we still perform the 128-bit load to get those upper bits to pass to give to the instruction since the memory form of the instruction only reads 32 or 64 bits.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288781
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 08:08:01 +0000 (08:08 +0000)]
[X86] Add test case that shows a scalar sqrtsd intrinsic of a 128-bit vector load using the load form of the sqrtsd instruction which violates the intrinsic semantics.
The sqrtsd instruction only loads 64-bits and writes bits 63:0 with the sqrt result. Bits 127:64 are preserved in the destination register. The semantics of the intrinsic indicate bits 127:64 should come from the intrinsic argument which in this case is a 128-bit load. So the generated code should have a 128-bit load and use a register form of sqrtsd.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288780
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 08:07:58 +0000 (08:07 +0000)]
[X86] Correct pattern for VSQRTSSr_Int, VSQRTSDr_Int, VRCPSSr_Int, and VRSQRTSSr_Int to not have an IMPLICIT_DEF on the first input. The semantics of the intrinsic are clear and not undefined.
The intrinsic takes one argument, the lower bits are affected by the operation and the upper bits should be passed through. The instruction itself takes two operands, the high bits of the first operand are passed through and the low bits of the second operand are modified by the operation. To match this to the intrinsic we should pass the single intrinsic input to both operands.
I had to remove the stack folding test for these instructions since they depended on the incorrect behavior. The same register is now used for both inputs so the load can't be folded.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288779
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Tue, 6 Dec 2016 06:00:49 +0000 (06:00 +0000)]
[ObjectYAML] First bit of support for encoding DWARF in MachO
This patch adds the starting support for encoding data from the MachO __DWARF segment. The first section supported is the __debug_str section because it is the simplest.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288774
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Tue, 6 Dec 2016 04:58:39 +0000 (04:58 +0000)]
[X86] Remove scalar logical op alias instructions. Just use COPY_FROM/TO_REGCLASS and the normal packed instructions instead
Summary:
This patch removes the scalar logical operation alias instructions. We can just use reg class copies and use the normal packed instructions instead. This removes the need for putting these instructions in the execution domain fixing tables as was done recently.
I removed the loadf64_128 and loadf32_128 patterns as DAG combine creates a narrower load for (extractelt (loadv4f32)) before we ever get to isel.
I plan to add similar patterns for AVX512DQ in a future commit to allow use of the larger register class when available.
Reviewers: spatel, delena, zvi, RKSimon
Subscribers: llvm-commits
Differential Revision: https://reviews.llvm.org/D27401
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288771
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Tue, 6 Dec 2016 04:45:11 +0000 (04:45 +0000)]
[CMake] Cleanup TableGen include flags
It is kinda crazy to have llvm/include and llvm/lib/Target in the include path for every tablegen invocation for every tablegen-like tool.
This patch removes those flags from the tablgen function that is called everywhere by instead creating a variable LLVM_TABLEGEN_FLAGS which is setup in the LLVM source directories.
This removes TableGen.cmake's dependency on LLVM_MAIN_SRC_DIR, and LLVM_MAIN_INCLUDE_DIR.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288770
91177308-0d34-0410-b5e6-
96231b3b80d8
Philip Reames [Tue, 6 Dec 2016 03:34:33 +0000 (03:34 +0000)]
[LVI] Remove dead code in mergeIn
Integers are expressed in the lattice via constant ranges. They can never be represented by constants or not-constants; those are reserved for non-integer types. This code has been dead for literaly years.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288767
91177308-0d34-0410-b5e6-
96231b3b80d8
Philip Reames [Tue, 6 Dec 2016 03:22:03 +0000 (03:22 +0000)]
[LVI] Extract a helper function
Extracting a helper function out of solveBlockValue makes the contract around the cache much easier to understand.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288766
91177308-0d34-0410-b5e6-
96231b3b80d8
Philip Reames [Tue, 6 Dec 2016 03:01:08 +0000 (03:01 +0000)]
[LVI] Hide the last markX function on LVILatticeVal
This completes a small series of patches to hide the stateful updates of LVILatticeVal from the consuming code. The only remaining stateful API is mergeIn.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288765
91177308-0d34-0410-b5e6-
96231b3b80d8
Philip Reames [Tue, 6 Dec 2016 02:54:16 +0000 (02:54 +0000)]
[LVI] Hide a confusing internal interface
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288764
91177308-0d34-0410-b5e6-
96231b3b80d8
Mandeep Singh Grang [Tue, 6 Dec 2016 02:49:17 +0000 (02:49 +0000)]
[llvm] Fix D26214: Move error handling out of MC and to the callers.
Summary: Related clang patch; https://reviews.llvm.org/D27360
Reviewers: t.p.northover, grosbach, compnerd, echristo
Subscribers: compnerd, mehdi_amini, llvm-commits
Differential Revision: https://reviews.llvm.org/D27359
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288763
91177308-0d34-0410-b5e6-
96231b3b80d8
Philip Reames [Tue, 6 Dec 2016 02:36:58 +0000 (02:36 +0000)]
[LVI] Remove duplicate code using existing helper function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288761
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Tue, 6 Dec 2016 02:26:50 +0000 (02:26 +0000)]
Revert "[SCCP] Remove manual folding of terminator instructions."
This reverts commit r288725 as it broke a bot.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288759
91177308-0d34-0410-b5e6-
96231b3b80d8
Zijiao Ma [Tue, 6 Dec 2016 02:22:08 +0000 (02:22 +0000)]
Refactor TargetParserTests.
The TargetParser tests are a bit redundant. Refactor them in a more
repeatable way.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288758
91177308-0d34-0410-b5e6-
96231b3b80d8
Mehdi Amini [Tue, 6 Dec 2016 01:23:04 +0000 (01:23 +0000)]
Introduces cmake option `LLVM_DISABLE_ABI_BREAKING_CHECKS_ENFORCING`
Summary:
We recently introduced a feature that enforce at link-time that the
LLVM headers used by a clients are matching the ABI setting of the
LLVM library linked to.
However for clients that are using only headers from ADT and promise
they won't call into LLVM, this is forcing to link libSupport. This
new flag is intended to provide a way to configure LLVM with this
promise for such client.
Reviewers: bob.wilson, compnerd
Subscribers: mgorny, llvm-commits
Differential Revision: https://reviews.llvm.org/D27432
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288754
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Tue, 6 Dec 2016 01:02:51 +0000 (01:02 +0000)]
AMDGPU: Don't required structured CFG
The structured CFG is just an aid to inserting exec
mask modification instructions, once that is done
we don't really need it anymore. We also
do not analyze blocks with terminators that
modify exec, so this should only be impacting
true branches.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288744
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Haarman [Tue, 6 Dec 2016 00:55:55 +0000 (00:55 +0000)]
revert inadvertedly introduced build break
Summary:
r288722 introduced a build break due some code that should
not have been part of the commit. This change removes the offending
code.
Reviewers: davide, ruiu
Differential Revision: https://reviews.llvm.org/D27435
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288742
91177308-0d34-0410-b5e6-
96231b3b80d8
Weiming Zhao [Mon, 5 Dec 2016 23:55:13 +0000 (23:55 +0000)]
Summary: Currently there is no way to disable deprecated warning from asm like this
clang -target arm deprecated-asm.s -c
deprecated-asm.s:30:9: warning: use of SP or PC in the list is deprecated
stmia r4!, {r12-r14}
We have to have an option what can disable it.
Patched by Yin Ma!
Reviewers: joey, echristo, weimingz
Subscribers: llvm-commits, aemerson
Differential Revision: https://reviews.llvm.org/D27219
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288734
91177308-0d34-0410-b5e6-
96231b3b80d8
Kostya Serebryany [Mon, 5 Dec 2016 23:35:22 +0000 (23:35 +0000)]
[libFuzzer] refactor the code to allow collecting features in different ways. Also initialize a couple of Fuzzer:: members that might have been used uninitialized :(
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288731
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 23:10:19 +0000 (23:10 +0000)]
GlobalISel: avoid looking too closely at PHIs when we bail.
The function used to finish off PHIs by adding the relevant basic blocks can
fail if we're aborting and still don't actually have the needed
MachineBasicBlocks. So avoid trying in that case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288727
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Mon, 5 Dec 2016 23:04:21 +0000 (23:04 +0000)]
[SCCP] Remove manual folding of terminator instructions.
There are two cases handled here:
1) a branch on undef
2) a switch with an undef condition.
Both cases are currently handled by ResolvedUndefsIn. If we have
a branch on undef, we force its value to false (which is trivially
foldable). If we have a switch on undef, we force to the first
constant (which is also foldable).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288725
91177308-0d34-0410-b5e6-
96231b3b80d8
Davide Italiano [Mon, 5 Dec 2016 22:58:01 +0000 (22:58 +0000)]
[TableGen] Centralize/Unify error handling.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288724
91177308-0d34-0410-b5e6-
96231b3b80d8
Bob Haarman [Mon, 5 Dec 2016 22:44:00 +0000 (22:44 +0000)]
[pdb] handle missing pdb streams more gracefully
Summary: The code we use to read PDBs assumed that streams we ask it to read exist, and would read memory outside a vector and crash if this wasn't the case. This would, for example, cause llvm-pdbdump to crash on PDBs generated by lld. This patch handles such cases more gracefully: the PDB reading code in LLVM now reports errors when asked to get a stream that is not present, and llvm-pdbdump will report missing streams and continue processing streams that are present.
Reviewers: ruiu, zturner
Subscribers: thakis, amccarth
Differential Revision: https://reviews.llvm.org/D27325
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288722
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 22:40:13 +0000 (22:40 +0000)]
GlobalISel: place constants correctly in the entry block.
When the entry block was empty after arg lowering, we were always placing
constants at the end. This is probably hamrless while translating the same
block, but horribly wrong once its terminator has been translated. So switch to
inserting at the beginning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288720
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Mon, 5 Dec 2016 22:26:17 +0000 (22:26 +0000)]
AMDGPU: Consolidate inline immediate predicate functions
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288718
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 22:20:32 +0000 (22:20 +0000)]
GlobalISel: handle pointer arguments that get assigned to the stack.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288717
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Mon, 5 Dec 2016 22:07:21 +0000 (22:07 +0000)]
AMDGPU: Minor assembler refactoring
Fix return before else, check types for selecting
fltSemantics, refactor immediate checks.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288715
91177308-0d34-0410-b5e6-
96231b3b80d8
Eugene Zelenko [Mon, 5 Dec 2016 21:55:02 +0000 (21:55 +0000)]
[IR] Fix some Clang-tidy modernize-use-equals-delete and Include What You Use warnings; other minor fixes (NFC).
Also remove obsolete comment from CommandLine.h spotted by Malcolm Parsons.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288714
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 21:54:17 +0000 (21:54 +0000)]
GlobalISel: translate constants larger than 64 bits.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288713
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 21:47:07 +0000 (21:47 +0000)]
GlobalISel: make G_CONSTANT take a ConstantInt rather than int64_t.
This makes it more similar to the floating-point constant, and also allows for
larger constants to be translated later. There's no real functional change in
this patch though, just syntax updates.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288712
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 21:40:33 +0000 (21:40 +0000)]
GlobalISel: improve translation fallback for constants.
Returning 0 (NoReg) from getOrCreateVReg leads to unexpected situations later
in the translation. It's better to return a valid (if undefined) register and
let the rest of the instruction carry on as planned.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288709
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 5 Dec 2016 21:25:33 +0000 (21:25 +0000)]
GlobalISel: handle 1-element aggregates during ABI lowering.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288706
91177308-0d34-0410-b5e6-
96231b3b80d8
Keno Fischer [Mon, 5 Dec 2016 21:25:03 +0000 (21:25 +0000)]
[LAA] Prevent invalid IR for loop-invariant bound in loop body
Summary:
If LAA expands a bound that is loop invariant, but not hoisted out
of the loop body, it used to use that value anyway, causing a
non-domination error, because the memcheck block is of course not
dominated by the scalar loop body. Detect this situation and expand
the SCEV expression instead.
Fixes PR31251
Reviewers: anemet
Subscribers: mzolotukhin, llvm-commits
Differential Revision: https://reviews.llvm.org/D27397
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288705
91177308-0d34-0410-b5e6-
96231b3b80d8
Michael Kuperstein [Mon, 5 Dec 2016 20:57:37 +0000 (20:57 +0000)]
[X86] Fix non-intrinsic roundss/roundsd to not read the destination register
This changes the scalar non-intrinsic non-avx roundss/sd instruction
definitions not to read their destination register - allowing partial dependency
breaking.
This fixes PR31143.
Differential Revision: https://reviews.llvm.org/D27323
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288703
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Mon, 5 Dec 2016 20:42:41 +0000 (20:42 +0000)]
AMDGPU: Assembler support for exp
compr is not currently parsed (or printed) correctly,
but that should probably be fixed along with
intrinsic changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288698
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Mon, 5 Dec 2016 20:31:49 +0000 (20:31 +0000)]
AMDGPU: Change how exp is printed
This is an improvement over a long list of unreadable numbers.
A follow up patch will try to match how sc formats these.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288697
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Mon, 5 Dec 2016 20:23:10 +0000 (20:23 +0000)]
AMDGPU: Refactor exp instructions
Structure the definitions a bit more like the other classes.
The main change here is to split EXP with the done bit set
to a separate opcode, so we can set mayLoad = 1 so that it won't
be reordered before the other exp stores, since this has the special
constraint that if the done bit is set then this should be the last
exp in she shader.
Previously all exp instructions were inferred to have unmodeled
side effects.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288695
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Fiselier [Mon, 5 Dec 2016 20:21:21 +0000 (20:21 +0000)]
[lit] Support custom parsers in parseIntegratedTestScript
Summary:
Libc++ frequently has the need to parse more than just the builtin *test keywords* (`RUN`, `REQUIRES`, `XFAIL`, ect). For example libc++ currently needs a new keyword `MODULES-DEFINES: macro list...`. Instead of re-implementing the script parsing in libc++ this patch allows `parseIntegratedTestScript` to take custom parsers.
This patch introduces a new class `IntegratedTestKeywordParser` which implements the logic to parse/process a test keyword. Parsing of various keyword "kinds" are supported out of the box, including 'TAG', 'COMMAND', and 'LIST', which parse keywords such as `END.`, `RUN:` and `XFAIL:` respectively.
As an example after this change libc++ can implement the `MODULES-DEFINES` simply using:
```
mparser = IntegratedTestKeywordParser('MODULES-DEFINES:', ParserKind.LIST)
parseIntegratedTestScript(test, additional_parsers=[mparser])
macro_list = mparser.getValue()
```
Reviewers: ddunbar, modocache, rnk, danalbert, jroelofs
Subscribers: mgrang, llvm-commits, cfe-commits
Differential Revision: https://reviews.llvm.org/D27005
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288694
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 19:44:31 +0000 (19:44 +0000)]
TableGen/AsmMatcherEmitter: Bring sorting check back under EXPENSIVE_CHECKS
Bring the sorting check back that I removed in r288655 but put it under
EXPENSIVE_CHECKS this time. Also document that this the check isn't
purely about having a sorted list but also about operator < having the
correct transitive behavior.
Apply the same to the other check in the file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288693
91177308-0d34-0410-b5e6-
96231b3b80d8
Quentin Colombet [Mon, 5 Dec 2016 19:02:37 +0000 (19:02 +0000)]
[AArch64][RegisterBankInfo] Fix typo in the logic used in assert.
Thanks to David Binderman <dcb314@hotmail.com> for bringing it to my
attention.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288688
91177308-0d34-0410-b5e6-
96231b3b80d8
Adrian Prantl [Mon, 5 Dec 2016 18:04:47 +0000 (18:04 +0000)]
[DIExpression] Introduce a dedicated DW_OP_LLVM_fragment operation
so we can stop using DW_OP_bit_piece with the wrong semantics.
The entire back story can be found here:
http://lists.llvm.org/pipermail/llvm-commits/Week-of-Mon-
20161114/405934.html
The gist is that in LLVM we've been misinterpreting DW_OP_bit_piece's
offset field to mean the offset into the source variable rather than
the offset into the location at the top the DWARF expression stack. In
order to be able to fix this in a subsequent patch, this patch
introduces a dedicated DW_OP_LLVM_fragment operation with the
semantics that we used to apply to DW_OP_bit_piece, which is what we
actually need while inside of LLVM. This patch is complete with a
bitcode upgrade for expressions using the old format. It does not yet
fix the DWARF backend to use DW_OP_bit_piece correctly.
Implementation note: We discussed several options for implementing
this, including reserving a dedicated field in DIExpression for the
fragment size and offset, but using an custom operator at the end of
the expression works just fine and is more efficient because we then
only pay for it when we need it.
Differential Revision: https://reviews.llvm.org/D27361
rdar://problem/
29335809
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288683
91177308-0d34-0410-b5e6-
96231b3b80d8
Chris Bieneman [Mon, 5 Dec 2016 17:02:11 +0000 (17:02 +0000)]
[CMake] Fix symlink refactor for multi-configuration generators
This fix, while a bit complicated, preserves the reusability while fixing the issues reported on llvm-commits with visual studio generators.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288679
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 5 Dec 2016 15:58:21 +0000 (15:58 +0000)]
[TargetLowering] add special-case for demanded bits analysis of 'not'
We treat bitwise 'not' as a special operation and try not to reduce its all-ones mask.
Presumably, this is because a 'not' may be cheaper than a generic 'xor' or it may get
folded into another logic op if the target has those. However, if we can remove a logic
instruction by changing the xor's constant mask value, that should always be a win.
Note that the IR version of SimplifyDemandedBits() does not treat 'not' as a special-case
currently (although that's marked with a FIXME). So if you run this IR through -instcombine,
you should get the same end result. I'm hoping to add a different backend transform that
will expose this problem though, so I need to solve this first.
Differential Revision: https://reviews.llvm.org/D27356
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288676
91177308-0d34-0410-b5e6-
96231b3b80d8
Sanjay Patel [Mon, 5 Dec 2016 15:45:27 +0000 (15:45 +0000)]
[x86] fold fand (fxor X, -1) Y --> fandn X, Y
I noticed this gap in the scalar FP-logic matching with:
D26712
and:
rL287171
Differential Revision: https://reviews.llvm.org/D27385
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288675
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Mon, 5 Dec 2016 14:25:04 +0000 (14:25 +0000)]
Use range based for loop. NFCI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288671
91177308-0d34-0410-b5e6-
96231b3b80d8
Nirav Dave [Mon, 5 Dec 2016 14:11:03 +0000 (14:11 +0000)]
[PPC] Slightly Improve Assembly Parsing errors and add EOL comment
parsing tests.
NFC intended.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288667
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Dardis [Mon, 5 Dec 2016 12:55:19 +0000 (12:55 +0000)]
[mips][ias] N32/N64 must not sort the relocation table.
Doing so changes the evaluation order for relocation composition.
Patch By: Daniel Sanders
Reviewers: vkalintiris, atanasyan
Differential Revision: https://reviews.llvm.org/D26401
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288666
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Mon, 5 Dec 2016 11:25:13 +0000 (11:25 +0000)]
[X86][SSE] Add support for combining target shuffles to UNPCKL/UNPCKH.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288663
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Pilgrim [Mon, 5 Dec 2016 11:00:25 +0000 (11:00 +0000)]
[X86][SSE] Add helper function to create UNPCKL/UNPCKH shuffle masks. NFCI.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288659
91177308-0d34-0410-b5e6-
96231b3b80d8
Diana Picus [Mon, 5 Dec 2016 10:40:33 +0000 (10:40 +0000)]
[GlobalISel] Extract handleAssignments out of AArch64CallLowering
This function seems target-independent so far: all the target-specific behaviour
is isolated in the CCAssignFn and the ValueHandler (which we're also extracting
into the generic CallLowering).
The intention is to use this in the ARM backend.
Differential Revision: https://reviews.llvm.org/D27045
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288658
91177308-0d34-0410-b5e6-
96231b3b80d8
Sam Kolton [Mon, 5 Dec 2016 09:58:51 +0000 (09:58 +0000)]
[AMDGPU] Disassembler: fix s_buffer_store_dword instructions
Summary: s_buffer_store_dword instructions sdata operand was called sdst in encoding. This caused disassembler to fail.
Reviewers: tstellarAMD, vpykhtin, artem.tamazov
Subscribers: arsenm, nhaehnle, rampitec
Differential Revision: https://reviews.llvm.org/D27100
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288657
91177308-0d34-0410-b5e6-
96231b3b80d8
Michal Gorny [Mon, 5 Dec 2016 09:15:05 +0000 (09:15 +0000)]
[cmake] Include component in Sphinx install rules
Include component in install rules for Sphinx targets. Based on
a similar suggestion for other doc targets in D24935.
Differential Revision: https://reviews.llvm.org/D24982
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288656
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 08:15:57 +0000 (08:15 +0000)]
TableGen/AsmMatcherEmitter: Trust that stable_sort works
A debug build of AsmMatcherEmitter would use a quadratic algorithm to
check whether std::stable_sort() actually sorted. Let's hope the authors
of our C++ standard library did that testing for us. Removing the check
gives a 3x speedup in the X86 case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288655
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 07:35:13 +0000 (07:35 +0000)]
TableGen: Some more std::string->StringInit* replacements
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288653
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 07:35:09 +0000 (07:35 +0000)]
TableGen/Record: Shortcut member access in hottest function
This may seem unusual, but makes most debug tblgen builds ~10% faster.
Usually we wouldn't care about speed that much in debug builds, but for
tblgen that also translates into build time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288652
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 07:04:19 +0000 (07:04 +0000)]
TableGen: TableGenStringKey is no longer necessary as of r288642
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288651
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 07:00:44 +0000 (07:00 +0000)]
TableGen: Use range based for; reserve vectors where possible
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288650
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Mon, 5 Dec 2016 06:41:54 +0000 (06:41 +0000)]
TableGen/TGParser: Prefer SmallVector/ArrayRef over std::vector
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@288649
91177308-0d34-0410-b5e6-
96231b3b80d8