make GMPless version compile.
git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@1696 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
parent
23757e5563
commit
47a621d236
@ -10,8 +10,12 @@
|
|||||||
* *
|
* *
|
||||||
* File: absmi.c *
|
* File: absmi.c *
|
||||||
* comments: Portable abstract machine interpreter *
|
* comments: Portable abstract machine interpreter *
|
||||||
* Last rev: $Date: 2006-09-20 20:03:51 $,$Author: vsc $ *
|
* Last rev: $Date: 2006-09-28 16:15:54 $,$Author: vsc $ *
|
||||||
* $Log: not supported by cvs2svn $
|
* $Log: not supported by cvs2svn $
|
||||||
|
* Revision 1.204 2006/09/20 20:03:51 vsc
|
||||||
|
* improve indexing on floats
|
||||||
|
* fix sending large lists to DB
|
||||||
|
*
|
||||||
* Revision 1.203 2006/08/07 18:51:44 vsc
|
* Revision 1.203 2006/08/07 18:51:44 vsc
|
||||||
* fix garbage collector not to try to garbage collect when we ask for large
|
* fix garbage collector not to try to garbage collect when we ask for large
|
||||||
* chunks of stack in a single go.
|
* chunks of stack in a single go.
|
||||||
@ -8305,9 +8309,7 @@ Yap_absmi(int inp)
|
|||||||
if (IsExtensionFunctor(f0)) {
|
if (IsExtensionFunctor(f0)) {
|
||||||
switch ((CELL)f0) {
|
switch ((CELL)f0) {
|
||||||
case (CELL)FunctorLongInt:
|
case (CELL)FunctorLongInt:
|
||||||
#ifdef USE_GMP
|
|
||||||
case (CELL)FunctorBigInt:
|
case (CELL)FunctorBigInt:
|
||||||
#endif
|
|
||||||
PREG = NEXTOP(PREG, xF);
|
PREG = NEXTOP(PREG, xF);
|
||||||
GONext();
|
GONext();
|
||||||
default:
|
default:
|
||||||
|
12
H/TermExt.h
12
H/TermExt.h
@ -10,7 +10,7 @@
|
|||||||
* File: TermExt.h *
|
* File: TermExt.h *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Extensions to standard terms for YAP *
|
* comments: Extensions to standard terms for YAP *
|
||||||
* version: $Id: TermExt.h,v 1.11 2006-08-23 12:12:14 vsc Exp $ *
|
* version: $Id: TermExt.h,v 1.12 2006-09-28 16:15:54 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
#ifdef USE_SYSTEM_MALLOC
|
#ifdef USE_SYSTEM_MALLOC
|
||||||
@ -267,9 +267,11 @@ IsLongIntTerm (Term t)
|
|||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
|
typedef UInt mp_limb_t;
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
UInt _size, _mp_alloc;
|
int _mp_size, _mp_alloc;
|
||||||
void *_mp_d;
|
mp_limb_t *_mp_d;
|
||||||
} MP_INT;
|
} MP_INT;
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
@ -501,9 +503,11 @@ unify_extension (Functor f, CELL d0, CELL * pt0, CELL d1)
|
|||||||
return (d0 == d1);
|
return (d0 == d1);
|
||||||
case long_int_e:
|
case long_int_e:
|
||||||
return (pt0[1] == RepAppl (d1)[1]);
|
return (pt0[1] == RepAppl (d1)[1]);
|
||||||
#ifdef USE_GMP
|
|
||||||
case big_int_e:
|
case big_int_e:
|
||||||
|
#ifdef USE_GMP
|
||||||
return (mpz_cmp (Yap_BigIntOfTerm (d0), Yap_BigIntOfTerm (d1)) == 0);
|
return (mpz_cmp (Yap_BigIntOfTerm (d0), Yap_BigIntOfTerm (d1)) == 0);
|
||||||
|
#else
|
||||||
|
return d0 == d1;
|
||||||
#endif /* USE_GMP */
|
#endif /* USE_GMP */
|
||||||
case double_e:
|
case double_e:
|
||||||
{
|
{
|
||||||
|
@ -1,10 +1,13 @@
|
|||||||
|
|
||||||
|
|
||||||
|
:- multifile user:file_search_path/2.
|
||||||
|
|
||||||
|
:- add_to_path('.').
|
||||||
|
|
||||||
:- use_module(library(swi)).
|
:- use_module(library(swi)).
|
||||||
|
|
||||||
:- yap_flag(unknown,error).
|
:- yap_flag(unknown,error).
|
||||||
|
|
||||||
library_directory('yap_extras').
|
|
||||||
|
|
||||||
:- include('chr_swi_bootstrap.pl').
|
:- include('chr_swi_bootstrap.pl').
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user