toolchain: xcc: fake __builtin_umul[ll]_overflow

XCC doesn't provide these builtins so we have to define them
with minimal functionality for testing.

Signed-off-by: Daniel Leung <daniel.leung@intel.com>
This commit is contained in:
Daniel Leung 2018-10-19 09:22:47 -07:00 committed by Anas Nashif
parent fb50cac6b8
commit 51e47180f0

View file

@ -43,5 +43,7 @@
*/
#define __builtin_add_overflow(a, b, output) ({ *output = (a) + (b); 0; })
#define __builtin_mul_overflow(a, b, output) ({ *output = (a) * (b); 0; })
#define __builtin_umul_overflow(a, b, output) ({ *output = (a) * (b); 0; })
#define __builtin_umulll_overflow(a, b, output) ({ *output = (a) * (b); 0; })
#endif