]> 4ch.mooo.com Git - 16.git/blobdiff - src/fmemtest.c
16_in improvements and added debugging stuff
[16.git] / src / fmemtest.c
old mode 100644 (file)
new mode 100755 (executable)
index 8d9ca6b..2cdbadd
@@ -20,6 +20,9 @@
  *
  */
 #include <stdio.h>
+#include "src/lib/16_head.h"
+#include "src/lib/16_ca.h"
+#include "src/lib/16_mm.h"
 #include "src/lib/types.h"
 
 void
@@ -28,8 +31,17 @@ main(int argc, char *argv[])
        int x=420;
        int huge *ptr=&x;
        int *ptr0=&x;
+       //void __based(__self) *pee;
+       memptr pee;
+       void __near *npee;
+       void __far *fpee;
+       void *dpee;
+       __segment segu;
        //word csw=0,dsw=0,esw=0,ssw=0,ipw=0;
 
+       _nheapgrow();
+       _fheapgrow();
+       _heapgrow();
        //ptr=&x;
        printf("&main()=%Fp\n", *argv[0]);
        printf("ptr0=%Fp\n", ptr0);
@@ -55,4 +67,12 @@ main(int argc, char *argv[])
        //printf("cs=%u\n", csw);
        //printf("ds=%u\n", dsw);
        //printf("es=%u\n", esw);
+       printf("memavl=%u\n", _memavl());
+       printf("size of based pee~=%u   %FP\n", _bmsize(segu, pee), pee);
+       printf("size of default pee~=%u %FP\n", _msize(dpee), dpee);
+       printf("size of near pee~=%u    %FP\n", _nmsize(npee), npee);
+       printf("size of far pee~=%u     %FP\n", _fmsize(fpee), fpee);
+       printf("pee=%Fp\n", pee);
+       printf("npee=%Fp\n", npee);
+       printf("&main()=%Fp\n", *argv[0]);
 }