ams: avoid UB infinite loops

This commit is contained in:
Michael Scire 2020-08-13 17:28:29 -07:00
parent 874208b44a
commit 51b5c3d87d
9 changed files with 17 additions and 10 deletions

View file

@ -65,3 +65,5 @@
#define AMS_ASSUME(expr) do { if (!static_cast<bool>((expr))) { __builtin_unreachable(); } } while (0)
#define AMS_CURRENT_FUNCTION_NAME __FUNCTION__
#define AMS_INFINITE_LOOP() do { __asm__ __volatile__("" ::: "memory"); } while (1)