-
Notifications
You must be signed in to change notification settings - Fork 273
/
Copy pathallocainc.h
59 lines (37 loc) · 1.19 KB
/
allocainc.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
/*******************************************************************\
Module: Big Integers
Author: Daniel Kroening, [email protected]
\*******************************************************************/
// Whatever is necessary to use alloca().
#ifndef CPROVER_BIG_INT_ALLOCAINC_H
#define CPROVER_BIG_INT_ALLOCAINC_H
// clang-format off
#if defined linux || defined __linux__ \
|| defined __sun \
|| defined UWIN \
|| defined osf1 \
|| defined __MACH__ \
|| defined __CYGWIN__ \
|| defined __EMSCRIPTEN__
// clang-format on
# include <alloca.h>
#elif defined _MSC_VER \
|| defined __BORLANDC__ \
|| defined __MINGW32__
# include <malloc.h>
#elif defined __vax
// In vax-alloca.mar.
extern "C" void *alloca (unsigned);
#elif defined __VMS
// DEC CXX on VMS alpha.
# include <builtins.h>
# define alloca(N) __ALLOCA(N)
#elif defined __xlC__
# pragma alloca
# include <stdlib.h>
#elif defined __FCC__
# define alloca(X) __builtin_alloca(X)
#elif defined __FreeBSD__ || defined __FreeBSD_kernel__ || defined __OpenBSD__
# include <stdlib.h>
#endif
#endif // CPROVER_BIG_INT_ALLOCAINC_H