aboutsummaryrefslogtreecommitdiffstats
path: root/src/bytecode.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/bytecode.c')
-rw-r--r--src/bytecode.c12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/bytecode.c b/src/bytecode.c
index 010477904be..45fe5d49154 100644
--- a/src/bytecode.c
+++ b/src/bytecode.c
@@ -313,9 +313,11 @@ struct byte_stack
313 Lisp_Object byte_string; 313 Lisp_Object byte_string;
314 const unsigned char *byte_string_start; 314 const unsigned char *byte_string_start;
315 315
316#if BYTE_MARK_STACK
316 /* The vector of constants used during byte-code execution. Storing 317 /* The vector of constants used during byte-code execution. Storing
317 this here protects it from GC because mark_byte_stack marks it. */ 318 this here protects it from GC because mark_byte_stack marks it. */
318 Lisp_Object constants; 319 Lisp_Object constants;
320#endif
319 321
320 /* Next entry in byte_stack_list. */ 322 /* Next entry in byte_stack_list. */
321 struct byte_stack *next; 323 struct byte_stack *next;
@@ -376,12 +378,12 @@ unmark_byte_stack (struct byte_stack *stack)
376} 378}
377 379
378 380
379/* Fetch the next byte from the bytecode stream */ 381/* Fetch the next byte from the bytecode stream. */
380 382
381#define FETCH *stack.pc++ 383#define FETCH *stack.pc++
382 384
383/* Fetch two bytes from the bytecode stream and make a 16-bit number 385/* Fetch two bytes from the bytecode stream and make a 16-bit number
384 out of them */ 386 out of them. */
385 387
386#define FETCH2 (op = FETCH, op + (FETCH << 8)) 388#define FETCH2 (op = FETCH, op + (FETCH << 8))
387 389
@@ -401,7 +403,7 @@ unmark_byte_stack (struct byte_stack *stack)
401#define DISCARD(n) (top -= (n)) 403#define DISCARD(n) (top -= (n))
402 404
403/* Get the value which is at the top of the execution stack, but don't 405/* Get the value which is at the top of the execution stack, but don't
404 pop it. */ 406 pop it. */
405 407
406#define TOP (*top) 408#define TOP (*top)
407 409
@@ -532,7 +534,9 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
532 534
533 stack.byte_string = bytestr; 535 stack.byte_string = bytestr;
534 stack.pc = stack.byte_string_start = SDATA (bytestr); 536 stack.pc = stack.byte_string_start = SDATA (bytestr);
537#if BYTE_MARK_STACK
535 stack.constants = vector; 538 stack.constants = vector;
539#endif
536 if (MAX_ALLOCA / word_size <= XFASTINT (maxdepth)) 540 if (MAX_ALLOCA / word_size <= XFASTINT (maxdepth))
537 memory_full (SIZE_MAX); 541 memory_full (SIZE_MAX);
538 top = alloca ((XFASTINT (maxdepth) + 1) * sizeof *top); 542 top = alloca ((XFASTINT (maxdepth) + 1) * sizeof *top);
@@ -748,7 +752,6 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
748 { 752 {
749 BEFORE_POTENTIAL_GC (); 753 BEFORE_POTENTIAL_GC ();
750 wrong_type_argument (Qlistp, v1); 754 wrong_type_argument (Qlistp, v1);
751 AFTER_POTENTIAL_GC ();
752 } 755 }
753 NEXT; 756 NEXT;
754 } 757 }
@@ -783,7 +786,6 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth,
783 { 786 {
784 BEFORE_POTENTIAL_GC (); 787 BEFORE_POTENTIAL_GC ();
785 wrong_type_argument (Qlistp, v1); 788 wrong_type_argument (Qlistp, v1);
786 AFTER_POTENTIAL_GC ();
787 } 789 }
788 NEXT; 790 NEXT;
789 } 791 }