ARM: remove unnecessary state-tracking during frame lowering.

ResolveFrameIndex had what appeared to be a very nasty hack for when the
frame-index referred to a callee-saved register. In this case it "adjusted" the
offset so that the address was correct if (and only if) the MachineInstr
immediately followed the respective push.

This "worked" for all forms of GPR & DPR but was only ever used to set the
frame pointer itself, and once this was put in a more sensible location the
entire state-tracking machinery it relied on became redundant. So I stripped
it.

The only wrinkle is that "add r7, sp, #0" might theoretically be slower (need
an actual ALU slot) compared to "mov r7, sp" so I added a micro-optimisation
that also makes emitARMRegUpdate and emitT2RegUpdate also work when NumBytes ==
0.

No test changes since there shouldn't be any functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194025 91177308-0d34-0410-b5e6-96231b3b80d8
Revert r194019 to r194021, "Submit the basic port of the rest of ARM constant islands code to Mips."

It broke -Asserts build.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194026 91177308-0d34-0410-b5e6-96231b3b80d8
Add a runtime unrolling parameter to the LoopUnroll pass constructor

As with the other loop unrolling parameters (the unrolling threshold, partial
unrolling, etc.) runtime unrolling can now also be controlled via the
constructor. This will be necessary for moving non-trivial unrolling late in
the pass manager (after loop vectorization).

No functionality change intended.

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

ErrorOr had quiet a bit of complexity and indirection to be able to hold a user
type with the error.

That feature is not used anymore. This patch removes it, it will live in svn
history if we ever need it again.

If we do need it again, IMHO there is one thing that should be done
differently: Holding extra info in the error is not a property a function also
returning a value or not. The ability to hold extra info should be in the error
type and ErrorOr templated over it so that we don't need the funny looking
ErrorOr<void>.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194030 91177308-0d34-0410-b5e6-96231b3b80d8
Fix MSVC build by not putting an error_code directly in a union.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194032 91177308-0d34-0410-b5e6-96231b3b80d8
Support for reading run counts in llvm-cov.

This patch enables llvm-cov to correctly output the run count stored in
the GCDA file. GCOVProfiling currently does not generate this
information, so the GCDA run data had to be hacked on from a GCDA file
generated by gcc. This is corrected by a subsequent patch.

With the run and program data included, both llvm-cov and gcov produced
the same output.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194033 91177308-0d34-0410-b5e6-96231b3b80d8
llvm-cov: Added command-line option to change dir.

This will allow for much easier testing when the input files are in a
different folder from the test script.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194034 91177308-0d34-0410-b5e6-96231b3b80d8
Added basic unit test for llvm-cov.

This test compares the output of llvm-cov against a coverage file
generated by gcov.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194038 91177308-0d34-0410-b5e6-96231b3b80d8
Revert "Added basic unit test for llvm-cov."

This reverts commit 9cacd131c22b888303cb88e9a3235b2d7b2f19a1.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194039 91177308-0d34-0410-b5e6-96231b3b80d8
Revert "llvm-cov: Added command-line option to change dir."

This reverts commit d8acf0078cf363252727acff00f85ae8074f95b3.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194040 91177308-0d34-0410-b5e6-96231b3b80d8
Implemented aarch64 neon intrinsic vcopy_lane with float type.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194041 91177308-0d34-0410-b5e6-96231b3b80d8
Implement AArch64 post-index vector load/store multiple N-element structure class SIMD(lselem-post).
Including following 14 instructions:
4 ld1 insts: post-index load multiple 1-element structure to sequential 1/2/3/4 registers.
ld2/ld3/ld4: post-index load multiple N-element structure to sequential N registers (N=2,3,4).
4 st1 insts: post-index store multiple 1-element structure from sequential 1/2/3/4 registers.
st2/st3/st4: post-index store multiple N-element structure from sequential N registers (N = 2,3,4).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194043 91177308-0d34-0410-b5e6-96231b3b80d8
Lift alignment restrictions on load folding for a significant portion of AVX instructions.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194048 91177308-0d34-0410-b5e6-96231b3b80d8
Fix symbol defines in config.h.cmake

These were incorrectly pointing to HAVE_LOG despite being checked for
correctly in config-ix.cmake.

Patch by James Lyon!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194051 91177308-0d34-0410-b5e6-96231b3b80d8
Fix r194019 as requested by Eric Christopher.
Submit the basic port of the rest of ARM constant islands code to Mips. 
Two test cases are added which reflect the next level of functionality:
constants getting moved to water areas that are out of range from the
initial placement at the end of the function and basic blocks being split to
create water when none exists that can be used. There is a bunch of this
code that is not complete and has been marked with IN_PROGRESS. I will
finish cleaning this all up during the next week or two and submit the
rest of the test cases. I have elminated some code for dealing with
inline assembly because to me it unecessarily complicates things and
some of the newer features of llvm like function attributies and builtin
assembler give me better tools to solve the alignment issues created
there. Also, for Mips16 I even have the option of not doing constant
islands in the present of inline assembler if I chose. When everything
has been completed I will summarize the port and notify people that
are knowledgable regarding the ARM Constant Islands code so they can
review it in it's entirety if they wish.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194053 91177308-0d34-0410-b5e6-96231b3b80d8
[OCaml] Llvm_linker: do not use external in module interface

Workaround for an OCaml bug:
http://caml.inria.fr/mantis/view.php?id=4166

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194057 91177308-0d34-0410-b5e6-96231b3b80d8
[OCaml] Properly tag the custom operations of Llvm.llbuilder

All other custom operations tags have LLVM prefix.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194058 91177308-0d34-0410-b5e6-96231b3b80d8
Suppress OS crash dialog in llvm-rtdyld

All other tools have this -- it's needed to avoid hanging lit on Windows in
case of a crash.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194060 91177308-0d34-0410-b5e6-96231b3b80d8
X86 Disassembler: remove unused bool typedef-name


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194062 91177308-0d34-0410-b5e6-96231b3b80d8
[OCaml] (PR11717) Make declare_qualified_global respect address argument

Original patch by Jonathan Ragan-Kelley

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