On Thu, 3 Jul 2025, Corinna Vinschen wrote:

> On Jul  2 10:37, Jeremy Drake via Cygwin-patches wrote:
> > On Wed, 2 Jul 2025, Corinna Vinschen wrote:
> >
> > > On Jun 30 10:11, Jeremy Drake via Cygwin-patches wrote:
> > > > On Mon, 30 Jun 2025, Corinna Vinschen wrote:
> > > >
> > > > > On Jun 27 10:34, Jeremy Drake via Cygwin-patches wrote:
> > > > > > On Fri, 27 Jun 2025, Corinna Vinschen wrote:
> > > > > >
> > > > > > > On Jun 26 13:31, Jeremy Drake via Cygwin-patches wrote:
> > > > > > > > BTW, I noticed while editing mingw/Makefile.am, shouldn't 
> > > > > > > > cygload have
> > > > > > > > -Wl,--disable-high-entropy-va in LDFLAGS?
> > > > > > >
> > > > > > > Why?
> > > > > >
> > > > > > With high-entropy-va, it has been observed that the PEB, TEB and 
> > > > > > stack can
> > > > > > happen to overlap with the cygheap
> > > > > > https://cygwin.com/pipermail/cygwin/2024-May/256000.html
> > > > >
> > > > > Yeah, but HEVA simply breaks fork.  We don't have to test this, 
> > > > > because
> > > > > it won't work and we don't do it.  You can set the PE flag, but than
> > > > > you're on your own.
> > > >
> > > > Outside of fork, is cygheap able to "relocate" in case the memory it 
> > > > would
> > > > like to occupy is already used?
> > >
> > > I don't think so, without checking and, well, fixing every pointer usage
> > > potentially pointing into the cygheap.  Even fhandlers have pointers to
> > > fhandlers...
> > >
> >
> > So shouldn't any user of the cygwin dll then need
> > -Wl,--disable-high-entropy-va to avoid the chance that Windows places its
> > structures where cygheap wants to be?
>
> -Wl,--disable-high-entropy-va isn't required because gcc doesn't enable
> it by default on Cygwin.
>
> If newer versions do, it's a bug in these gcc versions.

cygload is built in the mingw directory, with the mingw cross toolchain.

Reply via email to