[LTP] [PATCH 2/2] syscalls/brk: limit the largest requesting memory to UINT_MAX

Cyril Hrubis chrubis@suse.cz
Mon Dec 11 16:48:06 CET 2017


Hi!
> sometimes(some platforms), sbrk(0) will return a huge address(e.g
> Beg_brk_val=94392102215680), it will lead to the request a huge
> memory by brk(size>1T) which beyonds most host memory size

I think that the code in the setup that determines the Max_brk_byte_size
does not make any sense to me, it seems to just multiply random value
(the initial break addres) by 4 and uses that as a base for increment. I
guess that it would be much better if we just choosen some multiple of
page size for the test.

Also the test should be running several iterations but we run only one
by default.

All in all I think that it would be much better if we rewrote the test
from scratch using the new test library instead of applying band aids
to problems that are broken by design.

In short, do you want to take on rewriting the test or should I do that?

-- 
Cyril Hrubis
chrubis@suse.cz


More information about the ltp mailing list