Add an LLVM_BUILTIN_DEBUGTRAP macro.
authorMark Lacey <mark.lacey@apple.com>
Thu, 10 Mar 2016 05:15:03 +0000 (05:15 +0000)
committerMark Lacey <mark.lacey@apple.com>
Thu, 10 Mar 2016 05:15:03 +0000 (05:15 +0000)
commit125bb29c65320d8b37c76d37fbb5650453746146
treeaf147b46654bd3cae3096943713136f7e90c9c3d
parent03e41ee6a78064ae55ac87b66b1ac763c1c9456c
Add an LLVM_BUILTIN_DEBUGTRAP macro.

Summary:
This provides a macro that expands to __builtin_debugtrap() for clang,
and __debugbreak() for MSVC.

It intentionally expands to nothing for compilers that do not support a
similar mechanism that halts the debugger without otherwise crashing the
process.

Differential Revision: http://reviews.llvm.org/D18002

llvm-svn: 263095
llvm/include/llvm/Support/Compiler.h