Hi, Valdis Klētnieks, Mulyadi Santosa
Thanks to both of you.
>> Just pseudo idea, if this is in user space, try to: allocate many blocks
>> of memory using malloc, each having different size, keep the returned
>> pointer, then randomly free() some of them, then malloc() again with
>> different size
>That will cause userspace malloc() to have fragmentation, but as far
>as the kernel is concerned it's all just 4K pages of user memory.
>Causing physical memory fragmentation will require abusing the kernel
>memory allocators such as kmalloc() and vmalloc() and friends.
I fully understand what you mean by "cause userspace malloc() to have fragmentation".
Thanks to both of you.
>> Just pseudo idea, if this is in user space, try to: allocate many blocks
>> of memory using malloc, each having different size, keep the returned
>> pointer, then randomly free() some of them, then malloc() again with
>> different size
>That will cause userspace malloc() to have fragmentation, but as far
>as the kernel is concerned it's all just 4K pages of user memory.
>Causing physical memory fragmentation will require abusing the kernel
>memory allocators such as kmalloc() and vmalloc() and friends.
I fully understand what you mean by "cause userspace malloc() to have fragmentation".
I am sorry, maybe I mislead you. I just want there are no available free high order blocks(i.e
32KB,64KB, 128KB and etc) on the platform.
How can I more efficiently and automatically achieve this goal?
_______________________________________________ Kernelnewbies mailing list Kernelnewbies@xxxxxxxxxxxxxxxxx https://lists.kernelnewbies.org/mailman/listinfo/kernelnewbies