summaryrefslogtreecommitdiff
path: root/runtime/calloc.c
diff options
context:
space:
mode:
authorGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2007-08-04 07:27:50 +0000
committerGravatar xleroy <xleroy@fca1b0fc-160b-0410-b1d3-a4f43f01ea2e>2007-08-04 07:27:50 +0000
commit355b4abcee015c3fae9ac5653c25259e104a886c (patch)
treecfdb5b17f36b815bb358699cf420f64eba9dfe25 /runtime/calloc.c
parent22ff08b38616ceef336f5f974d4edc4d37d955e8 (diff)
Fusion des modifications faites sur les branches "tailcalls" et "smallstep".
En particulier: - Semantiques small-step depuis RTL jusqu'a PPC - Cminor independant du processeur - Ajout passes Selection et Reload - Ajout des langages intermediaires CminorSel et LTLin correspondants - Ajout des tailcalls depuis Cminor jusqu'a PPC git-svn-id: https://yquem.inria.fr/compcert/svn/compcert/trunk@384 fca1b0fc-160b-0410-b1d3-a4f43f01ea2e
Diffstat (limited to 'runtime/calloc.c')
-rw-r--r--runtime/calloc.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/runtime/calloc.c b/runtime/calloc.c
new file mode 100644
index 0000000..2526ceb
--- /dev/null
+++ b/runtime/calloc.c
@@ -0,0 +1,13 @@
+#include <stdio.h>
+#include <stddef.h>
+#include <stdlib.h>
+
+void * compcert_alloc(int sz)
+{
+ void * res = malloc(sz);
+ if (res == NULL) {
+ fprintf(stderr, "Out of memory in compcert_alloc().\n");
+ abort();
+ }
+ return res;
+}