Commit Graph

95971 Commits

Author SHA1 Message Date
Daniel Sanders cba1922915 [mips][msa] Added support for matching slli, srai, and srli from normal IR (i.e. not intrinsics)
llvm-svn: 191285
2013-09-24 10:28:18 +00:00
Bill Wendling c63c30c9a2 Followup to r191252.
Make sure that the code that handles the constant addresses is run for the
GEPs. This just refactors that code and then calls it for the GEPs that are
collected during the iteration.

<rdar://problem/12445434>

llvm-svn: 191281
2013-09-24 07:19:30 +00:00
Craig Topper 9836f5995a Fix formatting to match coding standards.
llvm-svn: 191280
2013-09-24 06:21:04 +00:00
NAKAMURA Takumi b4efd90d2f llvm/test/CodeGen/AArch64/neon-scalar-reduce-pairwise.ll: Use -mtriple here, or aach64-pecoff might be misassumed on win32 hosts.
llvm-svn: 191275
2013-09-24 04:14:29 +00:00
NAKAMURA Takumi cc57dd58e0 DWARFTypeUnit::dump(): Use PRIx64 to format uint64_t.
llvm-svn: 191266
2013-09-24 03:23:07 +00:00
Jiangning Liu 63dc840fc5 Initial support for Neon scalar instructions.
Patch by Ana Pazos.

1.Added support for v1ix and v1fx types.
2.Added Scalar Pairwise Reduce instructions.
3.Added initial implementation of Scalar Arithmetic instructions.

llvm-svn: 191263
2013-09-24 02:47:27 +00:00
Michael Gottesman ec43974234 [stackprotector] Forgot to add in PR number to test case.
llvm-svn: 191261
2013-09-24 02:10:55 +00:00
Michael Gottesman 5e3600c1ce [stackprotector] Allow for copies from vreg -> vreg to be in a terminator sequence.
Sometimes a copy from a vreg -> vreg sneaks into the middle of a terminator
sequence. It is safe to slice this into the stack protector success bb.

This fixes PR16979.

llvm-svn: 191260
2013-09-24 01:50:26 +00:00
Eli Friedman 410393a15d Misc fixes for cpp backend.
PR17317.

llvm-svn: 191258
2013-09-24 00:36:09 +00:00
Eric Christopher 55364d71d0 Add namespaces to the list of items that we expose via pubnames.
llvm-svn: 191257
2013-09-24 00:17:57 +00:00
Eric Christopher fa986e7f18 Regenerate testcase from source.
llvm-svn: 191256
2013-09-24 00:17:54 +00:00
Eric Christopher 0840a5a69c Format the index entry kind string to align.
llvm-svn: 191255
2013-09-24 00:17:49 +00:00
David Blaikie 799856259f Make dwarfdump-type-units.test order-independent
The order in which the comdat type unit sections appear in the output is
unspecified and may vary from machine to machine.

llvm-svn: 191253
2013-09-24 00:13:23 +00:00
Bill Wendling 585a901a12 Selecting the address from a very long chain of GEPs can blow the stack.
The recursive nature of the address selection code can cause the stack to
explode if there is a long chain of GEPs. Convert the recursive bit into a
iterative method to avoid this.

<rdar://problem/12445434>

llvm-svn: 191252
2013-09-24 00:13:08 +00:00
David Blaikie 427e435b21 Comments for r191234 as suggested by Eric Christopher.
llvm-svn: 191244
2013-09-23 23:39:55 +00:00
Reid Kleckner 36cf1f02f8 Explicitly request unsigned enum types when desired
The underlying type of all plain enums in MSVC is 'int', even if the
enumerator contains large 32-bit unsigned values or values greater than
UINT_MAX.  The only way to get a large or unsigned enum type is to
request it explicitly with the C++11 strong enum types feature.

However, since LLVM isn't C++11 yet, I had to add a conditional
LLVM_ENUM_INT_TYPE to Compiler.h to control its usage.

The motivating true positive for this change is compiling PointerIntPair
with MSVC for win64.  The PointerIntMask value is supposed to be pointer
sized value of all ones with some low zeros.  Instead, it's truncated to
32-bits!  We are only saved later because it is sign extended back in
the AND with int64_t, and we happen to want all ones.

This silences lots of -Wmicrosoft warnings during a clang self-host
targeting Windows.

llvm-svn: 191241
2013-09-23 23:26:57 +00:00
Eric Christopher 6d0f1e683a Add more external types to the pubtypes table. Expand the asm
checking patch until we get full dumping support.

llvm-svn: 191239
2013-09-23 23:15:58 +00:00
David Blaikie 8de5e98f6a Unbreak the build (from r191233)since we're calling printf.
llvm-svn: 191238
2013-09-23 23:15:57 +00:00
Eric Christopher ccac5c4bf9 Rename IsStatic variable to Linkage in order to be a bit more descriptive.
llvm-svn: 191236
2013-09-23 22:59:14 +00:00
Eric Christopher b0fc0b9a7b Formatting.
llvm-svn: 191235
2013-09-23 22:59:11 +00:00
David Blaikie 03c089cf97 llvm-dwarfdump/libDebugInfo support for type units
llvm-svn: 191234
2013-09-23 22:44:47 +00:00
David Blaikie 07e22449a3 Exract most of DWARFCompileUnit into a new DWARFUnit to prepare for the coming DWARFTypeUnit.
llvm-svn: 191233
2013-09-23 22:44:40 +00:00
Reed Kotler e883f501bb Make nomips16 mask not repeat if it ends with a '.'.
This mask is purely for debugging and testing.

llvm-svn: 191231
2013-09-23 22:36:11 +00:00
Bill Wendling 8faa30ef4b Reformat code with clang-format.
llvm-svn: 191226
2013-09-23 20:57:47 +00:00
Eric Christopher 261d234302 Handle gnu pubtypes sections:
a) Make sure we are emitting the correct section in our section labels
when we begin the module.
b) Make sure we are emitting the correct pubtypes section in the
presence of gnu pubtypes.
c) For C++ struct, union, class, and enumeration types are default
external.

llvm-svn: 191225
2013-09-23 20:55:35 +00:00
Peter Collingbourne 213358aeaa Add a paragraph on prefix data layout.
llvm-svn: 191219
2013-09-23 20:14:21 +00:00
Rafael Espindola 6f5b0e3727 Remove remaining references to -O4.
Thanks to Hal Finkel for noticing it.

llvm-svn: 191216
2013-09-23 19:50:59 +00:00
Kay Tiong Khoo 9195a5b081 fix typo: than -> then
llvm-svn: 191214
2013-09-23 18:43:51 +00:00
Richard Mitton 089ed89e76 Fixed debug_aranges handling for common symbols.
The size of common symbols is now tracked correctly, so they can be listed in the arange section without needing knowledge of other following symbols.

.comm (and .lcomm) do not indicate to the system assembler any particular section to use, so we have to treat them as having no section.

Test case update to account for this.

llvm-svn: 191210
2013-09-23 17:56:20 +00:00
David Blaikie 1b5ee5d9f1 DebugInfo: Wrap section data and relocs together for dwarf dumping support
This is a small step that may enable some simplifications in producer
(DWARFContext) and consumer (DWARFCompileUnit and other places) by
making a more complete abstraction around the data and relocations for a
section. Small initial steps could include simple changes such as
passing the pair to DWARFCompileUnit's ctor rather than passing the data
and relocs separately. I don't intend to pursue any such changes
immediately, however.

The motivation for doing this now is that type unit dumping will need to
deal with these data+reloc pairs moreso than the existing dumping
support has needed to associate the data as type unit sections are named
the same (debug_types) and comdat group folded. So to implement dumping
and reloc handling we'll need a mapping of section->data+relocs.

llvm-svn: 191209
2013-09-23 17:42:01 +00:00
Ben Langmuir f1bd57814a Add sha intrinsic tests
These should have been included with r190864, but I forgot to use svn add.

llvm-svn: 191208
2013-09-23 16:57:52 +00:00
Arnold Schwaighofer 22639407d7 Revert "LoopVectorizer: Only allow vectorization of intrinsics."
Revert 191122 - with extra checks we are allowed to vectorize math library
function calls.

Standard library indentifiers are reserved names so functions with external
linkage must not overrided them. However, functions with internal linkage can.

Therefore, we can vectorize calls to math library functions with a check for
external linkage and matching signature. This matches what we do during
SelectionDAG building.

llvm-svn: 191206
2013-09-23 14:54:39 +00:00
Benjamin Kramer b517194f33 Expand test case a bit.
llvm-svn: 191205
2013-09-23 14:41:35 +00:00
Daniel Sanders 86d0c8d751 [mips][msa] Added support for matching addvi, and subvi from normal IR (i.e. not intrinsics)
llvm-svn: 191203
2013-09-23 14:29:55 +00:00
Amara Emerson 330afb54d3 [ARM] Split A/R class into separate subtarget features.
Patch by Bradley Smith.

llvm-svn: 191202
2013-09-23 14:26:15 +00:00
Benjamin Kramer 942dfe625b InstSimplify: Fold equality comparisons between non-inbounds GEPs.
Overflow doesn't affect the correctness of equalities. Computing this is cheap,
we just reuse the computation for the inbounds case and try to peel of more
non-inbounds GEPs. This pattern is unlikely to ever appear in code generated by
Clang, but SCEV occasionally produces it.

llvm-svn: 191200
2013-09-23 14:16:38 +00:00
Daniel Sanders a4c8f3a7b0 [mips][msa] Added support for matching insert and copy from normal IR (i.e. not intrinsics)
Changes to MIPS SelectionDAG:
* Added nodes VEXTRACT_[SZ]EXT_ELT to represent extract and extend in a single
  operation and implemented the DAG combines necessary to fold sign/zero
  extends into the extract.

llvm-svn: 191199
2013-09-23 14:03:12 +00:00
Daniel Sanders 766cb697a8 [mips][msa] Added support for matching pcnt from normal IR (i.e. not intrinsics)
llvm-svn: 191198
2013-09-23 13:40:21 +00:00
Daniel Sanders f7456c78f0 [mips][msa] Added support for matching nor from normal IR (i.e. not intrinsics)
llvm-svn: 191195
2013-09-23 13:22:24 +00:00
Daniel Sanders 8ca81e484e [mips][msa] Added support for matching and, or, and xor from normal IR (i.e. not intrinsics)
llvm-svn: 191194
2013-09-23 12:57:42 +00:00
Daniel Sanders 5f38701d5a Partially revert r191192: Fix -Wunused-variable error when assertions are disabled and -Werror is in use.
An unrelated change crept in because 'svn revert' isn't recursive by default.
The unrelated changes have been reverted.

llvm-svn: 191193
2013-09-23 12:33:38 +00:00
Daniel Sanders 3253de49c9 Fix -Wunused-variable error when assertions are disabled and -Werror is in use.
llvm-svn: 191192
2013-09-23 12:26:55 +00:00
Daniel Sanders 7a289d0e39 [mips][msa] Implemented build_vector using ldi, fill, and custom SelectionDAG nodes (VSPLAT and VSPLATD)
Note: There's a later patch on my branch that re-implements this to select
build_vector without the custom SelectionDAG nodes. The future patch avoids
the constant-folding problems stemming from the custom node (i.e. it doesn't
need to re-implement all the DAG combines related to BUILD_VECTOR).

Changes to MIPS specific SelectionDAG nodes:
* Added VSPLAT
    This is a special case of BUILD_VECTOR that covers the case the
    BUILD_VECTOR is a splat operation.
* Added VSPLATD
    This is a special case of VSPLAT that handles the cases when v2i64 is legal

llvm-svn: 191191
2013-09-23 12:02:46 +00:00
NAKAMURA Takumi c4aab49c84 llvm/test/tools/lto/lit.local.cfg: Add "MingW" for exclusion list.
llvm-svn: 191185
2013-09-23 09:03:48 +00:00
Craig Topper 51617c3d2c Add missing index comments to the left side of the DAG ISel matcher table for each individual case of SwitchOpcode/Type.
llvm-svn: 191181
2013-09-22 23:18:50 +00:00
Venkatraman Govindaraju 94629eb861 [Sparc] Use correct instruction pattern for CMPri.
llvm-svn: 191180
2013-09-22 18:54:54 +00:00
David Blaikie 4f099cb2ba Remove dead code
llvm-svn: 191179
2013-09-22 18:25:32 +00:00
David Blaikie ba860d74ba StringRef-ize some things
llvm-svn: 191178
2013-09-22 17:01:50 +00:00
Benjamin Kramer 8817cca5ce Provide basic type safety for array_pod_sort comparators.
This makes using array_pod_sort significantly safer. The implementation relies
on function pointer casting but that should be safe as we're dealing with void*
here.

llvm-svn: 191175
2013-09-22 14:09:50 +00:00
Benjamin Kramer 5626259506 Drop spurious handle in comment.
llvm-svn: 191172
2013-09-22 11:24:58 +00:00