made allocation chunk size dependant on pointer size
This commit is contained in:
parent
35023ba945
commit
f21378d696
2 changed files with 11 additions and 10 deletions
|
@ -185,17 +185,14 @@ static int
|
||||||
cmp_ext(e1, e2)
|
cmp_ext(e1, e2)
|
||||||
struct EXTEND *e1, *e2;
|
struct EXTEND *e1, *e2;
|
||||||
{
|
{
|
||||||
int sign = e1->sign ? -1 : 1;
|
struct EXTEND tmp;
|
||||||
|
|
||||||
if (e1->sign > e2->sign) return -1;
|
e2->sign = ! e2->sign;
|
||||||
if (e1->sign < e2->sign) return 1;
|
add_ext(e1, e2, &tmp);
|
||||||
if (e1->exp < e2->exp) return -sign;
|
e2->sign = ! e2->sign;
|
||||||
if (e1->exp > e2->exp) return sign;
|
if (tmp.m1 == 0 && tmp.m2 == 0) return 0;
|
||||||
if (e1->m1 < e2->m1) return -sign;
|
if (tmp->sign) return -1;
|
||||||
if (e1->m1 > e2->m1) return sign;
|
return 1;
|
||||||
if (e1->m2 < e2->m2) return -sign;
|
|
||||||
if (e1->m2 > e2->m2) return sign;
|
|
||||||
return 0;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static
|
static
|
||||||
|
|
|
@ -14,7 +14,11 @@
|
||||||
#define ptrint long
|
#define ptrint long
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if EM_PSIZE == 2
|
||||||
|
#define BRKSIZE 1024
|
||||||
|
#else
|
||||||
#define BRKSIZE 4096
|
#define BRKSIZE 4096
|
||||||
|
#endif
|
||||||
#define PTRSIZE sizeof(char *)
|
#define PTRSIZE sizeof(char *)
|
||||||
#define Align(x,a) (((x) + (a - 1)) & ~(a - 1))
|
#define Align(x,a) (((x) + (a - 1)) & ~(a - 1))
|
||||||
#define NextSlot(p) (* (char **) ((p) - PTRSIZE))
|
#define NextSlot(p) (* (char **) ((p) - PTRSIZE))
|
||||||
|
|
Loading…
Reference in a new issue