Re: [HACKERS] patch for memory overrun on Linux(i386)

From: The Hermit Hacker <scrappy(at)hub(dot)org>
To: ocie(at)paracel(dot)com
Cc: Maurice Gittens <mgittens(at)david(dot)gits(dot)nl>, hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] patch for memory overrun on Linux(i386)
Date: 1998-03-22 01:26:18
Message-ID: Pine.BSF.3.96.980321212527.324F-100000@thelab.hub.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sat, 21 Mar 1998 ocie(at)paracel(dot)com wrote:

> Maurice Gittens wrote:
> >
> > Hi,
> >
> > It turns of that one of the bugs I detected with Electric Fence
> > is caused by an assumption that memory return by palloc and malloc
> > is aligned on 8 bytes boundaries (double alignment).
> > Adjusting this to correspond with the reality of the malloc
> > implementation on my pentium based linux box fixes the problem.
> >
> > The following simple patch to include/utils/memutils.h
> > will fix the problem.
> >
> > 85c85
> > < #if ! defined(sco)
> > ---
> > > #if ! defined(sco) && !defined(linux)
>
> I may be off on this one, but I thought that memory alignment was a
> cpu, and not necessarily an OS issue. I.E. Solaris x86 might show the
> "misalignment", while Linux Alpha would not.

Ummm...you are comparing both two different CPU and two different
OSs here...more appropriately to your argument would be Linux/x86 vs
Linux/Alpha, wouldn't it? If it was a CPU issue...?

Marc G. Fournier
Systems Administrator @ hub.org
primary: scrappy(at)hub(dot)org secondary: scrappy(at){freebsd|postgresql}.org

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message The Hermit Hacker 1998-03-22 01:33:16 Re: sched_yield()
Previous Message ocie 1998-03-22 00:37:34 Re: [HACKERS] patch for memory overrun on Linux(i386)