aboutsummaryrefslogtreecommitdiffstats
path: root/erts/emulator
diff options
context:
space:
mode:
Diffstat (limited to 'erts/emulator')
-rw-r--r--erts/emulator/beam/export.c8
-rw-r--r--erts/emulator/beam/export.h6
-rw-r--r--erts/emulator/beam/module.c8
3 files changed, 11 insertions, 11 deletions
diff --git a/erts/emulator/beam/export.c b/erts/emulator/beam/export.c
index 31de141497..9656a67a4a 100644
--- a/erts/emulator/beam/export.c
+++ b/erts/emulator/beam/export.c
@@ -44,10 +44,10 @@ static erts_smp_atomic_t total_entries_bytes;
#include "erl_smp.h"
-erts_smp_rwmtx_t export_table_lock; /* Locks the secondary export table. */
+erts_smp_rwmtx_t export_staging_lock; /* Locks the staging export table. */
-#define export_read_lock() erts_smp_rwmtx_rlock(&export_table_lock)
-#define export_read_unlock() erts_smp_rwmtx_runlock(&export_table_lock)
+#define export_read_lock() erts_smp_rwmtx_rlock(&export_staging_lock)
+#define export_read_unlock() erts_smp_rwmtx_runlock(&export_staging_lock)
extern BeamInstr* em_call_error_handler;
extern BeamInstr* em_call_traced_function;
@@ -180,7 +180,7 @@ init_export_table(void)
rwmtx_opt.type = ERTS_SMP_RWMTX_TYPE_FREQUENT_READ;
rwmtx_opt.lived = ERTS_SMP_RWMTX_LONG_LIVED;
- erts_smp_rwmtx_init_opt(&export_table_lock, &rwmtx_opt, "export_tab");
+ erts_smp_rwmtx_init_opt(&export_staging_lock, &rwmtx_opt, "export_tab");
erts_smp_atomic_init_nob(&total_entries_bytes, 0);
f.hash = (H_FUN) export_hash;
diff --git a/erts/emulator/beam/export.h b/erts/emulator/beam/export.h
index f59c5e5c89..ef9c1d2680 100644
--- a/erts/emulator/beam/export.h
+++ b/erts/emulator/beam/export.h
@@ -76,9 +76,9 @@ Export *export_get(Export*);
void export_start_staging(void);
void export_end_staging(int commit);
-extern erts_smp_rwmtx_t export_table_lock;
-#define export_write_lock() erts_smp_rwmtx_rwlock(&export_table_lock)
-#define export_write_unlock() erts_smp_rwmtx_rwunlock(&export_table_lock)
+extern erts_smp_rwmtx_t export_staging_lock;
+#define export_write_lock() erts_smp_rwmtx_rwlock(&export_staging_lock)
+#define export_write_unlock() erts_smp_rwmtx_rwunlock(&export_staging_lock)
#include "beam_load.h" /* For em_* extern declarations */
#define ExportIsBuiltIn(EntryPtr) \
diff --git a/erts/emulator/beam/module.c b/erts/emulator/beam/module.c
index d3fd3f118d..6d5f1528b4 100644
--- a/erts/emulator/beam/module.c
+++ b/erts/emulator/beam/module.c
@@ -163,7 +163,7 @@ int module_table_sz(void)
static ErtsCodeIndex dbg_load_code_ix = 0;
#endif
-static int entries_at_start_load = 0;
+static int entries_at_start_staging = 0;
void module_start_staging(void)
{
@@ -199,8 +199,8 @@ void module_start_staging(void)
dst_mod->curr = src_mod->curr;
dst_mod->old = src_mod->old;
}
- entries_at_start_load = dst->entries;
+ entries_at_start_staging = dst->entries;
IF_DEBUG(dbg_load_code_ix = erts_staging_code_ix());
}
@@ -211,8 +211,8 @@ void module_end_staging(int commit)
if (!commit) { /* abort */
IndexTable* tab = &module_tables[erts_staging_code_ix()];
- ASSERT(entries_at_start_load <= tab->entries);
- index_erase_latest_from(tab, entries_at_start_load);
+ ASSERT(entries_at_start_staging <= tab->entries);
+ index_erase_latest_from(tab, entries_at_start_staging);
}
IF_DEBUG(dbg_load_code_ix = -1);