From 223bcfecc9587b7e0f058236b85836a21651b534 Mon Sep 17 00:00:00 2001 From: Nickolas Lloyd Date: Sat, 31 Dec 2016 18:21:25 -0500 Subject: [PATCH] ; Store jit_function_t value instead of closure. ; * src/bytecode-jit.c (jit_byte_code__, jit_exec): Use the COMPILED_JIT_ID field for storing the jit_function_t value so that we can retrive the jit_context_t later for destruction. --- src/bytecode-jit.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/bytecode-jit.c b/src/bytecode-jit.c index 60984478f33..859df8b7c42 100644 --- a/src/bytecode-jit.c +++ b/src/bytecode-jit.c @@ -675,7 +675,7 @@ jit_exec (Lisp_Object byte_code, Lisp_Object args_template, ptrdiff_t nargs, Lis stack.next = byte_stack_list; byte_stack_list = &stack; Lisp_Object (*func)(Lisp_Object *) = - (Lisp_Object (*)(Lisp_Object *))AREF (byte_code, COMPILED_JIT_ID); + (Lisp_Object (*)(Lisp_Object *))jit_function_to_closure ((void *)AREF (byte_code, COMPILED_JIT_ID)); Lisp_Object ret = func (top); byte_stack_list = byte_stack_list->next; return ret; @@ -1588,7 +1588,7 @@ jit_byte_code__ (Lisp_Object byte_code) jit_context_build_end (ctxt.libjit_ctxt); if (err) emacs_abort (); - ASET (byte_code, COMPILED_JIT_ID, (Lisp_Object )jit_function_to_closure (ctxt.func)); + ASET (byte_code, COMPILED_JIT_ID, (Lisp_Object )ctxt.func); } } -- 2.39.5