diff options
author | Rickard Green <[email protected]> | 2016-11-22 16:00:25 +0100 |
---|---|---|
committer | Rickard Green <[email protected]> | 2016-11-22 16:00:25 +0100 |
commit | 7a6973a2fa238468bb47d175908e99d230fbc0b1 (patch) | |
tree | 57a08ee1646796d6168624d438b74ab8ab828a4c /erts/emulator | |
parent | d82ed483ae6bae52745d2725017d77cb2c7810c7 (diff) | |
download | otp-7a6973a2fa238468bb47d175908e99d230fbc0b1.tar.gz otp-7a6973a2fa238468bb47d175908e99d230fbc0b1.tar.bz2 otp-7a6973a2fa238468bb47d175908e99d230fbc0b1.zip |
Fix GC when NifExport is in use
Diffstat (limited to 'erts/emulator')
-rw-r--r-- | erts/emulator/beam/erl_gc.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/erts/emulator/beam/erl_gc.c b/erts/emulator/beam/erl_gc.c index 6f641a1ea7..af799d09da 100644 --- a/erts/emulator/beam/erl_gc.c +++ b/erts/emulator/beam/erl_gc.c @@ -2325,6 +2325,11 @@ move_msgq_to_heap(Process *p) static Uint setup_rootset(Process *p, Eterm *objv, int nobj, Rootset *rootset) { + /* + * NOTE! + * Remember to update offset_rootset() when changing + * this function. + */ Roots* roots; Uint n; @@ -2969,6 +2974,12 @@ offset_one_rootset(Process *p, Sint offs, char* area, Uint area_size, offset_heap_ptr(objv, nobj, offs, area, area_size); } offset_off_heap(p, offs, area, area_size); + if (ERTS_PROC_GET_NIF_TRAP_EXPORT(p)) { + Eterm* argv; + int argc; + if (erts_setup_nif_gc(p, &argv, &argc)) + offset_heap_ptr(argv, argc, offs, area, area_size); + } } static void |