[PATCH] nptl: Don't madvise user provided stack

Szabolcs Nagy szabolcs.nagy@arm.com
Wed Jun 24 11:32:49 GMT 2020

The 06/24/2020 13:05, Florian Weimer wrote:
> * Szabolcs Nagy:
> > +  if (!pd->user_stack)
> > +    advise_stack_range (pd->stackblock, pd->stackblock_size, (uintptr_t) pd,
> > +			pd->guardsize);
> Could we still use MADV_FREE?
> But the patch as-is looks fine to me.

MADV_FREE has the same issue (it does
not zero the tags immediately, but may
do so later)

i hope users don't commonly use madvise
(or other mmap/munmap/.. operations) on
malloced memory, that is unlikely to be
supportable with memory tagging.

More information about the Libc-alpha mailing list