Open ohofox opened 2 years ago
what are you talking about? 15392894357503 byte of memory? that would be 15392894 GB ... impossible :)
The size mapped is defined by HIGH_SHADOW_SIZE, from line https://github.com/AFLplusplus/qemuafl/blob/master/qemuafl/asan-giovese.h#L45. Could anyone help to explain why it is so large?
https://github.com/google/sanitizers/wiki/AddressSanitizerAlgorithm
Because it is a shadow memory
Thank you for the explanation. So the shadow memory are calculated by the following equation:
Shadow = (Mem >> 3) + 0x7fff8000;
And the range of shadow memory are divided into 2 parts, LowMem and HighMem. And HIGH_SHADOW_SIZE
is the size of HighShadow [0x02008fff7000, 0x10007fff7fff] .
[0x10007fff8000, 0x7fffffffffff] | HighMem [0x02008fff7000, 0x10007fff7fff] | HighShadow [0x00008fff7000, 0x02008fff6fff] | ShadowGap [0x00007fff8000, 0x00008fff6fff] | LowShadow [0x000000000000, 0x00007fff7fff] | LowMem
Back to this assertion error, the mmap is mapping HighShadow but failed. Should I change any configuration of my CentOS system? Or maybe it is an flaw of mmap function on CentOS system? Could anyone offer help?
I don't really know what CentOS does, but you can check with /proc/
Thank you for this great project! Currently I'm trying to use afl++ in qemu mode. Everything is OK when I run it on Ubuntu 20.04. However, when I run qemu mode on my CentOS server, and when I set the AFL_USE_QASAN environment option to turn on QASAN module, the assertion error occurs. The assert triggered on line https://github.com/AFLplusplus/qemuafl/blob/master/qemuafl/asan-giovese-inl.h#L110 This is the configuration of my CentOS server:
Also I write a simple mmap test program, the same assertion error occurs
I am sure that there is enough memory space, but why the mmap with the options failed with
Cannot allocate memory
on the CentOS system? Thanks a lot for any suggestions.