aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator/beam
diff options
context:
space:
mode:
authorSverker Eriksson <[email protected]>2016-10-13 20:59:58 +0200
committerSverker Eriksson <[email protected]>2016-10-14 14:43:50 +0200
commit3582e6f420d84ddac64b55cb13100f1ae7f31b08 (patch)
tree6ece73414540dc8d923999b6ebb4e62f8e755b6d /erts/emulator/beam
parent7d5021bc9e1150b5d839438756851b3175f3ba85 (diff)
downloadotp-3582e6f420d84ddac64b55cb13100f1ae7f31b08.tar.gz
otp-3582e6f420d84ddac64b55cb13100f1ae7f31b08.tar.bz2
otp-3582e6f420d84ddac64b55cb13100f1ae7f31b08.zip
erts: Replace unsafe Module.first_hipe_ref
with hash table mod2mfa_tab
Diffstat (limited to 'erts/emulator/beam')
-rw-r--r--erts/emulator/beam/beam_bif_load.c2
-rw-r--r--erts/emulator/beam/module.c7
-rw-r--r--erts/emulator/beam/module.h3
3 files changed, 2 insertions, 10 deletions
diff --git a/erts/emulator/beam/beam_bif_load.c b/erts/emulator/beam/beam_bif_load.c
index 0a4d89d51b..c31abbb84f 100644
--- a/erts/emulator/beam/beam_bif_load.c
+++ b/erts/emulator/beam/beam_bif_load.c
@@ -1711,7 +1711,7 @@ BIF_RETTYPE erts_internal_purge_module_2(BIF_ALIST_2)
modp->old.catches = BEAM_CATCHES_NIL;
erts_remove_from_ranges(code);
#ifdef HIPE
- hipe_purge_module(modp);
+ hipe_purge_module(modp, is_blocking);
#endif
ERTS_BIF_PREP_RET(ret, am_true);
}
diff --git a/erts/emulator/beam/module.c b/erts/emulator/beam/module.c
index e9b18ba525..3e622c0f3a 100644
--- a/erts/emulator/beam/module.c
+++ b/erts/emulator/beam/module.c
@@ -91,9 +91,6 @@ static Module* module_alloc(Module* tmpl)
erts_module_instance_init(&obj->curr);
erts_module_instance_init(&obj->old);
obj->on_load = 0;
-#ifdef HIPE
- obj->first_hipe_mfa = NULL;
-#endif
DBG_TRACE_MFA(make_atom(obj->module), 0, 0, "module_alloc");
return obj;
}
@@ -128,6 +125,7 @@ void init_module_table(void)
erts_smp_atomic_init_nob(&tot_module_bytes, 0);
}
+
Module*
erts_get_module(Eterm mod, ErtsCodeIndex code_ix)
{
@@ -208,9 +206,6 @@ static ERTS_INLINE void copy_module(Module* dst_mod, Module* src_mod)
dst_mod->curr = src_mod->curr;
dst_mod->old = src_mod->old;
dst_mod->on_load = src_mod->on_load;
-#ifdef HIPE
- dst_mod->first_hipe_mfa = src_mod->first_hipe_mfa;
-#endif
}
void module_start_staging(void)
diff --git a/erts/emulator/beam/module.h b/erts/emulator/beam/module.h
index 9de610ccf7..1d6d9dd463 100644
--- a/erts/emulator/beam/module.h
+++ b/erts/emulator/beam/module.h
@@ -47,9 +47,6 @@ typedef struct erl_module {
struct erl_module_instance curr;
struct erl_module_instance old; /* protected by "old_code" rwlock */
struct erl_module_instance* on_load;
-#ifdef HIPE
- struct hipe_mfa_info* first_hipe_mfa;
-#endif
} Module;
void erts_module_instance_init(struct erl_module_instance* modi);