Skip to content

Commit

Permalink
0.9.7.15:
Browse files Browse the repository at this point in the history
	Mark as foreing function call before the first tagged Lisp
	register gets clobbered.
  • Loading branch information
Thiemo Seufer committed Dec 4, 2005
1 parent 92d1627 commit 3f13400
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 14 deletions.
27 changes: 14 additions & 13 deletions src/runtime/mips-assem.S
Original file line number Diff line number Diff line change
Expand Up @@ -122,9 +122,6 @@ symbol:
li reg_ALLOC, 1
.set reorder

/* Mark us as in Lisp land. */
sw zero, foreign_function_call_active

/* Load the allocation pointer, preserving the low-bit of alloc */
lw reg_BSP, dynamic_space_free_pointer
addu reg_ALLOC, reg_BSP
Expand Down Expand Up @@ -158,8 +155,12 @@ symbol:
/* Indirect closure */
lw reg_CODE, CLOSURE_FUN_OFFSET(reg_LEXENV)

/* Jump into lisp land. */
addu reg_LIP, reg_CODE, SIMPLE_FUN_CODE_OFFSET

/* Mark us as in Lisp land. */
sw zero, foreign_function_call_active

/* Jump into lisp land. */
jr reg_LIP

.align 3
Expand All @@ -180,16 +181,16 @@ lra: .word RETURN_PC_HEADER_WIDETAG
addu reg_ALLOC, 1
.set reorder

/* Mark us as in C land. */
sw reg_CSP, foreign_function_call_active

/* Save LISP state. */
subu reg_NL0, reg_ALLOC, 1
sw reg_NL0, dynamic_space_free_pointer
sw reg_BSP, current_binding_stack_pointer
sw reg_CSP, current_control_stack_pointer
sw reg_CFP, current_control_frame_pointer

/* Mark us as in C land. */
sw reg_CSP, foreign_function_call_active

/* Check for interrupt */
.set noreorder
bgez reg_NL4, 1f
Expand Down Expand Up @@ -251,6 +252,9 @@ lra: .word RETURN_PC_HEADER_WIDETAG
addu reg_ALLOC, 1
.set reorder

/* Mark us as in C land. */
sw reg_CSP, foreign_function_call_active

/* Convert the return address to an offset and save it on the stack. */
subu reg_NFP, reg_LIP, reg_CODE
addu reg_NFP, OTHER_POINTER_LOWTAG
Expand All @@ -265,9 +269,6 @@ lra: .word RETURN_PC_HEADER_WIDETAG
sw reg_CSP, current_control_stack_pointer
sw reg_CFP, current_control_frame_pointer

/* Mark us as in C land. */
sw reg_CSP, foreign_function_call_active

/* Check for interrupt */
.set noreorder
bgez reg_NL4, 1f
Expand Down Expand Up @@ -314,9 +315,6 @@ lra: .word RETURN_PC_HEADER_WIDETAG
li reg_ALLOC, 1
.set reorder

/* Mark us as in Lisp land. */
sw zero, foreign_function_call_active

/* Load the allocation pointer, preserving the low-bit of alloc */
lw reg_BSP, dynamic_space_free_pointer
addu reg_ALLOC, reg_BSP
Expand All @@ -341,6 +339,9 @@ lra: .word RETURN_PC_HEADER_WIDETAG
move reg_CSP, reg_CFP
move reg_CFP, reg_OCFP

/* Mark us as in Lisp land. */
sw zero, foreign_function_call_active

/* Return to LISP. */
jr reg_LIP
END(call_into_c)
Expand Down
2 changes: 1 addition & 1 deletion version.lisp-expr
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
"0.9.7.14"
"0.9.7.15"

0 comments on commit 3f13400

Please sign in to comment.