aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam/erl_message.h
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2015-03-03 19:32:00 +0100
committerBjörn-Egil Dahlberg <[email protected]>2015-03-12 19:15:32 +0100
commitf8dbf0c0ff3bd68d720faca230356d281e4e3e42 (patch)
tree952117ca7a0f2d09a9a2c8b3431a33ebda42328c /erts/emulator/beam/erl_message.h
parent412c30b4dcdb8388b7472c8abb328f2a2fce92c0 (diff)
downloadotp-f8dbf0c0ff3bd68d720faca230356d281e4e3e42.tar.gz
otp-f8dbf0c0ff3bd68d720faca230356d281e4e3e42.tar.bz2
otp-f8dbf0c0ff3bd68d720faca230356d281e4e3e42.zip
First stab at binary_to_term for hamt
with over estimation of heap size.
Diffstat (limited to 'erts/emulator/beam/erl_message.h')
-rw-r--r--erts/emulator/beam/erl_message.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/erts/emulator/beam/erl_message.h b/erts/emulator/beam/erl_message.h
index 0f3bb8d281..ece75a5ee4 100644
--- a/erts/emulator/beam/erl_message.h
+++ b/erts/emulator/beam/erl_message.h
@@ -68,6 +68,23 @@ struct erl_heap_fragment {
Eterm mem[1]; /* Data */
};
+typedef struct {
+ Process* p;
+ Eterm* hp;
+ Eterm* hp_end;
+ /* more to come... */
+} ErtsHeapFactory;
+
+Eterm* erts_produce_heap(ErtsHeapFactory*, Uint need, Uint xtra);
+#ifdef CHECK_FOR_HOLES
+# define ERTS_FACTORY_HOLE_CHECK(f) do { \
+ if ((f)->p) erts_check_for_holes((f)->p); \
+ } while (0)
+#else
+# define ERTS_FACTORY_HOLE_CHECK(p)
+#endif
+
+
typedef struct erl_mesg {
struct erl_mesg* next; /* Next message */
union {