mirror of
https://github.com/ashinn/chibi-scheme.git
synced 2025-07-08 21:47:33 +02:00
adding bignum support for 64-bit machines
using gcc 128-bit register extensions to hold the result of multpliying two 64-bit integers.
This commit is contained in:
parent
91efc04852
commit
445f8e9fa4
1 changed files with 7 additions and 0 deletions
|
@ -5,8 +5,15 @@
|
|||
#ifndef SEXP_BIGNUM_H
|
||||
#define SEXP_BIGNUM_H
|
||||
|
||||
#if (SEXP_64_BIT)
|
||||
typedef unsigned int uint128_t __attribute__((mode(TI)));
|
||||
typedef int sint128_t __attribute__((mode(TI)));
|
||||
typedef uint128_t sexp_luint_t;
|
||||
typedef sint128_t sexp_lsint_t;
|
||||
#else
|
||||
typedef unsigned long long sexp_luint_t;
|
||||
typedef long long sexp_lsint_t;
|
||||
#endif
|
||||
|
||||
sexp_sint_t sexp_bignum_compare (sexp a, sexp b);
|
||||
sexp sexp_compare (sexp ctx, sexp a, sexp b);
|
||||
|
|
Loading…
Add table
Reference in a new issue