oota-llvm.git
10 years agoMC: Add AsmLexer::BigNum token for integers greater than 64 bits
David Woodhouse [Sat, 1 Feb 2014 16:20:54 +0000 (16:20 +0000)]
MC: Add AsmLexer::BigNum token for integers greater than 64 bits

This will be needed for .octa support, but we don't want to just use the
existing AsmLexer::Integer for it and then have to litter all its users
with explicit checks for the size, and make them use the new get APIntVal()
method.

So let the lexer produce an AsmLexer::Integer as before for numbers which
are small enough — which appears to cover what was previously a nasty
special case handling of numbers which don't fit in int64_t but *do* fit
in uint64_t.

Where the number is too large even for that, produce an AsmLexer::BigNum
instead. We do nothing with these except complain about them for now,
but that will be changed shortly...

Based on a patch from PaX Team <pageexec@freemail.hu>

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

10 years ago[LPM] Apply a really big hammer to fix PR18688 by recursively reforming
Chandler Carruth [Sat, 1 Feb 2014 13:35:14 +0000 (13:35 +0000)]
[LPM] Apply a really big hammer to fix PR18688 by recursively reforming
LCSSA when we promote to SSA registers inside of LICM.

Currently, this is actually necessary. The promotion logic in LICM uses
SSAUpdater which doesn't understand how to place LCSSA PHI nodes.
Teaching it to do so would be a very significant undertaking. It may be
worthwhile and I've left a FIXME about this in the code as well as
starting a thread on llvmdev to try to figure out the right long-term
solution.

For now, the PR needs to be fixed. Short of using the promition
SSAUpdater to place both the LCSSA PHI nodes and the promoted PHI nodes,
I don't see a cleaner or cheaper way of achieving this. Fortunately,
LCSSA is relatively lazy and sparse -- it should only update
instructions which need it. We can also skip the recursive variant when
we don't promote to SSA values.

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

10 years agoRemove some unused #includes
Eli Bendersky [Sat, 1 Feb 2014 13:12:54 +0000 (13:12 +0000)]
Remove some unused #includes

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

10 years agoSilence GCC warnings.
Benjamin Kramer [Sat, 1 Feb 2014 11:26:18 +0000 (11:26 +0000)]
Silence GCC warnings.

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

10 years ago[inliner] Skip debug intrinsics even earlier in computing the inline
Chandler Carruth [Sat, 1 Feb 2014 10:38:17 +0000 (10:38 +0000)]
[inliner] Skip debug intrinsics even earlier in computing the inline
cost so that they don't impact the vector bonus. Fundamentally, counting
unsimplified instructions is just *wrong*; it will continue to introduce
instability as things which do not generate code bizarrely impact
inlining. For example, sufficiently nested inlined functions could turn
off the vector bonus with lifetime markers just like the debug
intrinsics do. =/

This is a short-term tactical fix. Long term, I think we need to remove
the vector bonus entirely. That's a separate patch and discussion
though.

The patch to fix this provided by Dario Domizioli. I've added some
comments about the planned direction and used a heavily pruned form of
debug info intrinsics for the test case. While this debug info doesn't
work or "do" anything useful, it lets us easily test all manner of
interference easily, and I suspect this will not be the last time we
want to craft a pattern where debug info interferes with the inliner in
a problematic way.

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

10 years agoSimplify some x86 format classes and remove some ambiguities in their application.
Craig Topper [Sat, 1 Feb 2014 08:17:56 +0000 (08:17 +0000)]
Simplify some x86 format classes and remove some ambiguities in their application.

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

10 years agoUpdate a .fill test to use the updated semantics.
David Majnemer [Sat, 1 Feb 2014 07:36:52 +0000 (07:36 +0000)]
Update a .fill test to use the updated semantics.

Something funny happened, this should've been part of r200606.

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

10 years agoMC: Improve the .fill directive's compatibility with GAS
David Majnemer [Sat, 1 Feb 2014 07:19:38 +0000 (07:19 +0000)]
MC: Improve the .fill directive's compatibility with GAS

Per the GAS documentation, .fill should permit pattern widths that
aren't a power of two. While I was in the neighborhood, I added some
sanity checking. This change was motivated by a use of this construct
in the Linux Kernel.

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

10 years agoHopefully fix mingw32 bots.
Peter Collingbourne [Sat, 1 Feb 2014 02:42:20 +0000 (02:42 +0000)]
Hopefully fix mingw32 bots.

For some reason this symbolic constant isn't defined in some versions of mingw32.

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

10 years agoRevert "[SLPV] Recognize vectorizable intrinsics during SLP vectorization ..."
Reid Kleckner [Sat, 1 Feb 2014 01:37:30 +0000 (01:37 +0000)]
Revert "[SLPV] Recognize vectorizable intrinsics during SLP vectorization ..."

This reverts commit r200576.  It broke 32-bit self-host builds by
vectorizing two calls to @llvm.bswap.i64, which we then fail to expand.

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

10 years ago[stackprotector] Implement the sspstrong rules for stack layout.
Josh Magee [Sat, 1 Feb 2014 01:36:16 +0000 (01:36 +0000)]
[stackprotector] Implement the sspstrong rules for stack layout.

This changes the PrologueEpilogInserter and LocalStackSlotAllocation passes to
follow the extended stack layout rules for sspstrong and sspreq.

The sspstrong layout rules are:
 1. Large arrays and structures containing large arrays (>= ssp-buffer-size)
are closest to the stack protector.
 2. Small arrays and structures containing small arrays (< ssp-buffer-size) are
2nd closest to the protector.
 3. Variables that have had their address taken are 3rd closest to the
protector.

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

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

10 years agoImplement inalloca codegen for x86 with the new inalloca design
Reid Kleckner [Fri, 31 Jan 2014 23:50:57 +0000 (23:50 +0000)]
Implement inalloca codegen for x86 with the new inalloca design

Calls with inalloca are lowered by skipping all stores for arguments
passed in memory and the initial stack adjustment to allocate argument
memory.

Now the frontend is responsible for the memory layout, and the backend
doesn't have to do any work.  As a result these changes are pretty
minimal.

Reviewers: echristo

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

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

10 years agoIntroduce line editor library.
Peter Collingbourne [Fri, 31 Jan 2014 23:46:14 +0000 (23:46 +0000)]
Introduce line editor library.

This library will be used by clang-query. I can imagine LLDB becoming another
client of this library, so I think LLVM is a sensible place for it to live.
It wraps libedit, and adds tab completion support.

The code is loosely based on the line editor bits in LLDB, with a few
improvements:

 - Polymorphism for retrieving the list of tab completions, based on
   the concept pattern from the new pass manager.

 - Tab completion doesn't corrupt terminal output if the input covers
   multiple lines. Unfortunately this can only be done in a truly horrible
   way, as far as I can tell. But since the alternative is to implement our
   own line editor (which I don't think LLVM should be in the business of
   doing, at least for now) I think it may be acceptable.

 - Includes a fallback for the case where the user doesn't have libedit
   installed.

Note that this uses C stdio, mainly because libedit also uses C stdio.

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

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

10 years agoIntroduce llvm::sys::path::home_directory.
Peter Collingbourne [Fri, 31 Jan 2014 23:46:06 +0000 (23:46 +0000)]
Introduce llvm::sys::path::home_directory.

This will be used by the line editor library to derive a default path to
the history file.

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

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

10 years agoDon't put non-static allocas in the static alloca map
Reid Kleckner [Fri, 31 Jan 2014 23:45:12 +0000 (23:45 +0000)]
Don't put non-static allocas in the static alloca map

Allocas marked inalloca are never static, but we were trying to put them
into the static alloca map if they were in the entry block.  Also add an
assertion in x86 fastisel.

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

10 years agoSplit out small-code-model MCJIT testcase in order to xfail for AArch64, where
Lang Hames [Fri, 31 Jan 2014 23:36:25 +0000 (23:36 +0000)]
Split out small-code-model MCJIT testcase in order to xfail for AArch64, where
PC-rel relocations aren't yet fully implemented.

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

10 years agoRemove a redundant call to hasRawTextSupport.
Rafael Espindola [Fri, 31 Jan 2014 23:14:01 +0000 (23:14 +0000)]
Remove a redundant call to hasRawTextSupport.

The code path it was guarding was already using emitRawComment.

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

10 years agoRemove another hasRawTextSupport.
Rafael Espindola [Fri, 31 Jan 2014 23:10:26 +0000 (23:10 +0000)]
Remove another hasRawTextSupport.

To remove this one simply move the end of file logic from the asm printer to
the target mc streamer.

This removes the last call to hasRawTextSupport from lib/Target.

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

10 years agoSet -mcpu to make this test pass on atom bots
Reid Kleckner [Fri, 31 Jan 2014 22:58:10 +0000 (22:58 +0000)]
Set -mcpu to make this test pass on atom bots

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

10 years ago[inliner] Print out extra stats about the cost, threshold, and vector
Chandler Carruth [Fri, 31 Jan 2014 22:32:32 +0000 (22:32 +0000)]
[inliner] Print out extra stats about the cost, threshold, and vector
bonus in the inline cost analysis.

Split out of a patch by Dario Domizioli to commit separately.

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

10 years agoRemove the last hasRawTextSupport call from R600.
Rafael Espindola [Fri, 31 Jan 2014 22:14:06 +0000 (22:14 +0000)]
Remove the last hasRawTextSupport call from R600.

There is nothing wrong with printing the disassembly section when printing
text. An hypothetical assembler would then produce a .o just like our
direct object emission produces.

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

10 years agoReplace another use with hasRawTextSupport+EmitRawText with emitRawComment.
Rafael Espindola [Fri, 31 Jan 2014 22:08:19 +0000 (22:08 +0000)]
Replace another use with hasRawTextSupport+EmitRawText with emitRawComment.

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

10 years agoUse emitRawComment to avoid a call to hasRawTextSupport.
Rafael Espindola [Fri, 31 Jan 2014 21:54:49 +0000 (21:54 +0000)]
Use emitRawComment to avoid a call to hasRawTextSupport.

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

10 years agoFix file header for APFloat.h
Duncan P. N. Exon Smith [Fri, 31 Jan 2014 21:45:54 +0000 (21:45 +0000)]
Fix file header for APFloat.h

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

10 years agoClean up whitespace
Duncan P. N. Exon Smith [Fri, 31 Jan 2014 21:45:51 +0000 (21:45 +0000)]
Clean up whitespace

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

10 years agoMark the first dynamic elf symbol as SF_FormatSpecific.
Rafael Espindola [Fri, 31 Jan 2014 21:40:13 +0000 (21:40 +0000)]
Mark the first dynamic elf symbol as SF_FormatSpecific.

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

10 years agoReplace X86 FMA intrinsic pseduo-instructions with def pats.
Lang Hames [Fri, 31 Jan 2014 21:29:19 +0000 (21:29 +0000)]
Replace X86 FMA intrinsic pseduo-instructions with def pats.

It looks like these pseudos were only used for pattern matching. Def pats are
the appropriate way to do that. As a bonus, these intrinsics will now have
memory operands folded properly, and better FMA3 variants selected where
appropriate (see r199933).

<rdar://problem/15611947>

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

10 years ago[SLPV] Recognize vectorizable intrinsics during SLP vectorization and
Chandler Carruth [Fri, 31 Jan 2014 21:14:40 +0000 (21:14 +0000)]
[SLPV] Recognize vectorizable intrinsics during SLP vectorization and
transform accordingly. Based on similar code from Loop vectorization.
Subsequent commits will include vectorization of function calls to
vector intrinsics and form function calls to vector library calls.

Patch by Raul Silvera! (Much delayed due to my not running dcommit)

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

10 years agoSimplify getSymbolFlags.
Rafael Espindola [Fri, 31 Jan 2014 20:57:12 +0000 (20:57 +0000)]
Simplify getSymbolFlags.

None of the object formats require extra parsing to compute these flags,
so the method cannot fail.

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

10 years agoIf we're not producing DWARF accel tables, don't waste memory
Paul Robinson [Fri, 31 Jan 2014 20:39:19 +0000 (20:39 +0000)]
If we're not producing DWARF accel tables, don't waste memory
keeping track of those entries.

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

10 years agoAdd support for DW_FORM_flag and DW_FORM_flag_present to the DIE hashing
Eric Christopher [Fri, 31 Jan 2014 20:02:58 +0000 (20:02 +0000)]
Add support for DW_FORM_flag and DW_FORM_flag_present to the DIE hashing
algorithm. Sink the 'A' + Attribute hash into each form so we don't
have to check valid forms before deciding whether or not we're going
to hash which will let the default be to return without doing anything.

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

10 years agoFix name of nested type in comment to match code.
Eric Christopher [Fri, 31 Jan 2014 20:02:55 +0000 (20:02 +0000)]
Fix name of nested type in comment to match code.

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

10 years agoDebugInfo: Flag type unit references as declarations
David Blaikie [Fri, 31 Jan 2014 19:52:26 +0000 (19:52 +0000)]
DebugInfo: Flag type unit references as declarations

This ensures DWARF consumers don't confuse these references for
definitions. I'd argue it might be nice to improve debuggers so we don't
need this, but it's just one field in an abbreviation anyway - so it
doesn't seem worth the fight.

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

10 years agox86: Rename NumBytesForCalleeToPush to ...Pop for accuracy
Reid Kleckner [Fri, 31 Jan 2014 19:07:18 +0000 (19:07 +0000)]
x86: Rename NumBytesForCalleeToPush to ...Pop for accuracy

If we have a callee cleanup convention, the callee is going to pop the
arguments off the stack, not push them on.

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

10 years agoRevert r200560, "LTO itself hasn't depended on MCDisassembler any more."
NAKAMURA Takumi [Fri, 31 Jan 2014 17:57:50 +0000 (17:57 +0000)]
Revert r200560, "LTO itself hasn't depended on MCDisassembler any more."

Oh sorry, I missed LTO.exports, ... I checked just only *.cpp(s).

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

10 years ago[ms-cxxabi] Add a new calling convention that swaps 'this' and 'sret'
Reid Kleckner [Fri, 31 Jan 2014 17:41:22 +0000 (17:41 +0000)]
[ms-cxxabi] Add a new calling convention that swaps 'this' and 'sret'

MSVC always places the 'this' parameter for a method first.  The
implicit 'sret' pointer for methods always comes second.  We already
implement this for __thiscall by putting sret parameters on the stack,
but __cdecl methods require putting both parameters on the stack in
opposite order.

Using a special calling convention allows frontends to keep the sret
parameter first, which avoids breaking lots of assumptions in LLVM and
Clang.

Fixes PR15768 with the corresponding change in Clang.

Reviewers: ributzka, majnemer

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

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

10 years agoLTO itself hasn't depended on MCDisassembler any more.
NAKAMURA Takumi [Fri, 31 Jan 2014 17:40:11 +0000 (17:40 +0000)]
LTO itself hasn't depended on MCDisassembler any more.

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

10 years agollvm/tools: Prune redundant target_link_libraries.
NAKAMURA Takumi [Fri, 31 Jan 2014 17:40:06 +0000 (17:40 +0000)]
llvm/tools: Prune redundant target_link_libraries.

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

10 years ago[CMake] Move libgtest for external projects.
NAKAMURA Takumi [Fri, 31 Jan 2014 17:32:46 +0000 (17:32 +0000)]
[CMake] Move libgtest for external projects.

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

10 years agoAddLLVM.cmake: Untabify.
NAKAMURA Takumi [Fri, 31 Jan 2014 17:32:42 +0000 (17:32 +0000)]
AddLLVM.cmake: Untabify.

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

10 years agoHandleLLVMOptions.cmake: Typo, s/proerty/property/
NAKAMURA Takumi [Fri, 31 Jan 2014 17:32:36 +0000 (17:32 +0000)]
HandleLLVMOptions.cmake: Typo, s/proerty/property/

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

10 years ago[mips][msa] Add insert.d instruction.
Matheus Almeida [Fri, 31 Jan 2014 13:31:20 +0000 (13:31 +0000)]
[mips][msa] Add insert.d instruction.

This instruction is only available on Mips64 cores that implement the MSA ASE.

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

10 years agoUpdate FileCheck prefixes in preparation for the addition of Mips64 MSA tests.
Matheus Almeida [Fri, 31 Jan 2014 13:05:56 +0000 (13:05 +0000)]
Update FileCheck prefixes in preparation for the addition of Mips64 MSA tests.

No functional changes.

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

10 years ago[vectorizer] Tweak the way we do small loop runtime unrolling in the
Chandler Carruth [Fri, 31 Jan 2014 10:51:08 +0000 (10:51 +0000)]
[vectorizer] Tweak the way we do small loop runtime unrolling in the
loop vectorizer to not do so when runtime pointer checks are needed and
share code with the new (not yet enabled) load/store saturation runtime
unrolling. Also ensure that we only consider the runtime checks when the
loop hasn't already been vectorized. If it has, the runtime check cost
has already been paid.

I've fleshed out a test case to cover the scalar unrolling as well as
the vector unrolling and comment clearly why we are or aren't following
the pattern.

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

10 years agoSeparate x86 opcode maps and 0x66/0xf2/0xf3 prefixes from each other in the TSFlags...
Craig Topper [Fri, 31 Jan 2014 08:47:06 +0000 (08:47 +0000)]
Separate x86 opcode maps and 0x66/0xf2/0xf3 prefixes from each other in the TSFlags. This greatly simplifies the switch statements in the disassembler tables and the code emitters.

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

10 years agoMove REP out of the Prefix field of the X86 format. Give it its own bit. It had speci...
Craig Topper [Fri, 31 Jan 2014 07:00:55 +0000 (07:00 +0000)]
Move REP out of the Prefix field of the X86 format. Give it its own bit. It had special handling anyway and this enables a future patch.

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

10 years agoMove address override handling in X86CodeEmitter to a place where it works for VEX...
Craig Topper [Fri, 31 Jan 2014 05:42:35 +0000 (05:42 +0000)]
Move address override handling in X86CodeEmitter to a place where it works for VEX encoded instructions too. This allows 32-bit addressing to work in 64-bit mode.

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

10 years agoMove address override handling in X86MCCodeEmitter to a place where it works for...
Craig Topper [Fri, 31 Jan 2014 05:33:45 +0000 (05:33 +0000)]
Move address override handling in X86MCCodeEmitter to a place where it works for VEX encoded instructions too. This allows 32-bit addressing to work in 64-bit mode.

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

10 years agoFix a bug in gcov instrumentation introduced by r195513. <rdar://15930350>
Bob Wilson [Fri, 31 Jan 2014 05:24:01 +0000 (05:24 +0000)]
Fix a bug in gcov instrumentation introduced by r195513. <rdar://15930350>

The entry block of a function starts with all the static allocas. The change
in r195513 splits the block before those allocas, which has the effect of
turning them into dynamic allocas. That breaks all sorts of things. Change to
split after the initial allocas, and also add a comment explaining why the
block is split.

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

10 years ago[Sparc] Save and restore float registers that may be used for parameter passing.
Venkatraman Govindaraju [Fri, 31 Jan 2014 01:53:08 +0000 (01:53 +0000)]
[Sparc] Save and restore float registers that may be used for parameter passing.

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

10 years agoThis patch teaches the DAGCombiner how to fold insert_subvector nodes
Manman Ren [Fri, 31 Jan 2014 01:10:35 +0000 (01:10 +0000)]
This patch teaches the DAGCombiner how to fold insert_subvector nodes
when the input is a concat_vectors and the insert replaces one of the
concat halves:

Lower half: fold (insert_subvector (concat_vectors X, Y), Z) ->
(concat_vectors Z, Y)
Upper half: fold (insert_subvector (concat_vectors X, Y), Z) ->
(concat_vectors X, Z)

This can be seen with the following IR:

define <8 x float> @lower_half(<4 x float> %v1, <4 x float> %v2, <4 x
float> %v3) {
  %1 = shufflevector <4 x float> %v1, <4 x float> %v2, <8 x i32> <i32
0, i32 1, i32 2, i32 3, i32 4, i32 5, i32 6, i32 7>
  %2 = tail call <8 x float> @llvm.x86.avx.vinsertf128.ps.256(<8 x
float> %1, <4 x float> %v3, i8 0)

The vinsertf128 intrinsic is converted into an insert_subvector node
in SelectionDAGBuilder.cpp.

Using AVX, without the patch this generates two vinsertf128 instructions:

vinsertf128 $1, %xmm1, %ymm0, %ymm0
vinsertf128 $0, %xmm2, %ymm0, %ymm0

With the patch this is optimized into:

vinsertf128 $1, %xmm1, %ymm2, %ymm0

Patch by Robert Lougher.

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

10 years agoDAGCombine should not produce ISD::OR nodes after operation legalization if they...
Owen Anderson [Fri, 31 Jan 2014 00:51:43 +0000 (00:51 +0000)]
DAGCombine should not produce ISD::OR nodes after operation legalization if they're not legal.

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

10 years agoPGO branch weight: update edge weights in SelectionDAGBuilder.
Manman Ren [Fri, 31 Jan 2014 00:42:44 +0000 (00:42 +0000)]
PGO branch weight: update edge weights in SelectionDAGBuilder.

When converting from "or + br" to two branches, or converting from
"and + br" to two branches, we correctly update the edge weights of
the two branches.

The previous attempt at r200431 was reverted at r200434 because of
two testing case failures. I modified my patch a little, but forgot
to re-run "make check-all".

Testing case CodeGen/ARM/lsr-unfolded-offset.ll is updated because of
the patch's impact on branch probability which causes changes in
spill placement.

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

10 years agoAllow speculating llvm.sqrt, fma and fmuladd
Matt Arsenault [Fri, 31 Jan 2014 00:09:00 +0000 (00:09 +0000)]
Allow speculating llvm.sqrt, fma and fmuladd

This doesn't set errno, so this should be OK.
Also update the documentation to explicitly state
that errno are not set.

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

10 years agoAdd a link to a bug to a couple of FIXMEs
Timur Iskhodzhanov [Thu, 30 Jan 2014 23:14:38 +0000 (23:14 +0000)]
Add a link to a bug to a couple of FIXMEs

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

10 years ago[CMake] llvm_update_compile_flags: Honor LLVM_COMPILE_FLAGS.
NAKAMURA Takumi [Thu, 30 Jan 2014 22:55:25 +0000 (22:55 +0000)]
[CMake] llvm_update_compile_flags: Honor LLVM_COMPILE_FLAGS.

I accidentally mis-dropped LLVM_COMPILE_FLAGS in r200301. Sorry for that.

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

10 years agoHandleLLVMOptions.cmake: Typo in comment.
NAKAMURA Takumi [Thu, 30 Jan 2014 22:55:20 +0000 (22:55 +0000)]
HandleLLVMOptions.cmake: Typo in comment.

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

10 years ago[x86] Fix signed relocations for i64i32imm operands
David Woodhouse [Thu, 30 Jan 2014 22:20:41 +0000 (22:20 +0000)]
[x86] Fix signed relocations for i64i32imm operands

These should end up (in ELF) as R_X86_64_32S relocs, not R_X86_64_32.
Kill the horrid and incomplete special case and FIXME in
EncodeInstruction() and set things up so it can infer the signedness
from the ImmType just like it can the size and whether it's PC-relative.

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

10 years agoThis file already has a "using namespace object;", use it.
Rafael Espindola [Thu, 30 Jan 2014 21:51:42 +0000 (21:51 +0000)]
This file already has a "using namespace object;", use it.

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

10 years ago[AArch64] Custom lower concat_vector patterns with v4i16, v4i32, v8i8, v8i16, v16i8...
Chad Rosier [Thu, 30 Jan 2014 21:46:54 +0000 (21:46 +0000)]
[AArch64] Custom lower concat_vector patterns with v4i16, v4i32, v8i8, v8i16, v16i8 types.

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

10 years agoFix PR18381 - print a minimal diagnostic rather than assert on unresolved .secidx...
Timur Iskhodzhanov [Thu, 30 Jan 2014 21:13:05 +0000 (21:13 +0000)]
Fix PR18381 - print a minimal diagnostic rather than assert on unresolved .secidx target

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

10 years agoOnly ELF has a dynamic symbol table. Remove it from ObjectFile.
Rafael Espindola [Thu, 30 Jan 2014 20:45:33 +0000 (20:45 +0000)]
Only ELF has a dynamic symbol table. Remove it from ObjectFile.

COFF has only one symbol table.
MachO has a LC_DYSYMTAB, but that is not a symbol table, just extra info about
the one symbol table (LC_SYMTAB).
IR (coming soon) also has only one table.

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

10 years agoThis has been fixed.
Rafael Espindola [Thu, 30 Jan 2014 20:29:25 +0000 (20:29 +0000)]
This has been fixed.

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

10 years agoUse early returns and factor the object::Binary creation.
Rafael Espindola [Thu, 30 Jan 2014 19:24:00 +0000 (19:24 +0000)]
Use early returns and factor the object::Binary creation.

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

10 years ago[Stackmaps] Record the stack size of each function that contains a stackmap/patchpoin...
Juergen Ributzka [Thu, 30 Jan 2014 18:58:27 +0000 (18:58 +0000)]
[Stackmaps] Record the stack size of each function that contains a stackmap/patchpoint intrinsic.

Re-applying the patch, but this time without using AsmPrinter methods.

Reviewed by Andy

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

10 years agoComment out unused macro because of warning
Renato Golin [Thu, 30 Jan 2014 18:55:47 +0000 (18:55 +0000)]
Comment out unused macro because of warning

Modern compilers (Clang 3.4, GCC 4.8) warn on variadic macros being
introduced in C99, which produces a huge number of useless diagnostics
since this macro is unused in the whole project.

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

10 years agoExplicitly specify the CPU to avoid Atom-specific assembly mismatch
Timur Iskhodzhanov [Thu, 30 Jan 2014 17:53:45 +0000 (17:53 +0000)]
Explicitly specify the CPU to avoid Atom-specific assembly mismatch

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

10 years agoReenable ARM EHABI on Android.
Evgeniy Stepanov [Thu, 30 Jan 2014 14:18:25 +0000 (14:18 +0000)]
Reenable ARM EHABI on Android.

Broken in r200388.

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

10 years ago[mips] Fix typo.
Matheus Almeida [Thu, 30 Jan 2014 13:40:26 +0000 (13:40 +0000)]
[mips] Fix typo.

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

10 years agoRemove duplicate patterns
Craig Topper [Thu, 30 Jan 2014 07:19:10 +0000 (07:19 +0000)]
Remove duplicate patterns

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

10 years agoCouple minor formatting fixes to the XXXGenDAGISel.inc files.
Craig Topper [Thu, 30 Jan 2014 06:42:52 +0000 (06:42 +0000)]
Couple minor formatting fixes to the XXXGenDAGISel.inc files.

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

10 years agoRemove some AddedComplexity tags that were forcing priority for AVX over SSE. Use...
Craig Topper [Thu, 30 Jan 2014 06:26:25 +0000 (06:26 +0000)]
Remove some AddedComplexity tags that were forcing priority for AVX over SSE. Use predicates instead.

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

10 years agotools: fix Twine abuse
Saleem Abdulrasool [Thu, 30 Jan 2014 06:19:27 +0000 (06:19 +0000)]
tools: fix Twine abuse

utohexstr provides a temporary string, making it unsafe to use with the Twine
interface which will not copy the string.  Switch to using std::string.

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

10 years agotools: remove unnecessary typename
Saleem Abdulrasool [Thu, 30 Jan 2014 06:19:24 +0000 (06:19 +0000)]
tools: remove unnecessary typename

This is acceptted by clang and gcc, but MSVC seems to balk at it.  As it is
unneeded, simply drop it.  Fixes MSVC buildbots.

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

10 years agoRemove duplicate pattern and add predicate checks on other patterns.
Craig Topper [Thu, 30 Jan 2014 06:03:19 +0000 (06:03 +0000)]
Remove duplicate pattern and add predicate checks on other patterns.

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

10 years agotools: repair Windows build
Saleem Abdulrasool [Thu, 30 Jan 2014 05:20:31 +0000 (05:20 +0000)]
tools: repair Windows build

exp2 is not available on Windows.  Fortunately, we are calculating powers of 2
with expontents within the range of [4,12].  Simply use an equivalent bitshift
operation to repair compilation with MSVC which does not provide this standard
function.

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

10 years agoImplement SPARCv9 atomic_swap_64 with a pseudo.
Jakob Stoklund Olesen [Thu, 30 Jan 2014 04:48:46 +0000 (04:48 +0000)]
Implement SPARCv9 atomic_swap_64 with a pseudo.

The SWAP instruction only exists in a 32-bit variant, but the 64-bit
atomic swap can be implemented in terms of CASX, like the other atomic
rmw primitives.

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

10 years agoARM IAS: support .object_arch
Saleem Abdulrasool [Thu, 30 Jan 2014 04:46:41 +0000 (04:46 +0000)]
ARM IAS: support .object_arch

The .object_arch directive indicates an alternative architecture to be specified
in the object file.  The directive does *not* effect the enabled feature bits
for the object file generation.  This is particularly useful when the code
performs runtime detection and would like to indicate a lower architecture as
the requirements than the actual instructions used.

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

10 years agotools: add support for decoding ARM attributes
Saleem Abdulrasool [Thu, 30 Jan 2014 04:46:33 +0000 (04:46 +0000)]
tools: add support for decoding ARM attributes

Enhance the ARM specific parsing support in llvm-readobj to support attributes.
This allows for simpler tests to validate encoding of the build attributes as
specified in the ARM ELF specification.

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

10 years agoARM IAS: support .movsp
Saleem Abdulrasool [Thu, 30 Jan 2014 04:46:24 +0000 (04:46 +0000)]
ARM IAS: support .movsp

.movsp is an ARM unwinding directive that indicates to the unwinder that a
register contains an offset from the current stack pointer.  If the offset is
unspecified, it defaults to zero.

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

10 years agoARM: suuport .tlsdescseq directive
Saleem Abdulrasool [Thu, 30 Jan 2014 04:02:47 +0000 (04:02 +0000)]
ARM: suuport .tlsdescseq directive

This enhances the ARMAsmParser to handle .tlsdescseq directives.  This is a
slightly special relocation.  We must be able to generate them, but not consume
them in assembly.  The relocation is meant to assist the linker in generating a
TLS descriptor sequence.  The ELF target streamer is enhanced to append
additional fixups into the current segment and that is used to emit the new
R_ARM_TLS_DESCSEQ relocations.

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

10 years agoARM: support TLS descriptor relocations
Saleem Abdulrasool [Thu, 30 Jan 2014 04:02:38 +0000 (04:02 +0000)]
ARM: support TLS descriptor relocations

Add support for tlsdesc relocations which are part of the ABI, marked as
experimental.  These relocations permit the linker to perform TLS reference
optimizations.

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

10 years agoARM: support tlscall relocations
Saleem Abdulrasool [Thu, 30 Jan 2014 04:02:31 +0000 (04:02 +0000)]
ARM: support tlscall relocations

This adds support for TLS CALL relocations.  TLS CALL relocations are used to
indicate to the linker to generate appropriate entries to resolve TLS references
via an appropriate function invocation (e.g. __tls_get_addr(PLT)).

In order to accomodate the linker relaxation of the TLS access model for the
references (GD/LD -> IE, IE -> LE), the relocation addend must be incomplete.
This requires that the partial inplace value is also incomplete (i.e. 0).  We
simply avoid the offset value calculation at the time of the fixup adjustment in
the ARM assembler backend.

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

10 years agoRevert "[Stackmaps] Record the stack size of each function that contains a stackmap...
Juergen Ributzka [Thu, 30 Jan 2014 03:34:02 +0000 (03:34 +0000)]
Revert "[Stackmaps] Record the stack size of each function that contains a stackmap/patchpoint intrinsic."

This reverts commit r200444 to unbreak buildbots.

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

10 years ago[Stackmaps] Record the stack size of each function that contains a stackmap/patchpoin...
Juergen Ributzka [Thu, 30 Jan 2014 03:06:14 +0000 (03:06 +0000)]
[Stackmaps] Record the stack size of each function that contains a stackmap/patchpoint intrinsic.

Reviewed by Andy

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

10 years agoSimplify the handling of iterators in ObjectFile.
Rafael Espindola [Thu, 30 Jan 2014 02:49:50 +0000 (02:49 +0000)]
Simplify the handling of iterators in ObjectFile.

None of the object file formats reported error on iterator increment. In
retrospect, that is not too surprising: no object format stores symbols or
sections in a linked list or other structure that requires chasing pointers.
As a consequence, all error checking can be done on begin() and end().

This reduces the text segment of bin/llvm-readobj in my machine from 521233 to
518526 bytes.

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

10 years agoExtend the preserve_most/all calling convention description in LangRef about the
Juergen Ributzka [Thu, 30 Jan 2014 02:39:00 +0000 (02:39 +0000)]
Extend the preserve_most/all calling convention description in LangRef about the
fact that the argument registers will be preserved too.

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

10 years agoReland r200340 - 'Add line table debug info to COFF files when using a win32 triple'
Timur Iskhodzhanov [Thu, 30 Jan 2014 01:39:17 +0000 (01:39 +0000)]
Reland r200340 - 'Add line table debug info to COFF files when using a win32 triple'

This incorporates a couple of fixes reviewed at http://llvm-reviews.chandlerc.com/D2651

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

10 years agoadd a bunch of LLVM_OVERRIDE before I start refactoring these.
Rafael Espindola [Thu, 30 Jan 2014 01:17:42 +0000 (01:17 +0000)]
add a bunch of LLVM_OVERRIDE before I start refactoring these.

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

10 years agoRemove dead code.
Rafael Espindola [Thu, 30 Jan 2014 01:10:21 +0000 (01:10 +0000)]
Remove dead code.

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

10 years agoRevert r200431 due to bot failures.
Manman Ren [Thu, 30 Jan 2014 00:53:27 +0000 (00:53 +0000)]
Revert r200431 due to bot failures.

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

10 years agoFix TLS handling in ELF's getAddress and llvm-nm to print 'D' for it.
Rafael Espindola [Thu, 30 Jan 2014 00:42:30 +0000 (00:42 +0000)]
Fix TLS handling in ELF's getAddress and llvm-nm to print 'D' for it.

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

10 years agoPGO branch weight: update edge weights in SelectionDAGBuilder.
Manman Ren [Thu, 30 Jan 2014 00:24:37 +0000 (00:24 +0000)]
PGO branch weight: update edge weights in SelectionDAGBuilder.

When converting from "or + br" to two branches, or converting from
"and + br" to two branches, we correctly update the edge weights of
the two branches.

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

10 years agoPGO branch weight: update edge weights in IfConverter.
Manman Ren [Wed, 29 Jan 2014 23:18:47 +0000 (23:18 +0000)]
PGO branch weight: update edge weights in IfConverter.

This commit only handles IfConvertTriangle. To update edge weights
of a successor, one interface is added to MachineBasicBlock:
/// Set successor weight of a given iterator.
setSuccWeight(succ_iterator I, uint32_t weight)

An existing testing case test/CodeGen/Thumb2/v8_IT_5.ll is updated,
since we now correctly update the edge weights, the cold block
is placed at the end of the function and we jump to the cold block.

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

10 years agoMove range handling for a function to endFunction rather than
Eric Christopher [Wed, 29 Jan 2014 23:05:43 +0000 (23:05 +0000)]
Move range handling for a function to endFunction rather than
when we create the subprogram DIE.

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

10 years agoIf we use DW_AT_ranges we need to specify a base address that ranges
Eric Christopher [Wed, 29 Jan 2014 22:22:56 +0000 (22:22 +0000)]
If we use DW_AT_ranges we need to specify a base address that ranges
are relative to in the compile unit. Currently let's just use 0...

Thanks to Greg Clayton for the catch!

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

10 years agoTurn on CU ranges if we've got multiple compile units in the same
Eric Christopher [Wed, 29 Jan 2014 22:06:27 +0000 (22:06 +0000)]
Turn on CU ranges if we've got multiple compile units in the same
module since there's no range guarantee that we could make given
output order. This also fixes up the testcases that have multiple
CUs to have the correct range offset.

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

10 years agoMake the compile unit map a MapVector so that we can assume a stable
Eric Christopher [Wed, 29 Jan 2014 22:06:23 +0000 (22:06 +0000)]
Make the compile unit map a MapVector so that we can assume a stable
output ordering.

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

10 years agoFix formatting of comment.
Eric Christopher [Wed, 29 Jan 2014 22:06:21 +0000 (22:06 +0000)]
Fix formatting of comment.

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

10 years agollvm-cov: Accept the long forms of gcov options
Justin Bogner [Wed, 29 Jan 2014 21:31:47 +0000 (21:31 +0000)]
llvm-cov: Accept the long forms of gcov options

This is a bit imperfect, as these options don't show up in the help as
is and single dash variants are accepted, which differs from gcov.
Unfortunately, this seems to be as good as it gets with the cl::opt
machinery, so it'll do as an incremental step.

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