Path: utzoo!utgpu!jarvis.csri.toronto.edu!rutgers!mailrus!csd4.csd.uwm.edu!cs.utexas.edu!uunet!mcvax!sunic!ifi!tor!edb_tom
From: edb_tom@tor.nhh.no (Tom Ivar Helbekkmo)
Newsgroups: comp.os.minix
Subject: Disk performance, and a compiler bug
Message-ID: <64@tor.nhh.no>
Date: 19 Aug 89 17:10:59 GMT
Organization: NHH, Bergen, Norway
Lines: 44

First:  I've applied Bruce Evans' changes to fs/buf.h and fs/cache.c,
delaying write for all but superblock and map blocks, and flushing all
dirty blocks on a device when one needs flushing.  Sure works -- when
I copy large files around, I now get about 30 - 35 percent increased
throughput!  Also, I can tell by the sound of the hard disk that it's
being treated much better -- it used to thrash the heads around quite a
bit, which it now does to a much smaller extent.  Thanks, Bruce!

Second:  I've come across a bug in the compiler (the 1.2 version for the
PC).  If I compile this little C program:

#include 

int    main (argc, argv)
int    arc;
char **argv;
{
    long  a = 0L;
    char *p = "Some string";

    a += 0xFF & *p++;
    printf("a is now %ld\n", a);

    exit(0);
}

the compile fails with the "Error: Bombed out of codegen" message.  When
a is an int it works OK.  Casting, as in

	a += (long) (0xFF & *p++);

does not fix it, neither does parenthesizing.  Changing the line to

	a = a + 0xFF & *p++;

works OK.  Since I don't have source code for the compiler, I can't look
into the matter that way -- so I'll leave it up to someone who can... 

-tih

---------------------------------------------------------------------------
Internet:     | Tom Ivar Helbekkmo, NHH, Bergen, Norway
EAN:       | Phone: +47-5-959205(W), +47-5-960561(P)
BITNET:         | MS-DOS and OS/2?  Just say NO!      :-)