compile under sun's cc.
git-svn-id: https://yap.svn.sf.net/svnroot/yap/trunk@165 b08c6af1-5177-4d33-ba66-4b1c6b8b522a
This commit is contained in:
parent
34010ba45a
commit
2eb822797e
10
C/sysbits.c
10
C/sysbits.c
@ -367,7 +367,7 @@ void cputime_interval(Int *now,Int *interval)
|
|||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(__sun__) && defined(__svr4__)
|
#if defined(__sun__) && (defined(__svr4__) || defined(__SVR4))
|
||||||
|
|
||||||
#if HAVE_LIMITS_H
|
#if HAVE_LIMITS_H
|
||||||
#include <limits.h>
|
#include <limits.h>
|
||||||
@ -812,7 +812,7 @@ p_srandom (void)
|
|||||||
STATIC_PROTO (void InitSignals, (void));
|
STATIC_PROTO (void InitSignals, (void));
|
||||||
|
|
||||||
|
|
||||||
#if defined(__svr4__)
|
#if (defined(__svr4__) || defined(__SVR4))
|
||||||
|
|
||||||
#if HAVE_SIGINFO_H
|
#if HAVE_SIGINFO_H
|
||||||
#include <siginfo.h>
|
#include <siginfo.h>
|
||||||
@ -1200,7 +1200,7 @@ ProcessSIGINT(void)
|
|||||||
that might be
|
that might be
|
||||||
*/
|
*/
|
||||||
static RETSIGTYPE
|
static RETSIGTYPE
|
||||||
#if defined(__svr4__)
|
#if (defined(__svr4__) || defined(__SVR4))
|
||||||
HandleSIGINT (int sig, siginfo_t *x, ucontext_t *y)
|
HandleSIGINT (int sig, siginfo_t *x, ucontext_t *y)
|
||||||
#else
|
#else
|
||||||
HandleSIGINT (int sig)
|
HandleSIGINT (int sig)
|
||||||
@ -1238,7 +1238,7 @@ HandleSIGINT (int sig)
|
|||||||
#if !defined(_WIN32)
|
#if !defined(_WIN32)
|
||||||
/* this routine is called if the system activated the alarm */
|
/* this routine is called if the system activated the alarm */
|
||||||
static RETSIGTYPE
|
static RETSIGTYPE
|
||||||
#if defined(__svr4__)
|
#if (defined(__svr4__) || defined(__SVR4))
|
||||||
HandleALRM (int s, siginfo_t *x, ucontext_t *y)
|
HandleALRM (int s, siginfo_t *x, ucontext_t *y)
|
||||||
#else
|
#else
|
||||||
HandleALRM(int s)
|
HandleALRM(int s)
|
||||||
@ -1259,7 +1259,7 @@ HandleALRM(int s)
|
|||||||
|
|
||||||
#if !defined(LIGHT) && !_MSC_VER && !defined(__MINGW32__) && !defined(LIGHT)
|
#if !defined(LIGHT) && !_MSC_VER && !defined(__MINGW32__) && !defined(LIGHT)
|
||||||
static RETSIGTYPE
|
static RETSIGTYPE
|
||||||
#if defined(__svr4__)
|
#if (defined(__svr4__) || defined(__SVR4))
|
||||||
ReceiveSignal (int s, siginfo_t *x, ucontext_t *y)
|
ReceiveSignal (int s, siginfo_t *x, ucontext_t *y)
|
||||||
#else
|
#else
|
||||||
ReceiveSignal (int s)
|
ReceiveSignal (int s)
|
||||||
|
@ -47,9 +47,10 @@ rational_tree_loop(CELL *pt0, CELL *pt0_end, CELL **to_visit0)
|
|||||||
|
|
||||||
loop:
|
loop:
|
||||||
while (pt0 < pt0_end) {
|
while (pt0 < pt0_end) {
|
||||||
register CELL *ptd0 = ++pt0;
|
register CELL *ptd0;
|
||||||
register CELL d0;
|
register CELL d0;
|
||||||
|
|
||||||
|
ptd0 = ++pt0;
|
||||||
pt0 = ptd0;
|
pt0 = ptd0;
|
||||||
d0 = *ptd0;
|
d0 = *ptd0;
|
||||||
deref_head(d0, rtree_loop_unk);
|
deref_head(d0, rtree_loop_unk);
|
||||||
@ -139,11 +140,13 @@ OCUnify_complex(register CELL *pt0, register CELL *pt0_end,
|
|||||||
)
|
)
|
||||||
{
|
{
|
||||||
|
|
||||||
register CELL **to_visit = (CELL **) H;
|
register CELL **to_visit;
|
||||||
#if SHADOW_HB
|
#if SHADOW_HB
|
||||||
register CELL *HBREG = HB;
|
register CELL *HBREG;
|
||||||
|
HBREG = HB;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
to_visit = (CELL **) H;
|
||||||
loop:
|
loop:
|
||||||
while (pt0 < pt0_end) {
|
while (pt0 < pt0_end) {
|
||||||
register CELL *ptd0 = ++pt0;
|
register CELL *ptd0 = ++pt0;
|
||||||
|
@ -53,9 +53,9 @@
|
|||||||
#define LOAD_DL 1
|
#define LOAD_DL 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef sparc
|
#if defined(sparc) || defined(__sparc)
|
||||||
#undef NO_DYN
|
#undef NO_DYN
|
||||||
#ifndef __svr4__
|
#if (!defined(__svr4__) && !defined(__SVR4))
|
||||||
#define A_OUT 1
|
#define A_OUT 1
|
||||||
#else
|
#else
|
||||||
#ifdef SIMICS
|
#ifdef SIMICS
|
||||||
@ -66,7 +66,7 @@
|
|||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef __svr4__
|
#if (defined(__svr4__) || defined(__SVR4))
|
||||||
#ifndef SIMICS
|
#ifndef SIMICS
|
||||||
#ifdef NO_DYN
|
#ifdef NO_DYN
|
||||||
#undef NO_DYN
|
#undef NO_DYN
|
||||||
|
4
H/Regs.h
4
H/Regs.h
@ -10,7 +10,7 @@
|
|||||||
* File: Regs.h *
|
* File: Regs.h *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: YAP abstract machine registers *
|
* comments: YAP abstract machine registers *
|
||||||
* version: $Id: Regs.h,v 1.4 2001-06-27 15:46:26 vsc Exp $ *
|
* version: $Id: Regs.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
|
|
||||||
@ -25,7 +25,7 @@
|
|||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef sparc
|
#if defined(sparc) || defined(__sparc)
|
||||||
#undef PUSH_REGS
|
#undef PUSH_REGS
|
||||||
#undef PUSH_X
|
#undef PUSH_X
|
||||||
#endif
|
#endif
|
||||||
|
@ -28,7 +28,7 @@ static char SccsId[] = "%W% %G%";
|
|||||||
*/
|
*/
|
||||||
#ifdef __GNUC__
|
#ifdef __GNUC__
|
||||||
|
|
||||||
#ifdef sparc
|
#if defined(sparc) || defined(__sparc)
|
||||||
#define SHADOW_P 1
|
#define SHADOW_P 1
|
||||||
#define SHADOW_Y 1
|
#define SHADOW_Y 1
|
||||||
#define SHADOW_S 1
|
#define SHADOW_S 1
|
||||||
|
@ -102,7 +102,7 @@ void STD_PROTO(YAP_InitHeap, (void *));
|
|||||||
|
|
||||||
#elif USE_SBRK
|
#elif USE_SBRK
|
||||||
|
|
||||||
#ifdef __svr4__
|
#if (defined(__svr4__) || defined(__SVR4))
|
||||||
#include <unistd.h>
|
#include <unistd.h>
|
||||||
#elif sun
|
#elif sun
|
||||||
#include <sys/types.h>
|
#include <sys/types.h>
|
||||||
|
@ -371,7 +371,9 @@ Int unify(Term t0, Term t1)
|
|||||||
return(TRUE);
|
return(TRUE);
|
||||||
} else {
|
} else {
|
||||||
while(TR != TR0) {
|
while(TR != TR0) {
|
||||||
CELL *p = (CELL *)TrailTerm(--TR);
|
CELL *p;
|
||||||
|
--TR;
|
||||||
|
p = (CELL *)TrailTerm(TR);
|
||||||
RESET_VARIABLE(p);
|
RESET_VARIABLE(p);
|
||||||
}
|
}
|
||||||
return(FALSE);
|
return(FALSE);
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Tag Scheme for machines with 24 bits adresses (m68000) *
|
* comments: Tag Scheme for machines with 24 bits adresses (m68000) *
|
||||||
* version: $Id: Tags_24bits.h,v 1.4 2001-08-09 14:01:19 vsc Exp $ *
|
* version: $Id: Tags_24bits.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/* Version for 24 bit addresses (68000)
|
/* Version for 24 bit addresses (68000)
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
||||||
* version: $Id: Tags_32LowTag.h,v 1.4 2001-08-09 14:01:19 vsc Exp $ *
|
* version: $Id: Tags_32LowTag.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
#define TAG_LOW_BITS_32 1
|
#define TAG_LOW_BITS_32 1
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
||||||
* version: $Id: Tags_32Ops.h,v 1.4 2001-08-09 14:01:19 vsc Exp $ *
|
* version: $Id: Tags_32Ops.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
||||||
* version: $Id: Tags_32bits.h,v 1.4 2001-08-09 14:01:19 vsc Exp $ *
|
* version: $Id: Tags_32bits.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/* Original version for 32 bit addresses machines,
|
/* Original version for 32 bit addresses machines,
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
||||||
* version: $Id: Tags_64bits.h,v 1.4 2001-08-09 14:01:19 vsc Exp $ *
|
* version: $Id: Tags_64bits.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
#define TAG_64BITS 1
|
#define TAG_64BITS 1
|
||||||
|
@ -17,7 +17,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.4 2001-08-09 14:01:19 vsc Exp $ *
|
* version: $Id: TermExt.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
#if USE_OFFSETS
|
#if USE_OFFSETS
|
||||||
|
@ -17,7 +17,7 @@
|
|||||||
* File: Yap.h.m4 *
|
* File: Yap.h.m4 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: main header file for YAP *
|
* comments: main header file for YAP *
|
||||||
* version: $Id: Yap.h,v 1.4 2001-08-09 14:01:20 vsc Exp $ *
|
* version: $Id: Yap.h,v 1.5 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
@ -171,7 +171,7 @@
|
|||||||
/* */ typedef unsigned long int UInt;
|
/* */ typedef unsigned long int UInt;
|
||||||
|
|
||||||
#else
|
#else
|
||||||
error Yap require integer types of the same size as a pointer
|
# error Yap require integer types of the same size as a pointer
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if SIZEOF_SHORT_INT==2
|
#if SIZEOF_SHORT_INT==2
|
||||||
@ -179,7 +179,7 @@
|
|||||||
/* */ typedef unsigned short int UShort;
|
/* */ typedef unsigned short int UShort;
|
||||||
|
|
||||||
#else
|
#else
|
||||||
error Yap requires integer types half the size of a pointer
|
# error Yap requires integer types half the size of a pointer
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#elif SIZEOF_INT_P==8
|
#elif SIZEOF_INT_P==8
|
||||||
@ -197,7 +197,7 @@
|
|||||||
/* */ typedef unsigned long long int UInt;
|
/* */ typedef unsigned long long int UInt;
|
||||||
|
|
||||||
# else
|
# else
|
||||||
error Yap requires integer types of the same size as a pointer
|
# error Yap requires integer types of the same size as a pointer
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
# if SIZEOF_SHORT_INT==4
|
# if SIZEOF_SHORT_INT==4
|
||||||
@ -209,12 +209,12 @@
|
|||||||
/* */ typedef short int UShort;
|
/* */ typedef short int UShort;
|
||||||
|
|
||||||
# else
|
# else
|
||||||
error Yap requires integer types half the size of a pointer
|
# error Yap requires integer types half the size of a pointer
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
#else
|
#else
|
||||||
|
|
||||||
error Yap requires pointers of size 4 or 8
|
# error Yap requires pointers of size 4 or 8
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
||||||
* version: $Id: Tags_32Ops.h.m4,v 1.1.1.1 2001-04-09 19:53:46 vsc Exp $ *
|
* version: $Id: Tags_32Ops.h.m4,v 1.2 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -71,7 +71,7 @@ are now 1 in compound terms and structures.
|
|||||||
This allows optimisation of switch_list
|
This allows optimisation of switch_list
|
||||||
|
|
||||||
*/
|
*/
|
||||||
#if defined(i386) || defined(sparc) || defined(_POWER)
|
#if defined(i386) || defined(sparc) || defined(_POWER) || defined(__sparc)
|
||||||
#define UNIQUE_TAG_FOR_PAIRS 1
|
#define UNIQUE_TAG_FOR_PAIRS 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
* Last rev: December 90 *
|
* Last rev: December 90 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
* comments: Original Tag Scheme for machines with 32 bits adresses *
|
||||||
* version: $Id: Tags_64ops.h.m4,v 1.1.1.1 2001-04-09 19:53:46 vsc Exp $ *
|
* version: $Id: Tags_64ops.h.m4,v 1.2 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -69,7 +69,7 @@ are now 1 in compound terms and structures.
|
|||||||
This allows optimisation of switch_list
|
This allows optimisation of switch_list
|
||||||
|
|
||||||
*/
|
*/
|
||||||
#if defined(i386) || defined(sparc) || defined(_POWER)
|
#if defined(i386) || defined(sparc) || defined(_POWER) || defined(__sparc)
|
||||||
#define UNIQUE_TAG_FOR_PAIRS 1
|
#define UNIQUE_TAG_FOR_PAIRS 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
* File: Yap.h.m4 *
|
* File: Yap.h.m4 *
|
||||||
* mods: *
|
* mods: *
|
||||||
* comments: main header file for YAP *
|
* comments: main header file for YAP *
|
||||||
* version: $Id: Yap.h.m4,v 1.11 2001-09-24 14:06:06 vsc Exp $ *
|
* version: $Id: Yap.h.m4,v 1.12 2001-09-24 18:07:16 vsc Exp $ *
|
||||||
*************************************************************************/
|
*************************************************************************/
|
||||||
|
|
||||||
#include "config.h"
|
#include "config.h"
|
||||||
@ -315,7 +315,7 @@ typedef CELL Term;
|
|||||||
#ifdef i386
|
#ifdef i386
|
||||||
#include <x86_locks.h>
|
#include <x86_locks.h>
|
||||||
#endif
|
#endif
|
||||||
#ifdef sparc
|
#if defined(sparc) || defined(__sparc)
|
||||||
#include <sparc_locks.h>
|
#include <sparc_locks.h>
|
||||||
#endif
|
#endif
|
||||||
#ifdef mips
|
#ifdef mips
|
||||||
@ -567,7 +567,7 @@ and RefOfTerm(t) : Term -> DBRef = ...
|
|||||||
incompatible with the high tag scheme. Linux-ELF also does not like
|
incompatible with the high tag scheme. Linux-ELF also does not like
|
||||||
if you place things in the lower addresses (power to the libc people).
|
if you place things in the lower addresses (power to the libc people).
|
||||||
*/
|
*/
|
||||||
#if (defined(_AIX) || defined(_WIN32) || defined(sparc) || defined(mips) || defined(__FreeBSD__) || defined(_POWER) || defined(IN_SECOND_QUADRANT)) && !defined(TABLING)
|
#if (defined(_AIX) || defined(_WIN32) || defined(sparc) || defined(__sparc) || defined(mips) || defined(__FreeBSD__) || defined(_POWER) || defined(IN_SECOND_QUADRANT)) && !defined(TABLING)
|
||||||
#define USE_LOW32_TAGS 1
|
#define USE_LOW32_TAGS 1
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user