From: sparky4 Date: Thu, 30 Jul 2015 20:37:43 +0000 (-0500) Subject: hmmm X-Git-Url: http://4ch.mooo.com/gitweb/?a=commitdiff_plain;h=62f639bbb2ed0d2d1a4340ab9a7d87f537fc4eda;p=16.git hmmm modified: 16.exe modified: bakapi.exe modified: exmmtest.exe modified: fmemtest.exe modified: fontgfx.exe modified: fonttest.exe modified: inputest.exe modified: makefile modified: maptest.exe modified: palettec.exe modified: pcxtest.exe modified: scroll.exe modified: sega.exe modified: sountest.exe modified: src/sega.c modified: test.exe modified: test2.exe modified: tsthimem.exe --- diff --git a/16.exe b/16.exe index 93f6c82f..bb1cde6c 100644 Binary files a/16.exe and b/16.exe differ diff --git a/bakapi.exe b/bakapi.exe index 2936de4f..250b110f 100644 Binary files a/bakapi.exe and b/bakapi.exe differ diff --git a/exmmtest.exe b/exmmtest.exe index 94efc0f8..964ca886 100644 Binary files a/exmmtest.exe and b/exmmtest.exe differ diff --git a/fmemtest.exe b/fmemtest.exe index cfaeb569..a5a7ab9a 100644 Binary files a/fmemtest.exe and b/fmemtest.exe differ diff --git a/fontgfx.exe b/fontgfx.exe index 559ba884..b4df19bc 100644 Binary files a/fontgfx.exe and b/fontgfx.exe differ diff --git a/fonttest.exe b/fonttest.exe index f3807cef..4de46206 100644 Binary files a/fonttest.exe and b/fonttest.exe differ diff --git a/inputest.exe b/inputest.exe index 5bc4678f..c69afba7 100644 Binary files a/inputest.exe and b/inputest.exe differ diff --git a/makefile b/makefile index 44984d64..4c32f61e 100644 --- a/makefile +++ b/makefile @@ -22,12 +22,11 @@ WCPULIB=$(SRCLIB)wcpu$(DIRSEP) 16FLAGS=-fh=16.hed BAKAPIFLAGS=-fh=bakapi.hed -SEGAFLAGS=-0 -d2 -lr $(OFLAGS) SFLAGS=-k32768#51200#49152 DFLAGS=-DTARGET_MSDOS=16 -DMSDOS=1 $(SFLAGS) ZFLAGS=-zk0 -zq# -zu -zm# -zc# -zdp# -zp16 -zq -CFLAGS=-ei -wo -x -r -mc +CFLAGS=-mc -ei -wo -x# -r OFLAGS=-ot -ox -ob -oh -or -om -ol# -ol+ FLAGS=-0 -d2 -lr $(OFLAGS) $(CFLAGS) $(DFLAGS) $(ZFLAGS) @@ -59,9 +58,9 @@ scroll.$(OBJ): $(SRC)scroll.c wcl $(FLAGS) -c $(SRC)scroll.c sega.exe: sega.$(OBJ) - wcl $(SEGAFLAGS) sega.$(OBJ) + wcl $(FLAGS) sega.$(OBJ) sega.$(OBJ): $(SRC)sega.c - wcl $(SEGAFLAGS) -c $(SRC)sega.c + wcl $(FLAGS) -c $(SRC)sega.c test.exe: test.$(OBJ) gfx.lib wcl $(FLAGS) test.$(OBJ) gfx.lib diff --git a/maptest.exe b/maptest.exe index bca3fdb9..d36848a2 100644 Binary files a/maptest.exe and b/maptest.exe differ diff --git a/palettec.exe b/palettec.exe index 70ad36f8..7f2d2708 100644 Binary files a/palettec.exe and b/palettec.exe differ diff --git a/pcxtest.exe b/pcxtest.exe index 9bbdaeec..9b7e5e98 100644 Binary files a/pcxtest.exe and b/pcxtest.exe differ diff --git a/scroll.exe b/scroll.exe index 31111a65..e10bed35 100644 Binary files a/scroll.exe and b/scroll.exe differ diff --git a/sega.exe b/sega.exe index 4ec072e2..b0ad2b8b 100644 Binary files a/sega.exe and b/sega.exe differ diff --git a/sountest.exe b/sountest.exe index b5a81f32..254b8fa2 100644 Binary files a/sountest.exe and b/sountest.exe differ diff --git a/src/sega.c b/src/sega.c index d4d04d27..27c74b2d 100644 --- a/src/sega.c +++ b/src/sega.c @@ -10,12 +10,13 @@ struct list { void main(int argc, char *argv[]) { int i; - __segment segu; + __segment segu; + void __based(__self) *pee; struct list __based(segu) *head; struct list __based(segu) *p; /* allocate based heap */ - segu = _bheapseg( 1024 ); + segu = _bheapseg( 65536 ); if( segu == _NULLSEG ) { printf( "Unable to allocate based heap\n" ); exit( 1 ); @@ -23,7 +24,7 @@ void main(int argc, char *argv[]) /* create a linked list in the based heap */ head = 0; - for( i = 1; i < 10; i++ ) { + for( i = 1; i < 4096; i++ ) { p = _bmalloc( segu, sizeof( struct list ) ); if( p == _NULLOFF ) { printf( "_bmalloc failed\n" ); @@ -36,9 +37,13 @@ void main(int argc, char *argv[]) /* traverse the linked list, printing out values */ for( p = head; p != 0; p = p->next ) { - printf("Segu = %04X %FP", p, p); - printf( " Value = %d\n", p->value ); + if(p==head || p->next==0 || p==pee){ + printf("Segu = %04X", p); printf( " Value = %d\n", p->value ); + } } + + printf("program=%FP\n", *argv[0]); + printf("seg=%04X\n", segu); /* free all the elements of the linked list */ for( ; p = head; ) { @@ -47,6 +52,4 @@ void main(int argc, char *argv[]) } /* free the based heap */ _bfreeseg( segu ); - printf("program=%P\n", *argv[0]); - printf("seg=%P\n", segu); } diff --git a/test.exe b/test.exe index 4a0080c5..1c800062 100644 Binary files a/test.exe and b/test.exe differ diff --git a/test2.exe b/test2.exe index 8e07f0b2..17b2e157 100644 Binary files a/test2.exe and b/test2.exe differ diff --git a/tsthimem.exe b/tsthimem.exe index 4489e404..0011eeee 100644 Binary files a/tsthimem.exe and b/tsthimem.exe differ