mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-01-03 13:31:05 +00:00
Provide a portability macro for __builtin_trap.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@162300 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
799aacfb27
commit
74169b293f
@ -187,4 +187,13 @@
|
||||
# define LLVM_BUILTIN_UNREACHABLE __builtin_unreachable()
|
||||
#endif
|
||||
|
||||
// LLVM_BUILTIN_TRAP - On compilers which support it, expands to an expression
|
||||
// which causes the program to exit abnormally.
|
||||
#if defined(__clang__) || (__GNUC__ > 4) \
|
||||
|| (__GNUC__ == 4 && __GNUC_MINOR__ >= 3)
|
||||
# define LLVM_BUILTIN_TRAP __builtin_trap()
|
||||
#else
|
||||
# define LLVM_BUILTIN_TRAP *(volatile int*)0x11 = 0
|
||||
#endif
|
||||
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user