Commit b7b27cc5 authored by Ryan Pavlik's avatar Ryan Pavlik Committed by Jakob Bornecrantz

include: Add XRT_DEBUGBREAK to xrt_cmmpiler.h

parent 891eb7f1
......@@ -42,3 +42,14 @@
#else
#define XRT_MAYBE_UNUSED
#endif
/*!
* @define XRT_DEBUGBREAK()
* To trigger a trap/break in the debugger.
*/
#if defined(__clang__) || defined(__GNUC__)
#define XRT_DEBUGBREAK() __builtin_trap()
#elif defined(_MSC_VER)
#include <intrin.h>
#define XRT_DEBUGBREAK() __debugbreak()
#endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment