From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from felloff.net ([94.135.131.69]) by ttr; Tue Apr 29 16:11:41 EDT 2014 Message-ID: List-ID: <9front.9front.org> X-Glyph: ➈ X-Bullshit: anonymous compliant shader dependency layer Date: Tue, 29 Apr 2014 22:11:37 +0200 From: cinap_lenrek@felloff.net To: 9front@9front.org Subject: Re: [9front] cwfs fsmempercent In-Reply-To: <03F1455E-0438-49E0-A5F2-D3F76BBE0CA8@ar.aichi-u.ac.jp> MIME-Version: 1.0 Content-Type: text/plain; charset="US-ASCII" Content-Transfer-Encoding: 7bit that might work. i havnt tried it. you need to be carefull with overflows as 2GB becomes negative with signed 32 bit ints. if(dsize >= 0x80000000UL){ /* for sanity, overflow */ werrstr("invalid allocation size"); return nil; } the only routine that does substantial allocation is iobufinit() in cwfs/malloc.c. as far as i can see, this memory is never freed, so we might just remove the define: all.h:13: #define malloc(n) ialloc(n, 0) and provide our own ialloc() that just uses brk(). -- cinap