[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Guile-commits] 06/17: Move receive-values slow path out of line
From: |
Andy Wingo |
Subject: |
[Guile-commits] 06/17: Move receive-values slow path out of line |
Date: |
Wed, 11 Dec 2019 03:47:50 -0500 (EST) |
wingo pushed a commit to branch master
in repository guile.
commit 8d8c52dde9ac7212875a496c2165aa906ec84210
Author: Andy Wingo <address@hidden>
Date: Sat Dec 7 22:23:36 2019 +0100
Move receive-values slow path out of line
* libguile/jit.c (compile_receive_values, compile_receive_values_slow):
Move slow path out of line.
---
libguile/jit.c | 28 ++++++++++------------------
1 file changed, 10 insertions(+), 18 deletions(-)
diff --git a/libguile/jit.c b/libguile/jit.c
index b9eccad..bc0d994 100644
--- a/libguile/jit.c
+++ b/libguile/jit.c
@@ -1613,27 +1613,13 @@ compile_receive_values (scm_jit_state *j, uint32_t
proc, uint8_t allow_extra,
uint32_t nvalues)
{
jit_gpr_t t = T0;
- uint32_t saved_state = j->register_state;
if (allow_extra)
- {
- jit_reloc_t k;
- k = emit_branch_if_frame_locals_count_greater_than (j, t,
proc+nvalues-1);
- emit_store_current_ip (j, T0);
- emit_call_0 (j, scm_vm_intrinsics.error_not_enough_values);
- j->register_state = saved_state;
- jit_patch_here (j->jit, k);
- }
+ add_slow_path_patch
+ (j, emit_branch_if_frame_locals_count_less_than (j, t, proc + nvalues));
else
- {
- jit_reloc_t k;
- k = emit_branch_if_frame_locals_count_eq (j, t, proc + nvalues);
- emit_store_current_ip (j, T0);
- emit_call_1 (j, scm_vm_intrinsics.error_wrong_number_of_values,
- jit_operand_imm (JIT_OPERAND_ABI_UINT32, nvalues));
- j->register_state = saved_state;
- jit_patch_here (j->jit, k);
- }
+ add_slow_path_patch
+ (j, emit_branch_if_frame_locals_count_not_eq (j, t, proc + nvalues));
j->frame_size_min = proc + nvalues;
j->frame_size_max = allow_extra ? INT32_MAX : j->frame_size_min;
@@ -1643,6 +1629,12 @@ static void
compile_receive_values_slow (scm_jit_state *j, uint32_t proc, uint8_t
allow_extra,
uint32_t nvalues)
{
+ emit_store_current_ip (j, T0);
+ if (allow_extra)
+ emit_call_0 (j, scm_vm_intrinsics.error_not_enough_values);
+ else
+ emit_call_1 (j, scm_vm_intrinsics.error_wrong_number_of_values,
+ jit_operand_imm (JIT_OPERAND_ABI_UINT32, nvalues));
}
static void
- [Guile-commits] branch master updated (4a6a7e1 -> 114198d), Andy Wingo, 2019/12/11
- [Guile-commits] 02/17: Move add/immediate, sub/immediate slow paths out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 03/17: Move add, sub slow paths out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 04/17: Move handle-interrupts slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 10/17: Add subr-call out-of-line slow path, Andy Wingo, 2019/12/11
- [Guile-commits] 09/17: Move alloc-frame slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 13/17: Move assert-nargs-le slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 14/17: Move allocate-words/immediate slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 05/17: Move receive slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 07/17: Move assert-nargs-ee slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 06/17: Move receive-values slow path out of line,
Andy Wingo <=
- [Guile-commits] 08/17: Move assert-nargs-ge slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 11/17: Add out-of-line slow path for compose-continuation, Andy Wingo, 2019/12/11
- [Guile-commits] 12/17: Add out-of-line slow path for abort, Andy Wingo, 2019/12/11
- [Guile-commits] 15/17: Move allocate-pointerless-words/immediate slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 01/17: Add infrastructure for out-of-line JIT compilation of slow paths, Andy Wingo, 2019/12/11
- [Guile-commits] 17/17: Move less? slow path out of line, Andy Wingo, 2019/12/11
- [Guile-commits] 16/17: Add fixnum fast-path for =, Andy Wingo, 2019/12/11