On Fri, Apr 3, 2020 at 11:59 PM Ian Lance Taylor via Gcc-patches <gcc-patches@gcc.gnu.org> wrote: > > The split-stack code invokes mmap and munmap with a limited amount of > stack space. That is fine when the functions just make a system call, > but it's not fine when programs use LD_PRELOAD or linker tricks to add > hooks to mmap/munmap. Those hooks may use too much stack space, > leading to an obscure program crash. > > Avoid that at least on GNU/Linux by calling __mmap/__munmap instead. > > Bootstrapped and ran Go and split-stack tests on x86_64-pc-linux-gnu. > Committed to mainline.
This causes references to GLIBC_PRIVATE exported symbols which is highly undesirable for system integrators (no ABI stability is guaranteed for those). I opened the regression PR94513 for this. Richard. > Ian > > 2020-04-03 Ian Lance Taylor <i...@golang.org> > > * generic-morestack.c: On GNU/Linux use __mmap/__munmap rather > than mmap/munmap, to avoid hooks.