Home
last modified time | relevance | path

Searched refs:BcNum (Results 1 – 10 of 10) sorted by relevance

/freebsd-13.1/contrib/bc/include/
H A Dnum.h548 void bc_num_add(BcNum *a, BcNum *b, BcNum *c, size_t scale);
557 void bc_num_sub(BcNum *a, BcNum *b, BcNum *c, size_t scale);
566 void bc_num_mul(BcNum *a, BcNum *b, BcNum *c, size_t scale);
575 void bc_num_div(BcNum *a, BcNum *b, BcNum *c, size_t scale);
584 void bc_num_mod(BcNum *a, BcNum *b, BcNum *c, size_t scale);
593 void bc_num_pow(BcNum *a, BcNum *b, BcNum *c, size_t scale);
603 void bc_num_places(BcNum *a, BcNum *b, BcNum *c, size_t scale);
612 void bc_num_lshift(BcNum *a, BcNum *b, BcNum *c, size_t scale);
621 void bc_num_rshift(BcNum *a, BcNum *b, BcNum *c, size_t scale);
641 void bc_num_divmod(BcNum *a, BcNum *b, BcNum *c, BcNum *d, size_t scale);
[all …]
H A Dprogram.h123 BcNum strmb;
128 BcNum last;
266 typedef void (*BcProgramUnary)(BcResult *r, BcNum *n);
357 void bc_program_negate(BcResult *r, BcNum *n);
364 void bc_program_not(BcResult *r, BcNum *n);
373 void bc_program_trunc(BcResult *r, BcNum *n);
H A Dvm.h577 BcNum zero;
582 BcNum one;
585 BcNum max;
588 BcNum max2;
H A Dlang.h367 BcNum num;
472 BcNum n;
H A Dlibrary.h210 #define BC_NUM(c, n) ((BcNum*) bc_vec_item(&(c)->nums, (n).i))
/freebsd-13.1/contrib/bc/src/
H A Dnum.c51 static void bc_num_m(BcNum *a, BcNum *b, BcNum *restrict c, size_t scale);
1733 static void bc_num_r(BcNum *a, BcNum *b, BcNum *restrict c, in bc_num_r()
3039 BcNum *n = (BcNum*) num; in bc_num_free()
3516 void bc_num_add(BcNum *a, BcNum *b, BcNum *c, size_t scale) { in bc_num_add()
3522 void bc_num_sub(BcNum *a, BcNum *b, BcNum *c, size_t scale) { in bc_num_sub()
3528 void bc_num_mul(BcNum *a, BcNum *b, BcNum *c, size_t scale) { in bc_num_mul()
3534 void bc_num_div(BcNum *a, BcNum *b, BcNum *c, size_t scale) { in bc_num_div()
3540 void bc_num_mod(BcNum *a, BcNum *b, BcNum *c, size_t scale) { in bc_num_mod()
3546 void bc_num_pow(BcNum *a, BcNum *b, BcNum *c, size_t scale) { in bc_num_pow()
3713 void bc_num_divmod(BcNum *a, BcNum *b, BcNum *c, BcNum *d, size_t scale) { in bc_num_divmod()
[all …]
H A Dlibrary.c324 BcNum n; in bcl_num_create()
441 BcNum *n = (BcNum*) num; in bcl_num_destruct()
576 BcNum n; in bcl_bigdig2num()
610 BcNum c; in bcl_binary()
691 BcNum b; in bcl_sqrt()
799 BcNum d; in bcl_modexp()
904 BcNum n; in bcl_parse()
995 BcNum b; in bcl_irand()
1084 BcNum n; in bcl_frand()
1155 BcNum b; in bcl_ifrand()
[all …]
H A Dprogram.c289 BcNum *n; in bc_program_num()
875 BcNum *n; in bc_program_print()
967 BcNum *num; in bc_program_unary()
1082 BcNum *n; in bc_program_assignStr()
1524 BcNum *num; in bc_program_pushArray()
1566 BcNum *num; in bc_program_incdec()
1811 BcNum *num; in bc_program_builtin()
2015 BcNum num; in bc_program_asciifyNum()
2061 BcNum *n; in bc_program_asciify()
2112 BcNum *n; in bc_program_printStream()
[all …]
H A Dlang.c173 if (nums) bc_vec_init(a, sizeof(BcNum), BC_DTOR_NUM); in bc_array_init()
201 BcNum *dnum, *snum; in bc_array_copy()
207 if (BC_PROG_STR(snum)) memcpy(dnum, snum, sizeof(BcNum)); in bc_array_copy()
221 if (a->size == sizeof(BcNum) && a->dtor == BC_DTOR_NUM) { in bc_array_expand()
225 BcNum *n = bc_vec_pushEmpty(a); in bc_array_expand()
283 memcpy(&d->d.n, &src->d.n, sizeof(BcNum)); in bc_result_copy()
/freebsd-13.1/contrib/bc/
H A DNEWS.md508 Third, `bc` tries to reuse `BcNum`'s (the internal representation of
509 arbitary-precision numbers). If a `BcNum` has the default capacity of
511 to a list of available `BcNum`'s. And then, when a `BcNum` is allocated with a
512 capacity of `BC_NUM_DEF_SIZE` and any `BcNum`'s exist on the list of reusable
543 especially with regard to reusing `BcNum`'s. One was putting `BcNum`'s into
545 worse than `bc` did in `2.7.2`. Another was putting any `BcNum` on the reuse
546 list that had a capacity of `BC_NUM_DEF_SIZE * 2` and reusing them for `BcNum`'s
549 using `strace`, a bunch more `brk` calls showed up.) Just reusing `BcNum`'s that