From 2feef375870082542a17412e5e9da23dee0425ac Mon Sep 17 00:00:00 2001 From: Peter Bex Date: Sun, 7 Aug 2016 21:32:59 +0200 Subject: [PATCH 1/2] Change bignum representation to use a custom type. Instead of using a generic record type with a "bignum_type_tag" symbol slot, we use a custom object containing only a pointer to the actual bignum data. This saves at least one slot when pre-allocating for a call to an arithmetic operator. In case of the generic operators, this can save up to four slots (maximum size is allotted for a complex number consisting of two ratnums, each containing two bignums; so four bignums in total). Less allocation results in slower nursery growth, which in turn means minor garbage collections will happen less frequently. The change in object type also means we need to do one less check in the bignum? predicate. --- c-backend.scm | 4 ++-- c-platform.scm | 22 ++++++++--------- chicken.h | 42 ++++++++++++++++++-------------- library.scm | 24 +++++++++---------- runtime.c | 22 +++++++---------- types.db | 76 +++++++++++++++++++++++++++++----------------------------- 6 files changed, 96 insertions(+), 94 deletions(-) diff --git a/c-backend.scm b/c-backend.scm index 6e271e4..f58d3d4 100644 --- a/c-backend.scm +++ b/c-backend.scm @@ -671,9 +671,9 @@ (define (literal-size lit) (cond ((immediate? lit) 0) - ((big-fixnum? lit) 3) ; immediate if fixnum, bignum see below + ((big-fixnum? lit) 2) ; immediate if fixnum, bignum see below ((string? lit) 0) ; statically allocated - ((bignum? lit) 3) ; internal vector statically allocated + ((bignum? lit) 2) ; internal vector statically allocated ((flonum? lit) words-per-flonum) ((symbol? lit) 7) ; size of symbol, and possibly a bucket ((pair? lit) (+ 3 (literal-size (car lit)) (literal-size (cdr lit)))) diff --git a/c-platform.scm b/c-platform.scm index 7e4528b..d929651 100644 --- a/c-platform.scm +++ b/c-platform.scm @@ -584,11 +584,11 @@ (rewrite 'abs 14 'fixnum 1 "C_fixnum_abs" "C_fixnum_abs") -(rewrite 'chicken.bitwise#bitwise-and 21 -1 "C_fixnum_and" "C_u_fixnum_and" "C_s_a_i_bitwise_and" 6) -(rewrite 'chicken.bitwise#bitwise-xor 21 0 "C_fixnum_xor" "C_fixnum_xor" "C_s_a_i_bitwise_xor" 6) -(rewrite 'chicken.bitwise#bitwise-ior 21 0 "C_fixnum_or" "C_u_fixnum_or" "C_s_a_i_bitwise_ior" 6) +(rewrite 'chicken.bitwise#bitwise-and 21 -1 "C_fixnum_and" "C_u_fixnum_and" "C_s_a_i_bitwise_and" 5) +(rewrite 'chicken.bitwise#bitwise-xor 21 0 "C_fixnum_xor" "C_fixnum_xor" "C_s_a_i_bitwise_xor" 5) +(rewrite 'chicken.bitwise#bitwise-ior 21 0 "C_fixnum_or" "C_u_fixnum_or" "C_s_a_i_bitwise_ior" 5) -(rewrite 'chicken.bitwise#bitwise-not 22 1 "C_s_a_i_bitwise_not" #t 6 "C_fixnum_not") +(rewrite 'chicken.bitwise#bitwise-not 22 1 "C_s_a_i_bitwise_not" #t 5 "C_fixnum_not") (rewrite 'chicken.flonum#fp+ 16 2 "C_a_i_flonum_plus" #f words-per-flonum) (rewrite 'chicken.flonum#fp- 16 2 "C_a_i_flonum_difference" #f words-per-flonum) @@ -674,12 +674,12 @@ (rewrite 'lcm 18 1) (rewrite 'list 18 '()) -(rewrite '+ 16 2 "C_s_a_i_plus" #t 36) -(rewrite '- 16 2 "C_s_a_i_minus" #t 36) -(rewrite '* 16 2 "C_s_a_i_times" #t 40) -(rewrite 'quotient 16 2 "C_s_a_i_quotient" #t 6) -(rewrite 'remainder 16 2 "C_s_a_i_remainder" #t 6) -(rewrite 'modulo 16 2 "C_s_a_i_modulo" #t 6) +(rewrite '+ 16 2 "C_s_a_i_plus" #t 32) +(rewrite '- 16 2 "C_s_a_i_minus" #t 32) +(rewrite '* 16 2 "C_s_a_i_times" #t 36) +(rewrite 'quotient 16 2 "C_s_a_i_quotient" #t 5) +(rewrite 'remainder 16 2 "C_s_a_i_remainder" #t 5) +(rewrite 'modulo 16 2 "C_s_a_i_modulo" #t 5) (rewrite '= 17 2 "C_i_nequalp") (rewrite '> 17 2 "C_i_greaterp") @@ -829,7 +829,7 @@ (make-node '##core#inline '("C_i_fixnum_arithmetic_shift") callargs) (make-node '##core#inline_allocate - (list "C_s_a_i_arithmetic_shift" 6) + (list "C_s_a_i_arithmetic_shift" 5) callargs) ) ) ) ) ) ) ) ) (rewrite '##sys#byte 17 2 "C_subbyte") diff --git a/chicken.h b/chicken.h index fdad916..96a03ea 100644 --- a/chicken.h +++ b/chicken.h @@ -464,7 +464,7 @@ static inline int isinf_ld (long double x) # define C_PAIR_TYPE (0x0300000000000000L) # define C_CLOSURE_TYPE (0x0400000000000000L | C_SPECIALBLOCK_BIT) # define C_FLONUM_TYPE (0x0500000000000000L | C_BYTEBLOCK_BIT | C_8ALIGN_BIT) -/* unused (0x0600000000000000L ...) */ +# define C_BIGNUM_TYPE (0x0600000000000000L) /* Just the wrapper */ # define C_PORT_TYPE (0x0700000000000000L | C_SPECIALBLOCK_BIT) # define C_STRUCTURE_TYPE (0x0800000000000000L) # define C_POINTER_TYPE (0x0900000000000000L | C_SPECIALBLOCK_BIT) @@ -494,7 +494,7 @@ static inline int isinf_ld (long double x) # else # define C_FLONUM_TYPE (0x05000000 | C_BYTEBLOCK_BIT | C_8ALIGN_BIT) # endif -/* unused (0x06000000 ...) */ +# define C_BIGNUM_TYPE (0x06000000) /* Just the wrapper */ # define C_PORT_TYPE (0x07000000 | C_SPECIALBLOCK_BIT) # define C_STRUCTURE_TYPE (0x08000000) # define C_POINTER_TYPE (0x09000000 | C_SPECIALBLOCK_BIT) @@ -526,11 +526,11 @@ static inline int isinf_ld (long double x) #define C_SIZEOF_STRUCTURE(n) ((n)+1) #define C_SIZEOF_CLOSURE(n) ((n)+1) #define C_SIZEOF_INTERNAL_BIGNUM_VECTOR(n) (C_SIZEOF_VECTOR((n)+1)) -#define C_internal_bignum_vector(b) (C_block_item(b,1)) +#define C_internal_bignum_vector(b) (C_block_item(b,0)) /* This is for convenience and allows flexibility in representation */ #define C_SIZEOF_FIX_BIGNUM C_SIZEOF_BIGNUM(1) -#define C_SIZEOF_BIGNUM_WRAPPER C_SIZEOF_STRUCTURE(2) +#define C_SIZEOF_BIGNUM_WRAPPER 2 #define C_SIZEOF_BIGNUM(n) (C_SIZEOF_INTERNAL_BIGNUM_VECTOR(n)+C_SIZEOF_BIGNUM_WRAPPER) /* Fixed size types have pre-computed header tags */ @@ -541,6 +541,7 @@ static inline int isinf_ld (long double x) #define C_TAGGED_POINTER_TAG (C_TAGGED_POINTER_TYPE | (C_SIZEOF_TAGGED_POINTER - 1)) #define C_SYMBOL_TAG (C_SYMBOL_TYPE | (C_SIZEOF_SYMBOL - 1)) #define C_FLONUM_TAG (C_FLONUM_TYPE | sizeof(double)) +#define C_BIGNUM_TAG (C_BIGNUM_TYPE | 1) #define C_STRUCTURE3_TAG (C_STRUCTURE_TYPE | 3) #define C_STRUCTURE2_TAG (C_STRUCTURE_TYPE | 2) @@ -1174,7 +1175,7 @@ typedef void (C_ccall *C_proc)(C_word, C_word *) C_noret; #define C_forwardedp(x) C_mk_bool((C_block_header(x) & C_GC_FORWARDING_BIT) != 0) #define C_immp(x) C_mk_bool(C_immediatep(x)) #define C_flonump(x) C_mk_bool(C_block_header(x) == C_FLONUM_TAG) -#define C_bignump(x) C_mk_bool(C_block_header(x) == C_STRUCTURE2_TAG && C_block_item(x, 0) == C_bignum_type_tag) +#define C_bignump(x) C_mk_bool(C_block_header(x) == C_BIGNUM_TAG) #define C_stringp(x) C_mk_bool(C_header_bits(x) == C_STRING_TYPE) #define C_symbolp(x) C_mk_bool(C_block_header(x) == C_SYMBOL_TAG) #define C_pairp(x) C_mk_bool(C_block_header(x) == C_PAIR_TAG) @@ -1735,7 +1736,6 @@ C_varextern C_TLS C_word *C_scratchspace_top, *C_scratchspace_limit, C_scratch_usage, - C_bignum_type_tag, C_ratnum_type_tag, C_cplxnum_type_tag; C_varextern C_TLS C_long @@ -2438,6 +2438,15 @@ C_inline C_word C_ratnum(C_word **ptr, C_word x, C_word y) return C_a_i_record3(ptr, 2, C_ratnum_type_tag, x, y); } +C_inline C_word C_a_i_bignum_wrapper(C_word **ptr, C_word vec) +{ + C_word *p = *ptr, *p0 = p; + + *(p++) = C_BIGNUM_TAG; + *(p++) = vec; + *ptr = p; + return (C_word)p0; +} /* Silly (this is not normalized) but in some cases needed internally */ C_inline C_word C_bignum0(C_word **ptr) @@ -2448,7 +2457,7 @@ C_inline C_word C_bignum0(C_word **ptr) *(p++) = 0; /* zero is always positive */ *ptr = p; - return C_a_i_record2(ptr, 2, C_bignum_type_tag, p0); + return C_a_i_bignum_wrapper(ptr, p0); } C_inline C_word C_bignum1(C_word **ptr, int negp, C_uword d1) @@ -2460,7 +2469,7 @@ C_inline C_word C_bignum1(C_word **ptr, int negp, C_uword d1) *(p++) = d1; *ptr = p; - return C_a_i_record2(ptr, 2, C_bignum_type_tag, p0); + return C_a_i_bignum_wrapper(ptr, p0); } /* Here d1, d2, ... are low to high (ie, little endian)! */ @@ -2474,14 +2483,12 @@ C_inline C_word C_bignum2(C_word **ptr, int negp, C_uword d1, C_uword d2) *(p++) = d2; *ptr = p; - return C_a_i_record2(ptr, 2, C_bignum_type_tag, p0); + return C_a_i_bignum_wrapper(ptr, p0); } C_inline C_word C_i_bignump(C_word x) { - return C_mk_bool(!C_immediatep(x) && - C_block_header(x) == C_STRUCTURE2_TAG && - C_block_item(x, 0) == C_bignum_type_tag); + return C_mk_bool(!C_immediatep(x) && C_block_header(x) == C_BIGNUM_TAG); } @@ -2749,9 +2756,8 @@ C_inline C_word basic_eqvp(C_word x, C_word y) ((C_block_header(x) == C_FLONUM_TAG && C_flonum_magnitude(x) == C_flonum_magnitude(y)) || - (C_block_header(x) == C_STRUCTURE2_TAG && - C_block_item(x, 0) == C_bignum_type_tag && - C_block_item(y, 0) == C_bignum_type_tag && + (C_block_header(x) == C_BIGNUM_TAG && + C_block_header(y) == C_BIGNUM_TAG && C_i_bignum_cmp(x, y) == C_fix(0))))); } @@ -2821,7 +2827,7 @@ C_inline C_word C_i_numberp(C_word x) return C_mk_bool((x & C_FIXNUM_BIT) || (!C_immediatep(x) && (C_block_header(x) == C_FLONUM_TAG || - C_truep(C_bignump(x)) || + C_block_header(x) == C_BIGNUM_TAG || (C_block_header(x) == C_STRUCTURE3_TAG && (C_block_item(x, 0) == C_ratnum_type_tag || C_block_item(x, 0) == C_cplxnum_type_tag))))); @@ -2833,7 +2839,7 @@ C_inline C_word C_i_realp(C_word x) return C_mk_bool((x & C_FIXNUM_BIT) || (!C_immediatep(x) && (C_block_header(x) == C_FLONUM_TAG || - C_truep(C_bignump(x)) || + C_block_header(x) == C_BIGNUM_TAG || (C_block_header(x) == C_STRUCTURE3_TAG && C_block_item(x, 0) == C_ratnum_type_tag)))); } @@ -2849,7 +2855,7 @@ C_inline C_word C_i_rationalp(C_word x) double n = C_flonum_magnitude(x); return C_mk_bool(!C_isinf(n) && !C_isnan(n)); } else { - return C_mk_bool(C_truep(C_bignump(x)) || + return C_mk_bool(C_block_header(x) == C_BIGNUM_TAG || (C_block_header(x) == C_STRUCTURE3_TAG && C_block_item(x, 0) == C_ratnum_type_tag)); } diff --git a/library.scm b/library.scm index 4674504..81622bb 100644 --- a/library.scm +++ b/library.scm @@ -984,7 +984,7 @@ EOF (import chicken.flonum) (define-inline (integer-negate x) - (##core#inline_allocate ("C_s_a_u_i_integer_negate" 6) x)) + (##core#inline_allocate ("C_s_a_u_i_integer_negate" 5) x)) (define = (##core#primitive "C_nequalp")) (define > (##core#primitive "C_greaterp")) @@ -1109,7 +1109,7 @@ EOF (define signum (##core#primitive "C_signum")) (define-inline (%flo->int x) - (##core#inline_allocate ("C_s_a_u_i_flo_to_int" 6) x)) + (##core#inline_allocate ("C_s_a_u_i_flo_to_int" 5) x)) (define (flonum->ratnum x) ;; Try to multiply by two until we reach an integer @@ -1160,20 +1160,20 @@ EOF (define bitwise-and (##core#primitive "C_bitwise_and")) (define bitwise-ior (##core#primitive "C_bitwise_ior")) (define bitwise-xor (##core#primitive "C_bitwise_xor")) -(define (bitwise-not n) (##core#inline_allocate ("C_s_a_i_bitwise_not" 6) n)) +(define (bitwise-not n) (##core#inline_allocate ("C_s_a_i_bitwise_not" 5) n)) (define (bit-set? n i) (##core#inline "C_i_bit_setp" n i)) (define (integer-length x) (##core#inline "C_i_integer_length" x)) (define (arithmetic-shift n m) - (##core#inline_allocate ("C_s_a_i_arithmetic_shift" 6) n m))) + (##core#inline_allocate ("C_s_a_i_arithmetic_shift" 5) n m))) (import chicken.bitwise) ;;; Basic arithmetic: (define-inline (%integer-gcd a b) - (##core#inline_allocate ("C_s_a_u_i_integer_gcd" 6) a b)) + (##core#inline_allocate ("C_s_a_u_i_integer_gcd" 5) a b)) -(define (abs x) (##core#inline_allocate ("C_s_a_i_abs" 10) x)) +(define (abs x) (##core#inline_allocate ("C_s_a_i_abs" 9) x)) (define (/ arg1 . args) (if (null? args) @@ -1186,7 +1186,7 @@ EOF (##sys#/-2 x (##sys#slot args 0))) ) ) ) ) (define-inline (%integer-quotient a b) - (##core#inline_allocate ("C_s_a_u_i_integer_quotient" 6) a b)) + (##core#inline_allocate ("C_s_a_u_i_integer_quotient" 5) a b)) (define (##sys#/-2 x y) (when (eq? y 0) @@ -1302,9 +1302,9 @@ EOF (exact->inexact result) result))) -(define (quotient a b) (##core#inline_allocate ("C_s_a_i_quotient" 6) a b)) -(define (remainder a b) (##core#inline_allocate ("C_s_a_i_remainder" 6) a b)) -(define (modulo a b) (##core#inline_allocate ("C_s_a_i_modulo" 6) a b)) +(define (quotient a b) (##core#inline_allocate ("C_s_a_i_quotient" 5) a b)) +(define (remainder a b) (##core#inline_allocate ("C_s_a_i_remainder" 5) a b)) +(define (modulo a b) (##core#inline_allocate ("C_s_a_i_modulo" 5) a b)) (define quotient&remainder (##core#primitive "C_quotient_and_remainder")) ;; Modulo's sign follows y (whereas remainder's sign follows x) @@ -1770,7 +1770,7 @@ EOF (end (or hashes digits))) (and-let* ((end) (num (##core#inline_allocate - ("C_s_a_i_digits_to_integer" 3) + ("C_s_a_i_digits_to_integer" 2) str start (car end) radix neg?))) (when hashes ; Eeewww. Feeling dirty yet? (set! seen-hashes? #t) @@ -1785,7 +1785,7 @@ EOF (end (scan-digits start))) (go-inexact!) (cons (##core#inline_allocate - ("C_s_a_i_digits_to_integer" 3) + ("C_s_a_i_digits_to_integer" 2) str start (car end) radix (eq? sign 'neg)) (cdr end))))))) (scan-decimal-tail ; The part after the decimal dot diff --git a/runtime.c b/runtime.c index ea06b47..ee84a20 100644 --- a/runtime.c +++ b/runtime.c @@ -340,7 +340,6 @@ C_TLS C_word *C_scratchspace_top, *C_scratchspace_limit, C_scratch_usage, - C_bignum_type_tag, C_ratnum_type_tag, C_cplxnum_type_tag; C_TLS C_long @@ -1126,7 +1125,6 @@ void initialize_symbol_table(void) for(i = 0; i < symbol_table->size; symbol_table->table[ i++ ] = C_SCHEME_END_OF_LIST); /* Obtain reference to hooks for later: */ - C_bignum_type_tag = C_intern2(C_heaptop, C_text("\003sysbignum")); C_ratnum_type_tag = C_intern2(C_heaptop, C_text("\003sysratnum")); C_cplxnum_type_tag = C_intern2(C_heaptop, C_text("\003syscplxnum")); core_provided_symbol = C_intern2(C_heaptop, C_text("\004coreprovided")); @@ -2688,7 +2686,7 @@ C_regparm C_word C_fcall C_static_bignum(C_word **ptr, int len, C_char *str) C_block_header_init(bigvec, C_STRING_TYPE | C_wordstobytes(size + 1)); C_set_block_item(bigvec, 0, negp); /* This needs to be allocated at ptr, not dptr, because GC moves type tag */ - bignum = C_a_i_record2(ptr, 2, C_bignum_type_tag, bigvec); + bignum = C_a_i_bignum_wrapper(ptr, bigvec); retval = str_to_bignum(bignum, str, str + len, 16); if (retval & C_FIXNUM_BIT) @@ -3609,7 +3607,6 @@ C_regparm void C_fcall C_reclaim(void *trampoline, C_word c) C_regparm void C_fcall mark_system_globals(void) { - mark(&C_bignum_type_tag); mark(&C_ratnum_type_tag); mark(&C_cplxnum_type_tag); mark(&core_provided_symbol); @@ -3944,7 +3941,6 @@ C_regparm void C_fcall C_rereclaim2(C_uword size, int relative_resize) C_regparm void C_fcall remark_system_globals(void) { - remark(&C_bignum_type_tag); remark(&C_ratnum_type_tag); remark(&C_cplxnum_type_tag); remark(&core_provided_symbol); @@ -5978,7 +5974,7 @@ C_regparm C_word C_fcall C_i_vector_set(C_word v, C_word i, C_word x) return C_SCHEME_UNDEFINED; } -/* This needs at most C_SIZEOF_FIX_BIGNUM + C_SIZEOF_STRUCTURE(3) so 10 words */ +/* This needs at most C_SIZEOF_FIX_BIGNUM + C_SIZEOF_STRUCTURE(3) so 9 words */ C_regparm C_word C_fcall C_s_a_i_abs(C_word **ptr, C_word n, C_word x) { @@ -6039,7 +6035,7 @@ C_regparm C_word C_fcall C_a_i_abs(C_word **a, int c, C_word x) /* The maximum this can allocate is a cplxnum which consists of two * ratnums that consist of 2 fix bignums each. So that's - * C_SIZEOF_STRUCTURE(3) * 3 + C_SIZEOF_FIX_BIGNUM * 4 = 36 words! + * C_SIZEOF_STRUCTURE(3) * 3 + C_SIZEOF_FIX_BIGNUM * 4 = 32 words! */ C_regparm C_word C_fcall C_s_a_i_negate(C_word **ptr, C_word n, C_word x) @@ -7765,7 +7761,7 @@ cplx_times(C_word **ptr, C_word rx, C_word ix, C_word ry, C_word iy) { /* Allocation here is kind of tricky: Each intermediate result can * be at most a ratnum consisting of two bignums (2 digits), so - * C_SIZEOF_STRUCTURE(3) + C_SIZEOF_BIGNUM(2) = 11 words + * C_SIZEOF_STRUCTURE(3) + C_SIZEOF_BIGNUM(2) = 10 words */ C_word ab[(C_SIZEOF_STRUCTURE(3) + C_SIZEOF_BIGNUM(2))*6], *a = ab, r1, r2, i1, i2, r, i; @@ -7796,7 +7792,7 @@ cplx_times(C_word **ptr, C_word rx, C_word ix, C_word ry, C_word iy) * number result, where both real and imag parts consist of ratnums. * The maximum size of those ratnums is if they consist of two bignums * from a fixnum multiplication (2 digits each), so we're looking at - * C_SIZEOF_STRUCTURE(3) * 3 + C_SIZEOF_BIGNUM(2) * 4 = 40 words! + * C_SIZEOF_STRUCTURE(3) * 3 + C_SIZEOF_BIGNUM(2) * 4 = 36 words! */ C_regparm C_word C_fcall C_s_a_i_times(C_word **ptr, C_word n, C_word x, C_word y) @@ -8241,7 +8237,7 @@ static C_word rat_plusmin_rat(C_word **ptr, C_word x, C_word y, integer_plusmin_ * number result, where both real and imag parts consist of ratnums. * The maximum size of those ratnums is if they consist of two "fix * bignums", so we're looking at C_SIZEOF_STRUCTURE(3) * 3 + - * C_SIZEOF_FIX_BIGNUM * 4 = 36 words! + * C_SIZEOF_FIX_BIGNUM * 4 = 32 words! */ C_regparm C_word C_fcall C_s_a_i_plus(C_word **ptr, C_word n, C_word x, C_word y) @@ -8503,7 +8499,7 @@ static C_word bignum_minus_unsigned(C_word **ptr, C_word x, C_word y) return C_bignum_simplify(res); } -/* Like C_s_a_i_plus, this needs at most 36 words */ +/* Like C_s_a_i_plus, this needs at most 32 words */ C_regparm C_word C_fcall C_s_a_i_minus(C_word **ptr, C_word n, C_word x, C_word y) { @@ -10309,7 +10305,7 @@ static C_word allocate_tmp_bignum(C_word size, C_word negp, C_word initp) 0, C_wordstobytes(C_unfix(size))); } - return C_a_i_record2(&mem, 2, C_bignum_type_tag, bigvec); + return C_a_i_bignum_wrapper(&mem, bigvec); } C_regparm C_word C_fcall @@ -10325,7 +10321,7 @@ C_allocate_scratch_bignum(C_word **ptr, C_word size, C_word negp, C_word initp) 0, C_wordstobytes(C_unfix(size))); } - big = C_a_i_record2(ptr, 2, C_bignum_type_tag, bigvec); + big = C_a_i_bignum_wrapper(ptr, bigvec); C_mutate_scratch_slot(&C_internal_bignum_vector(big), bigvec); return big; } diff --git a/types.db b/types.db index e6e31a6..0d970d5 100644 --- a/types.db +++ b/types.db @@ -317,18 +317,18 @@ ((float float) (float) (##core#inline_allocate ("C_a_i_flonum_plus" 4) #(1) #(2))) ((fixnum fixnum) (integer) - (##core#inline_allocate ("C_a_i_fixnum_plus" 6) #(1) #(2))) + (##core#inline_allocate ("C_a_i_fixnum_plus" 5) #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_plus" 6) #(1) #(2))) + (##core#inline_allocate ("C_s_a_u_i_integer_plus" 5) #(1) #(2))) ((* *) (number) - (##core#inline_allocate ("C_s_a_i_plus" 36) #(1) #(2)))) + (##core#inline_allocate ("C_s_a_i_plus" 32) #(1) #(2)))) (- (#(procedure #:clean #:enforce #:foldable) - (number #!rest number) number) - ((fixnum) (integer) (##core#inline_allocate ("C_a_i_fixnum_negate" 6) #(1))) + ((fixnum) (integer) (##core#inline_allocate ("C_a_i_fixnum_negate" 5) #(1))) ((integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_negate" 6) #(1))) + (##core#inline_allocate ("C_s_a_u_i_integer_negate" 5) #(1))) ((float) (float) (##core#inline_allocate ("C_a_i_flonum_negate" 4) #(1))) - ((*) (*) (##core#inline_allocate ("C_s_a_i_negate" 36) #(1))) + ((*) (*) (##core#inline_allocate ("C_s_a_i_negate" 32) #(1))) ((float fixnum) (float) (##core#inline_allocate ("C_a_i_flonum_difference" 4) @@ -342,11 +342,11 @@ ((float float) (float) (##core#inline_allocate ("C_a_i_flonum_difference" 4) #(1) #(2))) ((fixnum fixnum) (integer) - (##core#inline_allocate ("C_a_i_fixnum_difference" 6) #(1) #(2))) + (##core#inline_allocate ("C_a_i_fixnum_difference" 5) #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_minus" 6) #(1) #(2))) + (##core#inline_allocate ("C_s_a_u_i_integer_minus" 5) #(1) #(2))) ((* *) (number) - (##core#inline_allocate ("C_s_a_i_minus" 36) #(1) #(2)))) + (##core#inline_allocate ("C_s_a_i_minus" 32) #(1) #(2)))) (* (#(procedure #:clean #:enforce #:foldable) * (#!rest number) number) (() (fixnum) '1) @@ -370,11 +370,11 @@ ((float float) (float) (##core#inline_allocate ("C_a_i_flonum_times" 4) #(1) #(2))) ((fixnum fixnum) (integer) - (##core#inline_allocate ("C_a_i_fixnum_times" 7) #(1) #(2))) + (##core#inline_allocate ("C_a_i_fixnum_times" 5) #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_times" 7) #(1) #(2))) + (##core#inline_allocate ("C_s_a_u_i_integer_times" 5) #(1) #(2))) ((* *) (number) - (##core#inline_allocate ("C_s_a_i_times" 40) #(1) #(2)))) + (##core#inline_allocate ("C_s_a_i_times" 36) #(1) #(2)))) (/ (#(procedure #:clean #:enforce #:foldable) / (number #!rest number) number) ((float fixnum) (float) @@ -441,11 +441,11 @@ (##core#inline_allocate ("C_a_i_flonum_actual_quotient_checked" 4) #(1) #(2))) ((fixnum fixnum) (integer) - (##core#inline_allocate ("C_a_i_fixnum_quotient_checked" 6) + (##core#inline_allocate ("C_a_i_fixnum_quotient_checked" 5) #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_quotient" 6) #(1) #(2))) - ((* *) (##core#inline_allocate ("C_s_a_i_quotient" 6) #(1) #(2)))) + (##core#inline_allocate ("C_s_a_u_i_integer_quotient" 5) #(1) #(2))) + ((* *) (##core#inline_allocate ("C_s_a_i_quotient" 5) #(1) #(2)))) (remainder (#(procedure #:clean #:enforce #:foldable) remainder ((or integer float) (or integer float)) (or integer float)) ((float float) (float) @@ -455,8 +455,8 @@ ((fixnum fixnum) (fixnum) (##core#inline "C_i_fixnum_remainder_checked" #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_remainder" 6) #(1) #(2))) - ((* *) (##core#inline_allocate ("C_s_a_i_remainder" 6) #(1) #(2)))) + (##core#inline_allocate ("C_s_a_u_i_integer_remainder" 5) #(1) #(2))) + ((* *) (##core#inline_allocate ("C_s_a_i_remainder" 5) #(1) #(2)))) (quotient&remainder (#(procedure #:clean #:enforce #:foldable) quotient&remainder ((or integer float) (or integer float)) (or integer float) (or integer float)) ((float float) (float float) @@ -472,7 +472,7 @@ (let ((#(tmp1) #(1))) (let ((#(tmp2) #(2))) (##sys#values - (##core#inline_allocate ("C_a_i_fixnum_quotient_checked" 6) + (##core#inline_allocate ("C_a_i_fixnum_quotient_checked" 5) #(tmp1) #(tmp2)) (##core#inline "C_i_fixnum_remainder_checked" #(tmp1) #(tmp2)))))) @@ -490,15 +490,15 @@ ((fixnum fixnum) (fixnum) (##core#inline "C_fixnum_modulo" #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_modulo" 6) #(1) #(2))) - ((* *) (##core#inline_allocate ("C_s_a_i_modulo" 6) #(1) #(2)))) + (##core#inline_allocate ("C_s_a_u_i_integer_modulo" 5) #(1) #(2))) + ((* *) (##core#inline_allocate ("C_s_a_i_modulo" 5) #(1) #(2)))) (gcd (#(procedure #:clean #:enforce #:foldable) gcd (#!rest (or integer float)) (or integer float)) (() '0) ((fixnum fixnum) (fixnum) (chicken.fixnum#fxgcd #(1) #(2))) ((float float) (float) (chicken.flonum#fpgcd #(1) #(2))) ((integer integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_gcd" 6) #(1) #(2))) + (##core#inline_allocate ("C_s_a_u_i_integer_gcd" 5) #(1) #(2))) ((* *) (##sys#gcd #(1) #(2)))) (##sys#gcd (#(procedure #:clean #:enforce #:foldable) ##sys#gcd (number number) number)) @@ -510,12 +510,12 @@ (##sys#lcm (#(procedure #:clean #:enforce #:foldable) ##sys#lcm (number number) number)) (abs (#(procedure #:clean #:enforce #:foldable) abs (number) number) - ((fixnum) (integer) (##core#inline_allocate ("C_a_i_fixnum_abs" 6) #(1))) + ((fixnum) (integer) (##core#inline_allocate ("C_a_i_fixnum_abs" 5) #(1))) ((float) (float) (##core#inline_allocate ("C_a_i_flonum_abs" 4) #(1))) ((integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_abs" 6) #(1))) + (##core#inline_allocate ("C_s_a_u_i_integer_abs" 5) #(1))) ((*) (*) - (##core#inline_allocate ("C_s_a_i_abs" 10) #(1)))) + (##core#inline_allocate ("C_s_a_i_abs" 9) #(1)))) (floor (#(procedure #:clean #:enforce #:foldable) floor ((or integer ratnum float)) (or integer ratnum float)) ((fixnum) (fixnum) #(1)) @@ -818,11 +818,11 @@ ((cplxnum) (##sys#slot #(1) '2))) (magnitude (#(procedure #:clean #:enforce #:foldable) magnitude (number) number) - ((fixnum) (integer) (##core#inline_allocate ("C_a_i_fixnum_abs" 6) #(1))) - ((integer) (##core#inline_allocate ("C_s_a_u_i_integer_abs" 6) #(1))) + ((fixnum) (integer) (##core#inline_allocate ("C_a_i_fixnum_abs" 5) #(1))) + ((integer) (##core#inline_allocate ("C_s_a_u_i_integer_abs" 5) #(1))) ((float) (float) (##core#inline_allocate ("C_a_i_flonum_abs" 4) #(1))) (((or fixnum float bignum ratnum)) - (##core#inline_allocate ("C_s_a_i_abs" 10) #(1)))) + (##core#inline_allocate ("C_s_a_i_abs" 9) #(1)))) (angle (#(procedure #:clean #:enforce #:foldable) angle (number) float) ((float) (##core#inline_allocate ("C_a_i_flonum_atan2" 4) '0.0 #(1))) @@ -879,13 +879,13 @@ (add1 (#(procedure #:clean #:enforce #:foldable) add1 (number) number) ((fixnum) (integer) - (##core#inline_allocate ("C_a_i_fixnum_plus" 6) #(1) '1)) + (##core#inline_allocate ("C_a_i_fixnum_plus" 5) #(1) '1)) ((integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_plus" 6) #(1) '1)) + (##core#inline_allocate ("C_s_a_u_i_integer_plus" 5) #(1) '1)) ((float) (float) (##core#inline_allocate ("C_a_i_flonum_plus" 4) #(1) '1.0)) ((*) (number) - (##core#inline_allocate ("C_s_a_i_plus" 36) #(1) '1))) + (##core#inline_allocate ("C_s_a_i_plus" 32) #(1) '1))) (argc+argv (#(procedure #:clean) argc+argv () fixnum pointer)) (argv (#(procedure #:clean) argv () (list-of string))) @@ -897,7 +897,7 @@ (chicken-bitwise#arithmetic-shift (#(procedure #:clean #:enforce #:foldable) chicken.bitwise#arithmetic-shift (integer fixnum) integer) - ((* *) (##core#inline_allocate ("C_s_a_i_arithmetic_shift" 6) #(1) #(2)))) + ((* *) (##core#inline_allocate ("C_s_a_i_arithmetic_shift" 5) #(1) #(2)))) (exact-integer-nth-root (#(procedure #:clean #:enforce #:foldable) exact-integer-nth-root (integer integer) integer integer) ((integer integer) (##sys#exact-integer-nth-root/loc 'exact-integer-nth-root #(1) #(2)))) @@ -922,7 +922,7 @@ ((fixnum) (fixnum) #(1)) ((integer) #(1)) ((fixnum fixnum) (fixnum) (##core#inline "C_u_fixnum_and" #(1) #(2))) - ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_and" 6) #(1) #(2)))) + ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_and" 5) #(1) #(2)))) (chicken.bitwise#bitwise-ior (#(procedure #:clean #:enforce #:foldable) chicken.bitwise#bitwise-ior (#!rest integer) integer) @@ -930,7 +930,7 @@ ((fixnum) (fixnum) #(1)) ((integer) #(1)) ((fixnum fixnum) (fixnum) (##core#inline "C_u_fixnum_or" #(1) #(2))) - ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_ior" 6) #(1) #(2)))) + ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_ior" 5) #(1) #(2)))) (chicken.bitwise#bitwise-xor (#(procedure #:clean #:enforce #:foldable) chicken.bitwise#bitwise-xor (#!rest integer) integer) @@ -938,11 +938,11 @@ ((fixnum) (fixnum) #(1)) ((integer) #(1)) ((fixnum fixnum) (fixnum) (##core#inline "C_fixnum_xor" #(1) #(2))) - ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_xor" 6) #(1) #(2)))) + ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_xor" 5) #(1) #(2)))) (chicken.bitwise#bitwise-not (#(procedure #:clean #:enforce #:foldable) chicken.bitwise#bitwise-not (integer) integer) - ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_not" 6) #(1)))) + ((* *) (##core#inline_allocate ("C_s_a_i_bitwise_not" 5) #(1)))) (blob->string (#(procedure #:clean #:enforce) blob->string (blob) string)) @@ -1320,13 +1320,13 @@ (sub1 (#(procedure #:clean #:enforce #:foldable) sub1 (number) number) ((fixnum) (integer) - (##core#inline_allocate ("C_a_i_fixnum_difference" 6) #(1) '1)) + (##core#inline_allocate ("C_a_i_fixnum_difference" 5) #(1) '1)) ((integer) (integer) - (##core#inline_allocate ("C_s_a_u_i_integer_minus" 6) #(1) '1)) + (##core#inline_allocate ("C_s_a_u_i_integer_minus" 5) #(1) '1)) ((float) (float) (##core#inline_allocate ("C_a_i_flonum_difference" 4) #(1) '1.0)) ((*) (number) - (##core#inline_allocate ("C_s_a_i_minus" 36) #(1) '1))) + (##core#inline_allocate ("C_s_a_i_minus" 32) #(1) '1))) (subvector (forall (a) (#(procedure #:clean #:enforce) subvector ((vector-of a) fixnum #!optional fixnum) (vector-of a)))) (symbol-escape (#(procedure #:clean) symbol-escape (#!optional *) *)) -- 2.1.4