fix machine-dependant #if's
This commit is contained in:
parent
df039a267d
commit
0caa529e0a
4 changed files with 9 additions and 5 deletions
|
@ -1,5 +1,9 @@
|
||||||
/* $Header$ */
|
/* $Header$ */
|
||||||
|
|
||||||
|
#if !defined(EM_WSIZE)
|
||||||
|
#define EM_WSIZE _EM_WSIZE
|
||||||
|
#endif
|
||||||
|
|
||||||
_randomi()
|
_randomi()
|
||||||
{
|
{
|
||||||
int i;
|
int i;
|
||||||
|
|
|
@ -44,7 +44,7 @@ _penvp
|
||||||
loi EM_PSIZE
|
loi EM_PSIZE
|
||||||
lae _penvp
|
lae _penvp
|
||||||
sti EM_PSIZE
|
sti EM_PSIZE
|
||||||
#if unix && ! (em22 || em24 || em44)
|
#if __unix && ! (__em22 || __em24 || __em44)
|
||||||
lpi $_ctch_
|
lpi $_ctch_
|
||||||
sig
|
sig
|
||||||
asp EM_PSIZE
|
asp EM_PSIZE
|
||||||
|
@ -61,7 +61,7 @@ _penvp
|
||||||
cal $exit
|
cal $exit
|
||||||
end
|
end
|
||||||
|
|
||||||
#if unix && ! (em22 || em24 || em44)
|
#if __unix && ! (__em22 || __em24 || __em44)
|
||||||
exp $_ctch_
|
exp $_ctch_
|
||||||
pro $_ctch_,0
|
pro $_ctch_,0
|
||||||
lol 0
|
lol 0
|
||||||
|
|
|
@ -8,13 +8,13 @@
|
||||||
#define ASSERT(b) /* empty */
|
#define ASSERT(b) /* empty */
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if EM_WSIZE == EM_PSIZE
|
#if _EM_WSIZE == _EM_PSIZE
|
||||||
#define ptrint int
|
#define ptrint int
|
||||||
#else
|
#else
|
||||||
#define ptrint long
|
#define ptrint long
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if EM_PSIZE == 2
|
#if _EM_PSIZE == 2
|
||||||
#define BRKSIZE 1024
|
#define BRKSIZE 1024
|
||||||
#else
|
#else
|
||||||
#define BRKSIZE 4096
|
#define BRKSIZE 4096
|
||||||
|
|
|
@ -4,7 +4,7 @@ static long seed = 1L;
|
||||||
int rand()
|
int rand()
|
||||||
{
|
{
|
||||||
seed = (1103515245L * seed + 12345) & 0x7FFFFFFF;
|
seed = (1103515245L * seed + 12345) & 0x7FFFFFFF;
|
||||||
#if EM_WSIZE == 4
|
#if _EM_WSIZE == 4
|
||||||
return (int) seed;
|
return (int) seed;
|
||||||
#else
|
#else
|
||||||
return ((int)(seed >> 8) & 0x7FFF);
|
return ((int)(seed >> 8) & 0x7FFF);
|
||||||
|
|
Loading…
Reference in a new issue