oota-llvm.git
8 years agoIR: Give 'DI' prefix to debug info metadata
Duncan P. N. Exon Smith [Wed, 29 Apr 2015 16:38:44 +0000 (16:38 +0000)]
IR: Give 'DI' prefix to debug info metadata

Finish off PR23080 by renaming the debug info IR constructs from `MD*`
to `DI*`.  The last of the `DIDescriptor` classes were deleted in
r235356, and the last of the related typedefs removed in r235413, so
this has all baked for about a week.

Note: If you have out-of-tree code (like a frontend), I recommend that
you get everything compiling and tests passing with the *previous*
commit before updating to this one.  It'll be easier to keep track of
what code is using the `DIDescriptor` hierarchy and what you've already
updated, and I think you're extremely unlikely to insert bugs.  YMMV of
course.

Back to *this* commit: I did this using the rename-md-di-nodes.sh
upgrade script I've attached to PR23080 (both code and testcases) and
filtered through clang-format-diff.py.  I edited the tests for
test/Assembler/invalid-generic-debug-node-*.ll by hand since the columns
were off-by-three.  It should work on your out-of-tree testcases (and
code, if you've followed the advice in the previous paragraph).

Some of the tests are in badly named files now (e.g.,
test/Assembler/invalid-mdcompositetype-missing-tag.ll should be
'dicompositetype'); I'll come back and move the files in a follow-up
commit.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236120 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoCodeGen: Default overflow operations to expand so we don't have to assume targets...
Jan Vesely [Wed, 29 Apr 2015 16:30:46 +0000 (16:30 +0000)]
CodeGen: Default overflow operations to expand so we don't have to assume targets are lying

Signed-off-by: Jan Vesely <jan.vesely@rutgers.edu>
Reviewed-by: ab
Differential Revision: http://reviews.llvm.org/D9265

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236119 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips][microMIPSr6] Implement SUB and SUBU instructions
Zoran Jovanovic [Wed, 29 Apr 2015 16:22:46 +0000 (16:22 +0000)]
[mips][microMIPSr6] Implement SUB and SUBU instructions
Differential Revision: http://reviews.llvm.org/D8764

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236118 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips][microMIPSr6] Implement ADD, ADDU and ADDIU instructions
Zoran Jovanovic [Wed, 29 Apr 2015 15:11:07 +0000 (15:11 +0000)]
[mips][microMIPSr6] Implement ADD, ADDU and ADDIU instructions
Differential Revision: http://reviews.llvm.org/D8704

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236111 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSparc: Prefer reg+reg address encoding when only one register used.
James Y Knight [Wed, 29 Apr 2015 14:54:44 +0000 (14:54 +0000)]
Sparc: Prefer reg+reg address encoding when only one register used.

Reg+%g0 is preferred to Reg+imm0 by the manual, and is what GCC produces.

Futhermore, reg+imm is invalid for the (not yet supported) "alternate
address space" instructions.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236107 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRelax assert to avoid spurious failures with /dev/null.
Rafael Espindola [Wed, 29 Apr 2015 14:53:25 +0000 (14:53 +0000)]
Relax assert to avoid spurious failures with /dev/null.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236106 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMips fast-isel - handle functions which return i8 or i6 .
Vasileios Kalintiris [Wed, 29 Apr 2015 14:17:14 +0000 (14:17 +0000)]
Mips fast-isel - handle functions which return i8 or i6 .

Summary: Allow Mips fast-isel to handle functions which return i8/i16 signed/unsigned.

Test Plan:
Make check tests are forthcoming.
Already passes test-suite at O0/O2 for Mips 32 r1/r2

Reviewers: dsanders, rkotler

Subscribers: llvm-commits, rfuhler

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236103 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoDon't constrain the section order in tests that don't depend on it.
Rafael Espindola [Wed, 29 Apr 2015 13:55:07 +0000 (13:55 +0000)]
Don't constrain the section order in tests that don't depend on it.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236102 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] Correct 128-bit shifts on 64-bit targets.
Daniel Sanders [Wed, 29 Apr 2015 12:28:58 +0000 (12:28 +0000)]
[mips] Correct 128-bit shifts on 64-bit targets.

Summary:
The existing code was correct for 32-bit GPR's but not 64-bit GPR's. It now
accounts for both cases.

Reviewers: vkalintiris

Reviewed By: vkalintiris

Subscribers: llvm-commits, mohit.bhakkad, sagar

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236099 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] [IAS] Inline assemble-time shifting out of createLShiftOri. NFC.
Toma Tabacu [Wed, 29 Apr 2015 10:19:56 +0000 (10:19 +0000)]
[mips] [IAS] Inline assemble-time shifting out of createLShiftOri. NFC.

Summary:
Do the assemble-time shifts from createLShiftOri at the source, which groups all the shifting together, closer to the main logic path, and
store the results in concisely-named variables to improve code clarity.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236096 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agofixed 80-chars; NFC
Elena Demikhovsky [Wed, 29 Apr 2015 08:49:57 +0000 (08:49 +0000)]
fixed 80-chars; NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236093 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFixed masked gather/scatter switch-case
Elena Demikhovsky [Wed, 29 Apr 2015 08:38:53 +0000 (08:38 +0000)]
Fixed masked gather/scatter switch-case

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236092 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[TableGen] Use range-based for loops. NFC.
Craig Topper [Wed, 29 Apr 2015 07:13:14 +0000 (07:13 +0000)]
[TableGen] Use range-based for loops. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236089 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[TableGen] Fold a couple dyn_casts into the ifs that check their results. NFC
Craig Topper [Wed, 29 Apr 2015 07:13:12 +0000 (07:13 +0000)]
[TableGen] Fold a couple dyn_casts into the ifs that check their results. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236088 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[TableGen] Replace some dyn_casts followed by an assert with just a regular cast...
Craig Topper [Wed, 29 Apr 2015 07:13:05 +0000 (07:13 +0000)]
[TableGen] Replace some dyn_casts followed by an assert with just a regular cast which asserts internally. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236087 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agofixed comments, blanks, nullptr; NFC
Elena Demikhovsky [Wed, 29 Apr 2015 06:49:50 +0000 (06:49 +0000)]
fixed comments, blanks, nullptr; NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236086 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[TableGen] Use range-based for loops. NFC
Craig Topper [Wed, 29 Apr 2015 04:43:36 +0000 (04:43 +0000)]
[TableGen] Use range-based for loops. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236083 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoDrop Dragonegg from the release export script
Hans Wennborg [Wed, 29 Apr 2015 02:36:43 +0000 (02:36 +0000)]
Drop Dragonegg from the release export script

Follow-up to r236077.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236081 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse an "early return" idiom for the error case. NFC
Filipe Cabecinhas [Wed, 29 Apr 2015 02:36:08 +0000 (02:36 +0000)]
Use an "early return" idiom for the error case. NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236080 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoCheck that we have a valid PointerType element type before calling get()
Filipe Cabecinhas [Wed, 29 Apr 2015 02:27:28 +0000 (02:27 +0000)]
Check that we have a valid PointerType element type before calling get()

Same as r236073 but for PointerType.

Bug found with AFL fuzz.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236079 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse the ArrayType member function for array element types.
Filipe Cabecinhas [Wed, 29 Apr 2015 02:27:21 +0000 (02:27 +0000)]
Use the ArrayType member function for array element types.

ArrayType and StructType accept the same types, so no test.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236078 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoDrop Dragonegg support from the release script
Hans Wennborg [Wed, 29 Apr 2015 02:14:26 +0000 (02:14 +0000)]
Drop Dragonegg support from the release script

It doesn't have a maintainer and none of the release testers test it,
so I don't think it should be part of the release.

http://reviews.llvm.org/D9331

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236077 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoTurn an assert into report_fatal_error since it's reachable based on user input
Filipe Cabecinhas [Wed, 29 Apr 2015 01:58:31 +0000 (01:58 +0000)]
Turn an assert into report_fatal_error since it's reachable based on user input

Bug found with AFL fuzz.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236076 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[Orc] It's not valid to pass a null resolver to addModuleSet. Use a no-op
Lang Hames [Wed, 29 Apr 2015 01:33:35 +0000 (01:33 +0000)]
[Orc] It's not valid to pass a null resolver to addModuleSet. Use a no-op
resolver with a diagnostic instread.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236074 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMake sure that isValidElementType(Type) before calling {Array,Struct}Type::get(Type)
Filipe Cabecinhas [Wed, 29 Apr 2015 01:27:01 +0000 (01:27 +0000)]
Make sure that isValidElementType(Type) before calling {Array,Struct}Type::get(Type)

Bug found with AFL fuzz.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236073 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRegisterCoalescer: hide terminal rule option by default
Matthias Braun [Tue, 28 Apr 2015 23:55:11 +0000 (23:55 +0000)]
RegisterCoalescer: hide terminal rule option by default

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236062 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agotest-release.sh: Drop some unused command-line options.
Hans Wennborg [Tue, 28 Apr 2015 23:37:41 +0000 (23:37 +0000)]
test-release.sh: Drop some unused command-line options.

These haven't done anything since before r142165.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236061 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMap directly from signature symbol to group index. NFC.
Rafael Espindola [Tue, 28 Apr 2015 22:59:58 +0000 (22:59 +0000)]
Map directly from signature symbol to group index. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236058 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoReuse a lookup in an assert.
Eric Christopher [Tue, 28 Apr 2015 22:38:35 +0000 (22:38 +0000)]
Reuse a lookup in an assert.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236054 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRemove redundant temporary std::vector.
Rafael Espindola [Tue, 28 Apr 2015 22:26:19 +0000 (22:26 +0000)]
Remove redundant temporary std::vector.

New sections are added to the end of the list, so the RelSections array was
redundant.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236053 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoARM: fix peephole optimisation of TST
Tim Northover [Tue, 28 Apr 2015 22:03:55 +0000 (22:03 +0000)]
ARM: fix peephole optimisation of TST

We were trying to look through COPY instructions, but only to the next
instruction in a BB and incorrectly anyway. The cases where that would actually
be a good idea are rare enough (and not even tested!) that it's not worth
trying to get right.

rdar://20721342

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236050 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAvoid one more walk over all sections. NFC.
Rafael Espindola [Tue, 28 Apr 2015 22:03:22 +0000 (22:03 +0000)]
Avoid one more walk over all sections. NFC.

Set the group section index as they are created.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236049 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoStyle updates
Andrew Kaylor [Tue, 28 Apr 2015 22:01:51 +0000 (22:01 +0000)]
Style updates

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236048 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse a range loop. NFC.
Rafael Espindola [Tue, 28 Apr 2015 21:58:05 +0000 (21:58 +0000)]
Use a range loop. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236047 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[WinEH] Split blocks at calls to llvm.eh.begincatch
Andrew Kaylor [Tue, 28 Apr 2015 21:54:14 +0000 (21:54 +0000)]
[WinEH] Split blocks at calls to llvm.eh.begincatch

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236046 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAvoid an extra walk over the sections just to assign sections to groups.
Rafael Espindola [Tue, 28 Apr 2015 21:52:33 +0000 (21:52 +0000)]
Avoid an extra walk over the sections just to assign sections to groups.

Assign the sections in the same pass we compute the index.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236045 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSparc: Add alternate aliases for conditional branch instructions.
James Y Knight [Tue, 28 Apr 2015 21:27:31 +0000 (21:27 +0000)]
Sparc: Add alternate aliases for conditional branch instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236042 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[SEH] Add an LLVM intrinsic for _exception_info
Reid Kleckner [Tue, 28 Apr 2015 21:20:42 +0000 (21:20 +0000)]
[SEH] Add an LLVM intrinsic for _exception_info

Eventually, we will lower this out during IR preparation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236036 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRemove the GroupMapTy DenseMap. NFC.
Rafael Espindola [Tue, 28 Apr 2015 21:07:28 +0000 (21:07 +0000)]
Remove the GroupMapTy DenseMap. NFC.

Instead use the Group symbol of MCSectionELF.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236033 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agotransform fadd chains to increase parallelism
Sanjay Patel [Tue, 28 Apr 2015 21:03:22 +0000 (21:03 +0000)]
transform fadd chains to increase parallelism

This is a compromise: with this simple patch, we should always handle a chain of exactly 3
operations optimally, but we're not generating the optimal balanced binary tree for a longer
sequence.

In general, this transform will reduce the dependency chain for a sequence of instructions
using N operands from a worst case N-1 dependent operations to N/2 dependent operations.
The optimal balanced binary tree would reduce the chain to log2(N).

The trade-off for not dealing with longer sequences is: (1) we have less complexity in the
compiler, (2) we avoid unknown compile-time blowup calculating a balanced tree, and (3) we
don't need to worry about the increased register pressure required to parallelize longer
sequences. It also seems unlikely that we would ever encounter really long strings of
dependent ops like that in the wild, but I'm not sure how to verify that speculation.
FWIW, I see no perf difference for test-suite running on btver2 (x86-64) with -ffast-math
and this patch.

We can extend this patch to cover other associative operations such as fmul, fmax, fmin,
integer add, integer mul.

This is a partial fix for:
https://llvm.org/bugs/show_bug.cgi?id=17305

and if extended:
https://llvm.org/bugs/show_bug.cgi?id=21768
https://llvm.org/bugs/show_bug.cgi?id=23116

The issue also came up in:
http://reviews.llvm.org/D8941

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236031 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[bpf] fix build
Alexei Starovoitov [Tue, 28 Apr 2015 20:38:56 +0000 (20:38 +0000)]
[bpf] fix build

Patch by Brenden Blanco.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236030 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse range loops. NFC.
Rafael Espindola [Tue, 28 Apr 2015 20:23:35 +0000 (20:23 +0000)]
Use range loops. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236028 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRelax an assert when there's a type mismatch in forward references
Filipe Cabecinhas [Tue, 28 Apr 2015 20:18:47 +0000 (20:18 +0000)]
Relax an assert when there's a type mismatch in forward references

Summary:
We don't seem to need to assert here, since this function's callers expect
to get a nullptr on error. This way we don't assert on user input.

Bug found with AFL fuzz.

Reviewers: rafael

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236027 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAvoid adding to SectionIndexMap sections that we never lookup. NFC.
Rafael Espindola [Tue, 28 Apr 2015 20:09:13 +0000 (20:09 +0000)]
Avoid adding to SectionIndexMap sections that we never lookup. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236026 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMake getModRefInfo(Instruction *) not crash on certain types of instructions
Daniel Berlin [Tue, 28 Apr 2015 19:19:14 +0000 (19:19 +0000)]
Make getModRefInfo(Instruction *) not crash on certain types of instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236023 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse a range loop. NFC.
Rafael Espindola [Tue, 28 Apr 2015 19:07:16 +0000 (19:07 +0000)]
Use a range loop. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236015 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[x86] remove RCPPS and RSQRTPS intrinsic instruction definitions
Sanjay Patel [Tue, 28 Apr 2015 18:48:45 +0000 (18:48 +0000)]
[x86] remove RCPPS and RSQRTPS intrinsic instruction definitions

We don't need codegen-only intrinsic instructions for the vector forms of these instructions.

This makes the reciprocal estimate instruction lowering identical to how we handle normal
square roots: (V)SQRTPS / (V)SQRTPD.

No existing regression tests fail with this patch.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236013 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd a fixme to resetTargetOptions to explain why it needs to go
Eric Christopher [Tue, 28 Apr 2015 18:09:05 +0000 (18:09 +0000)]
Add a fixme to resetTargetOptions to explain why it needs to go
away.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236009 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFix a [-Werror,-Winconsistent-missing-override] problem in the
Eric Christopher [Tue, 28 Apr 2015 18:06:27 +0000 (18:06 +0000)]
Fix a [-Werror,-Winconsistent-missing-override] problem in the
NVPTX overrides.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236007 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoR600: Fix up for AsmPrinter's OutStreamer being a unique_ptr
Tom Stellard [Tue, 28 Apr 2015 17:37:03 +0000 (17:37 +0000)]
R600: Fix up for AsmPrinter's OutStreamer being a unique_ptr

Fixes a crash with basically any OpenGL application using the radeonsi
driver.

Patch by: Michel Dänzer

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=90176
Signed-off-by: Michel Dänzer <michel.daenzer@amd.com>
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236004 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoR600/SI: Add a lower case alias for subtarget feature: +DumpCode
Tom Stellard [Tue, 28 Apr 2015 17:37:00 +0000 (17:37 +0000)]
R600/SI: Add a lower case alias for subtarget feature: +DumpCode

llc converts all feature strings to lower case, while the LLVM C API
does not, so we need a lower case alias in order to test this with llc.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236003 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[NVPTX] Handle addrspacecast constant expressions in aggregate initializers
Justin Holewinski [Tue, 28 Apr 2015 17:18:30 +0000 (17:18 +0000)]
[NVPTX] Handle addrspacecast constant expressions in aggregate initializers

We need to track if an AddrSpaceCast expression was seen when
generating an MCExpr for a ConstantExpr.  This change introduces a
custom lowerConstant method to the NVPTX asm printer that will create
NVPTXGenericMCSymbolRefExpr nodes at the appropriate places to encode
the information that a given symbol needs to be casted to a generic
address.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@236000 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[opaque pointer type] Encode the allocated type of an alloca rather than its pointer...
David Blaikie [Tue, 28 Apr 2015 16:51:01 +0000 (16:51 +0000)]
[opaque pointer type] Encode the allocated type of an alloca rather than its pointer result type.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235998 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agomove IR-level optimization flags into their own struct
Sanjay Patel [Tue, 28 Apr 2015 16:39:12 +0000 (16:39 +0000)]
move IR-level optimization flags into their own struct

This is a preliminary step to using the IR-level floating-point fast-math-flags in the SDAG (D8900).

In this patch, we introduce the optimization flags as their own struct. As noted in the TODO comment,
we should eventually share this data between the IR passes and the backend.

We also switch the existing nsw / nuw / exact bit functionality of the BinaryWithFlagsSDNode class to
use the new struct.

The tradeoff is that instead of using the free but limited space of SDNode's SubclassData, we add a
data member to the subclass. This means we don't have to repeat all of the get/set methods per flag,
but we're potentially adding size to all nodes of this subclassi type.

In practice on 64-bit systems (measured on Linux and MacOS X), there is no size difference between an
SDNode and BinaryWithFlagsSDNode after this change: they're both 80 bytes. This means that we had at
least one free byte to play with due to struct alignment.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235997 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse a std::vector to record the offsets of the sections. NFC.
Rafael Espindola [Tue, 28 Apr 2015 15:26:21 +0000 (15:26 +0000)]
Use a std::vector to record the offsets of the sections. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235995 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAvoid an extra loop for computing the section size. NFC.
Rafael Espindola [Tue, 28 Apr 2015 15:04:09 +0000 (15:04 +0000)]
Avoid an extra loop for computing the section size. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235994 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFixed crash of variable shift inst on AVX2
Elena Demikhovsky [Tue, 28 Apr 2015 14:46:35 +0000 (14:46 +0000)]
Fixed crash of variable shift inst on AVX2

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235993 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] [IAS] Do not generate redundant ORi in createLShiftOri.
Toma Tabacu [Tue, 28 Apr 2015 14:06:35 +0000 (14:06 +0000)]
[mips] [IAS] Do not generate redundant ORi in createLShiftOri.

Summary: If the immediate is 0, the ORi is pointless.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235990 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoReapply r235977 "[DebugInfo] Add debug locations to constant SD nodes"
Sergey Dmitrouk [Tue, 28 Apr 2015 14:05:47 +0000 (14:05 +0000)]
Reapply r235977 "[DebugInfo] Add debug locations to constant SD nodes"

[DebugInfo] Add debug locations to constant SD nodes

This adds debug location to constant nodes of Selection DAG and updates
all places that create constants to pass debug locations
(see PR13269).

Can't guarantee that all locations are correct, but in a lot of cases choice
is obvious, so most of them should be. At least all tests pass.

Tests for these changes do not cover everything, instead just check it for
SDNodes, ARM and AArch64 where it's easy to get incorrect locations on
constants.

This is not complete fix as FastISel contains workaround for wrong debug
locations, which drops locations from instructions on processing constants,
but there isn't currently a way to use debug locations from constants there
as llvm::Constant doesn't cache it (yet). Although this is a bit different
issue, not directly related to these changes.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235989 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse CIE version 4 for dwarf4.
Rafael Espindola [Tue, 28 Apr 2015 13:55:31 +0000 (13:55 +0000)]
Use CIE version 4 for dwarf4.

According to http://www.dwarfstd.org/doc/DWARF4.pdf appendix F the CIE
version for dwarf 4 is 4.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235988 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoRevert "[DebugInfo] Add debug locations to constant SD nodes"
Daniel Jasper [Tue, 28 Apr 2015 13:38:35 +0000 (13:38 +0000)]
Revert "[DebugInfo] Add debug locations to constant SD nodes"

This breaks a test:
http://bb.pgr.jp/builders/cmake-llvm-x86_64-linux/builds/23870

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235987 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] [IAS] Rename the createShiftOr function to createLShiftOri. NFC.
Toma Tabacu [Tue, 28 Apr 2015 13:16:06 +0000 (13:16 +0000)]
[mips] [IAS] Rename the createShiftOr function to createLShiftOri. NFC.

Summary: The new name is more accurate with regard to the functionality.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235984 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] [IAS] Store the expandLoadImm destination register in a variable. NFC.
Toma Tabacu [Tue, 28 Apr 2015 12:04:53 +0000 (12:04 +0000)]
[mips] [IAS] Store the expandLoadImm destination register in a variable. NFC.

Summary: This removes multiple calls to getReg() and saves us column space in the source file.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235978 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[DebugInfo] Add debug locations to constant SD nodes
Sergey Dmitrouk [Tue, 28 Apr 2015 11:56:37 +0000 (11:56 +0000)]
[DebugInfo] Add debug locations to constant SD nodes

This adds debug location to constant nodes of Selection DAG and updates
all places that create constants to pass debug locations
(see PR13269).

Can't guarantee that all locations are correct, but in a lot of cases choice
is obvious, so most of them should be. At least all tests pass.

Tests for these changes do not cover everything, instead just check it for
SDNodes, ARM and AArch64 where it's easy to get incorrect locations on
constants.

This is not complete fix as FastISel contains workaround for wrong debug
locations, which drops locations from instructions on processing constants,
but there isn't currently a way to use debug locations from constants there
as llvm::Constant doesn't cache it (yet). Although this is a bit different
issue, not directly related to these changes.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235977 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAVX-512: Added "pandn" intrinsics set
Elena Demikhovsky [Tue, 28 Apr 2015 08:12:42 +0000 (08:12 +0000)]
AVX-512: Added "pandn" intrinsics set
by Asaf Badouh (asaf.badouh@intel.com)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235971 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMasked gather and scatter: Added code for SelectionDAG.
Elena Demikhovsky [Tue, 28 Apr 2015 07:57:37 +0000 (07:57 +0000)]
Masked gather and scatter: Added code for SelectionDAG.
All other patches, including tests will follow.

http://reviews.llvm.org/D7665

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235970 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[opaque pointer type] Encode the pointee type in the bitcode for 'cmpxchg'
David Blaikie [Tue, 28 Apr 2015 04:30:29 +0000 (04:30 +0000)]
[opaque pointer type] Encode the pointee type in the bitcode for 'cmpxchg'

As a space optimization, this instruction would just encode the pointer
type of the first operand and use the knowledge that the second and
third operands would be of the pointee type of the first. When typed
pointers go away, this assumption will no longer be available - so
encode the type of the second operand explicitly and rely on that for
the third.

Test case added to demonstrate the backwards compatibility concern,
which only comes up when the definition of the second operand comes
after the use (hence the weird basic block sequence) - at which point
the type needs to be explicitly encoded in the bitcode and the record
length changes to accommodate this.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235966 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[MC] Use LShr for constant evaluation of ">>" on ELF/arm64--darwin.
Ahmed Bougacha [Tue, 28 Apr 2015 01:37:11 +0000 (01:37 +0000)]
[MC] Use LShr for constant evaluation of ">>" on ELF/arm64--darwin.

This matches other assemblers and is less unexpected (e.g. PR23227).
On ELF, I tried binutils gas v2.24 and nasm 2.10.09, and they both
agree on LShr.  On COFF, I couldn't get my hands on an assembler yet,
so don't change the behavior.  For now, don't change it on non-AArch64
Darwin either, as the other assembler is gas v1.38, which does an AShr.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235963 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoDebugInfo: Support up to 2^16 arguments in a subprogram
Duncan P. N. Exon Smith [Tue, 28 Apr 2015 01:07:33 +0000 (01:07 +0000)]
DebugInfo: Support up to 2^16 arguments in a subprogram

Support up to 2^16 arguments to a function.  If we do hit the limit,
assert out rather than restarting at 0 as we've done historically.

This fixes PR23332.  A clang test will follow.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235955 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoCleanup, remove unused return value
Matthias Braun [Tue, 28 Apr 2015 00:37:05 +0000 (00:37 +0000)]
Cleanup, remove unused return value

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235952 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[MC] Split MCBinaryExpr::Shr into LShr and AShr.
Ahmed Bougacha [Tue, 28 Apr 2015 00:21:32 +0000 (00:21 +0000)]
[MC] Split MCBinaryExpr::Shr into LShr and AShr.

Defaulting to AShr without consulting the target MCAsmInfo isn't OK.
Add a flag to fix that.  Keep it off for now: target migrations will
follow in separate commits.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235951 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[MC] Move getBinOpPrecedence into AsmParser. NFC.
Ahmed Bougacha [Tue, 28 Apr 2015 00:17:39 +0000 (00:17 +0000)]
[MC] Move getBinOpPrecedence into AsmParser. NFC.

In preparation for a future patch.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235950 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSwitch lowering: use uint32_t for weights everywhere
Hans Wennborg [Mon, 27 Apr 2015 23:52:19 +0000 (23:52 +0000)]
Switch lowering: use uint32_t for weights everywhere

I previously thought switch clusters would need to use uint64_t in case
the weights of multiple cases overflowed a 32-bit int. It turns
out that the weights on a terminator instruction are capped to allow for
being added together, so using a uint32_t should be safe.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235945 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoLTO: Add API to choose whether to embed uselists
Duncan P. N. Exon Smith [Mon, 27 Apr 2015 23:38:54 +0000 (23:38 +0000)]
LTO: Add API to choose whether to embed uselists

Reverse libLTO's default behaviour for preserving use-list order in
bitcode, and add API for controlling it.  The default setting is now
`false` (don't preserve them), which is consistent with `clang`'s
default behaviour.

Users of libLTO should call `lto_codegen_should_embed_uselists(CG,true)`
prior to calling `lto_codegen_write_merged_modules()` whenever the
output file isn't part of the production workflow in order to reproduce
results with subsequent calls to `llc`.

(I haven't added tests since `llvm-lto` (the test tool for LTO) doesn't
support bitcode output, and even if it did: there isn't actually a good
way to test whether a tool has passed the flag.  If the order is already
"natural" (if the order will already round-trip) then no use-list
directives are emitted at all.  At some point I'll circle back to add
tests to `llvm-as` (etc.) that they actually respect the flag, at which
point I can somehow add a test here as well.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235943 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSwitch lowering: Take branch weight into account when ordering for fall-through
Hans Wennborg [Mon, 27 Apr 2015 23:35:22 +0000 (23:35 +0000)]
Switch lowering: Take branch weight into account when ordering for fall-through

Previously, the code would try to put a fall-through case last,
even if that meant moving a case with much higher branch weight
further down the chain.

Ordering by branch weight is most important, putting a fall-through
block last is secondary.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235942 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoLTO: Simplify code generator initialization
Duncan P. N. Exon Smith [Mon, 27 Apr 2015 23:19:26 +0000 (23:19 +0000)]
LTO: Simplify code generator initialization

Simplify `LTOCodeGenerator` initialization by initializing simple fields
at their definition.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235939 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[docs] Fix the link to SanitizerCoverage docs.
Alexey Samsonov [Mon, 27 Apr 2015 22:50:06 +0000 (22:50 +0000)]
[docs] Fix the link to SanitizerCoverage docs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235934 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoremove obsolete pattern matches for scalar SSE ops
Sanjay Patel [Mon, 27 Apr 2015 22:23:17 +0000 (22:23 +0000)]
remove obsolete pattern matches for scalar SSE ops

The blendi pattern should always replace the insertps pattern after:
http://reviews.llvm.org/rL232850
http://reviews.llvm.org/rL235124

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235930 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoLTO: Correct some doxygen comments about API availability
Duncan P. N. Exon Smith [Mon, 27 Apr 2015 22:08:01 +0000 (22:08 +0000)]
LTO: Correct some doxygen comments about API availability

These look like copy/paste errors, and shouldn't have the "prior to"
qualifier.  Each API was introduced at the given values of
`LTO_API_VERSION`.  The "prior to" in other doxygen comments is because
I couldn't easily differentiate between versions 1 and 2 when I added
these comments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235925 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoUse CIE version 1 for .eh_frame.
Rafael Espindola [Mon, 27 Apr 2015 22:04:24 +0000 (22:04 +0000)]
Use CIE version 1 for .eh_frame.

According to

http://www.linuxbase.org/betaspecs/lsb/LSB-Core-generic/LSB-Core-generic/ehframechpt.html

we should always use 1.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235923 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[AArch64] Also combine vector selects fed by non-i1 SETCCs.
Ahmed Bougacha [Mon, 27 Apr 2015 21:43:12 +0000 (21:43 +0000)]
[AArch64] Also combine vector selects fed by non-i1 SETCCs.

After legalization, scalar SETCC has an i32 result type on AArch64.
The i1 requirement seems too conservative, replace it with an assert.

This also means that we now can run after legalization. That should also
be fine, since the ops legalizer runs again after each combine, and
all types created all have the same sizes as the (legal) inputs.

Exposed by r235917; while there, robustize its tests (bsl also uses the
register it defines).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235922 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAdd missing library dependency in libPDB.
Pete Cooper [Mon, 27 Apr 2015 21:23:12 +0000 (21:23 +0000)]
Add missing library dependency in libPDB.

PDB uses COFFObjectFile::getPE32Header which lives in libObject.

Make sure that LLVMBuild.txt reflects this dependency.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235920 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAllow building the gold plugin even if the gold binary is not found.
Rafael Espindola [Mon, 27 Apr 2015 21:08:47 +0000 (21:08 +0000)]
Allow building the gold plugin even if the gold binary is not found.

The gold binary is not required to build the plugin. All that is
needed is for LLVM_BINUTILS_INCDIR to point to the directory
containing plugin-api.h.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235918 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[AArch64] Don't assert when combining (v3f32 select (setcc f64)).
Ahmed Bougacha [Mon, 27 Apr 2015 21:01:20 +0000 (21:01 +0000)]
[AArch64] Don't assert when combining (v3f32 select (setcc f64)).

When the setcc has f64 operands, we can't build a vector setcc mask
to feed a vselect, because f64 doesn't divide v3f32 evenly.
Just bail out when that happens.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235917 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFixes a hang that can occur if a signal comes in during malloc calls.
Chris Bieneman [Mon, 27 Apr 2015 20:45:35 +0000 (20:45 +0000)]
Fixes a hang that can occur if a signal comes in during malloc calls.

We need to dereference the signals mutex during handler registration so that we force its construction. This is to prevent the first use being during handling an actual signal because you can't safely allocate memory in a signal handler.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235914 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSilence unused variable errors for no-asserts builds
Bill Schmidt [Mon, 27 Apr 2015 20:22:35 +0000 (20:22 +0000)]
Silence unused variable errors for no-asserts builds

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235913 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoSwitch lowering: order bit tests by branch weight.
Hans Wennborg [Mon, 27 Apr 2015 20:21:17 +0000 (20:21 +0000)]
Switch lowering: order bit tests by branch weight.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235912 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[opaque pointer type] encode the pointee type of global variables
David Blaikie [Mon, 27 Apr 2015 19:58:56 +0000 (19:58 +0000)]
[opaque pointer type] encode the pointee type of global variables

Use a few extra bits in the const field (after widening it from a fixed
single bit) to stash the address space which is no longer provided by
the type (and an extra bit in there to specify that we're using that new
encoding).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235911 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[PPC64LE] Remove unnecessary swaps from lane-insensitive vector computations
Bill Schmidt [Mon, 27 Apr 2015 19:57:34 +0000 (19:57 +0000)]
[PPC64LE] Remove unnecessary swaps from lane-insensitive vector computations

This patch adds a new SSA MI pass that runs on little-endian PPC64
code with VSX enabled. Loads and stores of 4x32 and 2x64 vectors
without alignment constraints are accomplished for little-endian using
lxvd2x/xxswapd and xxswapd/stxvd2x. The existence of the additional
xxswapd instructions hurts performance in comparison with big-endian
code, but they are necessary in the general case to support correct
semantics.

However, the general case does not apply to most vector code. Many
vector instructions are lane-insensitive; they do not "care" which
lanes the parallel computations are performed within, provided that
the resulting data is stored into the correct locations. Thus this
pass looks for computations that perform only lane-insensitive
operations, and remove the unnecessary swaps from loads and stores in
such computations.

Future improvements will allow computations using certain
lane-sensitive operations to also be optimized in this manner, by
modifying the lane-sensitive operations to account for the permuted
order of the lanes. However, this patch only adds the infrastructure
to permit this; no lane-sensitive operations are optimized at this
time.

This code is heavily exercised by the various vectorizing applications
in the projects/test-suite tree. For the time being, I have only added
one simple test case to demonstrate what the pass is doing. Although
it is quite simple, it provides coverage for much of the code,
including the special case handling of copies and subreg-to-reg
operations feeding the swaps. I plan to add additional tests in the
future as I fill in more of the "special handling" code.

Two existing tests were affected, because they expected the swaps to
be present, but they are now removed.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235910 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[llvm-symbolizer] Link DebugInfoPDB for the autoconf build
Zachary Turner [Mon, 27 Apr 2015 19:41:40 +0000 (19:41 +0000)]
[llvm-symbolizer] Link DebugInfoPDB for the autoconf build

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235909 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agofix 80-cols; NFC
Sanjay Patel [Mon, 27 Apr 2015 17:45:44 +0000 (17:45 +0000)]
fix 80-cols; NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235902 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoFix build broken by incorrect class name.
Zachary Turner [Mon, 27 Apr 2015 17:22:30 +0000 (17:22 +0000)]
Fix build broken by incorrect class name.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235901 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMake llvm-symbolizer work on Windows.
Zachary Turner [Mon, 27 Apr 2015 17:19:51 +0000 (17:19 +0000)]
Make llvm-symbolizer work on Windows.

Differential Revision: http://reviews.llvm.org/D9234
Reviewed By: Alexey Samsonov

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235900 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoMake an RAII com initializer.
Zachary Turner [Mon, 27 Apr 2015 17:19:26 +0000 (17:19 +0000)]
Make an RAII com initializer.

Differential Revision: http://reviews.llvm.org/D9267
Reviewed By: Aaron Ballman, David Majnemer

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235898 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agofix typos; NFC
Sanjay Patel [Mon, 27 Apr 2015 17:03:31 +0000 (17:03 +0000)]
fix typos; NFC

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235896 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] Correct bytes to bits in 2 comments. NFC.
Toma Tabacu [Mon, 27 Apr 2015 15:21:38 +0000 (15:21 +0000)]
[mips] Correct bytes to bits in 2 comments. NFC.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235891 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoAVX-512: added calling conventions for i1 vectors.
Elena Demikhovsky [Mon, 27 Apr 2015 15:11:19 +0000 (15:11 +0000)]
AVX-512: added calling conventions for i1 vectors.

Fixed bug: https://llvm.org/bugs/show_bug.cgi?id=20724

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235889 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[Hexagon] Use constant extenders to fix up hardware loops
Brendon Cahoon [Mon, 27 Apr 2015 14:16:43 +0000 (14:16 +0000)]
[Hexagon] Use constant extenders to fix up hardware loops

Use a loop instruction with a constant extender for a hardware
loop instruction that is too far away from the start of the loop.
This is cheaper than changing the SA register value.

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235882 91177308-0d34-0410-b5e6-96231b3b80d8

8 years ago[mips] [IAS] Improve warning for using AT with .set noat.
Toma Tabacu [Mon, 27 Apr 2015 14:05:04 +0000 (14:05 +0000)]
[mips] [IAS] Improve warning for using AT with .set noat.

Summary:
Changed the warning message to show the current value of $at, similar to what clang does for typedef's, and renamed warnIfAssemblerTemporary to a more descriptive name.

I also changed the type of variables which store registers from int to unsigned, updated the relevant test and tried to make the related comments clearer.

Reviewers: dsanders

Reviewed By: dsanders

Subscribers: llvm-commits

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

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235881 91177308-0d34-0410-b5e6-96231b3b80d8

8 years agoReapply "[mips][FastISel] Implement shift ops for Mips fast-isel.""
Vasileios Kalintiris [Mon, 27 Apr 2015 13:28:05 +0000 (13:28 +0000)]
Reapply "[mips][FastISel] Implement shift ops for Mips fast-isel.""

This reapplies r235194, which was reverted in r235495 because it was causing a
failure in our out-of-tree buildbots for MIPS. With the sign-extension patch
in r235718, this patch doesn't cause any problem any more.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@235878 91177308-0d34-0410-b5e6-96231b3b80d8