Commit Graph

101630 Commits

Author SHA1 Message Date
Matt Arsenault
62b3e22092 R600/SI: Add support for 64-bit LDS loads.
v2:
  -Use correct opcode for DS_READ_64

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204273 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 22:19:52 +00:00
Matt Arsenault
6eaa49233f R600/SI: Match i16 immediate offset of LDS instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204272 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 22:19:49 +00:00
Matt Arsenault
adf5141ecd R600/SI: Fix test checking wrong instruction operand.
The source and destination happen to be the same register.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204271 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 22:19:45 +00:00
Matt Arsenault
9c0b2d08d3 R600/SI: Don't display the GDS bit.
It isn't actually used now, and probably never will be, plus it makes
tests less annoying. I also think SC prints GDS instructions as a
separate instruction name.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204270 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 22:19:43 +00:00
Matt Arsenault
6d1781733d R600/SI: Merge offset0 and offset1 fields for single address DS instructions v2
Also remove unused data fields from the DS_Load_Helper class.

v2:
  - Merge fields for DS_WRITE

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204269 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 22:19:39 +00:00
David Majnemer
875b3c9afd COFF: Fix a typo
Introduced when I rebased my changes to use isReservedSectionNumber.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204260 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 20:16:23 +00:00
Hans Wennborg
a2ff1c5de1 Fix comment (PR19188)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204256 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 18:41:38 +00:00
Matheus Almeida
e7f8a0b47a [mips] 80-column.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204252 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 16:29:06 +00:00
Matheus Almeida
947fa5b7b7 [mips] Making sure that a '.set noreorder' directive is correctly parsed
and emitted and that no NOPs are emitted in a 'noreorder section'.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204250 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 16:20:19 +00:00
Evgeniy Stepanov
eef411a52a Set debug info for instructions inserted in SplitBlockAndInsertIfThen.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204230 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 12:56:38 +00:00
Craig Topper
59ae7294ef Prune includes in X86 target.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204216 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 06:53:25 +00:00
David Majnemer
6d191534f6 Object: Provide a richer means of describing auxiliary symbols
The current state of affairs has auxiliary symbols described as a big
bag of bytes. This is less than satisfying, it detracts from the YAML
file as being human readable.

Instead, allow for symbols to optionally contain their auxiliary data.
This allows us to have a much higher level way of describing things like
weak symbols, function definitions and section definitions.

This depends on D3105.

Differential Revision: http://llvm-reviews.chandlerc.com/D3092

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204214 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 04:47:47 +00:00
David Majnemer
92c5a193e0 Object: Move auxiliary symbol definitions from llvm-readobj
Summary: These definitions are useful to other aspects of LLVM, move them out.

Reviewers: rafael, nrieck, ruiu

CC: llvm-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D3105

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204213 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 04:33:27 +00:00
David Majnemer
75141e6c47 Object: Clean up COFF.h
The file violated the coding standard.  Make it conform.

No functionality change.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204212 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 02:37:19 +00:00
Justin Bogner
695043fb48 llvm-profdata: Make "merge" into a subcommand.
We'll be adding a few more subcommands in the near future.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204211 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 02:20:46 +00:00
Justin Bogner
fb007bb98c llvm-profdata: Update to use the naive text format with function hash
This also uses line_iterator to simplify the parsing logic.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204210 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 02:20:42 +00:00
Rafael Espindola
94ec09ae32 Make the test harder by using a non-zero offset.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204205 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 00:26:58 +00:00
Pete Cooper
f7efbb1906 When destroying a StringMap, just iterate over the map and destroy the contained elements. Don't reset them back to 0 as their values aren't needed any more. This results in ~StringMap() being mostly empty for POD types in BumpPtrAllocators
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204204 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 00:23:30 +00:00
Rafael Espindola
025e94d7dc Revert "Add back r203962, r204028 and r204059."
This reverts commit r204178.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204203 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 00:13:43 +00:00
David Blaikie
56ce2f5ab8 DebugInfo: Use the comp_dir of the referencing type units when building debug_line.dwo
This isn't a complete fix - it falls back to non-comp_dir when multiple
compile units are in play. Adding a map of comp_dir to table is part of
the more general solution, but I gave up (in the short term) when I
realized I'd also have to calculate the size of each type unit so as to
produce correct DW_AT_stmt_list attributes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204202 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-19 00:11:28 +00:00
Eli Bendersky
21354ec60d Expose "noduplicate" attribute as a property for intrinsics.
The "noduplicate" function attribute exists to prevent certain optimizations
from duplicating calls to the function. This is important on platforms where
certain function call duplications are unsafe (for example execution barriers
for CUDA and OpenCL).

This patch makes it possible to specify intrinsics as "noduplicate" and
translates that to the appropriate function attribute.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204200 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 23:51:07 +00:00
Rui Ueyama
cae25dcbf7 Object/COFF: Add function to check if section number is reserved one.
Differential Revision: http://llvm-reviews.chandlerc.com/D3103

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204199 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 23:37:53 +00:00
NAKAMURA Takumi
2c4507e850 Move yet another test that requires ARM to an ARM test directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204198 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 23:12:09 +00:00
Jim Grosbach
ec8a8564f8 Move tests that require ARM to an ARM test directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204197 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:43:59 +00:00
Duncan P. N. Exon Smith
9ea770ddbb Fix use_iterator crash in ObjCArc from r203364
The use_iterator redesign in r203364 introduced an increment past the
end of a range in -objc-arc-contract.  Added an explicit check for the
end of the range.

<rdar://problem/16333235>

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204195 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:32:43 +00:00
Jim Grosbach
6d1980d0ca C++ style comments
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204194 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:13:13 +00:00
Jim Grosbach
c18837f044 Tidy up. Update per naming conventions.
No functional change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204192 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:09:10 +00:00
Jim Grosbach
e133cd2ea2 MachO: Emit a version-min load command when possible.
When deployment target version information is available, emit it to the
target streamer for inclusion in the object file.

rdar://11337778

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204191 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:09:08 +00:00
Jim Grosbach
d55fc3f151 Darwin: Add assembler directives to create version-min load commands.
Allow object files to be tagged with a version-min load command for iOS
or MacOSX.

Teach macho-dump to understand the version-min load commands for
testcases.

rdar://11337778

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204190 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:09:05 +00:00
Jim Grosbach
802d81591a MachO: Comment fields in the version_min load command.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204189 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:08:58 +00:00
Chandler Carruth
3c1eb9903b [LV] While I'm here, use range based for loops which are so much cleaner
for this kind of walk.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204188 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 22:00:32 +00:00
Chandler Carruth
633eb08d31 [LV] The actual change I intended to commit in r204148. Sorry for the
noise.

Original commit log:
Replace some dead code with an assert. When I first ported this pass
from a loop pass to a function pass I did so in the naive, recursive
way. It doesn't actually work, we need a worklist instead. When
I switched to the worklist I didn't delete the naive recursion. That
recursion was also buggy because it was dead and never really exercised.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204187 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 21:58:38 +00:00
Chandler Carruth
a22773cd45 [LV] Replace some dead code with an assert. When I first ported this
pass from a loop pass to a function pass I did so in the naive,
recursive way. It doesn't actually work, we need a worklist instead.
When I switched to the worklist I didn't delete the naive recursion.
That recursion was also buggy because it was dead and never really
exercised.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204184 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 21:51:46 +00:00
Eric Christopher
18d3426b89 More header and forward declaration cleanup.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204183 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 21:44:12 +00:00
Eric Christopher
a673745a34 Add back the headers we're getting via (likely) transitive includes.
We really do use these things in the header.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204180 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 20:58:35 +00:00
Rafael Espindola
4af106a677 Add back r203962, r204028 and r204059.
This reverts commit r204137.

This includes a fix for handling aliases of aliases.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204178 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 20:40:38 +00:00
Eric Christopher
7f22dc90ad Fix for coding style.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204177 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 20:39:54 +00:00
Eric Christopher
994c303f24 Remove a bunch of unnecessary includes and forward declarations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204176 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 20:37:10 +00:00
Hans Wennborg
523f800e90 X86 memcpy lowering: use "rep movs" even when esi is used as base pointer
For functions where esi is used as base pointer, we would previously fall back
from lowering memcpy with "rep movs" because that clobbers esi.

With this patch, we just store esi in another physical register, and restore
it afterwards. This adds a little bit of register preassure, but the more
efficient memcpy should be worth it.

Differential Revision: http://llvm-reviews.chandlerc.com/D2968

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204174 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 20:04:34 +00:00
Rui Ueyama
172c31844b Use early returns to reduce nesting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204171 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 18:58:51 +00:00
Michael Zolotukhin
50e4d56b9f Fix test lsr-normalization.ll broken in r204161.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204166 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 18:17:59 +00:00
Raul E. Silvera
370981ad17 Add support for scalarizing/splitting vector bswap.
Summary:
  SLP Vectorization of intrinsics (r203707) has exposed cases where the
  expansion of vector bswap is failing (PR19151).

Reviewers: hfinkel

CC: chandlerc

Differential Revision: http://llvm-reviews.chandlerc.com/D3104

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204163 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 17:49:12 +00:00
Adrian Prantl
e1ea4faca1 Debug info: Remove OdrMemberMap from DwarfDebug, it's not necessary.
Follow-up to r203982.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204162 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 17:41:15 +00:00
Michael Zolotukhin
13ca05e2b8 Add stride normalization to SCEV Normalize/Denormalize transformation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204161 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 17:34:03 +00:00
Andrea Di Biagio
6077ca9abb [DAGCombiner] teach how to simplify xor/and/or nodes according to the following rules:
1)  (AND (shuf (A, C, Mask), shuf (B, C, Mask)) -> shuf (AND (A, B), C, Mask)
 2)  (OR  (shuf (A, C, Mask), shuf (B, C, Mask)) -> shuf (OR  (A, B), C, Mask)
 3)  (XOR (shuf (A, C, Mask), shuf (B, C, Mask)) -> shuf (XOR (A, B), V_0, Mask)

 4)  (AND (shuf (C, A, Mask), shuf (C, B, Mask)) -> shuf (C, AND (A, B), Mask)
 5)  (OR  (shuf (C, A, Mask), shuf (C, B, Mask)) -> shuf (C, OR  (A, B), Mask)
 6)  (XOR (shuf (C, A, Mask), shuf (C, B, Mask)) -> shuf (V_0, XOR (A, B), Mask)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204160 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 17:12:59 +00:00
Manuel Jacob
7e18b99f1e X86: Use enums for memory operand decoding instead of integer literals.
Summary:
X86BaseInfo.h defines an enum for the offset of each operand in a memory operand
sequence.  Some code uses it and some does not.  This patch replaces (hopefully)
all remaining locations where an integer literal was used instead of this enum.
No functionality change intended.

Reviewers: nadav

CC: llvm-commits, t.p.northover

Differential Revision: http://llvm-reviews.chandlerc.com/D3108

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204158 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 16:14:11 +00:00
Krzysztof Parzyszek
3da56299df Enable CFI on Hexagon.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204157 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 16:02:37 +00:00
Bill Schmidt
d4585b941a Fix PR19144: Incorrect offset generated for int-to-fp conversion at -O0.
When converting a signed 32-bit integer to double-precision floating point on
hardware without a lfiwax instruction, we have to instead use a lfd followed
by fcfid.  We were erroneously offsetting the address by 4 bytes in
preparation for either a lfiwax or lfiwzx when generating the lfd.  This fixes
that silly error.

This was not caught in the test suite since the conversion tests were run with
-mcpu=pwr7, which implies availability of lfiwax.  I've added another test
case for older hardware that checks the code we expect in the absence of
lfiwax and other flavors of fcfid.  There are fewer tests in this test case
because we punt to DAG selection in more cases on older hardware.  (We must
generate complex fiddly sequences in those cases, and there is marginal
benefit in duplicating that logic in fast-isel.)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204155 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 14:32:50 +00:00
Evgeniy Stepanov
610469f4c2 [msan] Origin tracking with history.
LLVM part of MSan implementation of advanced origin tracking,
when we record not only creation point, but all locations where
an uninitialized value was stored to memory, too.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204151 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 13:30:56 +00:00
Diego Novillo
c605296342 Tolerate unmangled names in sample profiles.
Summary:
The compiler does not always generate linkage names. If a function
has been inlined and its body elided, its linkage name may not be
generated.

When the binary executes, the profiler will use its unmangled name
when attributing samples. This results in unmangled names in the
input profile.

We are currently failing hard when this happens. However, in this case
all that happens is that we fail to attribute samples to the inlined
function. While this means fewer optimization opportunities, it should
not cause a compilation failure.

This patch accepts all valid function names, regardless of whether
they were mangled or not.

Reviewers: chandlerc

CC: llvm-commits

Differential Revision: http://llvm-reviews.chandlerc.com/D3087

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@204142 91177308-0d34-0410-b5e6-96231b3b80d8
2014-03-18 12:03:12 +00:00