Message-ID: <3EF5F855.7D32C992@yahoo.com> Date: Sun, 22 Jun 2003 14:41:25 -0400 From: CBFalconer Organization: Ched Research X-Mailer: Mozilla 4.75 [en] (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: djgpp-workers AT delorie DOT com Subject: Re: memalign hooks (was: LIBM patch for GCC 3.3 - math changes) References: <200306201334 DOT h5KDYMWU012441 AT speedy DOT ludd DOT luth DOT se> <000e01c337aa$7b238800$0100a8c0 AT acp42g> <3EF3E113 DOT 1C8C9C2B AT yahoo DOT com> <9743-Sat21Jun2003123351+0300-eliz AT elta DOT co DOT il> <3EF449C0 DOT 8C8A0C61 AT yahoo DOT com> <3791-Sun22Jun2003063027+0300-eliz AT elta DOT co DOT il> <3EF53044 DOT CDEA5BA1 AT yahoo DOT com> <3405-Sun22Jun2003201552+0300-eliz AT elta DOT co DOT il> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Reply-To: djgpp-workers AT delorie DOT com Eli Zaretskii wrote: > > From: CBFalconer > > > ... snip ... > > > I think memalign should also fail for alignment parameter < ALIGN > > value (i.e. 8 at present). > > IMHO, it should behave in a way that is compatible with other > implementations. Could someone please look on their nearest Unix or > GNU/Linux box and see what does memalign there do for such small > alignment parameters? (Sorry, no time to do this myself.) On reconsidering it will suffice to force the alignment with if (alignment < ALIGN) alignment = ALIGN; after the power of two check. -- Chuck F (cbfalconer AT yahoo DOT com) (cbfalconer AT worldnet DOT att DOT net) Available for consulting/temporary embedded and systems. USE worldnet address!