ARM:
Removed extra stack frame object for fixed byval arguments,
VarArgsStyleRegisters invocation was reworked due to some improper usage in
past. PR14099 also demonstrates it.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166273 91177308-0d34-0410-b5e6-96231b3b80d8
LoopVectorize: Keep the IRBuilder on the stack.

No functionality change.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166274 91177308-0d34-0410-b5e6-96231b3b80d8
Move SplitBlockAndInsertIfThen to BasicBlockUtils.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166278 91177308-0d34-0410-b5e6-96231b3b80d8
[ASan] Support comments in ASan/TSan blacklist file as lines starting with #

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166283 91177308-0d34-0410-b5e6-96231b3b80d8
SCEVExpander: Don't crash when trying to merge two constant phis.

Just constant fold them so they can't cause any trouble. Fixes PR12627.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166286 91177308-0d34-0410-b5e6-96231b3b80d8
Lower BUILD_VECTOR to SHUFFLE + INSERT_VECTOR_ELT for X86

- If INSERT_VECTOR_ELT is supported (above SSE2, either by custom
  sequence of legal insn), transform BUILD_VECTOR into SHUFFLE +
  INSERT_VECTOR_ELT if most of elements could be built from SHUFFLE with few
  (so far 1) elements being inserted.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166288 91177308-0d34-0410-b5e6-96231b3b80d8
lit: Propagate TERM variable in environment, some tools can do really obscure
odd things if this is missing.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166289 91177308-0d34-0410-b5e6-96231b3b80d8
Fix some doc-os.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166290 91177308-0d34-0410-b5e6-96231b3b80d8
Indvars: Don't recursively delete instruction during BB iteration.

This can invalidate the iterators leading to use after frees and crashes.
Fixes PR12536.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166291 91177308-0d34-0410-b5e6-96231b3b80d8
[ms-inline asm] Add the isParsingInlineAsm() function to the MCAsmTargetParser.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166292 91177308-0d34-0410-b5e6-96231b3b80d8
This patch is to fix radar://8426430. It is about llvm support of __builtin_debugtrap()
which is supposed to consistently raise SIGTRAP across all systems. In contrast,
__builtin_trap() behave differently on different systems. e.g. it raises SIGTRAP on ARM, and
SIGILL on X86. The purpose of __builtin_debugtrap() is to consistently provide "trap"
functionality, in the mean time preserve the compatibility with on gcc on __builtin_trap().

  The X86 backend is already able to handle debugtrap(). This patch is to:
  1) make front-end recognize "__builtin_debugtrap()" (emboddied in the one-line change to Clang).
  2) In DAG legalization phase, by default, "debugtrap" will be replaced with "trap", which
     make the __builtin_debugtrap() "available" to all existing ports without the hassle of
     changing their code.
  3) If trap-function is specified (via -trap-func=xyz to llc), both __builtin_debugtrap() and
     __builtin_trap() will be expanded into the function call of the specified trap function.
    This behavior may need change in the future.

  The provided testing-case is to make sure 2) and 3) are working for ARM port, and we
already have a testing case for x86. 


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166300 91177308-0d34-0410-b5e6-96231b3b80d8
tests: Stop mangling '-vg' into the triple, we don't use this currently.
 - Also, lit is going to get a valgrind feature, instead.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166302 91177308-0d34-0410-b5e6-96231b3b80d8
lit: Add 'valgrind' and 'valgrind-leaks' features when valgrind is used.
 - These can be used with the XFAIL options.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166303 91177308-0d34-0410-b5e6-96231b3b80d8
lit: Remove support for XTARGET.

 - The XTARGET feature (inherited from old DG tests) was just confusing (and
   barely ever used). The same effect can now be achieved with a combination of
   the more useful REQUIRES and XFAIL.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166305 91177308-0d34-0410-b5e6-96231b3b80d8
lit: Rename the valgrind leaks feature to match what is currently used
(vg_leak).

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166306 91177308-0d34-0410-b5e6-96231b3b80d8
[ms-inline asm] Add a MCAsmParserSemaCallback to the TargetAsmParser.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166308 91177308-0d34-0410-b5e6-96231b3b80d8
Fix a build error for ocaml bindings that was introduced with the TargetData --> DataLayout changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166309 91177308-0d34-0410-b5e6-96231b3b80d8
SimplifyLibcalls: The return value of ffsll is always i32, even when the input is zero.

Fixes PR13028.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166313 91177308-0d34-0410-b5e6-96231b3b80d8
Add 'IntrNoReturn' for longjmp intrinsics



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@166314 91177308-0d34-0410-b5e6-96231b3b80d8
[ms-inline asm] Have the TargetParser callback to Sema to determine the size of
a memory operand.  Retain this information and then add the sizing directives
to the IR.  This allows the backend to do proper instruction selection.



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