Seeking advice on writing a test [Re: [patch] Fix BZ 20419 -- stack overflow with huge PT_NOTE segment]
Siddhesh Poyarekar
siddhesh@gotplt.org
Mon May 7 09:47:00 GMT 2018
On 05/06/2018 11:47 PM, Paul Pluzhnikov wrote:
> Assuming we do want to protect against it (which is easy to do, so why
> wouldn't we?), I am having hard time coming up with a reasonable test
> strategy.
>
> I could write a little helper program to generate such a binary "by hand"
> (i.e. without compiler/linker involvement). Is there a simpler strategy?
Unless the helper is more generally applicable (i.e. you have a bigger
test plan) I'd say it is overkill for just this bug. That is, it would
be nice to have such a helper but shouldn't be necessary for this bug.
BTW on a related note, given the recent malloc tcache improvements how
much does this alloca even save in terms of performance? If it is not
very performance sensitive, it might make sense to just use malloc and
not bother with alloca at all.
Siddhesh
More information about the Libc-alpha
mailing list