Amara Emerson [Mon, 7 Oct 2013 16:55:23 +0000 (16:55 +0000)]
[ARM] Improve build attributes emission.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192111
91177308-0d34-0410-b5e6-
96231b3b80d8
Chad Rosier [Mon, 7 Oct 2013 16:36:15 +0000 (16:36 +0000)]
[AArch64] Add support for NEON scalar arithmetic instructions:
SQDMULH, SQRDMULH, FMULX, FRECPS, and FRSQRTS.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192107
91177308-0d34-0410-b5e6-
96231b3b80d8
Joey Gouly [Mon, 7 Oct 2013 16:13:03 +0000 (16:13 +0000)]
[ARMv8] Add some disassembly tests for Thumb sevl/sevl.w
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192106
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Mon, 7 Oct 2013 15:42:22 +0000 (15:42 +0000)]
Revert r191088, corresponding to r191823 to re-enable llvm-lto on cygming.
r191088 is "llvm/tools/Makefile: Suppress building llvm-lto on cygming, for now, probably due to LTO.dll."
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192104
91177308-0d34-0410-b5e6-
96231b3b80d8
NAKAMURA Takumi [Mon, 7 Oct 2013 15:33:30 +0000 (15:33 +0000)]
Windows/Process.inc: Fix for +Asserts. &Buf[0] is not guaranteed if size is zero.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192103
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 7 Oct 2013 13:57:59 +0000 (13:57 +0000)]
Fix typo.
Thanks to Sean Silva for noticing it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192102
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 7 Oct 2013 13:54:50 +0000 (13:54 +0000)]
Remove dead code.
Support for exception handling in the legacy JIT was removed in r181354 and
this code was dead since then.
Thanks to Yaron Keren for noticing it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192101
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 7 Oct 2013 13:39:22 +0000 (13:39 +0000)]
Remove getEHExceptionRegister and getEHHandlerRegister.
They haven't been used for a long time. Patch by MathOnNapkins.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192099
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Mon, 7 Oct 2013 13:34:05 +0000 (13:34 +0000)]
Fix the documentation of getDefaultSubtargetFeatures.
Patch by David Nadlinger.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192098
91177308-0d34-0410-b5e6-
96231b3b80d8
Tim Northover [Mon, 7 Oct 2013 11:10:47 +0000 (11:10 +0000)]
ARM: allow cortex-m0 to use hint instructions
The hint instructions ("nop", "yield", etc) are mostly Thumb2-only, but have
been ported across to the v6M architecture. Fortunately, v6M seems to sit
nicely between v6 (thumb-1 only) and v6T2, so we can add a feature for it
fairly easily.
rdar://problem/
15144406
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192097
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Mon, 7 Oct 2013 09:52:36 +0000 (09:52 +0000)]
Windows: Be more explicit with Win32 APIs
This addresses several issues in a similar vein:
- Use the Unicode APIs when possible, running nm on clang shows that we
only use Unicode APIs except for FormatMessage, CreateSemaphore, and
GetModuleHandle. AFAICT, the latter two are coming from MinGW and
not LLVM itself.
- Make getMainExecutable more resilient. It previously considered
return values of zero from ::GetModuleFileNameA to be acceptable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192096
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Atanasyan [Mon, 7 Oct 2013 08:58:27 +0000 (08:58 +0000)]
[Mips] Teach llvm-readobj to print MIPS-specific ELF program headers.
The patch reviewed by Michael Spencer.
http://llvm-reviews.chandlerc.com/D1846
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192093
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Mon, 7 Oct 2013 07:19:47 +0000 (07:19 +0000)]
Remove some instructions that seem to only exist to trick the filtering checks in the disassembler table creation. Just fix up the filter to let the real instruction through instead.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192090
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Mon, 7 Oct 2013 06:10:45 +0000 (06:10 +0000)]
Remove FsMOVAPSrr and friends. They have no patterns and are no longer selected anywhere.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192089
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Mon, 7 Oct 2013 05:42:48 +0000 (05:42 +0000)]
Teach X86 asm parser that VMOVAPSrr and other VEX-encoded register to register moves should be switched from using the MRMSrcReg form to the MRMDestReg form if the source register is a 64-bit extended register and the destination register is not.
This allows the instruction to be encoded using the 2-byte VEX form instead of the 3-byte VEX form. The GNU assembler has similar behavior and instruction selection already does this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192088
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Mon, 7 Oct 2013 04:28:06 +0000 (04:28 +0000)]
Add disassembler support for long encodings for INC/DEC in 32-bit mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192086
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Mon, 7 Oct 2013 01:00:07 +0000 (01:00 +0000)]
Revert "Revert "Windows: Add support for unicode command lines""
This reverts commit r192070 which reverted r192069, I forgot to
regenerate the configure scripts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192079
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sun, 6 Oct 2013 22:38:19 +0000 (22:38 +0000)]
Fix some assert messages to say the correct opcode name. Looks like one assert got copy and pasted to many places.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192078
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Sun, 6 Oct 2013 20:44:34 +0000 (20:44 +0000)]
Revert "Windows: Add support for unicode command lines"
This is causing MinGW bots to fail.
This reverts commit r192069.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192070
91177308-0d34-0410-b5e6-
96231b3b80d8
David Majnemer [Sun, 6 Oct 2013 20:25:49 +0000 (20:25 +0000)]
Windows: Add support for unicode command lines
Summary:
The MSVCRT deliberately sends main() code-page specific characters.
This isn't too useful to LLVM as we end up converting the arguments to
UTF-16 and subsequently attempt to use the result as, for example, a
file name. Instead, we need to have the ability to access the Unicode
command line and transform it to UTF-8.
This has the distinct advantage over using the MSVC-specific wmain()
function as our entry point because:
- It doesn't work on cygwin.
- It only work on MinGW with caveats and only then on certain versions.
- We get to keep our entry point as main(). :)
N.B. This patch includes fixes to other parts of lib/Support/Windows
s.t. we would be able to take advantage of getting the Unicode paths.
E.G. clang spawning clang -cc1 would want to give it Unicode arguments.
Reviewers: aaron.ballman, Bigcheese, rnk, ruiu
Reviewed By: rnk
CC: llvm-commits, ygao
Differential Revision: http://llvm-reviews.chandlerc.com/D1834
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192069
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sun, 6 Oct 2013 15:10:43 +0000 (15:10 +0000)]
Add support for aliases with linkonce_odr.
This will be used to extend constructor aliases in clang.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192066
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sun, 6 Oct 2013 13:52:41 +0000 (13:52 +0000)]
Force a CPU that doesn't have AVX, otherwise this test fails.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192065
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sun, 6 Oct 2013 13:48:22 +0000 (13:48 +0000)]
X86: Don't fold spills into SSE operations if the stack is unaligned.
Regalloc can emit unaligned spills nowadays, but we can't fold the
spills into SSE ops if we can't guarantee alignment. PR12250.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192064
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Sun, 6 Oct 2013 13:11:09 +0000 (13:11 +0000)]
AVX-512: added scalar convert instructions and intrinsics.
Fixed load folding in VPERM2I instruction.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192063
91177308-0d34-0410-b5e6-
96231b3b80d8
Simon Atanasyan [Sun, 6 Oct 2013 08:49:41 +0000 (08:49 +0000)]
[Mips] Add MIPS program header types.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192059
91177308-0d34-0410-b5e6-
96231b3b80d8
Venkatraman Govindaraju [Sun, 6 Oct 2013 07:06:44 +0000 (07:06 +0000)]
[Sparc] Do not emit nop after fcmp* instruction with V9.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192056
91177308-0d34-0410-b5e6-
96231b3b80d8
Elena Demikhovsky [Sun, 6 Oct 2013 06:11:18 +0000 (06:11 +0000)]
AVX-512: fixed shuffle lowering
in case of BLEND and added VSHUFPS patterns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192055
91177308-0d34-0410-b5e6-
96231b3b80d8
Venkatraman Govindaraju [Sun, 6 Oct 2013 03:36:18 +0000 (03:36 +0000)]
[Sparc] Custom lower addc/adde/subc/sube on i64 in sparc64.
This is required because i64 is a legal type but addxcc/subxcc reads icc carry bit, which are 32 bit conditional codes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192054
91177308-0d34-0410-b5e6-
96231b3b80d8
Venkatraman Govindaraju [Sun, 6 Oct 2013 02:11:10 +0000 (02:11 +0000)]
[Sparc] Use addxcc/subxcc for adde/sube instead of addx/subx.
addx/subx does not modify conditional codes whereas addxcc/subxx does.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192053
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sat, 5 Oct 2013 20:20:51 +0000 (20:20 +0000)]
Add TBM instructions to loading folding tables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192046
91177308-0d34-0410-b5e6-
96231b3b80d8
Nick Lewycky [Sat, 5 Oct 2013 20:11:44 +0000 (20:11 +0000)]
Rename this feature to "cx16" to match gcc's flag name. Apparently these strings
are directly tied to the flag names in clang with no remapping in between?
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192044
91177308-0d34-0410-b5e6-
96231b3b80d8
Aaron Ballman [Sat, 5 Oct 2013 19:41:41 +0000 (19:41 +0000)]
Silencing an MSVC warning.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192042
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sat, 5 Oct 2013 19:33:37 +0000 (19:33 +0000)]
Emit a better error when running out of registers on inline asm.
The most likely case where this error happens is when the user specifies
too many register operands. Don't make it look like an internal LLVM bug
when we can see that the error is coming from an inline asm instruction.
For other instructions we keep the "ran out of registers" error.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192041
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sat, 5 Oct 2013 19:27:26 +0000 (19:27 +0000)]
Remove underscores from TBM instruction names for consistency with other instruction naming.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192040
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sat, 5 Oct 2013 19:22:59 +0000 (19:22 +0000)]
Remove unneeded TBM intrinsics. The arithmetic/logical operation patterns are sufficient.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192039
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sat, 5 Oct 2013 17:17:53 +0000 (17:17 +0000)]
Add an additional pattern for BLCI since opt can turn (not (add x, 1)) into (sub -2, x).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192037
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 5 Oct 2013 16:42:21 +0000 (16:42 +0000)]
Remove some really nasty uses of hasRawTextSupport.
When MC was first added, targets could use hasRawTextSupport to keep features
working before they were added to the MC interface.
The design goal of MC is to provide an uniform api for printing assembly and
object files. Short of relaxations and other corner cases, a object file is
just another representation of the assembly.
It was never the intention that targets would keep doing things like
if (hasRawTextSupport())
Set flags in one way.
else
Set flags in another way.
When they do that they create two code paths and the object file is no longer
just another representation of the assembly. This also then requires testing
with llc -filetype=obj, which is extremelly brittle.
This patch removes some of these hacks by replacing them with smaller ones.
The ARM flag setting is trivial, so I just moved it to the constructor. For
Mips, the patch adds two temporary hack directives that allow the assembly
to represent the same things as the object file was already able to.
The hope is that the mips developers will replace the hack directives with
the same ones that gas uses and drop the -print-hack-directives flag.
I will also try to implement a target streamer interface, so that we can
move this out of the common code.
In summary, for any new work, two rules of the thumb are
* Don't use "llc -filetype=obj" in tests.
* Don't add calls to hasRawTextSupport.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192035
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Sat, 5 Oct 2013 11:53:20 +0000 (11:53 +0000)]
lli: Plug leaks in the remote target external implementation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192031
91177308-0d34-0410-b5e6-
96231b3b80d8
Jiangning Liu [Sat, 5 Oct 2013 08:22:10 +0000 (08:22 +0000)]
Implement aarch64 neon instruction set AdvSIMD (Across).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192028
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Sat, 5 Oct 2013 05:38:16 +0000 (05:38 +0000)]
Add OPC_CheckChildSame0-3 to the DAG isel matcher. This replaces sequences of MoveChild, CheckSame, MoveParent. Saves 846 bytes from the X86 DAG isel matcher, ~300 from ARM, ~840 from Hexagon.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192026
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Sat, 5 Oct 2013 02:58:36 +0000 (02:58 +0000)]
Convert test to FileCheck.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192025
91177308-0d34-0410-b5e6-
96231b3b80d8
Venkatraman Govindaraju [Sat, 5 Oct 2013 02:29:47 +0000 (02:29 +0000)]
[Sparc] Use correct alignment while loading/storing fp128 values.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192023
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Sat, 5 Oct 2013 01:56:50 +0000 (01:56 +0000)]
Updating XFAILs for recent GOT tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192022
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Sat, 5 Oct 2013 01:53:19 +0000 (01:53 +0000)]
Adding tests for multiple GOTs with MCJIT
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192021
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Sat, 5 Oct 2013 01:52:09 +0000 (01:52 +0000)]
Adding multiple GOT handling to RuntimeDyldELF
Patch by Ashok Thirumurthi
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192020
91177308-0d34-0410-b5e6-
96231b3b80d8
Manman Ren [Sat, 5 Oct 2013 01:43:03 +0000 (01:43 +0000)]
Debug Info: In DIBuilder, the derived-from field of a DW_TAG_pointer_type
is updated to use DITypeRef.
Move isUnsignedDIType and getOriginalTypeSize from DebugInfo.h to be static
helper functions in DwarfCompileUnit. We already have a static helper function
"isTypeSigned" in DwarfCompileUnit, and a pointer to DwarfDebug is added to
resolve the derived-from field. All three functions need to go across link
for derived-from fields, so we need to get hold of a type identifier map.
A pointer to DwarfDebug is also added to DbgVariable in order to resolve the
derived-from field.
Debug info verifier is updated to check a derived-from field is a TypeRef.
Verifier will not go across link for derived-from fields, in debug info finder,
we go across the link to add derived-from fields to types.
Function getDICompositeType is only used by dragonegg and since dragonegg does
not generate identifier for types, we use an empty map to resolve the
derived-from field.
When printing a derived-from field, we use DITypeRef::getName to either return
the type identifier or getName of the DIType.
A paired commit at clang is required due to changes to DIBuilder.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192018
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 5 Oct 2013 00:39:55 +0000 (00:39 +0000)]
Reorganize some member variables and update a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192017
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 5 Oct 2013 00:32:34 +0000 (00:32 +0000)]
Fix one comment and update another. Slightly reformat.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192016
91177308-0d34-0410-b5e6-
96231b3b80d8
Venkatraman Govindaraju [Sat, 5 Oct 2013 00:31:41 +0000 (00:31 +0000)]
[Sparc] Respect hasHardQuad parameter correctly when lowering SINT_TO_FP with fp128 operand.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192015
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 5 Oct 2013 00:27:02 +0000 (00:27 +0000)]
Add a resolve method on CompileUnit that forwards to DwarfDebug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192014
91177308-0d34-0410-b5e6-
96231b3b80d8
Adrian Prantl [Sat, 5 Oct 2013 00:08:27 +0000 (00:08 +0000)]
Debug info: Don't crash in SelectionDAGISel when a vreg that is being
pointed to by a dbg_value belonging to a function argument is eliminated
during instruction selection.
rdar://problem/
15094721.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192011
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Sat, 5 Oct 2013 00:05:51 +0000 (00:05 +0000)]
Make a bunch of CompileUnit member functions private.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192009
91177308-0d34-0410-b5e6-
96231b3b80d8
Venkatraman Govindaraju [Fri, 4 Oct 2013 23:54:30 +0000 (23:54 +0000)]
[Sparc] Correct the floating point conditional code mapping in GetOppositeBranchCondition().
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192006
91177308-0d34-0410-b5e6-
96231b3b80d8
David Blaikie [Fri, 4 Oct 2013 23:52:02 +0000 (23:52 +0000)]
Minor formatting/comment rewording/etc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192005
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 23:49:31 +0000 (23:49 +0000)]
Remove odd use of this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192004
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 23:49:29 +0000 (23:49 +0000)]
Reformat some odd formattings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192003
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 23:49:26 +0000 (23:49 +0000)]
Tighten up some type arguments to functions. Where we expect a
scope, pass a scope.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192002
91177308-0d34-0410-b5e6-
96231b3b80d8
Hal Finkel [Fri, 4 Oct 2013 23:41:05 +0000 (23:41 +0000)]
UpdatePHINodes in BasicBlockUtils should not crash on duplicate predecessors
UpdatePHINodes has an optimization to reuse an existing PHI node, where it
first deletes all of its entries and then replaces them. Unfortunately, in the
case where we had duplicate predecessors (which are allowed so long as the
associated PHI entries have the same value), the loop removing the existing PHI
entries from the to-be-reused PHI would assert (if that PHI was not the one
which had the duplicates).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192001
91177308-0d34-0410-b5e6-
96231b3b80d8
David Blaikie [Fri, 4 Oct 2013 23:37:30 +0000 (23:37 +0000)]
Remove some dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@192000
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 23:35:30 +0000 (23:35 +0000)]
Pull this out for a bit of readability.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191999
91177308-0d34-0410-b5e6-
96231b3b80d8
David Blaikie [Fri, 4 Oct 2013 23:21:16 +0000 (23:21 +0000)]
Simplify setting of DIE tag for type DIEs by setting it in one* place.
* two actually due to some weird template thing... investigating that.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191998
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 23:15:52 +0000 (23:15 +0000)]
Reformat.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191997
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 23:06:14 +0000 (23:06 +0000)]
Formatting.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191995
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 22:54:28 +0000 (22:54 +0000)]
Prune includes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191994
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Fri, 4 Oct 2013 22:54:05 +0000 (22:54 +0000)]
forgot to remove this file as well
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191993
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Fri, 4 Oct 2013 22:52:31 +0000 (22:52 +0000)]
reverting per request
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191992
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 22:40:10 +0000 (22:40 +0000)]
Use addFlag to add the enum class attribute.
This has the side effect of using DW_FORM_flag_present on dwarf4 and above.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191991
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 22:40:05 +0000 (22:40 +0000)]
Use Die->addValue and DIEIntegerOne directly when we want to add
a flag. No functional change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191990
91177308-0d34-0410-b5e6-
96231b3b80d8
Hal Finkel [Fri, 4 Oct 2013 22:18:12 +0000 (22:18 +0000)]
Fix DAGCombiner::visitFP_EXTEND to ignore indexed loads
DAGCombiner::visitFP_EXTEND will apply the following transformation:
fold (fpext (load x)) -> (fpext (fptrunc (extload x)))
but the implementation does not handle indexed loads (pre/post inc.), but did
not specifically ignore them either (unlike for extending loads, which it
already ignored), causing an assert when the transformation was applied to an
indexed load. This is the minimal fix for correctness (causing the
transformation to be skipped for indexed loads).
Unfortunately, I don't have an in-tree test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191989
91177308-0d34-0410-b5e6-
96231b3b80d8
Reed Kotler [Fri, 4 Oct 2013 22:01:40 +0000 (22:01 +0000)]
Support tblockaddr for static compilation in Mips16.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191986
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Fri, 4 Oct 2013 21:40:54 +0000 (21:40 +0000)]
Fix object file writing in llvm-lto on Windows.
We were writing in text mode.
Patch by Greg Bedwell.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191985
91177308-0d34-0410-b5e6-
96231b3b80d8
Jack Carter [Fri, 4 Oct 2013 21:26:15 +0000 (21:26 +0000)]
[MC][AsmParser] Hook for post assembly file processing
This patch handles LLVM standalone assembler (llvm-mc) ELF flag setting based on input file
directive processing.
Mips assembly requires processing inline directives that directly and
indirectly affect the output ELF header flags. This patch handles one
".abicalls".
To process these directives we are following the model the code generator
uses by storing state in a container as we go through processing and when
we detect the end of input file processing, AsmParser is notified and we
update the ELF header flags through a MipsELFStreamer method with a call from
MCTargetAsmParser::emitEndOfAsmFile(MCStreamer &OutStreamer).
This patch will allow other targets the same functionality.
Jack
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191982
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Fri, 4 Oct 2013 20:53:49 +0000 (20:53 +0000)]
Attempting to fix lli build error
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191979
91177308-0d34-0410-b5e6-
96231b3b80d8
Akira Hatanaka [Fri, 4 Oct 2013 20:51:40 +0000 (20:51 +0000)]
[mips] Fix a bug in MipsLongBranch::replaceBranch, which was erasing
instructions in delay slots along with the original branch instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191978
91177308-0d34-0410-b5e6-
96231b3b80d8
Arnold Schwaighofer [Fri, 4 Oct 2013 20:39:16 +0000 (20:39 +0000)]
SLPVectorizer: Sort inputs to commutative binary operations
Sort the operands of the other entries in the current vectorization root
according to the first entry's operands opcodes.
%conv0 = uitofp ...
%load0 = load float ...
= fmul %conv0, %load0
= fmul %load0, %conv1
= fmul %load0, %conv2
Make sure that we recursively vectorize <%conv0, %conv1, %conv2> and <%load0,
%load0, %load0>.
This makes it more likely to obtain vectorizable trees. We have to be careful
when we sort that we don't destroy 'good' existing ordering implied by source
order.
radar://
15080067
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191977
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Fri, 4 Oct 2013 20:09:36 +0000 (20:09 +0000)]
Fixing container/pointer bug in remote-lli found by ASan
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191976
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 19:40:33 +0000 (19:40 +0000)]
Temporarily revert r176882 as it needs to be implemented in a different
way for all platforms.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191975
91177308-0d34-0410-b5e6-
96231b3b80d8
Benjamin Kramer [Fri, 4 Oct 2013 19:10:03 +0000 (19:10 +0000)]
lli: Check pipe creation for errors.
This is unlikely to ever fail, but ubuntu GCC warns when the return value is
unused.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191973
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Fri, 4 Oct 2013 17:30:14 +0000 (17:30 +0000)]
Add lto_codegen_add_dso_symbol to the export list.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191970
91177308-0d34-0410-b5e6-
96231b3b80d8
Eric Christopher [Fri, 4 Oct 2013 17:08:38 +0000 (17:08 +0000)]
Temporarily revert r191792 as it is causing some LTO debug failures
on platforms with relocations in debug info and also temporarily
revert r191800 due to conflicts with the revert of r191792.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191967
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Fri, 4 Oct 2013 16:53:02 +0000 (16:53 +0000)]
Fix comment
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191966
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Fri, 4 Oct 2013 16:53:00 +0000 (16:53 +0000)]
Fix indentation
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191965
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Fri, 4 Oct 2013 16:52:58 +0000 (16:52 +0000)]
Fix typo
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191964
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Fri, 4 Oct 2013 16:52:56 +0000 (16:52 +0000)]
ARM: optimizeSelect has to consider the previous register class
optimizeSelect folds (predicated) copy instructions, it must not ignore
the original register class of the operand when replacing the register
with the copies dest register.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191963
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Fri, 4 Oct 2013 16:52:54 +0000 (16:52 +0000)]
ARM: do not add a regmask for TAILJUMPs
The jump doesn't really kill the registers, the following call does but
we never get back anyway.
This avoids some verify-machineinstrs problems when TAILJUMPs are
if-converted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191962
91177308-0d34-0410-b5e6-
96231b3b80d8
Matthias Braun [Fri, 4 Oct 2013 16:52:51 +0000 (16:52 +0000)]
ARM: preserve undef flag in pseudo instruction expanders
Copy over the whole register machine operand instead of creating a new one
with an incomplete set of flags.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191961
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Fri, 4 Oct 2013 14:53:58 +0000 (14:53 +0000)]
Fix this test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191958
91177308-0d34-0410-b5e6-
96231b3b80d8
Alp Toker [Fri, 4 Oct 2013 10:59:13 +0000 (10:59 +0000)]
Revert "Test commit to check e-mail address. Please discard this."
This reverts commit r191942.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191949
91177308-0d34-0410-b5e6-
96231b3b80d8
Alexey Samsonov [Fri, 4 Oct 2013 10:41:38 +0000 (10:41 +0000)]
Restore LLVM_BUILD_RUNTIME option that was deleted in r191835, but is still used to control building of compiler-rt and libcxx
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191948
91177308-0d34-0410-b5e6-
96231b3b80d8
Jiangning Liu [Fri, 4 Oct 2013 09:20:44 +0000 (09:20 +0000)]
Implement aarch64 neon instruction set AdvSIMD (3V elem).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191944
91177308-0d34-0410-b5e6-
96231b3b80d8
Jin-Gu Kang [Fri, 4 Oct 2013 06:53:57 +0000 (06:53 +0000)]
Test commit to check e-mail address. Please discard this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191942
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 4 Oct 2013 05:52:17 +0000 (05:52 +0000)]
Revert r191940 to see if it fixes the build bots.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191941
91177308-0d34-0410-b5e6-
96231b3b80d8
Craig Topper [Fri, 4 Oct 2013 05:22:20 +0000 (05:22 +0000)]
Add OPC_CheckChildSame0-3 to the DAG isel matcher. This replaces sequences of MoveChild, CheckSame, MoveParent. Saves 846 bytes from the X86 DAG isel matcher, ~300 from ARM, ~840 from Hexagon.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191940
91177308-0d34-0410-b5e6-
96231b3b80d8
David Blaikie [Fri, 4 Oct 2013 01:39:59 +0000 (01:39 +0000)]
DebugInfo: Fix ordering of members after r191928
In the case (shown in the attached test) where a member function
definition was emitted into debug info the following could occur:
1) build the debug info for the member function definition
2) in (1), build the debug info for the member function declaration
3) construct and add the member function declaration DIE
4) add it to its context
5) build its context (the type it is a member of)
6) construct the members and add them to the type
7) except don't add member functions because "getOrCreateSubprogram"
adds the function to its parent anyway
8) except we're only partway through building this subprogram
declaration so it hasn't been added yet - but we returned the partially
constructed DIE (since it's already in the MDNode->DIE mapping to avoid
infinitely recursing trying to create the member function DIE)
9) once the type is constructed, add the member function to it
10) now the members are out of order (the member function being defined
is listed as the last member, even though it was declared as the first)
To avoid this, construct the context of the subprogram DIE before we
query to see if it exists. That way we never end up creating it before
creating its context and ending up in this situation.
Alternatively, the type construction that visits/builds all the members
could call something like getOrCreateSubprogram, but that doesn't ever
do the "add to context" step. Then the type building code would always
be responsible for adding members (and the subprogram "addToContextDIE"
would no-op because the context building would have added the subprogram
declaration to the type/context DIE already).
(the test cases updated were overly-sensitive to offsets or abbreviation
numbers. We don't have a nice way to make these tests more robust as yet
- multiline FileCheck matches would be required)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191939
91177308-0d34-0410-b5e6-
96231b3b80d8
Andrew Kaylor [Fri, 4 Oct 2013 00:49:38 +0000 (00:49 +0000)]
Adding support and tests for multiple module handling in lli
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191938
91177308-0d34-0410-b5e6-
96231b3b80d8
Richard Mitton [Thu, 3 Oct 2013 22:07:08 +0000 (22:07 +0000)]
Fixed a bug with section names containing special characters.
Changed the dwarf aranges code to not use getLabelEndName, as it turns out it's not reliable to call that given user-defined section names. Section names can have characters in that aren't representable as symbol names.
The dwarf-aranges test case has been updated to include a special character, to check this.
This fixes pr17416.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191932
91177308-0d34-0410-b5e6-
96231b3b80d8
Owen Anderson [Thu, 3 Oct 2013 21:08:05 +0000 (21:08 +0000)]
Pull fptrunc's upwards through selects when one of the select's selectands was a constant. This has a number of benefits, including producing small immediates (easier to materialize, smaller constant pools) as well as being more likely to allow the fptrunc to fuse with a preceding instruction (truncating selects are unusual).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191929
91177308-0d34-0410-b5e6-
96231b3b80d8
David Blaikie [Thu, 3 Oct 2013 20:07:20 +0000 (20:07 +0000)]
DebugInfo: Avoid redundantly adding child DIEs to parents.
DIE::addChild had a shortcircuit that silently no-op'd when a child was
readded to the same parent. This hid some quirky/redundant code in
DwarfDebug/CompileUnit. By removing that functionality and replacing it
with an assert I was able to find and cleanup those cases, mostly
centering around adding members to types in various circumstances.
1) The original oddity I noticed while working on type units (which
actually was helping me in the short term, by accident) was the
addToContextOwner call in constructTypeDIE. This call was completely
bogus (why was it only done for non-virtual types? what relevance does
that have at all) and redundant with the more uniform addToContextOwner
made in getOrCreateTypeDIE.
2) If a member function definition was visited (createSubprogramDIE), it
would attempt to build the member function declaration. The declaration
DIE would then be added to its context, but in building the context (the
type for which this function is a member) the members of the type would
be added to the type automatically, so by the time the context was
constructed, the member function was already associated with it.
3) The same as (2) but without the member function being constructed
first. Whenever a type was constructed, the members would be created and
member functions would be created by getOrCreateSubprogramDIE - this
would lead to the subprogram being added to the (incomplete) type
already, then the general member-construction code would add it again.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191928
91177308-0d34-0410-b5e6-
96231b3b80d8
Matt Arsenault [Thu, 3 Oct 2013 19:50:01 +0000 (19:50 +0000)]
Rename DataLayout variables TD -> DL
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191927
91177308-0d34-0410-b5e6-
96231b3b80d8
Rafael Espindola [Thu, 3 Oct 2013 18:29:09 +0000 (18:29 +0000)]
Optimize linkonce_odr unnamed_addr functions during LTO.
Generalize the API so we can distinguish symbols that are needed just for a DSO
symbol table from those that are used from some native .o.
The symbols that are only wanted for the dso symbol table can be dropped if
llvm can prove every other dso has a copy (linkonce_odr) and the address is not
important (unnamed_addr).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@191922
91177308-0d34-0410-b5e6-
96231b3b80d8